我在处理分类问题中的高度不平衡数据,所以我使用加权类来处理这个问题, 但是当我运行这个Jupyter笔记本单元(fitting单元)时,Python就停止工作了。你知道吗
我的代码:
xg = XGBClassifier(objective ='reg:logistic', colsample_bytree = 0.3, learning_rate = 0.01,
max_depth = 5, alpha = 10, n_estimators = 100)
class_weight = {0: 1,
1: 9}
xg.fit(X_train,y_train,sample_weight=class_weight)
目前没有回答
相关问题 更多 >
编程相关推荐