[Python error solution] DeprecationWarning: `np.float` is a deprecated

报错amoconda libsite-packages sklearn linear model least ngl.py30: Deprecationmarming: mp.float is a deprecated alias for the builtinfloat , To silence this warning, wse flat by itself. Doing this will not modify amy behavior and is safe. If you specifically wanted thenumpy scalar type, use np. float64 here.

Solution 1: Upgrade scikit-learn version

conda update scikit-learn

Solution 2:

In Anaconda Prompt
(1) pip uninstall Scikit-learn
(2) pip install Scikit-learn

Guess you like

Origin blog.csdn.net/toby001111/article/details/132709477