Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I know that in the latest version (version 3.2 as of now) you have an int flag param with your predict function. If you set it to 1 it will give you a probability. It should look something like:

   Mat output;
   Mat input = getVector();
   int flag = 1;
   svm->predict(input,output,flag); 
   cout << "Prediction result " << output << endl;