Skip to main content

XGBoost and scikit-learn

The example demonstrates integrating ClearML into code that uses XGBoost.

The example does the following:

  • Trains a network on the scikit-learn iris classification dataset using XGBoost
  • Scores accuracy using scikit-learn
  • ClearML automatically logs the input model registered by XGBoost, and the output model (and its checkpoints), feature importance plot, and tree plot created with XGBoost.
  • Creates an experiment named XGBoost simple example in the examples project.


The feature importance plot and tree plot appear in the experiment's page in the ClearML web UI, under PLOTS.

Feature importance plot

Tree plot


All other console output appear in CONSOLE.



Models created by the experiment appear in the experiment's ARTIFACTS tab. ClearML automatically logs and tracks models and any snapshots created using XGBoost.


Clicking on the model's name takes you to the model's page, where you can view the model's details and access the model.