1 | initial version |
the ml module in 3.0 got some refactoring lately.
you can no more create an instance 'on the stack' like KNearest knn;
instead, you will have to use :
Ptr<ml::KNearest> knn = ml::KNearest::create();
knn->train(...);
knn->predict(...);
(btw, same for SVM, EM, etc.)