Ask Your Question
0

OpenCV 3.0 not longer recognises 'CvSVM'

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

jackbrucesimspon gravatar image

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

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 -0500

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 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

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

Seen: 2,994 times

Last updated: Jul 06 '15