Neptune.ai XGBoost integration library
Project Links
Meta
Author: neptune.ai
Requires Python: >=3.7,<4.0
Classifiers
Development Status
- 4 - Beta
Environment
- Console
Intended Audience
- Developers
- Science/Research
License
- OSI Approved :: Apache Software License
Natural Language
- English
Operating System
- MacOS
- Microsoft :: Windows
- POSIX
- Unix
Programming Language
- Python :: 3
- Python :: 3.7
- Python :: 3.8
- Python :: 3.9
- Python :: 3.10
- Python :: 3.11
- Python :: Implementation :: CPython
Topic
- Scientific/Engineering :: Artificial Intelligence
- Software Development :: Libraries :: Python Modules
Neptune + XGBoost integration
Experiment tracking, model registry, data versioning, and live model monitoring for XGBoost trained models.
What will you get with this integration?
- Log, display, organize, and compare ML experiments in a single place
- Version, store, manage, and query trained models, and model building metadata
- Record and monitor model training, evaluation, or production runs live
What will be logged to Neptune?
- metrics,
- parameters,
- learning rate,
- pickled model,
- visualizations (feature importance chart and tree visualizations),
- hardware consumption (CPU, GPU, Memory),
- stdout and stderr logs,
- training code and Git commit information,
- other metadata
Example dashboard with train-valid metrics and selected parameters
Resources
- Documentation
- Code example on GitHub
- Example of a run logged in the Neptune app
- Run example in Google Colab
Example
On the command line:
pip install xgboost>=1.3.0 neptune-xgboost
In Python:
import neptune
import xgboost as xgb
from neptune.integrations.xgboost import NeptuneCallback
# Start a run
run = neptune.init_run(
project="common/xgboost-integration",
api_token=neptune.ANONYMOUS_API_TOKEN,
)
# Create a NeptuneCallback instance
neptune_callback = NeptuneCallback(run=run, log_tree=[0, 1, 2, 3])
# Prepare datasets
...
data_train = xgb.DMatrix(X_train, label=y_train)
# Define model parameters
model_params = {
"eta": 0.7,
"gamma": 0.001,
"max_depth": 9,
...
}
# Train the model and log metadata to the run in Neptune
xgb.train(
params=model_params,
dtrain=data_train,
callbacks=[neptune_callback],
)
Support
If you got stuck or simply want to talk to us, here are your options:
- Check our FAQ page
- You can submit bug reports, feature requests, or contributions directly to the repository.
- Chat! When in the Neptune application click on the blue message icon in the bottom-right corner and send a message. A real person will talk to you ASAP (typically very ASAP),
- You can just shoot us an email at support@neptune.ai
Mar 31, 2023
1.1.1
Mar 14, 2023
1.1.0
Feb 20, 2023
1.0.0
Nov 07, 2022
0.10.1
Sep 12, 2022
0.10.0
Jul 20, 2021
0.9.13
Jul 19, 2021
0.9.12
Jul 07, 2021
0.9.11
Jun 18, 2021
0.9.10
Jun 17, 2021
0.9.9
Jun 11, 2021
0.9.8
May 27, 2021
0.9.7
May 04, 2021
0.9.6
Apr 29, 2021
0.9.5