I have saved the result of a Weka classification by right-clicking on the model and selecting "save model". Now, I want to load it and work with it in my Java application. How can I do that? Models could be naive Bayes, decision trees, or regression. I need to use these three models.
Any suggestion or solution would be appreciated.
Here is an example assuming you have a RandomTree model saved to a model.weka
file (change to whatever classifier and file you have)
RandomTree treeClassifier = (RandomTree) SerializationHelper.read(new FileInputStream("model.weka")));
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With