Open tonylee19544 opened 3 years ago
@tonylee19544 , great job! That's definitely what leaves needs!
I will come back yo you with review after the easter holidays.
Hi would like to ask if there is some news for the pull request. Thanks.
@dmitryikh Can you review? Super useful library and the json bindings help modernize!
Yes!! Would love to see this merged @dmitryikh
Have a problem with this pull request.
I have an xgboost model trained with version 1.6.0. Training code: https://gist.github.com/adensur/134b82c304cc69eed278e258e6b2a685
json read error: json: cannot unmarshal number into Go struct field Tree.learner.gradient_booster.model.trees.default_left of type bool
"default_left" field in tree nodes are ints (in current xgboost version, at least), not bools.
After fixing that, the prediction result is incorrect. I don't understand where this formula is coming from: https://github.com/dmitryikh/leaves/pull/81/files#diff-c524a0589fd250b78ba6e81dbd14998971af6ea9fd8dd2aad8c2dd8e3ecf6a4dR334
But without it prediction is correct, in my case at least
This will add support for json format and binary format of gbtree and gblinear which have the version not younger than v1.0.0