Export Weka models for use in C or C ++

I have had great success using Weka to research data and determine which classification algorithm is best for my problem. Now that I have a prepared model that works, I would like to integrate it into the rest of my C ++ program. Unfortunately, this seems like a daunting task: only Weka has built-in support for exporting classifiers as Java object files. Has anyone found a way to export model parameters developed by Weka in a useful format?

I would be particularly interested if there is a utility that generates C / C ++ code from the J48 decision tree.

+6
source share
2 answers

I understand that J48 is a Java implementation of the Quinlan C4.5 algorithm with C code, freely available at http://www.rulequest.com/Personal/ . Is this what it is looking for?

+2
source

J48 implements the Sourcable interface, which means that it can output the constructed model as Java source code (perhaps you can achieve this from the gui classifier panel). Then it will be possible to automatically translate this into C / C ++.

+2
source

Source: https://habr.com/ru/post/888132/


All Articles