opencv_contrib
opencv_contrib copied to clipboard
Default grid for polynomial kernel generates error
Transferred from http://code.opencv.org/issues/4263
|| Zsolt Kóróczki on 2015-04-04 15:05
|| Priority: Low
|| Affected: 2.4.0 - 2.4.8
|| Category: ml
|| Tracker: Bug
|| Difficulty:
|| PR:
|| Platform: x64 / Windows
Default grid for polynomial kernel generates error
Hello everyone!
Is it possibe that the train_auto function of the SVM class crashes when I use polynomial kernel type? My code works fine with all the other kernels, but when I try to use poly kernel my Visual Studio reports the following error: "Kernel parameter degree must be positive". It is very odd, because I use the default_grid for all the parameters in the auto_train function. I have even checked the default grid for the parameter degree, but it seemed to me fine: min_val=0.01, max_val=4, step=7. I have also tried to custom the grid for this parameter, but I always got the same error message so it just does not want to work with the poly kernel. Can somebody help?
Thanks in advance!
History
Vadim Pisarevsky on 2015-04-27 11:19
without a sample that reproduces the problem I set the ticket priority as low
- Priority changed from Normal to Low
- Category set to ml
I've got the same problem. Also using the constructor (like ml::ParamGrid gammaGrid(1.1, 10, 2);) instead of getDefaultGrid.