15分钟
LGBMRanker
- LGBMRegressor 是LGBMModel 的子类,它用于ranking 任务。
class lightgbm.LGBMRanker(boosting_type='gbdt', num_leaves=31, max_depth=-1,
learning_rate=0.1, n_estimators=10, max_bin=255, subsample_for_bin=200000,
objective=None, min_split_gain=0.0, min_child_weight=0.001, min_child_samples=20,
subsample=1.0, subsample_freq=1, colsample_bytree=1.0, reg_alpha=0.0,
reg_lambda=0.0, random_state=None, n_jobs=-1, silent=True, **kwargs)
- 参数:参考LGBMModel
2. 属性:参考LGBMModel
3. 方法:
- .fit(): 训练模型
fit(X, y, sample_weight=None, init_score=None, group=None, eval_set=None,
eval_names=None, eval_sample_weight=None, eval_init_score=None,
eval_group=None, eval_metric='ndcg', eval_at=[1], early_stopping_rounds=None,
verbose=True, feature_name='auto', categorical_feature='auto', callbacks=None)
学员评价