Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
409 views
in Technique[技术] by (71.8m points)

python - How to upgrade scikit-learn package in anaconda

I am trying to upgrade package of scikit-learn from 0.16 to 0.17. For that I am trying to use binaries from this website: http://www.lfd.uci.edu/~gohlke/pythonlibs/#scikit-learn. I have Windows 7 x64 bit. I downloaded the relevant package locally and gave following commands and got Requirement already up-to-date:

C:Usersskumar>pip install --upgrade --use-wheel --no-index --find-links=../../
SOURCE/APPS scikit-learn
Ignoring indexes: https://pypi.python.org/simple
Requirement already up-to-date: scikit-learn in c:anaconda3libsite-packages

Then I tried to upgrade it from remote site and got similar result:

C:Usersskumar>pip install --upgrade --use-wheel --no-index --trusted-host www.
lfd.uci.edu --find-links=http://www.lfd.uci.edu/~gohlke/pythonlibs/ scikit-learn

Ignoring indexes: https://pypi.python.org/simple
Requirement already up-to-date: scikit-learn in c:anaconda3libsite-packages

On Remote site there are two versions i.e., 0.16 & 0.17. Is there a way to specify version in command? Or how do you install/upgrade wheel file?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Anaconda comes with the conda package manager which is designed to handle these kinds of upgrades. Start by updating conda itself to get the most recent package lists:

conda update conda

And then install the version of scikit-learn you want

conda install scikit-learn=0.17

All necessary dependencies will be upgraded as well. If you have trouble with conda on Windows, there are some relevant FAQ here: http://docs.continuum.io/anaconda/faq


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...