Граф коммитов

1007 Коммитов

Автор SHA1 Сообщение Дата
Nikita Titov b7de71df53
[docs] fix inaccurate comment for `force_col_wise` param with CUDA version (#6695) 2024-10-24 22:45:38 -04:00
dragonbra c7d3ac1b41
[GPU] Add support for linear tree with device=gpu (#6567)
* basic gpu_linear_tree_learner implementation

* corresponding config of gpu linear tree

* Update src/io/config.cpp

Co-authored-by: Nikita Titov <nekit94-08@mail.ru>

* work around for gpu linear tree learner without gpu enabled

* add #endif

* add #ifdef USE_GPU

* fix lint problems

* fix compilation when USE_GPU is OFF

* add destructor

* add gpu_linear_tree_learner.cpp in make file list

* use template for linear tree learner

---------

Co-authored-by: Nikita Titov <nekit94-08@mail.ru>
Co-authored-by: shiyu1994 <shiyu_k1994@qq.com>
2024-10-18 13:55:28 +08:00
Atanas Dimitrov bbeecc09af
[c++] Fix `dump_model()` information for root node (#6569)
Co-authored-by: Atanas Dimitrov <nasko119@abv.bg>
Co-authored-by: James Lamb <jaylamb20@gmail.com>
2024-10-13 16:03:04 -05:00
shiyu1994 d1d218c329
[c++] Add Bagging by Query for Lambdarank (#6623)
* add bagging by query for lambdarank

* fix pre-commit

* fix bagging by query with cuda

* fix bagging by query test case

* fix bagging by query test case

* fix bagging by query test case

* add #include <vector>

* Update include/LightGBM/objective_function.h

Co-authored-by: Nikita Titov <nekit94-08@mail.ru>

* Update tests/python_package_test/test_engine.py

Co-authored-by: Nikita Titov <nekit94-08@mail.ru>

* Update tests/python_package_test/test_engine.py

Co-authored-by: Nikita Titov <nekit94-08@mail.ru>

---------

Co-authored-by: Nikita Titov <nekit94-08@mail.ru>
2024-10-03 00:19:28 +08:00
Nikita Titov 35a2a2e379
[ci] place all CI helpers under the .ci folder and use - instead of _ in their names (#6581) 2024-07-31 08:36:20 -05:00
James Lamb 2bc3ab86b7
[python-package] respect 'verbose' setting when using custom objective function (fixes #6014) (#6428) 2024-07-12 11:21:39 -07:00
James Lamb 525f8b4b80
[c++] remove HDFS support (fixes #6436) (#6534) 2024-07-12 09:31:34 -07:00
Christian Bourjau 1886bf5122
[c++] Avoid copy on Refit (#6478) 2024-07-10 09:21:21 -07:00
Nikita Titov 4292b16837
fix cpp casting errors "Comparison of narrow type with wide type in loop condition" (#6533) 2024-07-10 09:03:08 -07:00
Hoang Gia Minh a5054f7752
[C++] Remove template parameters from constructors (#6514) 2024-07-05 00:20:17 -05:00
Ikko Eltociear Ashimine d56a7a3c36
chore: update dataset_loader.cpp (#6483) 2024-06-16 21:33:43 -05:00
James Lamb 8579d5e34f
[python-package] clarify max_depth warning and limit when it is emitted (#6402) 2024-06-04 19:46:07 -05:00
Oliver Borchert 9f5fbb6479
[python-package] Allow to pass early stopping min delta in params (#6274)
* [python-package] Allow to pass early stopping min delta in params

* Fix test

* Add separate test

* Fix

* Add to cpp config

* Adjust test

* Adjust test

* Debug

* Revert

* Apply suggestions from code review

---------

Co-authored-by: James Lamb <jaylamb20@gmail.com>
2024-05-01 19:57:55 +02:00
Yohei Kishimoto 1871350515
remove unnecessary omp single that cause deadlock (fixes #6273) (#6394) 2024-04-22 21:52:02 -05:00
Parsiad Azimzadeh 89824a6c70
[docs] document how to use a custom objective function via the C API (#6396) 2024-04-20 01:37:32 -05:00
James Lamb 4466349cb9
[c++] remove unused variable 'need_connect_cnt' (#6410) 2024-04-19 17:36:25 -05:00
James Lamb 631e0a2a7b
[ci] prevent trailing whitespace, ensure files end with newline (#6373) 2024-03-18 23:24:14 -05:00
Thomas B 0a3e1a550c
Fix single row prediction performance in a multi-threaded environment (#6024) 2024-03-18 16:46:48 -05:00
James Lamb a26302f57b
[c++] remove unnecessary include in CLI (#6342) 2024-02-28 18:52:58 -06:00
shiyu1994 776c5c3c49
[c++][fix] Support Quantized Training with Categorical Features on CPU (#6301)
* support quantized training with categorical features on cpu

* remove white spaces

* add tests for quantized training with categorical features

* skip tests for cuda version

* fix cases when only 1 data block in row-wise quantized histogram construction with 8 inner bits

* remove useless capture

* fix compilation warnings

revert useless changes

* revert useless change

* separate functions in feature histogram into cpp file

* add feature_histogram.o in Makevars
2024-02-23 13:41:21 +08:00
Christian Lorentzen 894066dbcd
ENH more stable gradient of CrossEntropy (#6327)
* ENH more stable gradient of CrossEntropy

* FIX missing }

* FIX index score

* FIX missing parenthesis in hessian

---------

Co-authored-by: shiyu1994 <shiyu_k1994@qq.com>
2024-02-22 11:26:09 +08:00
CVPaul d0d70716ce
Fix calculation of number of bins in FindGroup (#6019)
* solve 'bin size 257 cannot run on GPU #3339'

https://github.com/microsoft/LightGBM/issues/3339#issuecomment-1665131743

* fix  typo LeafIndex -> leaf_index

---------

Co-authored-by: shiyu1994 <shiyu_k1994@qq.com>
Co-authored-by: James Lamb <jaylamb20@gmail.com>
2024-02-20 14:31:11 +08:00
James Lamb 255c93b551
[R-package] [ci] remove unnecessary include in linear_tree_learner (fixes #6264) (#6265) 2024-01-16 21:27:59 -08:00
Oliver Borchert 2dfb9a4047
[python-package] Allow to pass Arrow table for prediction (#6168) 2023-12-13 21:35:46 -06:00
James Lamb 1548b42bac
[R-package] [c++] add tighter multithreading control, avoid global OpenMP side effects (fixes #4705, fixes #5102) (#6226) 2023-12-07 17:03:16 -06:00
Oliver Borchert f5b6bd60d9
[python-package] Allow to pass Arrow table and array as init scores (#6167) 2023-12-04 13:26:55 -06:00
Oliver Borchert 516bde9501
[python-package] Allow to pass Arrow array as groups (#6166) 2023-11-22 15:50:31 -06:00
James Lamb bc6942226e
[CUDA] fix typo in error message (#6207) 2023-11-22 14:15:11 -06:00
Oliver Borchert deb70773b8
[python-package] Allow to pass Arrow array as weights (#6164) 2023-11-13 12:03:58 -06:00
Oliver Borchert b7f6311f27
[python-package] Allow to pass Arrow array as labels (#6163) 2023-11-07 12:14:09 -06:00
Oliver Borchert 3405ee82b9
[python-package] Allow to pass Arrow table as training data (#6034) 2023-11-01 08:21:48 -05:00
James Lamb 8ed371cee4
set explicit number of threads in every OpenMP `parallel` region (#6135) 2023-10-09 20:05:51 -05:00
James Lamb 992f505665
factor out uses of omp_get_num_threads() and omp_get_max_threads() outside of OpenMP wrapper (#6133) 2023-10-08 22:43:49 -05:00
shiyu1994 f901f47141
[CUDA] CUDA Quantized Training (fixes #5606) (#5933)
* add quantized training (first stage)

* add histogram construction functions for integer gradients

* add stochastic rounding

* update docs

* fix compilation errors by adding template instantiations

* update files for compilation

* fix compilation of gpu version

* initialize gradient discretizer before share states

* add a test case for quantized training

* add quantized training for data distributed training

* Delete origin.pred

* Delete ifelse.pred

* Delete LightGBM_model.txt

* remove useless changes

* fix lint error

* remove debug loggings

* fix mismatch of vector and allocator types

* remove changes in main.cpp

* fix bugs with uninitialized gradient discretizer

* initialize ordered gradients in gradient discretizer

* disable quantized training with gpu and cuda

fix msvc compilation errors and warnings

* fix bug in data parallel tree learner

* make quantized training test deterministic

* make quantized training in test case more accurate

* refactor test_quantized_training

* fix leaf splits initialization with quantized training

* check distributed quantized training result

* add cuda gradient discretizer

* add quantized training for CUDA version in tree learner

* remove cuda computability 6.1 and 6.2

* fix parts of gpu quantized training errors and warnings

* fix build-python.sh to install locally built version

* fix memory access bugs

* fix lint errors

* mark cuda quantized training on cuda with categorical features as unsupported

* rename cuda_utils.h to cuda_utils.hu

* enable quantized training with cuda

* fix cuda quantized training with sparse row data

* allow using global memory buffer in histogram construction with cuda quantized training

* recover build-python.sh

enlarge allowed package size to 100M
2023-10-08 23:25:46 +08:00
José Morales b793cd821c
ignore unknown parameters when loading from model file (#6126) 2023-10-06 22:43:40 -05:00
James Lamb ab1eaa832d
[python-package] [R-package] include more params in model text representation (fixes #6010) (#6077) 2023-09-13 17:35:38 -05:00
shiyu1994 a92bf3742b
[fix] fix quantized training (fixes #5982) (fixes #5994) (#6092)
* fix leaf splits update after split in quantized training

* fix preparation ordered gradients for quantized training

* remove force_row_wise in distributed test for quantized training

* Update src/treelearner/leaf_splits.hpp

---------

Co-authored-by: James Lamb <jaylamb20@gmail.com>
2023-09-13 01:06:20 +08:00
mjmckp 8203306400
Fix updates in random forest model using GOSS data sample strategy (#6017) 2023-09-04 20:34:35 -05:00
Pavel Metrikov 7e34d23c05
Treat position bias via GAM in LambdaMART (#5929)
* Update dataset.h

* Update metadata.cpp

* Update rank_objective.hpp

* Update metadata.cpp

* Update rank_objective.hpp

* Update metadata.cpp

* Update dataset.h

* Update rank_objective.hpp

* Update metadata.cpp

* Update test_engine.py

* Update test_engine.py

* Add files via upload

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update _rank.train.position

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update _rank.train.position

* Update _rank.train.position

* Update test_engine.py

* Update _rank.train.position

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update the position of import statement

* Update rank_objective.hpp

* Update config.h

* Update config_auto.cpp

* Update rank_objective.hpp

* Update rank_objective.hpp

* update documentation

* remove extra blank line

* Update src/io/metadata.cpp

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update src/io/metadata.cpp

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* remove _rank.train.position

* add position in python API

* fix set_positions in basic.py

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update docs/Advanced-Topics.rst

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update docs/Advanced-Topics.rst

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* Update Advanced-Topics.rst

* remove List from _LGBM_PositionType

* move new position parameter to the last in Dataset constructor

* add position_filename as a parameter

* Update docs/Advanced-Topics.rst

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update docs/Advanced-Topics.rst

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update Advanced-Topics.rst

* Update src/objective/rank_objective.hpp

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update src/io/metadata.cpp

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update metadata.cpp

* Update python-package/lightgbm/basic.py

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update python-package/lightgbm/basic.py

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update python-package/lightgbm/basic.py

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update python-package/lightgbm/basic.py

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update src/io/metadata.cpp

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* more infomrative fatal message

address more comments

* update documentation for more flexible position specification

* fix SetPosition

add tests for get_position and set_position

* remove position_filename

* remove useless changes

* Update python-package/lightgbm/basic.py

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* remove useless files

* move position file when position set in Dataset

* warn when positions are overwritten

* skip ranking with position test in cuda

* split test case

* remove useless import

* Update test_engine.py

* Update test_engine.py

* Update test_engine.py

* Update docs/Advanced-Topics.rst

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* Update Parameters.rst

* Update rank_objective.hpp

* Update config.h

* update config_auto.cppp

* Update docs/Advanced-Topics.rst

Co-authored-by: James Lamb <jaylamb20@gmail.com>

* fix randomness in test case for gpu

---------

Co-authored-by: shiyu1994 <shiyu_k1994@qq.com>
Co-authored-by: James Lamb <jaylamb20@gmail.com>
2023-09-04 17:05:46 +08:00
James Lamb 1881a50178
reduce verbosity of some log messages (#6073) 2023-09-03 13:41:01 -05:00
Zachary Huang 37c3d3fb80
fix percentile computation for regression objectives (#5848)
* Update regression_objective.hpp

* Update regression_objective.hpp

Maybe still need a (1.0 - alpha)

* fix position in percentile calculation

* fix regression metric threshold for l1

---------

Co-authored-by: shiyu1994 <shiyu_k1994@qq.com>
2023-08-15 10:11:39 +08:00
shiyu1994 5c9e61d190
[CUDA] Set GPU device ID in threads (#6028)
* set gpu device id in open mp threads

* move SetCUDADevice outside for loop

---------

Co-authored-by: James Lamb <jaylamb20@gmail.com>
2023-08-13 23:13:58 +08:00
shiyu1994 28e0e6f0d5
[c++] virtual destructor for gradient discretizer (#5965) 2023-07-12 18:34:29 +08:00
maskedcoder1337 9f78cceee4
move LightGBM-vendored json11 into a LightGBM-specific namespace (fixes #5944) (#5946) 2023-06-30 08:30:13 -05:00
Xuweijia-buaa 07e3cf47f6
[CUDA] Add more CUDA Regression Metrics (#5924)
* add l1 metric for cuda_exp

* add huber/fair metric for cuda_exp

* add poisson/mape/gamma/gamma_deviance/tweedie  metrics for cuda_exp

* fix cpplint error

* fix return  error
2023-06-16 16:58:29 +08:00
shiyu1994 17ecfab335
Add quantized training (CPU part) (#5800)
* add quantized training (first stage)

* add histogram construction functions for integer gradients

* add stochastic rounding

* update docs

* fix compilation errors by adding template instantiations

* update files for compilation

* fix compilation of gpu version

* initialize gradient discretizer before share states

* add a test case for quantized training

* add quantized training for data distributed training

* Delete origin.pred

* Delete ifelse.pred

* Delete LightGBM_model.txt

* remove useless changes

* fix lint error

* remove debug loggings

* fix mismatch of vector and allocator types

* remove changes in main.cpp

* fix bugs with uninitialized gradient discretizer

* initialize ordered gradients in gradient discretizer

* disable quantized training with gpu and cuda

fix msvc compilation errors and warnings

* fix bug in data parallel tree learner

* make quantized training test deterministic

* make quantized training in test case more accurate

* refactor test_quantized_training

* fix leaf splits initialization with quantized training

* check distributed quantized training result
2023-05-05 16:41:48 +08:00
José Morales 1113cb7a50
remove unused variables from bin.cpp (#5801) 2023-03-28 22:34:07 -05:00
shiyu1994 ce0813efea
[CUDA] Add quantile regression objective for new CUDA version (#5605)
* add cuda quantile regression objective

* remove white space

* resolve merge conflicts

* remove useless changes

* remove useless changes

* enable cuda quantile regression objective

* add a test case for quantile regression objective

* remove useless changes

* remove useless changes

* reduce DP_SHARED_HIST_SIZE to 5176 for CUDA 10

---------

Co-authored-by: James Lamb <jaylamb20@gmail.com>
2023-03-21 12:20:56 +08:00
shiyu1994 54486b4f6b
[CUDA] Add quantile metric for new CUDA version (contribute to #5163) (#5665)
Co-authored-by: James Lamb <jaylamb20@gmail.com>
2023-03-16 18:00:30 +08:00
Aleksandar Bojarov 8811063115
Fix DEBUG-mode GPU builds (#5778)
Fix for DEBUG mode

This commit fixes issue #5777
2023-03-15 13:44:47 +08:00