catboost icon indicating copy to clipboard operation
catboost copied to clipboard

Loading model with "loadModel" crashes without any error

Open flancast90 opened this issue 7 months ago • 3 comments

Problem: Running the below code using the Catboost NodeJS library. As soon as this line of code is triggered, the application crashes without any sort of error message.

const cbt = require("catboost");

const model = new cbt.Model();
model.loadModel(`./models/saves/nfl_probmodel.cbm`);
console.log("reached this!");

If you run the above code, the console.log(...) line never fires. Instead, the script crashes abruptly at the loadModel line.

For reference, the file it is loading was trained using the Python library, and is 200kb in size. This is a super strange error, I am hoping to get any kind of support on this that I can as this is required for delivery of a mission-critical application.

Catboost Version: Latest Operating System: Windows 11 CPU: N/A GPU: N/A

flancast90 avatar Jan 15 '24 05:01 flancast90

could you please catboost\node-package\e2e_tests\node-catboost-e2e-test-package\e2e_predict.js

npm i catboost
cd catboost\node-package
node e2e_tests\node-catboost-e2e-test-package\e2e_predict.js

here is my output image

could you please catboost\node-package\e2e_tests\node-catboost-e2e-test-package\e2e_predict.js

npm i catboost
cd catboost\node-package
node e2e_tests\node-catboost-e2e-test-package\e2e_predict.js

here is my output image

When I npm i catboost, there is no "catboost" directory created. The "catboost" directory in node_modules is only the nodejs code, and has none of the files you are running. Any suggestions?

flancast90 avatar Jan 15 '24 13:01 flancast90

could you please catboost\node-package\e2e_tests\node-catboost-e2e-test-package\e2e_predict.js

npm i catboost
cd catboost\node-package
node e2e_tests\node-catboost-e2e-test-package\e2e_predict.js

here is my output image

When I npm i catboost, there is no "catboost" directory created. The "catboost" directory in node_modules is only the nodejs code, and has none of the files you are running. Any suggestions?

to get catboost source code, please do git clone https://github.com/catboost/catboost.git