Repository navigation
prohibit use of regression_l1 objective with linear trees - #6859
Merged
Merged
Conversation
jameslamb
marked this pull request as ready for review
March 11, 2025 04:09
jameslamb
requested review from
StrikerRUS,
borchero,
guolinke,
jmoralez and
shiyu1994
as code owners
March 11, 2025 04:09
StrikerRUS
approved these changes
Mar 23, 2025
StrikerRUS
left a comment
Collaborator
There was a problem hiding this comment.
Very nice, thank you!
Contributor
|
This pull request has been automatically locked since there has not been any recent activity since it was closed. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
From the very first PR where @btrotta introduced linear trees here (#3299), it was never intended that they'd be used with the L1 loss. However, that's been technically possible the entire time because of a typo here:
https://github.com/microsoft/LightGBM/blob/6437645c4a0c17046be59e4f57d09952e2e0185f/src/io/config.cpp#L431-L433
This fixes that typo, and adds a test ensuring that LightGBM raises the expected errors when using unsupported parameters with linear trees.
Notes for Reviewers
This bug was caught by the newest version of
crates-ci/typos... pretty cool to see a spellchecker catching a real bug!!! (cc @borchero )This PR also updates other
pre-commithooks to their latest versions (though they didn't catch any new issues).