Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Two approaches are possible:

1 - Use of Bag of Words. Usually have four steps:

  1. Get the feature points from training data;
  2. Create a vocabulary from the features;
  3. Train (using SVM for example);
  4. Test in a image (not in training examples).

    There is a example here and in opencv/samples/cpp/bagofwords.cpp

2 - Use of a latent svm detector. The explanation is here. Have a running example of detection/categorization in opencv/samples/cpp/latentsvmdetector.cpp. You also need the opencv_extra/testdata/cv/latentsvm to properly test it. However I don't know how to make the training of new models in OpenCV.