matplotlib

mpl_toolkits.mplot3d.art3d.zalpha

mpl_toolkits.mplot3d.art3d.zalpha(colors, zs)

Modify the alphas of the color list according to depth