Ask Your Question
0

OpenCV 3.0 not longer recognises 'CvSVM'

asked 2015-07-06 08:11:52 -0600

jackbrucesimspon gravatar image

updated 2015-07-06 08:21:30 -0600

I recently updated to OpenCV 3.0, and my old code which trained an SVM has stopped working. Now writing this

CvSVM SVM; // or this
cv::CvSVM SVM;

gives me the following error:

error: unknown type name 'CvSVM'

Does anyone know whether they've changed the names in OpenCV 3.0 or if it's a bug in the new release?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
5

answered 2015-07-06 08:31:39 -0600

juanmanpr gravatar image
edit flag offensive delete link more

Comments

1

and you will need to use it like this:

Ptr<ml::SVM> svm = ml::SVM::create();
svm->setC(10);
berak gravatar imageberak ( 2015-07-07 04:24:20 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2015-07-06 08:11:52 -0600

Seen: 3,724 times

Last updated: Jul 06 '15