Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create a single constant-length feature vector from a variable number of image descriptors (SURF)

My problem is as follows:

  • I have 6 types of images, or 6 classes. For example, cat, dog, bird, etc.
  • For every type of image, I have many variations of that image. For example, brown cat, black dog, etc.
  • I'm currently using a Support Vector Machine (SVM) to classify the images using one-versus-rest classification. I'm unfolding each image into a single pixel vector and using that as the feature vector for a given image I'm experiencing decent classification accuracy, but I want to try something different.
  • I want to use image descriptors, particularly SURF features, as the feature vector for each image. This issue is, I can only have a single feature vector per given image and I'm given a variable number of SURF features from the feature extraction process. For example, 1 picture of a cat may give me 40 SURF features, while 1 picture of a dog will give me 68 SURF features. I could pick the n strongest features, but I have no way of guaranteeing that the chosen SURF features are ones that describe my image (for example, it could focus on the background). There's also no guarantee that ANY SURF features are found.

So, my problem is, how can I get many observations (each being a SURF feature vector), and "fold" these observations into a single feature vector which describes the raw image and can fed to an SVM for training?

Thanks for your help!

like image 601
trianta2 Avatar asked Oct 03 '22 15:10

trianta2


1 Answers

Typically the SURF descriptors are quantized using a K-means dictionary and aggregated into one l1-normalized histogram. So your inputs to the SVM algorithm are now fixed in size.

like image 58
jabaldonedo Avatar answered Oct 07 '22 20:10

jabaldonedo