项目文件夹

文件
wehub-resource-sync f3cad95168
Release Drafter / updateReleaseDraft (push) Has been cancelled
Build / archive (push) Has been cancelled
Python-package / bdist wheel (manylinux2014-arm, gcc, Python 3.14) (push) Has been cancelled
Python-package / sdist (windows-2022, MSVC, Python 3.10) (push) Has been cancelled
Python-package / sdist (macos-15-intel, clang, Python 3.10) (push) Has been cancelled
Python-package / mpi pip (ubuntu22.04, clang-17, Python 3.12) (push) Has been cancelled
Python-package / mpi source (ubuntu22.04, clang-17, Python 3.13) (push) Has been cancelled
Python-package / regular (ubuntu22.04, clang-17, Python 3.13) (push) Has been cancelled
Python-package / sdist (ubuntu22.04, clang-17, Python 3.14) (push) Has been cancelled
C++ / if-else (macos-15-intel, clang) (push) Has been cancelled
C++ / cpp-tests (macos-15-intel, clang) (push) Has been cancelled
C++ / if-else (ubuntu22.04, clang-17) (push) Has been cancelled
C++ / cpp-tests (ubuntu22.04, clang-17) (push) Has been cancelled
C++ / if-else (manylinux_2_28, gcc) (push) Has been cancelled
C++ / cpp-tests (windows-2022, msvc) (push) Has been cancelled
Python-package / gpu source (manylinux_2_28, gcc, Python 3.14) (push) Has been cancelled
Python-package / mpi source (macos-15-intel, gcc, Python 3.12) (push) Has been cancelled
Python-package / regular (manylinux_2_28, gcc, Python 3.11) (push) Has been cancelled
Python-package / bdist wheel (manylinux_2_28, gcc, Python 3.10) (push) Has been cancelled
Python-package / regular (macos-15-intel, clang, Python 3.11) (push) Has been cancelled
Python-package / bdist wheel (macos-15-intel, clang, Python 3.13) (push) Has been cancelled
Python-package / bdist wheel (macos-14, clang, Python 3.11) (push) Has been cancelled
Python-package / sdist (manylinux_2_28, gcc, Python 3.10) (push) Has been cancelled
Python-package / mpi wheel (ubuntu22.04, clang-17, Python 3.10) (push) Has been cancelled
Python-package / mpi source (manylinux_2_28, gcc, Python 3.11) (push) Has been cancelled
Python-package / regular (windows-2022, MSVC, Python 3.11) (push) Has been cancelled
Python-package / bdist wheel (windows-2022, MSVC, Python 3.13) (push) Has been cancelled
Python-package / Python - latest versions (manylinux_2_28) (push) Has been cancelled
Python-package / Python - oldest supported versions (manylinux_2_28, Python 3.10) (push) Has been cancelled
R-package / r-package (windows-2022, MSVC, R 4.3, cmake) (push) Has been cancelled
R-package / r-package (macos-15-intel, clang, R 4.3, cmake) (push) Has been cancelled
R-package / r-package (ubuntu22.04, clang, R 4.3, cmake) (push) Has been cancelled
R-package / r-package (ubuntu22.04, gcc, R 4.3, cmake) (push) Has been cancelled
R-package / r-package (windows-latest, MINGW, R 4.3, cran) (push) Has been cancelled
R-package / r-package (macos-14, clang, R 4.3, cran) (push) Has been cancelled
R-package / r-package (macos-15-intel, clang, R 4.3, cran) (push) Has been cancelled
R-package / r-package (clang21, R-devel) (push) Has been cancelled
R-package / r-package (windows-latest, MINGW, R 4.3, cmake) (push) Has been cancelled
R-package / r-package (ubuntu22.04, gcc, R 4.3, cran) (push) Has been cancelled
R-package / r-sanitizers (ubuntu-latest, R-devel, clang ASAN/UBSAN) (push) Has been cancelled
R-package / r-sanitizers (ubuntu-latest, R-devel, gcc ASAN/UBSAN) (push) Has been cancelled
R-package / r-package (clang22, R-devel) (push) Has been cancelled
R-package / r-package (gcc16, R-devel) (push) Has been cancelled
R-package / r-package (rchk, R-devel) (push) Has been cancelled
R-package / r-package (ubuntu-clang, R-devel) (push) Has been cancelled
R-package / r-package (ubuntu-gcc12, R-devel) (push) Has been cancelled
Static Analysis / lint (push) Has been cancelled
Static Analysis / check-docs (push) Has been cancelled
Static Analysis / r-package-check-docs (push) Has been cancelled
SWIG / swig (manylinux_2_28, gcc) (push) Has been cancelled
SWIG / swig (macos-15-intel, clang) (push) Has been cancelled
SWIG / swig (windows-2022, msvc) (push) Has been cancelled
SWIG / all-swig-jobs-successful (push) Has been cancelled
Build / all-build-jobs-successful (push) Has been cancelled
C++ / all-cpp-jobs-successful (push) Has been cancelled
Python-package / NuGet package (push) Has been cancelled
Python-package / upload-nightlies (push) Has been cancelled
Python-package / all-python-package-jobs-successful (push) Has been cancelled
R-package / all-r-package-jobs-successful (push) Has been cancelled
Static Analysis / all-static-analysis-jobs-successful (push) Has been cancelled
docs: make Chinese README the default
2026-07-13 10:38:42 +00:00

202 行
13 KiB
Markdown

此文件含有模棱两可的 Unicode 字符
此文件含有可能会与其他字符混淆的 Unicode 字符。 如果您是想特意这样的,可以安全地忽略该警告。 使用 Escape 按钮显示他们。
<!-- WEHUB_ZH_README -->
> [!NOTE]
> 本文档由 WeHub 基于上游 README 翻译整理,属于社区翻译,非官方中文文档。
> [English](./README.en.md) · [原始项目](https://github.com/lightgbm-org/LightGBM) · [上游 README](https://github.com/lightgbm-org/LightGBM/blob/HEAD/README.md)
> 原作者、版权与许可证归属以原始项目及本仓库 LICENSE 文件为准。
<img src=https://github.com/lightgbm-org/LightGBM/blob/main/docs/logo/LightGBM_logo_black_text.svg width=300 />
> [!NOTE]
> 本项目已于 2026 年 3 月从 `Microsoft/LightGBM` 迁移至 `lightgbm-org/LightGBM`。
> 本仓库仍是 LightGBM 的官方源代码,由同一批维护者(包括 LightGBM 的创建者)管理。
> 详情请参阅 https://github.com/lightgbm-org/LightGBM/issues/7187
Light Gradient Boosting Machine
===============================
[![C++ GitHub Actions Build Status](https://github.com/lightgbm-org/LightGBM/actions/workflows/cpp.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/cpp.yml)
[![Python-package GitHub Actions Build Status](https://github.com/lightgbm-org/LightGBM/actions/workflows/python_package.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/python_package.yml)
[![R-package GitHub Actions Build Status](https://github.com/lightgbm-org/LightGBM/actions/workflows/r_package.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/r_package.yml)
[![CUDA Version GitHub Actions Build Status](https://github.com/lightgbm-org/LightGBM/actions/workflows/cuda.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/cuda.yml)
[![SWIG Wrapper GitHub Actions Build Status](https://github.com/lightgbm-org/LightGBM/actions/workflows/swig.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/swig.yml)
[![Static Analysis GitHub Actions Build Status](https://github.com/lightgbm-org/LightGBM/actions/workflows/static_analysis.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/static_analysis.yml)
[![Appveyor Build Status](https://ci.appveyor.com/api/projects/status/1ys5ot401m0fep6l/branch/main?svg=true)](https://ci.appveyor.com/project/guolinke/lightgbm/branch/main)
[![Documentation Status](https://readthedocs.org/projects/lightgbm/badge/?version=latest)](https://lightgbm.readthedocs.io/)
[![Link checks](https://github.com/lightgbm-org/LightGBM/actions/workflows/lychee.yml/badge.svg?branch=main)](https://github.com/lightgbm-org/LightGBM/actions/workflows/lychee.yml)
[![License](https://img.shields.io/github/license/lightgbm-org/lightgbm.svg)](https://github.com/lightgbm-org/LightGBM/blob/main/LICENSE)
[![EffVer Versioning](https://img.shields.io/badge/version_scheme-EffVer-0097a7)](https://jacobtomlinson.dev/effver)
[![StackOverflow questions](https://img.shields.io/stackexchange/stackoverflow/t/lightgbm?logo=stackoverflow&logoColor=white&label=StackOverflow%20questions)](https://stackoverflow.com/questions/tagged/lightgbm?sort=votes)
[![Python Versions](https://img.shields.io/pypi/pyversions/lightgbm.svg?logo=python&logoColor=white)](https://pypi.org/project/lightgbm)
[![PyPI Version](https://img.shields.io/pypi/v/lightgbm.svg?logo=pypi&logoColor=white)](https://pypi.org/project/lightgbm)
[![conda Version](https://img.shields.io/conda/vn/conda-forge/lightgbm?logo=conda-forge&logoColor=white&label=conda)](https://anaconda.org/conda-forge/lightgbm)
[![CRAN Version](https://www.r-pkg.org/badges/version/lightgbm)](https://cran.r-project.org/package=lightgbm)
[![NuGet Version](https://img.shields.io/nuget/v/lightgbm?logo=nuget&logoColor=white)](https://www.nuget.org/packages/LightGBM)
[![Winget Version](https://img.shields.io/winget/v/Microsoft.LightGBM)](https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/LightGBM)
LightGBM 是一个采用基于树的学习算法的梯度提升(gradient boosting)框架。它面向分布式与高效场景设计,具有以下优势:
- 更快的训练速度与更高的效率。
- 更低的内存占用。
- 更好的准确率。
- 支持并行、分布式与 GPU 学习。
- 能够处理大规模数据。
更多细节请参阅 [Features](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Features.rst).
得益于这些优势,LightGBM 已广泛应用于众多机器学习竞赛的[获奖方案](https://github.com/lightgbm-org/LightGBM/blob/main/examples/README.md#machine-learning-challenge-winning-solutions)。
在公开数据集上的[对比实验](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Experiments.rst#comparison-experiment)表明,LightGBM 在效率与准确率方面均可优于现有 boosting 框架,且内存消耗显著更低。此外,[分布式学习实验](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Experiments.rst#parallel-experiment)表明,在特定设置下,LightGBM 可通过使用多台机器进行训练实现线性加速。
Get Started and Documentation
-----------------------------
我们的主要文档位于 https://lightgbm.readthedocs.io/,由本仓库生成。如果你是 LightGBM 新手,请按照该站点上的[安装说明](https://lightgbm.readthedocs.io/en/latest/Installation-Guide.html)操作。
接下来你可能想阅读:
- [**Examples**](https://github.com/lightgbm-org/LightGBM/tree/main/examples)展示常见任务的命令行用法。
- [**Features**](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Features.rst)以及 LightGBM 支持的算法。
- [**Parameters**](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Parameters.rst)是可进行自定义的详尽参数列表。
- [**Distributed Learning**](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Parallel-Learning-Guide.rst)与 [**GPU Learning**](https://github.com/lightgbm-org/LightGBM/blob/main/docs/GPU-Tutorial.rst)可加速计算。
- [**FLAML**](https://www.microsoft.com/en-us/research/project/fast-and-lightweight-automl-for-large-scale-data/articles/flaml-a-fast-and-lightweight-automl-library/)为 LightGBM 提供自动化调参([代码示例](https://microsoft.github.io/FLAML/docs/Examples/AutoML-for-LightGBM/)).
- [**Optuna Hyperparameter Tuner**](https://medium.com/optuna/lightgbm-tuner-new-optuna-integration-for-hyperparameter-optimization-8b7095e99258)为 LightGBM 超参数提供自动化调参([代码示例](https://github.com/optuna/optuna-examples/blob/main/lightgbm/lightgbm_tuner_simple.py)).
- [**Understanding LightGBM Parameters (and How to Tune Them using Neptune)**](https://neptune.ai/blog/lightgbm-parameters-guide).
面向贡献者的文档:
- [**How we update readthedocs.io**](https://github.com/lightgbm-org/LightGBM/blob/main/docs/README.rst).
- 查看 [**Development Guide**](https://github.com/lightgbm-org/LightGBM/blob/main/docs/Development-Guide.rst).
News
----
请参阅 [GitHub releases](https://github.com/lightgbm-org/LightGBM/releases)页面的变更日志。
External (Unofficial) Repositories
----------------------------------
此处列出的项目提供了使用 LightGBM 的替代方式。
它们并非由 `LightGBM` 开发团队维护或官方背书。
JPMML (Java PMML converter): https://github.com/jpmml/jpmml-lightgbm
Nyoka (Python PMML converter): https://github.com/SoftwareAG/nyoka
Treelite (model compiler for efficient deployment): https://github.com/dmlc/treelite
lleaves (LLVM-based model compiler for efficient inference): https://github.com/siboehm/lleaves
Hummingbird (model compiler into tensor computations): https://github.com/microsoft/hummingbird
GBNet (use `LightGBM` as a [PyTorch Module](https://docs.pytorch.org/docs/stable/generated/torch.nn.Module.html)): https://github.com/mthorrell/gbnet
cuML Forest Inference Library (GPU-accelerated inference): https://github.com/rapidsai/cuml
nvForest (GPU-accelerated inference): https://github.com/rapidsai/nvforest
daal4py (Intel CPU-accelerated inference): https://github.com/intel/scikit-learn-intelex/tree/master/daal4py
m2cgen (model appliers for various languages): https://github.com/BayesWitnesses/m2cgen
leavesGo 模型应用器):https://github.com/dmitryikh/leaves
ONNXMLToolsONNX 转换器):https://github.com/onnx/onnxmltools
SHAP(模型输出解释器):https://github.com/slundberg/shap
Shapash(模型可视化与解释):https://github.com/MAIF/shapash
dtreeviz(决策树可视化与模型解释):https://github.com/parrt/dtreeviz
supertree(决策树交互式可视化):https://github.com/mljar/supertree
SynapseMLSpark 上的 LightGBM):https://github.com/microsoft/SynapseML
Kubeflow FairingKubernetes 上的 LightGBM):https://github.com/kubeflow/fairing
Kubeflow OperatorKubernetes 上的 LightGBM):https://github.com/kubeflow/xgboost-operator
lightgbm_rayRay 上的 LightGBM):https://github.com/ray-project/lightgbm_ray
Ray(分布式计算框架):https://github.com/ray-project/ray
MarsMars 上的 LightGBM):https://github.com/mars-project/mars
ML.NET.NET/C# 包):https://github.com/dotnet/machinelearning
LightGBM.NET.NET/C# 包):https://github.com/rca22/LightGBM.Net
LightGBM RubyRuby gem):https://github.com/ankane/lightgbm-ruby
LightGBM4jJava 高级绑定):https://github.com/metarank/lightgbm4j
LightGBM4J(用 Scala 编写的 LightGBM JVM 接口):https://github.com/seek-oss/lightgbm4j
Julia-packagehttps://github.com/IQVIA-ML/LightGBM.jl
lightgbm3Rust 绑定):https://github.com/Mottl/lightgbm3-rs
MLServerLightGBM 推理服务器):https://github.com/SeldonIO/MLServer
MLflow(实验跟踪、模型监控框架):https://github.com/mlflow/mlflow
FLAML(用于超参数优化的 AutoML 库):https://github.com/microsoft/FLAML
MLJAR AutoML(表格数据上的 AutoML):https://github.com/mljar/mljar-supervised
Optuna(超参数优化框架):https://github.com/optuna/optuna
LightGBMLSS(基于 LightGBM 的概率建模):https://github.com/StatMixedML/LightGBMLSS
LightGBM-MoE(专家混合 / 状态切换扩展):https://github.com/kyo219/LightGBM-MoE
darts(使用 LightGBM 进行时间序列预测与异常检测):https://github.com/unit8co/darts
mlforecast(使用 LightGBM 进行时间序列预测):https://github.com/Nixtla/mlforecast
skforecast(使用 LightGBM 进行时间序列预测):https://github.com/JoaquinAmatRodrigo/skforecast
`{bonsai}`(符合 R `{parsnip}` 规范的接口):https://github.com/tidymodels/bonsai
`{mlr3extralearners}`(符合 R `{mlr3}` 规范的接口):https://github.com/mlr-org/mlr3extralearners
lightgbm-transform(特征转换绑定):https://github.com/lightgbm-org/LightGBM-transform
`postgresml`(通过 Postgres 扩展在 SQL 中进行 LightGBM 训练与预测):https://github.com/postgresml/postgresml
`pyodide`(在 Web 浏览器中运行 `lightgbm` Python 包):https://github.com/pyodide/pyodide
`vaex-ml`(自带 LightGBM 接口的 Python DataFrame 库):https://github.com/vaexio/vaex
支持
-------
- 在 [Stack Overflow 上使用 `lightgbm` 标签提问](https://stackoverflow.com/questions/ask?tags=lightgbm), we monitor this for new questions.
- 在 [GitHub issues](https://github.com/lightgbm-org/LightGBM/issues). 上提交 **bug 报告****功能请求**
如何贡献
-----------------
请参阅 [CONTRIBUTING](https://github.com/lightgbm-org/LightGBM/blob/main/CONTRIBUTING.md) 页面。
Microsoft 开源行为准则
-------------------------------------
本项目已采纳 [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). 更多信息请参阅 [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/),或通过 [opencode@microsoft.com](mailto:opencode@microsoft.com) 联系我们提出其他问题或意见。
参考论文
----------------
Yu Shi, Guolin Ke, Zhuoming Chen, Shuxin Zheng, Tie-Yan Liu. "Quantized Training of Gradient Boosting Decision Trees"[链接](https://proceedings.neurips.cc/paper/2022/hash/77911ed9e6e864ca1a3d165b2c3cb258-Abstract.html)). Advances in Neural Information Processing Systems 35 (NeurIPS 2022), pp. 18822-18833.
Guolin Ke, Qi Meng, Thomas Finley, Taifeng Wang, Wei Chen, Weidong Ma, Qiwei Ye, Tie-Yan Liu. "[LightGBM: A Highly Efficient Gradient Boosting Decision Tree](https://proceedings.neurips.cc/paper/2017/hash/6449f44a102fde848669bdd9eb6b76fa-Abstract.html)". Advances in Neural Information Processing Systems 30 (NIPS 2017), pp. 3149-3157.
Qi Meng, Guolin Ke, Taifeng Wang, Wei Chen, Qiwei Ye, Zhi-Ming Ma, Tie-Yan Liu. "[A Communication-Efficient Parallel Algorithm for Decision Tree](https://proceedings.neurips.cc/paper/2016/hash/10a5ab2db37feedfdeaab192ead4ac0e-Abstract.html)". Advances in Neural Information Processing Systems 29 (NIPS 2016), pp. 1279-1287.
Huan Zhang, Si Si and Cho-Jui Hsieh. "[GPU Acceleration for Large-scale Tree Boosting](https://arxiv.org/abs/1706.08359)". SysML Conference, 2018.
许可证
-------
本项目依据 MIT 许可证条款授权。更多详情请参阅 [LICENSE](https://github.com/lightgbm-org/LightGBM/blob/main/LICENSE)。