1. 01 Jul, 2021 1 commit
  2. 28 Jun, 2021 1 commit
    • Frank Fineis's avatar
      [dask] add support for eval sets and custom eval functions (#4101) · b5502d19
      Frank Fineis authored
      
      
      * es WiP, need to add eval_sample_weight and eval_group
      
      * add weight, group to dask es. WiP.
      
      * dask es reorg
      
      * Update python-package/lightgbm/dask.py
      
      _train_part model.fit args to lines
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update tests/python_package_test/test_dask.py
      
      _train_part model.fit args to lines, pt2
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      
      _train_part model.fit args to lines pt3
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update tests/python_package_test/test_dask.py
      
      dask_model.fit args to lines
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update tests/python_package_test/test_dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      
      use is instead of id()
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update tests/python_package_test/test_dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update tests/python_package_test/test_dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      
      * applying changes to eval_set PR WiP
      
      * dask support for eval_names, eval_metric, eval_stopping_rounds
      
      * add evals_result checks and other eval_set attribute-related test checks. need to merge master - WiP
      
      * fix lint errors in test_dask.py
      
      * drop group_shape from _lgbmmodel_doc_fit.format for non-rankers, add support for eval_at for dask ranker
      
      * add eval_at to test_dask eval_set ranker tests
      
      * add back group_shape to lgbmmmodel docs, tighten tests
      
      * drop random eval weights from early stopping, probably causing training to terminate too early
      
      * add eval data templates to sklearn fit docs, add eval data docs to dask
      
      * add n_features to _create_data, eval_set tests stop w/ desirable tree counts
      
      * import alphabetically
      
      * add back get_worker for eval_set error handling
      
      * test_dask argmin typo
      
      * push forgotten eval_names bugfix
      
      * eval_stopping_rounds -> early_stopping_rounds, fix failing non-es test
      
      * change default eval_at to tuple 1-5
      
      * re-drop get_worker
      
      * drop early stopping support from eval_set commits, move eval_set worker check prior to client.submit
      
      * add eval_class_weight and eval_init_score to lightgbm/dask, WiP
      
      * clean up eval_set tests, allow user to specify fewer eval_names, clswghts than eval_sets
      
      * remove redundant backslash
      
      * lint fixes
      
      * fix eval_at, eval_metric duplication, let eval_at be Iterable not just Tuple
      
      * use all data_outputs for test_eval_set tests
      
      * undo newlines from first pr
      
      * add custom_eval_metric test, correct issue with eval_at and metric names
      
      * move _constant_metric outside of test
      
      * dataset reference names instead of __strings__
      
      * add padding to eval_set parts makes each part has same len(eval_set)
      
      * eval set code clean up
      
      * revert n_evals to be max len eval_set across all parts on worker
      
      * pylint errors in _DatasetNames
      
      * more pylint fixes
      
      * pylinting...
      
      * add by pytest.mark, mistakenly deleted during merge conflict resolution
      
      * address code review comments
      
      * add _pad_eval_names to handle nondeterministic evals_result_ valid set names
      
      * change not evaluated evals_result_ test criteria
      
      * address fit eval docs issues, switch _DatasetNames to Enum
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Update python-package/lightgbm/dask.py
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * update eval_metrics, eval_at dask fit docstr to match sklearn, make tests reflect that l2 (rmse), logloss in evals_result_ by default
      
      * address eval_set dict keys naming in docstr and training eval_set naming issue
      
      * in test_dask check for obj-default metric names in eval_results, remove check for training key
      
      * lint fixes for _pad_eval_names
      
      * remove unnecessary breaklinen in _pad_eval_names docstr
      
      * use Enum.member syntax not Enum.member.name
      
      * remove str from supported eval_at types
      
      * add whitespace and remove DaskDataframes mention from eval_ param docstrs in _train
      
      * remove "of shape = [n_samples]" from group_shape docs
      
      * add eval_at base_doc in DaskLGBMRanker.fit
      
      * remove excess paren from eval_names docs in _train
      
      * make requested changes to test_dask.py
      
      * remove Optional() wrapper on eval_at
      
      * add _lgbmmodel_doc_custom_eval_note to dask.py fit.__doc__
      
      * fix ordering of .sklearn imports to attempt lint fix
      
      * dask custom eval note to f-string pt1
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * dask custom eval note to f-string pt 2
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * dask custom eval note to f-string pt 3
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      Co-authored-by: default avatarJames Lamb <jaylamb20@gmail.com>
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      b5502d19
  3. 21 May, 2021 1 commit
  4. 20 May, 2021 1 commit
  5. 04 May, 2021 1 commit
  6. 02 May, 2021 1 commit
  7. 30 Apr, 2021 1 commit
  8. 26 Apr, 2021 1 commit
  9. 19 Apr, 2021 1 commit
  10. 04 Mar, 2021 1 commit
    • jmoralez's avatar
      [dask] Include support for init_score (#3950) · 37e98782
      jmoralez authored
      * include support for init_score
      
      * use dataframe from init_score and test difference with and without init_score in local model
      
      * revert refactoring
      
      * initial docs. test between distributed models with and without init_score
      
      * remove ranker from tests
      
      * test value for root node and change docs
      
      * comma
      
      * re-include parametrize
      
      * fix incorrect merge
      
      * use single init_score and the booster_ attribute
      
      * use np.float64 instead of float
      37e98782
  11. 16 Feb, 2021 2 commits
  12. 15 Feb, 2021 1 commit
  13. 10 Feb, 2021 1 commit
  14. 09 Feb, 2021 1 commit
  15. 26 Jan, 2021 2 commits
  16. 25 Jan, 2021 1 commit
  17. 24 Jan, 2021 1 commit
  18. 19 Jan, 2021 1 commit
  19. 18 Jan, 2021 1 commit
  20. 09 Dec, 2020 1 commit
    • Nikita Titov's avatar
      [python] Drop Python 2 support (#3581) · 44a6fb7f
      Nikita Titov authored
      * Update setup.py
      
      * Update .appveyor.yml
      
      * Update .travis.yml
      
      * Update .vsts-ci.yml
      
      * Update __init__.py
      
      * Update test.sh
      
      * Update test_windows.ps1
      
      * Update advanced_example.py
      
      * Update requirements_base.txt
      
      * Update conf.py
      
      * Update conf.py
      
      * Update test_engine.py
      
      * Update utils.py
      
      * Update dockerfile-r
      
      * Update README.md
      
      * Update dockerfile.gpu
      
      * Update test_consistency.py
      
      * Update basic.py
      
      * Update compat.py
      
      * Update engine.py
      
      * Update sklearn.py
      
      * Update sklearn.py
      
      * Update callback.py
      
      * Update setup.py
      
      * Update __init__.py
      
      * Update plotting.py
      
      * Update sklearn.py
      
      * Update engine.py
      
      * Update compat.py
      
      * Update callback.py
      
      * Update basic.py
      
      * Update compat.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update compat.py
      
      * Update compat.py
      
      * Update plotting.py
      
      * Update engine.py
      
      * Update basic.py
      
      * Update sklearn.py
      
      * Update compat.py
      
      * Update engine.py
      
      * Update engine.py
      
      * Update callback.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update sklearn.py
      
      * Update sklearn.py
      
      * Update plotting.py
      
      * Update sklearn.py
      
      * Update compat.py
      
      * Update compat.py
      
      * Update engine.py
      
      * Update plotting.py
      
      * Update sklearn.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update compat.py
      
      * Update compat.py
      
      * Update compat.py
      
      * Update engine.py
      
      * Update basic.py
      
      * Update compat.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update compat.py
      
      * Update compat.py
      
      * Update basic.py
      
      * Update basic.py
      
      * Update .vsts-ci.yml
      
      * Update .vsts-ci.yml
      
      * Update conf.py
      
      * Revert "Update dockerfile-r"
      
      This reverts commit 4ff6ffc7e3eeda24cc6a59a3bb0c973f02d9d71c.
      44a6fb7f
  21. 10 Nov, 2020 1 commit
  22. 29 Sep, 2020 1 commit
  23. 06 Sep, 2020 1 commit
  24. 02 Sep, 2020 1 commit
  25. 24 Aug, 2020 1 commit
  26. 11 Aug, 2020 1 commit
  27. 06 Aug, 2020 1 commit
  28. 14 Jul, 2020 1 commit
  29. 07 Jul, 2020 1 commit
  30. 28 Jun, 2020 1 commit
    • Ilya Matiach's avatar
      adding sparse support to TreeSHAP in lightgbm (#3000) · 9f367d11
      Ilya Matiach authored
      * adding sparse support to TreeSHAP in lightgbm
      
      * updating based on comments
      
      * updated based on comments, used fromiter instead of frombuffer
      
      * updated based on comments
      
      * fixed limits import order
      
      * fix sparse feature contribs to work with more than int32 max rows
      
      * really fixed int64 max error and build warnings
      
      * added sparse test with >int32 max rows
      
      * fixed python side reshape check on sparse data
      
      * updated based on latest comments
      
      * fixed comments
      
      * added CSC INT32_MAX validation to test, fixed comments
      9f367d11
  31. 27 Jun, 2020 1 commit
    • Alex's avatar
      [python][scikit-learn] new stacking tests and make number of features a property (#3173) · 72849466
      Alex authored
      * modify attribute and include stacking tests
      
      * backwards compatibility
      
      * check sklearn version
      
      * move stacking import
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      Split number of features and stacking tests.
      
      * Number of input features (#3173)
      
      Modify test name.
      
      * Number of input features (#3173)
      
      Update stacking tests for review comments.
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      Modify classifier test.
      
      * Number of input features (#3173)
      
      * Number of input features (#3173)
      
      Check score.
      72849466
  32. 22 Jun, 2020 1 commit
  33. 02 Jun, 2020 1 commit
  34. 05 May, 2020 1 commit
  35. 10 Apr, 2020 1 commit
    • Nikita Titov's avatar
      [python] Re-enable scikit-learn 0.22+ support (#2949) · c633c6c2
      Nikita Titov authored
      * Revert "specify the last supported version of scikit-learn (#2637)"
      
      This reverts commit d1002776.
      
      * ban scikit-learn 0.22.0 and skip broken test
      
      * fix updated test
      
      * fix lint test
      
      * Revert "fix lint test"
      
      This reverts commit 8b4db0805fe7a9e7f7eb0be3eac231f85026d196.
      c633c6c2
  36. 20 Mar, 2020 1 commit
    • Lukas Pfannschmidt's avatar
      [python] handle RandomState object in Scikit-learn Api (#2904) · cf0a992e
      Lukas Pfannschmidt authored
      
      
      * Add handling of RandomState object, which is standard for sklearn methods.
      
      LightGBM expects an integer seed instead of an object.
      If passed object is RandomState, we choose random integer based on its state to seed the underlying low level code.
      While chosen random integer is only in the range between 1 and 1e10 I expect it to have enough entropy (?) to not matter in practice.
      
      * Add RandomState object to random_state docstring.
      
      * remove blank line
      
      * Use property to handle setting random_state.
      This enables setting cloned estimators with the set_params method in sklearn.
      
      * Add docstring to attribute.
      
      * Fix and simplify docstring.
      
      * Add test case.
      
      * Use maximal int for datatype in seed derivation.
      
      * Replace random_state property with interfacing in fit method.
      Derives int seed for C code only when fitting and keeps RandomState object as param.
      
      * Adapt unit test to property change.
      
      * Extended test case and docstring
      Co-Authored-By: default avatarNikita Titov <nekit94-08@mail.ru>
      
      * Add more equality checks (feature importance, best iteration/score).
      
      * Add equality comparison of boosters represented by strings.
      Remove useless best_iteration_ comparison (we do not use early_stopping).
      
      * fix whitespace
      
      * Test if two subsequent fits produce different models
      
      * Apply suggestions from code review
      Co-Authored-By: default avatarNikita Titov <nekit94-08@mail.ru>
      Co-authored-by: default avatarNikita Titov <nekit94-08@mail.ru>
      cf0a992e
  37. 15 Feb, 2020 1 commit
  38. 06 Feb, 2020 1 commit