jax
jax copied to clipboard
Fix to make `jax.scipy.special.sph_harm` to be close to `scipy.special.sph_harm` for multiple theta or phi
Fixes #20769
I'm having trouble evaluating whether this change is correct. This is part due to lack of test coverage, and part due to lack of documentation: it's just not clear to me what set of input shapes should be considered valid here, and so whether changing range(len(n)) to range(len(phi)) is correct or not is difficult to discern.
To be clear, this state of things precedes this PR, and is one reason we've previously flagged this API as a candidate for removal (see https://jax.readthedocs.io/en/latest/jep/18137-numpy-scipy-scope.html#scipy-special).