Ask Your Question
1

How to identify an image once in a video sequence?

asked 2013-04-18 03:39:04 -0600

Costantino gravatar image

Hi all.
In my application (iOS) I search circular and triangular red objects. To do this I do an analysis of the colors converting RGB space to HSV and search shapes using findContour(). If I find a red object (circular or triangular) cut the portion of the image that contains it using its contour to define the ROI. This happens for each frame, and the problem is that the same “object” is grabbed many times because its contour is found in multiple frames. So, If I take a red circle for 1 second by moving the iPad around this image and the acquisition takes place at 30 frames per second, at the end I will have 30 images of the same object, while I only want one. In the image below, in the upper left the captured video from the camera, at the top right the last image captured and in the lower the sequence of images captured. As you can see, the red circle is captured many times, but always refers to the same object, and this happens because the image I cut it based on the boundary identified. I think I have to use a tracking system, is that correct?

Any suggestions to solve this problem?

image description Best regards
Costantino

edit retag flag offensive close merge delete

Comments

1

Like what you say, maybe you could use tracking algorithm. But if you want to filter it so that you don't have duplicates, maybe try to match it with your already detected objects ? Maybe some template matching, or some other algorithm (i.e. normalize image, convert to grayscale, compare with detected ones) ?

sub_o gravatar imagesub_o ( 2013-04-18 03:43:01 -0600 )edit

2 answers

Sort by » oldest newest most voted
2

answered 2013-04-22 14:05:10 -0600

For this you can use the features2D part of openCV. Take a look at this tutorials, which apply a feature detector, descriptor and a matcher:

http://docs.opencv.org/doc/tutorials/features2d/table_of_content_features2d/table_of_content_features2d.html#table-of-content-feature2d

edit flag offensive delete link more
2

answered 2013-04-22 09:28:01 -0600

NightLife gravatar image

My suggestion is template matching. You can use this simple Example and use the current frame instead of Input Image.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-04-18 03:39:04 -0600

Seen: 771 times

Last updated: Apr 22 '13