-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
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
Add more detailed explanations and tutorial for advanced objectives #10283
base: master
Are you sure you want to change the base?
Conversation
You can find the "docs/readthedocs.org:xgboost" entry in the CI test list. |
Thanks, I just checked and it looks correctly rendered. PR is ready for review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for this didactic document! I will try to go through it in the coming days and hope you don't mind if I take my time to understand everything in the doc.
- Since the ``base_score`` parameter that XGBoost uses for an intercept is | ||
limited to a scalar, one can use the ``base_margin`` functionality instead, | ||
but note that using it requires a bit more effort. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We do intend to remove this restriction in the future once we can remove the existing binary serialization #7547 . Might be worth noting.
Added also R code for all of the examples, but running them will require merging this PR first : #10323 |
This PR expands the docs for custom objectives to cover some important details that are missing about what is or isn't supported.
It also adds a new example guide for advanced usage in which it uses Dirichlet regression as a custom objective (which doesn't meet the requirements of custom objectives for the Hessian), explaining the workarounds that can be used for adapting a model like this as explained in an earlier discussion so that it'd fit into xgboost's framework.
Note: I'm not 100% sure that the .rst file will render correctly. Would be ideal if someone could take a look before merging.
Note2: the tutorial copy-pasted some data from a publication, which was in turn taken from an R package. I added a citation there but I'm not sure if it requires some other additional form of attribution.