Improve error message for index dimension
Improve error message for index dimension

Since `x.ndim` can be `0`, but not accepted, this PR excludes the case explicitly in the error message.

I have wasted some time trying to figure out why `x.ndim > 2` but it turns out that `x.ndim` was actually `0`.

I haven't checked for other places this change applies nor unittests which asserts on the error message.
perimosocordiae/scipy,andyfaff/scipy,anntzer/scipy,ilayn/scipy,rgommers/scipy,ilayn/scipy,anntzer/scipy,matthew-brett/scipy,ilayn/scipy,matthew-brett/scipy,zerothi/scipy,zerothi/scipy,ilayn/scipy,vigna/scipy,WarrenWeckesser/scipy,grlee77/scipy,WarrenWeckesser/scipy,mdhaber/scipy,matthew-brett/scipy,andyfaff/scipy,WarrenWeckesser/scipy,Eric89GXL/scipy,WarrenWeckesser/scipy,endolith/scipy,e-q/scipy,rgommers/scipy,Eric89GXL/scipy,WarrenWeckesser/scipy,scipy/scipy,vigna/scipy,e-q/scipy,mdhaber/scipy,andyfaff/scipy,mdhaber/scipy,Stefan-Endres/scipy,endolith/scipy,Eric89GXL/scipy,scipy/scipy,anntzer/scipy,scipy/scipy,Stefan-Endres/scipy,rgommers/scipy,endolith/scipy,grlee77/scipy,andyfaff/scipy,Eric89GXL/scipy,tylerjereddy/scipy,mdhaber/scipy,Eric89GXL/scipy,rgommers/scipy,Stefan-Endres/scipy,anntzer/scipy,matthew-brett/scipy,e-q/scipy,Stefan-Endres/scipy,rgommers/scipy,perimosocordiae/scipy,e-q/scipy,endolith/scipy,perimosocordiae/scipy,Eric89GXL/scipy,andyfaff/scipy,grlee77/scipy,perimosocordiae/scipy,grlee77/scipy,perimosocordiae/scipy,grlee77/scipy,tylerjereddy/scipy,scipy/scipy,zerothi/scipy,endolith/scipy,e-q/scipy,WarrenWeckesser/scipy,ilayn/scipy,matthew-brett/scipy,tylerjereddy/scipy,zerothi/scipy,anntzer/scipy,scipy/scipy,Stefan-Endres/scipy,scipy/scipy,mdhaber/scipy,vigna/scipy,anntzer/scipy,ilayn/scipy,zerothi/scipy,vigna/scipy,tylerjereddy/scipy,endolith/scipy,perimosocordiae/scipy,andyfaff/scipy,zerothi/scipy,Stefan-Endres/scipy,mdhaber/scipy,tylerjereddy/scipy,vigna/scipy