Code QuizIntermediate

Regularization Terms Set to Zero

Trying to curb overfitting while disabling XGBoost's regularization penalties.

Codepython
import xgboost as xgb

# The model overfits; we want MORE regularization.
model = xgb.XGBRegressor(
    reg_lambda=0,   # L2 penalty on leaf weights
    gamma=0,        # min loss reduction to split
    max_depth=8
)
model.fit(X_train, y_train)

The model still overfits despite the 'regularization' settings. What is the bug?