Skip to content
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

use XGEnsembleFromFile to load the xgb model, model_t, err := leaves.XGEnsembleFromFile("xgb_model.json", true) #91

Open
absent1353 opened this issue May 3, 2024 · 1 comment

Comments

@absent1353
Copy link

panic: runtime error: makeslice: len out of range
goroutine 1 [running]:
github.com/dmitryikh/leaves/internal/xgbin.ReadString(0x140000940c0)
go/pkg/mod/github.com/dmitryikh/[email protected]/internal/xgbin/xgbin_io.go:176 +0x68
github.com/dmitryikh/leaves/internal/xgbin.ReadModelHeader(0x140000940c0)
go/pkg/mod/github.com/dmitryikh/[email protected]/internal/xgbin/xgbin_io.go:230 +0x6c
github.com/dmitryikh/leaves.XGEnsembleFromReader(0x140000940c0, 0x1)
go/pkg/mod/github.com/dmitryikh/[email protected]/xgensemble_io.go:140 +0x40
github.com/dmitryikh/leaves.XGEnsembleFromFile({0x1026945ce?, 0x102605838?}, 0x1)
go/pkg/mod/github.com/dmitryikh/[email protected]/xgensemble_io.go:259 +0x138
main.main()
Documents/code/GoAI/main.go:98 +0x40
exit status 2

how can I fix the error

@abucu
Copy link

abucu commented May 9, 2024

try xgb 0.90, and no json...
#80

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants