Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

OpenCV - Haar classifier for long objects with different angles

I have used Haar classifier with OpenCV before succesfully. Unfortunately it seems to work only on square objects and fixed angles (i.e. faces). However I need to find "long" (rectangular) objects which have different angles (see sample input image).

Is there a way to train Haar classifier to find such objects? All I can find are tutorials for face recognition. Any other alternative approches?

Sample input image

like image 937
Jacek Avatar asked Apr 12 '11 16:04

Jacek


1 Answers

Haar classifiers are known to work with rigid object only. You need a classifier for each of the view. For example, the side-face classifier in OpenCV doesn't work as good as front-face classifer(due to the reason being, side face has more variation in yaw-pitch-roll than front face).

There is no perfect way of answering your question.

However, in your case whatever you are trying to classify (microbes I suppose) are overlapping on each other. Its a complex issue. But, you can isolate the region where microbes occur (not isolate each microbe like a face).

You can refer fingerprint segmentation techniques that are known to enhance the ridges on a fingerprint (here in your case its microbe edges) from the background and isolate the image.

Check "ridgesegmentation.m" in the following page: http://www.csse.uwa.edu.au/~pk/Research/MatlabFns/index.html

like image 187
garak Avatar answered Oct 02 '22 08:10

garak