How to get rid of Deprecating Warning: 'np.float' is a deprecated alias for builtin 'float'

Viewed 4219

My file has only 1 line for troubleshooting purpose

from sklearn import linear_model

How to get rid of this deprecationWarning?

How to solve it.

2 Answers

Either use float by itself or use np.float64.

Upgrade your sklearn package:

pip3.8 install scikit-learn --upgrade --user

Related