Ask Your Question

Revision history [back]

Issue kernel_type no attribute called cv2.SVM_LINEAR

Hello, I am using the version 3.0.0 of OpenCV with Python version 2.7. I would like to use the SVM algorithm like below:

svm_params = dict( kernel_type=cv2.SVM_LINEAR, svm_type=cv2.SVM_C_SVC, C=1 ) svm_model = cv2.SVM() svm_model.train(training_set, response, params=svm_params)

But there is no attribute called 'SVM_LINEAR' Thanks in advance