【问题标题】:multi-classification using Xgboost Scikit API使用 Xgboost Scikit API 进行多分类
【发布时间】:2017-08-01 13:02:34
【问题描述】:

我很困惑如何以及在何处使用 Xgboost Scikit API 为多分类设置 num_class 参数。 在scikit网站上,docs中没有这个参数。

xgboost.XGBClassifier(max_depth=3, learning_rate=0.1, n_estimators=100,
    silent=True, objective='binary:logistic', nthread=-1, gamma=0,
    min_child_weight=1, max_delta_step=0, subsample=1, colsample_bytree=1,
    colsample_bylevel=1, reg_alpha=0, reg_lambda=1, scale_pos_weight=1,
    base_score=0.5, seed=0, missing=None)

【问题讨论】:

标签: machine-learning xgboost


【解决方案1】:

XGB Classifier 包装函数不需要您事先指定类的数量。 fit 上传递的“标签”列用于指定您将使用多少/哪些类。

【讨论】:

    猜你喜欢
    • 2020-01-19
    • 1970-01-01
    • 1970-01-01
    • 2017-09-30
    • 2015-03-16
    • 2016-05-16
    • 2015-11-11
    • 2018-07-27
    • 2020-11-15
    相关资源
    最近更新 更多