Update/ install Python scikit learn latest develop

2020-07-25 04:39发布

问题:

I am trying to replace/install my Python scikit-learn 0.17.0 with 0.18.dev0 latest development version in Windows, so that I can try out sklearn.neural_network.MLPClassifier. After reading and trying the advanced user manual here (http://scikit-learn.org/stable/developers/advanced_installation.html#install-bleeding-edge), I am kinda stuck.

 pip install -U scikit-learn

 => Still getting 0.17.0 but not 0.18.dev0

Could any guru provide step by step guides to install developmental Python 2.70 scikit-learn in windows? Thanks!

回答1:

The only way to get the development version is to clone it through git, as follows:

pip install git+https://github.com/scikit-learn/scikit-learn.git

For Windows, I highly recommend installing Anaconda (https://www.continuum.io/downloads) because it installs all the scientific computing packages that you need for Windows.



回答2:

I have same problem with you. After trying several solutions, I finally get sklearn 0.18 worked by simply type:

pip install git+https://github.com/scikit-learn/scikit-learn.git#egg=scikit-learn


回答3:

conda install scikit-learn

seems to do the job of updating to the latest version.

you can find the package you are looking for there:

from sklearn.neural_network import MLPClassifier

This is valid if you are using Anaconda, ofc.