135: Check failed: !auc_error AUC: the dataset only contains pos or neg samples

调用

xgb.cv(xgb_param, xgtrain, num_boost_round=alg.get_params()['n_estimators'], nfold=cv_folds,

metrics='auc', early_stopping_rounds=early_stopping_rounds),

正负样本其中一个较少,nfold设置折数多,导致错误发生

猜你喜欢

转载自blog.csdn.net/qq_34599526/article/details/81784059
auc