ModuleNotFoundError: No module named 'nltk' after installation on a Windows 10 + Ubuntu 18.04 machine


Answer: 1

12 hours ago

I've been trying to solve this problem for the last couple of hours, without luck.

I'm trying to run a python program that I wrote on my Windows 10 machine on my other machine that has a dual-boot of Windows 10 and Ubuntu 18.04 "Bionic Beaver", if I recall correctly.

This error comes up everytime I run the code using spyder/pycharm, even after trying a lot of suggestions that I found on here and on stackoverflow:

ModuleNotFoundError: No module named 'nltk'

So far, I have tried downloading nltk:

1) using their own website's instructions: sudo pip install -U nltk

2) using anaconda3: conda install -c anaconda nltk

First, it used to show me some permission denied problems, because I guess the anaconda3 folder was set to 'access only', but I used: sudo chown -R usr foldername to solve that.

I even tried updating pip, anaconda and nltk, without positive results.

Could this be connected to the fact of a dual-boot machine? Or maybe the fact that anaconda is installed?

Weird thing is, when I type python in the terminal and then import nltk it shows >> , and no error message. This is really frustrating and I hope someone can help me out!

Added by: Mr. Monroe Hill

Answer: 2

8 hours ago

It's probably related to using conda. I used it for a very short time, and it was easier for me to just blow it out and install things manually.

converted from a comment because OP said it solved their problem

Popular Search

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 1 2 3 4 5 6 7 8 9