I couldnt find proper references about how to pass the SVM parameters to the opencv cvSvm class. I got the parameter list, but not any tutorial on how to convert the parameters to the CV data structures.
Can I have some help please?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Construct a
CvSVMParamsobject.Its members are:
svm_type: SVM algorithm to usekernel_type: SVM kernel formdegree: Degree for polynomial kernelgamma: Scale for polynomial, RBF or sigmoid kernelcoef0: Offset for polynomial or sigmoid kernelC: C ratio for selecting support vectorsnu: nu value for nu-SVR algorithmp: p value for eps-SVRclass_weights: Class weights for C-SVMterm_crit: Termination criteria inCvTermCriteriaChange appropriate fields and pass it to
CvSVMconstructor. An SVM will be trained with your parameters.See documentation of CvSVM for more information:
http://opencv.willowgarage.com/documentation/cpp/support_vector_machines.html