add_lgbm_booster_constr#
- gurobi_ml.lightgbm.lgbm_regressor.add_lgbm_booster_constr(gp_model, lgbm_booster, input_vars, output_vars=None, epsilon=0.0, **kwargs)#
Formulate lgbm_booster into gp_model.
The formulation predicts the values of output_vars using input_vars according to lgbm_regressor. See our User’s Guide for details on the mip formulation used.
Note that only “gbtree” regressors are supported at this point.
- Parameters:
gp_model (gurobipy model) – The gurobipy model where the predictor should be inserted.
lgbm_regressor (
lightgbm.Booster
) – The booster to insert as predictor.input_vars (mvar_array_like) – Decision variables used as input for gradient boosting regressor in model.
output_vars (mvar_array_like, optional) – Decision variables used as output for gradient boosting regressor in model.
- Returns:
Object containing information about what was added to gp_model to formulate gradient_boosting_regressor.
- Return type:
LightGBMRegressorConstr
Notes
See
add_predictor_constr
for acceptable values for input_vars and output_varsAlso see
gurobi_ml.sklearn.decision_tree_regressor.add_decision_tree_regressor()
for specific parameters to model decision tree estimators.- Raises:
NoModel – If the booster is not of type “gbtree”.