## File: README.md

eXtreme Gradient Boosting
===========

[](https://github.com/dmlc/xgboost/actions)
[](https://xgboost.readthedocs.io)
[](./LICENSE)
[](https://cran.r-project.org/web/packages/xgboost)
[](https://pypi.python.org/pypi/xgboost/)
[](https://anaconda.org/conda-forge/py-xgboost)
[](https://optuna.org)
[](https://twitter.com/XGBoostProject)
[](https://api.securityscorecards.dev/projects/github.com/dmlc/xgboost)
[](https://colab.research.google.com/github/comet-ml/comet-examples/blob/master/integrations/model-training/xgboost/notebooks/how_to_use_comet_with_xgboost_tutorial.ipynb)

[Community](https://xgboost.ai/community) |
[Documentation](https://xgboost.readthedocs.io) |
[Resources](demo/README.md) |
[Contributors](CONTRIBUTORS.md) |
[Release Notes](https://xgboost.readthedocs.io/en/latest/changes/index.html)

XGBoost is an optimized distributed gradient boosting library designed to be highly ***efficient***, ***flexible*** and ***portable***.
It implements machine learning algorithms under the [Gradient Boosting](https://en.wikipedia.org/wiki/Gradient_boosting) framework.
XGBoost provides a parallel tree boosting (also known as GBDT, GBM) that solve many data science problems in a fast and accurate way.
The same code runs on major distributed environment (Kubernetes, Hadoop, SGE, Dask, Spark, PySpark) and can solve problems beyond billions of examples.

License
-------
© Contributors, 2021. Licensed under an [Apache-2](https://github.com/dmlc/xgboost/blob/master/LICENSE) license.

Contribute to XGBoost
---------------------
XGBoost has been developed and used by a group of active community members. Your help is very valuable to make the package better for everyone.
Checkout the [Community Page](https://xgboost.ai/community).

Reference
---------
- Tianqi Chen and Carlos Guestrin. [XGBoost: A Scalable Tree Boosting System](https://arxiv.org/abs/1603.02754). In 22nd SIGKDD Conference on Knowledge Discovery and Data Mining, 2016
- XGBoost originates from research project at University of Washington.

Sponsors
--------
Become a sponsor and get a logo here. See details at [Sponsoring the XGBoost Project](https://xgboost.ai/sponsors). The funds are used to defray the cost of continuous integration and testing infrastructure (https://xgboost-ci.net).

## Open Source Collective sponsors
[](#backers) [](#sponsors)

### Sponsors
[[Become a sponsor](https://opencollective.com/xgboost#sponsor)]

[](https://www.nvidia.com/en-us/)
[](https://www.comet.com/site/?utm_source=xgboost&utm_medium=github&utm_content=readme)
[](https://opencollective.com/tomislav1)
[](https://databento.com/?utm_source=xgboost&utm_medium=sponsor&utm_content=display)
[](https://www.intel.com/)

### Backers
[[Become a backer](https://opencollective.com/xgboost#backer)]

[](https://opencollective.com/xgboost#backers)

---

## File: demo/c-api/basic/README.md

C-APIs
===

**XGBoost** implements a C API originally designed for various language
bindings.  For detailed reference, please check xgboost/c_api.h.  Here is a
demonstration of using the API.

# CMake
If you use **CMake** for your project, you can either install **XGBoost**
somewhere in your system and tell CMake to find it by calling
`find_package(xgboost)`, or put **XGBoost** inside your project's source tree
and call **CMake** command: `add_subdirectory(xgboost)`.  To use
`find_package()`, put the following in your **CMakeLists.txt**:

``` CMake
find_package(xgboost REQUIRED)
add_executable(api-demo c-api-demo.c)
target_link_libraries(api-demo xgboost::xgboost)
```

If you want to put XGBoost inside your project (like git submodule), use this
instead:
``` CMake
add_subdirectory(xgboost)
add_executable(api-demo c-api-demo.c)
target_link_libraries(api-demo xgboost)
```

# make
You can start by modifying the makefile in this directory to fit your need.

---

## File: demo/c-api/external-memory/README.md

Defining a Custom Data Iterator to Load Data from External Memory
=================================================================

A simple demo for using custom data iterator with XGBoost.  The feature is still
**experimental** and not ready for production use.  If you are not familiar with C API,
please read its introduction in our tutorials and visit the basic demo first.

Defining Data Iterator
----------------------

In the example, we define a custom data iterator with 2 methods: `reset` and `next`.  The
`next` method passes data into XGBoost and tells XGBoost whether the iterator has reached
its end, and the `reset` method resets iterations. One important detail when using the C
API for data iterator is users need to make sure that the data passed into `next` method
must be kept in memory until the next iteration or `reset` is called.  The external memory
DMatrix is not limited to training, but also valid for other features like prediction.

---

## File: demo/data/README.md

This folder contains processed example dataset used by the demos.
Copyright of the dataset belongs to the original copyright holder

---

## File: demo/kaggle-higgs/README.md

Highlights
=====
Higgs challenge ends recently, xgboost is being used by many users. This list highlights the xgboost solutions of players
* Blogpost by phunther: [Winning solution of Kaggle Higgs competition: what a single model can do](http://no2147483647.wordpress.com/2014/09/17/winning-solution-of-kaggle-higgs-competition-what-a-single-model-can-do/)
* The solution by Tianqi Chen and Tong He [Link](https://github.com/hetong007/higgsml)

Guide for Kaggle Higgs Challenge
=====

This is the folder giving example of how to use XGBoost Python Module  to run Kaggle Higgs competition

This script will achieve about 3.600 AMS score in public leaderboard. To get start, you need do following step:

1. Compile the XGBoost python lib
```bash
cd ../..
make
```

2. Put training.csv test.csv on folder './data' (you can create a symbolic link)

3. Run ./run.sh

Speed
=====
speedtest.py compares xgboost's speed on this dataset with sklearn.GBM


Using R module
=====
* Alternatively, you can run using R, higgs-train.R and higgs-pred.R.

---

## File: demo/kaggle-otto/README.MD

Benchmark for Otto Group Competition
=========

This is a folder containing the benchmark for the [Otto Group Competition on Kaggle](http://www.kaggle.com/c/otto-group-product-classification-challenge).

## Getting started

1. Put `train.csv` and `test.csv` under the `data` folder
2. Run the script
3. Submit the `submission.csv`

The parameter `nthread` controls the number of cores to run on, please set it to suit your machine.

## R-package

To install the R-package of xgboost, please run

```r
install.packages("xgboost", repos = "https://cran.r-project.org")
```

Windows users may need to install [RTools](http://cran.r-project.org/bin/windows/Rtools/) first.