Is it possible to use models trained with Matlab classification learners outside Matlab, such as in java

조회 수: 1 (최근 30일)
I am using Classification Learners in apps, to classify my data, and it seems bagged trees and Linear SMV does the best prediction. Therefore, I want to export the model trained with these algorithms and use it in my custom Java application. I wonder, is it possible to export the trainedClassifier model outside of Matlab, if it is so, how can I do it? Thank you,

답변 (1개)

Abhisek Roy
Abhisek Roy 2016년 5월 31일
Hi Emin,
It is possible to deploy your MATLAB code to a Java platform by writing C wrapping code to enable the generated C code to be used with Java Native Interface (JNI). Please refer to the following link which gives you an example of how to generate C Code from MATLAB for Use with Java Applications -
http://www.mathworks.com/company/newsletters/articles/generating-c-code-from-matlab-for-use-with-java-and-net-applications.html
However, the functions which you have used in the MATLAB code should be Code generable as the code need to be converted to equivalent C Code to use it outside MATLAB. Please refer to the following link which gives you the full list of functions, classes, and System objects for which you can generate C/C++ code -
http://www.mathworks.com/help/coder/ug/functions-supported-for-code-generation--categorical-list.html#btwz3ma
Regards, Abhisek

카테고리

Help CenterFile Exchange에서 Get Started with Statistics and Machine Learning Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by