训练gbdt模型时的一些疑惑
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 48.7k
- Forks
- 7.7k
- PR merge metrics
- No merged PRs in 30d
Description
❓ Questions and Help
在训练gbdt模型的时候
准备数据的代码:
https://github.com/microsoft/qlib/blob/main/qlib/contrib/model/gbdt.py#L37
data_key=DataHandlerLP.DK_L会让y(df["label"])全是NaN
然后训练的时候得到如下日志
[20] train's rmse: 0 valid's rmse: 0
[40] train's rmse: 0 valid's rmse: 0
[60] train's rmse: 0 valid's rmse: 0
[80] train's rmse: 0 valid's rmse: 0
[100]train's rmse: 0 valid's rmse: 0
如果移除data_key
[20] train's rmse: 5.25546 valid's rmse: 3.89697
[40] train's rmse: 5.25546 valid's rmse: 3.89697
[60] train's rmse: 5.25546 valid's rmse: 3.89697
[80] train's rmse: 5.25546 valid's rmse: 3.89697
[100]train's rmse: 5.25546 valid's rmse: 3.89697
就不是0了
请问一下这里的train's rmse: 0 valid's rmse: 0
是因为我的模型参数没设置对呢?
还是受到data_key的影响了?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at qlib/contrib/model/gbdt.py around line 37 and inspect how data_key=DataHandlerLP.DK_L changes label selection before model training. Reproduce the training with and without data_key, checking whether df["label"] contains only NaN and how the resulting data reaches the GBDT model. Done means determining whether the zero RMSE comes from data selection or model parameters and documenting the relevant correction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data, machine-learning
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100