Import NLTK : no module NLTK corpus

Viewed 31028

I have installed NLTK. Here's an image of the installation log.

enter image description here

When i use import nltk i get an error:

"No module named NLTK.corpus"

Here is a screenshot.

enter image description here

What could be the cause?

5 Answers

If you find (Import NLTK : no module NLTK corpus) that type of error .

Make sure your saved file not be the name like (nltk.py). so just rename your file name (like rename nltk.py to example.py ) or something else:

I hope it will help you.

thanks

If you has using PyCharm IDE, you should have install NLTK from the IDE's own tools [File -> Settings -> Projetct Interpreter -> Install (button '+') -> Install Package].

Related