Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

SVM class count

Hi there,

It should be a very simple question but I just can't found the way to get the class count from the SVM model instance, i.e., something like


Ptr<svm> svmModel = StatModel::load<svm>("xxx.yml");

int classCount = svmModel->getClassCount();


The variable classCount is stored in xxx.yml just like another variable VarConut. I found the method getVarCount() but fail to find getClassCount(), any suggestions? Thanks