Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Warning messages when using python

I keep getting this when I run SVM python code:

Warning (from warnings module):
  File "/usr/local/lib/python2.7/dist-packages/sklearn/cross_validation.py", line 44
    "This module will be removed in 0.20.", DeprecationWarning)
DeprecationWarning: This module was deprecated in version 0.18 in favor of the model_selection module into which all the refactored classes and functions are moved. Also note that the interface of the new CV iterators are different from that of this module. This module will be removed in 0.20.

Warning (from warnings module):
  File "/usr/local/lib/python2.7/dist-packages/sklearn/grid_search.py", line 43
    DeprecationWarning)
DeprecationWarning: This module was deprecated in version 0.18 in favor of the model_selection module into which all the refactored classes and functions are moved. This module will be removed in 0.20.

What does this warning messages indicate?

Thanks in Advance

like image 988
Dhara Avatar asked Dec 20 '16 09:12

Dhara


1 Answers

the latest stable version of scikit-learn is 0.18 http://scikit-learn.org/stable/

The version you are using has deprecated these modules.
Alternatively use

    from sklearn.model_selection import train_test_split

Look at this discussion
https://github.com/rhiever/tpot/issues/284
and this comment:
https://github.com/rhiever/tpot/commit/84c5e26b447251088826737612ccf0817ef43db2

like image 157
Samer Aamar Avatar answered Nov 07 '22 08:11

Samer Aamar