-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
trees with one leaf can have strong bias in predictions, far outside observed range #4708
Comments
@arnocandel Thanks for using LightGBM! LightGBM/src/boosting/gbdt.cpp Lines 404 to 438 in df12c1b
the average score will be added. But I have been doubted about the code from line 417 to 434 before, since the average score should have been already added in line 375 LightGBM/src/boosting/gbdt.cpp Line 375 in df12c1b
With your example, I now confirm that the average score is added incorrectly. I'll open a PR to fix this. |
@shiyu1994 any updates about the fix? |
#5050 is opened to fix this. The output for the example with the fixed branch:
And the outputs are consistent with |
BTW, I found a new problem when dealing with this issue. Now in CLI version of LightGBM, when a single-leaf tree is trained (or all trees are single-leaf in an iteration of multi-class boosting), the training stops. See Lines 1672 to 1681 in 01568cf
Here is_finished means that the training is finished because no more splits can be found and the last tree is just single-leaf.However, in Python API, it seems that the return value of TrainOneIter is interpreted differently, seeLightGBM/python-package/lightgbm/basic.py Lines 2967 to 2971 in 01568cf
I believe the CLI version has the correct understanding of the return value of
|
This issue has been automatically locked since there has not been any recent activity since it was closed. To start a new related discussion, open a new issue at https://github.com/microsoft/LightGBM/issues including a reference to this. |
Description
Regression model predicts outside y range, by a lot
Reproducible example
Environment info
x86 Ubuntu 20.04
LightGBM version or commit hash:
https://github.com/microsoft/LightGBM/releases/tag/v3.3.0
Command(s) you used to install LightGBM
Discovered by H2O Driverless AI testing
Additional Comments
The text was updated successfully, but these errors were encountered: