dmitryikh / leaves

pure Go implementation of prediction part for GBRT (Gradient Boosting Regression Trees) models from popular frameworks
MIT License
419 stars 72 forks source link

Skips transformation for regression for LightGBM models #72

Closed Mottl closed 4 years ago

Mottl commented 4 years ago

This patch fixes the behaviour of LGEnsembleFromFile function. If a regression model is loaded then loadTransformation parameter will be autoset to false.

coveralls commented 4 years ago

Pull Request Test Coverage Report for Build 154


Changes Missing Coverage Covered Lines Changed/Added Lines %
lgensemble_io.go 9 16 56.25%
<!-- Total: 9 16 56.25% -->
Files with Coverage Reduction New Missed Lines %
lgensemble_io.go 2 71.67%
<!-- Total: 2 -->
Totals Coverage Status
Change from base Build 152: 1.3%
Covered Lines: 1673
Relevant Lines: 2391

💛 - Coveralls
llsguoqing commented 4 years ago

Is this pr about to merge? I am currently using this repo to load trained lightgbm model bu got stuck wit error: "unexpected objective field: 'regression'". Hope this pr can fix this error

Mottl commented 4 years ago

Is this pr about to merge? I am currently using this repo to load trained lightgbm model but got stuck wit error: "unexpected objective field: 'regression'". Hope this pr can fix this error

Yes, it will fix this

dmitryikh commented 4 years ago

@Mottl , thanks for PR! Sorry for delay, Now I'm about to merge it.

Mottl commented 4 years ago

@dmitryikh, could you also merge #70?