简体   繁体   中英

IMPORT ERROR when importing from sklearn.ensemble?

I received an import error when importing the HistGradientBooostingClassifier from sklearn.ensemble

I typed in jupyter notebook:

'from sklearn.ensemble import HistGradientBoostingClassifier'

错误截图 .

The first result from a (US) Google search for ImportError from sklearn.ensemble import HistGradientBoostingClassifier is this issue from the scikit-learn repo on Github.

HistGradientBoostingRegressor is experimental. You need to enable experimental features first:

from sklearn.experimental import enable_hist_gradient_boosting
from sklearn.ensemble import HistGradientBoostingRegressor

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM