OptGBM
OptGBM(= + )提供了一种scikit-learn兼容的估算器,可通过Optuna调整LightGBM中的超参数。
例子
import optgbm as lgb
from sklearn . datasets import load_boston
reg = lgb . LGBMRegressor ( random_state = 0 )
X , y = load_boston ( return_X_y = True )
reg . fit ( X , y )
y_pred = reg . predict ( X , y )
默认情况下,将搜索以下超参数。
bagging_fraction
bagging_freq
feature_fractrion
lambda_l1
lambda_l2
max_depth
min_data_in_leaf
1