Releases: dmlc/xgboost
2.1.2 Patch Release
The 2.1.2 patch release makes the following bug fixes:
- Clean up and modernize release-artifacts.py (#10818)
- Fix ellpack categorical feature with missing values. (#10906)
- Fix unbiased ltr with training continuation. (#10908)
- Fix potential race in feature constraint. (#10719)
- Fix boolean array for arrow-backed DF. (#10527)
- Ensure that
pip check
does not fail due to a bad platform tag (#10755) - Check cub errors (#10721)
- Limit the maximum number of threads. (#10872)
- Fixes for large size clusters. (#10880)
- POSIX compliant
poll.h
andmmap
(#10767)
Additional artifacts:
You can verify the downloaded packages by running the following command on your Unix shell:
echo "<hash> <artifact>" | shasum -a 256 --check
a84fc7d9846c24659a2ad16788a7eefa9640b19eea9bbc65f30e0a9d53c52453 xgboost-2.1.2.tar.gz
999eff38533ea79ab3a1f0da524c54f6d0abd2ef220b6dbb9ba1331703e898bc xgboost_r_gpu_linux_2.1.2.tar.gz
Experimental binary packages for R with CUDA enabled
- xgboost_r_gpu_linux_2.1.2.tar.gz: Download
Source tarball
- xgboost.tar.gz: Download
2.1.1 Patch Release
The 2.1.1 patch release make the following bug fixes:
- [Dask] Disable
broadcast
in thescatter
call so thatpredict
function won't hang (#10632) by @trivialfis - [Dask] Handle empty partitions correctly (#10559) by @trivialfis
- Fix federated learning for the encrypted GRPC backend (#10503) by @trivialfis
- Fix a race condition in column splitter (#10572) by @trivialfis
- Gracefully handle cases where system files like
/sys/fs/cgroup/cpu.max
are not readable by the user (#10623) by @trivialfis - Fix build and C++ tests for FreeBSD (#10480) by @hcho3, @trivialfis
- Clarify the requirement Pandas 1.2+ (#10476) by @hcho3
- More robust endianness detection in R package build (#10642) by @jakirkham, @hcho3
In addition, it contains several enhancements:
- Publish JVM packages targeting Linux ARM64 (#10487) by @hcho3
- Publish a CPU-only wheel under name
xgboost-cpu
(#10603) by @hcho3 - Support building with CUDA Toolkit 12.5 and latest CCCL (#10624, #10633, #10574) by @hcho3, @trivialfis, @jakirkham
Full Changelog: v2.1.0...v2.1.1
Additional artifacts:
You can verify the downloaded packages by running the following command on your Unix shell:
echo "<hash> <artifact>" | shasum -a 256 --check
eddbc5200b7c5210f2b8974b9d2a0328a30753416bfb81fdaf5040f4f7abb222 xgboost-2.1.1.tar.gz
3ba5a6e0c609bd5cc0a667d83c57457c06778bece50863e58c8bc1b4eb415fc6 xgboost_r_gpu_linux_2.1.1.tar.gz
Experimental binary packages for R with CUDA enabled
- xgboost_r_gpu_linux_2.1.1.tar.gz: Download
Source tarball
- xgboost.tar.gz: Download
Release 2.1.0 stable
2.1.0 (2024 Jun 20)
We are thrilled to announce the XGBoost 2.1 release. This note will start by summarizing some general changes and then highlighting specific package updates. As we are working on a new R interface, this release will not include the R package. We'll update the R package as soon as it's ready. Stay tuned!
Networking Improvements
An important ongoing work for XGBoost, which we've been collaborating on, is to support resilience for improved scaling and federated learning on various platforms. The existing networking library in XGBoost, adopted from the RABIT project, can no longer meet the feature demand. We've revamped the RABIT module in this release to pave the way for future development. The choice of using an in-house version instead of an existing library is due to the active development status with frequent new feature requests like loading extra plugins for federated learning. The new implementation features:
- Both CPU and GPU communication (based on NCCL).
- A reusable tracker for both the Python package and JVM packages. With the new release, the JVM packages no longer require Python as a runtime dependency.
- Supports federated communication patterns for both CPU and GPU.
- Supports timeout. The high-level interface parameter is currently hard-coded to 30 minutes, which we plan to improve.
- Supports significantly more data types.
- Supports thread-based workers.
- Improved handling for worker errors, including better error messages when one of the peers dies during training.
- Work with IPv6. Currently, this is only supported by the dask interface.
- Built-in support for various operations like broadcast, allgatherV, allreduce, etc.
Related PRs (#9597, #9576, #9523, #9524, #9593, #9596, #9661, #10319, #10152, #10125, #10332, #10306, #10208, #10203, #10199, #9784, #9777, #9773, #9772, #9759, #9745, #9695, #9738, #9732, #9726, #9688, #9681, #9679, #9659, #9650, #9644, #9649, #9917, #9990, #10313, #10315, #10112, #9531, #10075, #9805, #10198, #10414).
The existing option of using MPI
in RABIT is removed in the release. (#9525)
NCCL is now fetched from PyPI.
In the previous version, XGBoost statically linked NCCL, which significantly increased the binary size and led to hitting the PyPI repository limit. With the new release, we have made a significant improvement. The new release can now dynamically load NCCL from an external source, reducing the binary size. For the PyPI package, the nvidia-nccl-cu12
package will be fetched during installation. With more downstream packages reusing NCCL, we expect the user environments to be slimmer in the future as well. (#9796, #9804, #10447)
Parts of the Python package now require glibc 2.28+
Starting from 2.1.0, XGBoost Python package will be distributed in two variants:
manylinux_2_28
: for recent Linux distros with glibc 2.28 or newer. This variant comes with all features enabled.manylinux2014
: for old Linux distros with glibc older than 2.28. This variant does not support GPU algorithms or federated learning.
The pip
package manager will automatically choose the correct variant depending on your system.
Starting from May 31, 2025, we will stop distributing the manylinux2014
variant and exclusively distribute the manylinux_2_28
variant. We made this decision so that our CI/CD pipeline won't have depend on software components that reached end-of-life (such as CentOS 7). We strongly encourage everyone to migrate to recent Linux distros in order to use future versions of XGBoost.
Note. If you want to use GPU algorithms or federated learning on an older Linux distro, you have two alternatives:
- Upgrade to a recent Linux distro with glibc 2.28+. OR
- Build XGBoost from the source.
Multi-output
We continue the work on multi-target and vector leaf in this release:
- Revise the support for custom objectives with a new API,
XGBoosterTrainOneIter.
This new function supports strided matrices and CUDA inputs. In addition, custom objectives now return the correct shape for prediction. (#9508) - The
hinge
objective now supports multi-target regression (#9850) - Fix the gain calculation with vector leaf (#9978)
- Support graphviz plot for multi-target tree. (#10093)
- Fix multi-output with alternating strategies. (#9933)
Please note that the feature is still in progress and not suitable for production use.
Federated Learning
Progress has been made on federated learning with improved support for column-split, including the following updates:
- Column split work for both CPU and GPU. In addition, categorical data is now compatible with column split. (#9562, #9609, #9611, #9628, #9539, #9578, #9685, #9623, #9613, #9511, #9384, #9595)
- The use of UBJson to serialize split entries for column split has been implemented, aiding vector-leaf with column-based data split. (#10059, #10055, #9702)
- Documentation and small fixes. (#9610, #9552, #9614, #9867)
Ongoing work for SYCL support.
XGBoost is developing a SYCL plugin for SYCL devices, starting with the hist
tree method. (#10216, #9800, #10311, #9691, #10269, #10251, #10222, #10174, #10080, #10057, #10011, #10138, #10119, #10045, #9876, #9846, #9682) XGBoost now supports launchable inference on SYCL devices, and work on adding SYCL support for training is ongoing.
Looking ahead, we plan to complete the training in the coming releases and then focus on improving test coverage for SYCL, particularly for Python tests.
Optimizations
- Implement column sampler in CUDA for GPU-based tree methods. This helps us get faster training time when column sampling is employed (#9785)
- CMake LTO and CUDA arch (#9677)
- Small optimization to external memory with a thread pool. This reduces the number of threads launched during iteration. (#9605, #10288, #10374)
Deprecation and breaking changes
Package-specific breaking changes are outlined in respective sections. Here we list general breaking changes in this release:
- The command line interface is deprecated due to the increasing complexity of the machine learning ecosystem. Building a machine learning model using a command shell is no longer feasible and could mislead newcomers. (#9485)
Universal binary JSON
is now the default format for saving models (#9947, #9958, #9954, #9955). See #7547 for more info.- The
XGBoosterGetModelRaw
is now removed after deprecation in 1.6. (#9617) - Drop support for loading remote files. Users are encouraged to use dedicated libraries to fetch remote content. (#9504)
- Remove the dense libsvm parser plugin. This plugin is never tested or documented (#9799)
XGDMatrixSetDenseInfo
andXGDMatrixSetUIntInfo
are now deprecated. Use the array interface based alternatives instead.
Features
This section lists some new features that are general to all language bindings. For package-specific changes, please visit respective sections.
- Adopt a new XGBoost logo (#10270)
- Now supports dataframe data format in native XGBoost. This improvement enhances performance and reduces memory usage when working with dataframe-based structures such as pandas, arrow, and R dataframe. (#9828, #9616, #9905)
- Change default metric for gamma regression to
deviance
. (#9757) - Normalization for learning to rank is now optional with the introduction of the new
lambdarank_normalization
parameter. (#10094) - Contribution prediction with
QuantileDMatrix
on CPU. (#10043) - XGBoost on macos no longer bundles OpenMP runtime. Users can install the latest runtime from their dependency manager of choice. (#10440). Along with which, JVM packages on MacoOS are now built with OpenMP support (#10449).
Bug fixes
- Fix training with categorical data from external memory. (#10433)
- Fix compilation with CTK-12. (#10123)
- Fix inconsistent runtime library on Windows. (#10404)
- Fix default metric configuration. (#9575)
- Fix feature names with special characters. (#9923)
- Fix global configuration for external memory training. (#10173)
- Disable column sample by node for the exact tree method. (#10083)
- Fix the
FieldEntry
constructor specialization syntax error (#9980) - Fix pairwise objective with NDCG metric along with custom gain. (#10100)
- Fix the default value for
lambdarank_pair_method
. (#10098) - Fix UBJSON with boolean values. No existing code is affected by this fix. (#10054)
- Be more lenient on floating point errors for AUC. This prevents the AUC > 1.0 error. (#10264)
- Check support status for categorical features. This prevents
gblinear
from treating categorical features as numerical. (#9946)
Document
Here is a list of documentation changes not specific to any XGBoost package.
- A new coarse map for XGBoost features to assist development. (#10310)
- New language binding consistency guideline. (#9755, #9866)
- Fixes, cleanups, small updates (#9501, #9988, #10023, #10013, #10143, #9904, #10179, #9781, #10340, #9658, #10182, #9822)
- Update document for parameters (#9900)
- Brief introduction to
base_score
. (#9882) - Mention data consistency for categorical features. (#9678)
Python package
- Dask
Other than the changes in networking, we have some optimizations and document updates in dask:
- Filter models on workers instead of clients; this prevents an OOM error on the client machine. (#9518)
- Users are now encouraged to use
from xgboost import dask
instead ofimport xgboost.dask
to avoid drawing in unnecessary dependencies for non-dask users. (#9742) - Add seed to demos. (#10009)
- New document for using dask XGBoost with k8s. (#10271)
- Workaround potentially unaligned pointer from an empty partition. (#10418)
- Workaround a ...
Release candidate of version 2.1.0
See #10356 for details.
2.0.3 Patch Release
The 2.0.3 patch release make the following bug fixes:
- [backport][sklearn] Fix loading model attributes. (#9808) by @trivialfis in #9880
- [backport][py] Use the first found native library. (#9860) by @trivialfis in #9879
- [backport] [CI] Upload libxgboost4j.dylib (M1) to S3 bucket by @hcho3 in #9887
- [jvm-packages] Fix POM for xgboost-jvm metapackage by @hcho3 in #9893 #9897
Full Changelog: v2.0.2...v2.0.3
Additional artifacts:
You can verify the downloaded packages by running the following command on your Unix shell:
echo "<hash> <artifact>" | shasum -a 256 --check
7c4bd1cf6162d335fd20a8168a54dd11508342f82fbf381a80c02ac57be0bce4 xgboost-2.0.3.tar.gz
d0c3499504133a8ea0043da2974c51cc71aae792f0719080bc227d7add8fb881 xgboost_r_gpu_win64_2.0.3.tar.gz
ee47da5b21231965b1f054d191a5418543377f4ba0d0615a593a6f99d1832ca1 xgboost_r_gpu_linux_2.0.3.tar.gz
Experimental binary packages for R with CUDA enabled
2.0.2 Patch Release
2.0.1 Patch Release
This is a patch release for bug fixes.
Bug fixes
- Support pandas 2.1.0. by @trivialfis in #9655
- Fix default metric configuration. by @trivialfis in #9590
- [R] Fix method name. by @trivialfis in #9592
- Use array interface for testing NumPy arrays. by @trivialfis in #9635
- Workaround Apple clang issue. by @trivialfis in #9636
- Add support for cgroupv2. by @trivialfis in #9656
- Fix build for GCC 8.x by @hcho3 in #9670
- [pyspark] Support stage-level scheduling by @wbo4958 in #9686
- Fix build for AppleClang 11 by @hcho3 in #9684
- Fix libpath logic for Windows by @hcho3 in #9687, #9711
- Remove hard dependency on libjvm by @hcho3 in #9705
In addition, this is the first release where the JVM package is distributed with native support for Apple Silicon.
Additional artifacts:
You can verify the downloaded packages by running the following command on your Unix shell:
echo "<hash> <artifact>" | shasum -a 256 --check
529e9d0f88c2a7abae833f05b7d1e7e7ce01de20481ea60f6ebb6eb7fc96ba69 xgboost.tar.gz
25342c91e7cda98b1362b70282b286c2e4f3e996b518fb590c1303f53f39f188 xgboost_r_gpu_win64_2.0.1.tar.gz
3d8cde1160ab135c393b8092ce0475709dff318024022b735a253d968f9711b3 xgboost_r_gpu_linux_2.0.1.tar.gz
Experimental binary packages for R with CUDA enabled
Source tarball
- xgboost.tar.gz: Download
Release 2.0.0 stable
2.0.0 (2023 Sep 12)
We are excited to announce the release of XGBoost 2.0. This note will begin by covering some overall changes and then highlight specific updates to the package.
Initial work on multi-target trees with vector-leaf outputs
We have been working on vector-leaf tree models for multi-target regression, multi-label classification, and multi-class classification in version 2.0. Previously, XGBoost would build a separate model for each target. However, with this new feature that's still being developed, XGBoost can build one tree for all targets. The feature has multiple benefits and trade-offs compared to the existing approach. It can help prevent overfitting, produce smaller models, and build trees that consider the correlation between targets. In addition, users can combine vector leaf and scalar leaf trees during a training session using a callback. Please note that the feature is still a working in progress, and many parts are not yet available. See #9043 for the current status. Related PRs: (#8538, #8697, #8902, #8884, #8895, #8898, #8612, #8652, #8698, #8908, #8928, #8968, #8616, #8922, #8890, #8872, #8889, #9509) Please note that, only the hist
(default) tree method on CPU can be used for building vector leaf trees at the moment.
New device
parameter.
A new device
parameter is set to replace the existing gpu_id
, gpu_hist
, gpu_predictor
, cpu_predictor
, gpu_coord_descent
, and the PySpark specific parameter use_gpu
. Onward, users need only the device
parameter to select which device to run along with the ordinal of the device. For more information, please see our document page (https://xgboost.readthedocs.io/en/stable/parameter.html#general-parameters) . For example, with device="cuda", tree_method="hist"
, XGBoost will run the hist
tree method on GPU. (#9363, #8528, #8604, #9354, #9274, #9243, #8896, #9129, #9362, #9402, #9385, #9398, #9390, #9386, #9412, #9507, #9536). The old behavior of gpu_hist
is preserved but deprecated. In addition, the predictor
parameter is removed.
hist
is now the default tree method
Starting from 2.0, the hist
tree method will be the default. In previous versions, XGBoost chooses approx
or exact
depending on the input data and training environment. The new default can help XGBoost train models more efficiently and consistently. (#9320, #9353)
GPU-based approx tree method
There's initial support for using the approx
tree method on GPU. The performance of the approx
is not yet well optimized but is feature complete except for the JVM packages. It can be accessed through the use of the parameter combination device="cuda", tree_method="approx"
. (#9414, #9399, #9478). Please note that the Scala-based Spark interface is not yet supported.
Optimize and bound the size of the histogram on CPU, to control memory footprint
XGBoost has a new parameter max_cached_hist_node
for users to limit the CPU cache size for histograms. It can help prevent XGBoost from caching histograms too aggressively. Without the cache, performance is likely to decrease. However, the size of the cache grows exponentially with the depth of the tree. The limit can be crucial when growing deep trees. In most cases, users need not configure this parameter as it does not affect the model's accuracy. (#9455, #9441, #9440, #9427, #9400).
Along with the cache limit, XGBoost also reduces the memory usage of the hist
and approx
tree method on distributed systems by cutting the size of the cache by half. (#9433)
Improved external memory support
There is some exciting development around external memory support in XGBoost. It's still an experimental feature, but the performance has been significantly improved with the default hist
tree method. We replaced the old file IO logic with memory map. In addition to performance, we have reduced CPU memory usage and added extensive documentation. Beginning from 2.0.0, we encourage users to try it with the hist
tree method when the memory saving by QuantileDMatrix
is not sufficient. (#9361, #9317, #9282, #9315, #8457)
Learning to rank
We created a brand-new implementation for the learning-to-rank task. With the latest version, XGBoost gained a set of new features for ranking task including:
- A new parameter
lambdarank_pair_method
for choosing the pair construction strategy. - A new parameter
lambdarank_num_pair_per_sample
for controlling the number of samples for each group. - An experimental implementation of unbiased learning-to-rank, which can be accessed using the
lambdarank_unbiased
parameter. - Support for custom gain function with
NDCG
using thendcg_exp_gain
parameter. - Deterministic GPU computation for all objectives and metrics.
NDCG
is now the default objective function.- Improved performance of metrics using caches.
- Support scikit-learn utilities for
XGBRanker
. - Extensive documentation on how learning-to-rank works with XGBoost.
For more information, please see the tutorial. Related PRs: (#8771, #8692, #8783, #8789, #8790, #8859, #8887, #8893, #8906, #8931, #9075, #9015, #9381, #9336, #8822, #9222, #8984, #8785, #8786, #8768)
Automatically estimated intercept
In the previous version, base_score
was a constant that could be set as a training parameter. In the new version, XGBoost can automatically estimate this parameter based on input labels for optimal accuracy. (#8539, #8498, #8272, #8793, #8607)
Quantile regression
The XGBoost algorithm now supports quantile regression, which involves minimizing the quantile loss (also called "pinball loss"). Furthermore, XGBoost allows for training with multiple target quantiles simultaneously with one tree per quantile. (#8775, #8761, #8760, #8758, #8750)
L1 and Quantile regression now supports learning rate
Both objectives use adaptive trees due to the lack of proper Hessian values. In the new version, XGBoost can scale the leaf value with the learning rate accordingly. (#8866)
Export cut value
Using the Python or the C package, users can export the quantile values (not to be confused with quantile regression) used for the hist
tree method. (#9356)
column-based split and federated learning
We made progress on column-based split for federated learning. In 2.0, both approx
, hist
, and hist
with vector leaf can work with column-based data split, along with support for vertical federated learning. Work on GPU support is still on-going, stay tuned. (#8576, #8468, #8442, #8847, #8811, #8985, #8623, #8568, #8828, #8932, #9081, #9102, #9103, #9124, #9120, #9367, #9370, #9343, #9171, #9346, #9270, #9244, #8494, #8434, #8742, #8804, #8710, #8676, #9020, #9002, #9058, #9037, #9018, #9295, #9006, #9300, #8765, #9365, #9060)
PySpark
After the initial introduction of the PySpark interface, it has gained some new features and optimizations in 2.0.
- GPU-based prediction. (#9292, #9542)
- Optimization for data initialization by avoiding the stack operation. (#9088)
- Support predict feature contribution. (#8633)
- Python typing support. (#9156, #9172, #9079, #8375)
use_gpu
is deprecated. Thedevice
parameter is preferred.- Update eval_metric validation to support list of strings (#8826)
- Improved logs for training (#9449)
- Maintenance, including refactoring and document updates (#8324, #8465, #8605, #9202, #9460, #9302, #8385, #8630, #8525, #8496)
- Fix for GPU setup. (#9495)
Other General New Features
Here's a list of new features that don't have their own section and yet are general to all language bindings.
- Use array interface for CSC matrix. This helps XGBoost to use a consistent number of threads and align the interface of the CSC matrix with other interfaces. In addition, memory usage is likely to decrease with CSC input thanks to on-the-fly type conversion. (#8672)
- CUDA compute 90 is now part of the default build.. (#9397)
Other General Optimization
These optimizations are general to all language bindings. For language-specific optimization, please visit the corresponding sections.
- Performance for input with
array_interface
on CPU (likenumpy
) is significantly improved. (#9090) - Some optimization with CUDA for data initialization. (#9199, #9209, #9144)
- Use the latest thrust policy to prevent synchronizing GPU devices. (#9212)
- XGBoost now uses a per-thread CUDA stream, which prevents synchronization with other streams. (#9416, #9396, #9413)
Notable breaking change
Other than the aforementioned change with the device
parameter, here's a list of breaking changes affecting all packages.
- Users must specify the format for text input (#9077). However, we suggest using third-party data structures such as
numpy.ndarray
instead of relying on text inputs. See #9472 for more info.
Notable bug fixes
Some noteworthy bug fixes that are not related to specific language bindings are listed in this section.
- Some language environments use a different thread to perform garbage collection, which breaks the thread-local cache used in XGBoost. XGBoost 2.0 implements a new thread-safe cache using a light weight lock to replace the thread-local cache. (#8851)
- Fix model IO by clearing the prediction cache. (#8904)
inf
is checked during data construction. (#8911)- Preserve order of saved updaters configuration. Usually, this is not an issue unless the
updater
parameter is used instead of thetree_method
parameter (#9355) - Fix GPU memory allocation issue with categorical splits. (#9529)
- Handle escape sequence like
\t\n
in feature names for JSON model dump. (#9474) - Normalize file path for model IO and text input. This handles short paths on Windows and paths that contain
~
on Unix (#9463). In addition, all...
Release candidate of version 2.0.0
Roadmap: https://github.com/dmlc/xgboost/projects/2
Release note: #9484
Release status: #9497
1.7.6 Patch Release
This is a patch release for bug fixes. The CRAN package for the R binding is kept at 1.7.5.
Bug Fixes
- Fix distributed training with mixed dense and sparse partitions. (#9272)
- Fix monotone constraints on CPU with large trees. (#9122)
- [spark] Make the spark model have the same UID as its estimator (#9022)
- Optimize prediction with
QuantileDMatrix
. (#9096)
Document
Maintenance
- Fix tests with pandas 2.0. (#9014)
Additional artifacts:
You can verify the downloaded packages by running the following command on your Unix shell:
echo "<hash> <artifact>" | shasum -a 256 --check
0a54300dd274b98b7f039acffa006bec4875dace041fd9288422306fe7c379ca xgboost.tar.gz
990fb3c54be7ce53365389f2eb82ce3c1f2e78735b4605ddd2ddb0d47a15d3c3 xgboost_r_gpu_linux_1.7.6.tar.gz
a48fc64bce774bb76eddade6dc6df1d4fc25199a0c17dc66cdfa50cedd3282ad xgboost_r_gpu_win64_1.7.6.tar.gz
Experimental binary packages for R with CUDA enabled
Source tarball
Link in GitHub release assets