Due to some problems with version 2.4.12, I've been testing SVM training with OpenCV 3.0.0, and I've found it is much slower now with the new module.
To share some results, these are the times I got using the same training data and paramters in both versions, and training over 100 iterations to average:
- 1000 samples, 5000 features/sample: 0.11/SVM (2.4.12) vs 0.19/SVM (3.0.0) -> 72% slower
- 5000 samples, 5000 features/sample: 0.50/SVM (2.4.12) vs 0.95/SVM (3.0.0) -> 90% slower
- 5000 samples, 50000 features/sample: 4.9/SVM (2.4.12) vs 9/SVM (3.0.0) -> 83% slower
Not only that, memory consumption is quite higher in new version too. As you can see in the below images, 2.4.12 (fist one) consumes less memory and in a much more stable way than 3.0.0 does (second one).
So the question is... was this expected when rewriting the ml module? Is there anything that can be done (by the users and/or the devs) to improve it?