sph_harm was removed as it's deprecated: https://docs.scipy.org/doc/scipy/reference/generated/scipy.special.sph_harm.html Try to implement sph_harm_y: https://docs.scipy.org/doc//scipy/reference/generated/scipy.special.sph_harm_y.html