## Trying to run a kaggle notebook

0

I'm found an interesting problem on kaggle and more or less solved it with my limited knowledge of machine learning. I was curious how other people solved and checked the solution with the highest vote.

The solution includes a line where is implementing and training a model.

params = {'num_leaves': 8,
'min_data_in_leaf': 42,
'objective': 'binary',
'max_depth': 5,
'learning_rate': 0.01,
'boosting': 'gbdt',
'bagging_freq': 5,
'feature_fraction': 0.8201,
'bagging_seed': 11,
'reg_alpha': 1,
'reg_lambda': 4,
'random_state': 42,
'metric': 'auc',
'verbosity': -1,
'subsample': 0.81,
oof_lgb, scores = train_model(X, y, params=params, folds=folds, model_type='lgb', plot_feature_importance=True)


But it is nowhere mentioned what kind of model he is using, which causes the error.

NameError: name 'train_model' is not defined


Does someone of you know which model he is using, so that i can run his notebook on my computer.

The actual code is included in the notebook, if you click on the 'Code' button just above the cell with the code you provide you will see the code used to define the train_model function. If you look in that function you will see that this function can use different models based on the model_type argument, and in the line of code you linked 'lgb' means that a gradient boosting model from the lgb library is used.