bigframes.ml.ensemble.XGBClassifier.fit#
- XGBClassifier.fit(X: DataFrame | Series | DataFrame | Series, y: DataFrame | Series | DataFrame | Series, X_eval: DataFrame | Series | DataFrame | Series | None = None, y_eval: DataFrame | Series | DataFrame | Series | None = None) _T#
Fit gradient boosting model.
Note that calling
fit()multiple times will cause the model object to be re-fit from scratch. To resume training from a previous checkpoint, explicitly passxgb_modelargument.- Parameters:
X (bigframes.dataframe.DataFrame or bigframes.series.Series) – Series or DataFrame of shape (n_samples, n_features). Training data.
y (bigframes.dataframe.DataFrame or bigframes.series.Series) – DataFrame of shape (n_samples,) or (n_samples, n_targets). Target values. Will be cast to X’s dtype if necessary.
X_eval (bigframes.dataframe.DataFrame or bigframes.series.Series) – Series or DataFrame of shape (n_samples, n_features). Evaluation data.
y_eval (bigframes.dataframe.DataFrame or bigframes.series.Series) – DataFrame of shape (n_samples,) or (n_samples, n_targets). Evaluation target values. Will be cast to X_eval’s dtype if necessary.
- Returns:
Fitted estimator.
- Return type:
XGBModel