Roman
Roman

Reputation: 131228

ImportError: cannot import name NumpyTest

I am trying to read a *.wav file using scipy. I do it in the following way:

import scipy.io
x = scipy.io.wavfile.read('/usr/share/sounds/purple/receive.wav')

As a result I get the following error message:

Traceback (most recent call last):
  File "test3.py", line 1, in <module>
    import scipy.io
  File "/usr/lib/python2.5/site-packages/scipy/io/__init__.py", line 23, in <module>
    from numpy.testing import NumpyTest
ImportError: cannot import name NumpyTest

Does anybody know why scipy cannot import NumpyTest and how it can be fixed?

Upvotes: 0

Views: 2595

Answers (2)

Alok Singhal
Alok Singhal

Reputation: 96201

Looks like you have upgraded your numpy version but haven't installed a corresponding scipy version.

Upvotes: 1

Kimvais
Kimvais

Reputation: 39588

Do you have numpy installed? The package is most likely called numpy or python-numpy if you are running Linux

If your OS package manager does not have numpy package, download it from here

Upvotes: 0

Related Questions