[Tutor] ImportError: No module named numarray

Kent Johnson kent37 at tds.net
Mon Jul 11 13:13:25 CEST 2005


enas khalil wrote:
> when i write a code to import some module like the following :
>  
>  
> from nltk.probability import ConditionalFreqDist
>  
> I got the error :
>  
> Traceback (most recent call last):
>   File "C:\Python24\toky.py", line 1, in -toplevel-
>     from nltk.probability import ConditionalFreqDist
>   File "C:\Python24\Lib\site-packages\nltk\probability.py", line 56, in 
> -toplevel-
>     import types, math, numarray
> ImportError: No module named numarray
> 
>     can you please tell me the cause 

nltk is looking for a module called numarray that is not part of the standard Python distribution. Do you have numarray installed? Look for C:\Python24\Lib\site-packages\numarray. If you don't have it then download numarray from C:\Python24\Lib\site-packages\numarray and install it according to the instructions.

Kent



More information about the Tutor mailing list