seq2seq-chatbot icon indicating copy to clipboard operation
seq2seq-chatbot copied to clipboard

Error: No module named twitter

Open andrewt3000 opened this issue 6 years ago • 3 comments

python main_simple_seq2seq.py Traceback (most recent call last): File "main_simple_seq2seq.py", line 18, in from data.twitter import data ImportError: No module named twitter

andrewt3000 avatar May 28 '18 01:05 andrewt3000

I see this is a closed issue, but I am python noob, and knowing where the files are doesn't help me. You would think it would search from current directory and find it??? Should there be a change to an init file? Can this be resolved with a change to the code or config?

https://github.com/tensorlayer/seq2seq-chatbot/issues/3

andrewt3000 avatar May 28 '18 02:05 andrewt3000

It appears that you need to make sure you are using python3. By default, Ubuntu runs python v2 when you just call python. To get this app to run correctly, try python3 main.py with your arguments.

To make sure all of your modules are installed you will need to install them using pip3.

JDSlimz avatar Oct 08 '18 18:10 JDSlimz

For python2, you will need to do this instead:

import imp
data = imp.load_source('data.twitter.data', 'data/twitter/data.py')

pskrunner14 avatar Oct 08 '18 18:10 pskrunner14