Issue
Forgive me but I'm new to python. I've installed a package (theano) using
conda install theano
, and when I type conda list
, the package exists
However, when I enter the python interpreter by running python
, and try to import it with import theano
, I get an error: "no module named theano", and when I list all python modules, theano doesn't exist.
What am I missing?
Solution
Probably due to the fact you have multiply python envs installed in your computer.
when you do which python
you will probably get the native python installed in your computer. that is /usr/bin/python
You want to use the Python that came when you installed Anaconda.
Just add Anaconda path to the beginning of your $PATH
.
(In order to do this you probably need to edit your ~/.bashrc
file (or the equivalent file for your shell) then source ~/.bashrc
.
Next time you will go to will run python
and import theano
you'll succeed.
Answered By - mataney
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.