I am trying to use sklearn.feature_selection in Google Datalab however, Datalab has version 0.16.1 installed by default. I tried installing version 0.17 using
%%bash
pip install scikit-learn==0.17
This works well, however when I run a new block of code, I'm still getting the old sklearn version but the right path.
>> import sklearn
>> print(sklearn.__version__)
0.16.1
>> print(sklearn.__path__)
['/usr/local/lib/python2.7/dist-packages/sklearn']
Now let's try with a new bash block:
%%bash
pip install scikit-learn==0.17
python -c 'import sklearn; print(sklearn.__version__);print(sklearn.__path__)'
Requirement already satisfied (use --upgrade to upgrade): scikit-learn==0.17 in /usr/local/lib/python2.7/dist-packages
Cleaning up...
0.17
['/usr/local/lib/python2.7/dist-packages/sklearn']
What am I missing?