Issue
I wanna use scikit-learn. I have typed
pip install -U scikit-learn
pip3 install sklearn
to install it; but when i type
$ Python
>>> import sklearn
it returns
ImportError: No module named sklearn
I followed other tutorials, but it doesn't work. Furthermore, my enviroment returns this warning:
If you have installed scikit-learn from source, please do not forget to build the package before using it: run
python setup.py install
ormake
in the source directory.
What is the true code to type in the terminal? I tried to type python setup.py install
in the terminal but it doesn't work
Solution
Make sure that pip and python are the same version. For example if you run pip for python 2.7, it will install the package only in 2.7, and if your python command point to for example python 3.3 interpreter, it will not have that package
Answered By - Igor Fil
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.