Ask Your Question
0

Method to find best matching image in a video

asked 2014-07-22 02:28:58 -0600

sadshark gravatar image

Hello everyone, I would like to know if an effective method to find an image in a video already exists. Let me explain:

I have a video quite linear, where a camera is moving along an axis in a room. I also have a picture of the same room (somewhere on the axis, and slightly different) and I would like to determine which frame in the video matches the best this picture.

I dont know if a method already exists for that, Otherwise i may have ideas but i am open to suggestions. thank you!

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
1

answered 2014-07-22 03:12:36 -0600

Have a look at that tutorial which explain how to find an object in a picture. As you describe your problem, it seems to be similar.

You need to compute some keypoints from the initial image, and to compute the keypoints in each image of the video. There is many keypoints supported by OpenCV, some non free, like SIFT/SUFT, some free like ORB, FAST, etc. See the FeatureDetector method.

After that the tutorial explains how to compute the descriptors associated with the keypoints. See the DescriptorExtractor class to undertand the principles.

The matching is done with a Matcher object, which is a Brute Force, but could also be a KNN.

You need to compute the features and descriptors on the initial image once, and compute features and descriptors of images from the video in real-time, then do the matching process. You need to define a threshold for the matching (or keep the best at the end of the video, it's up to you…)

edit flag offensive delete link more

Question Tools

Stats

Asked: 2014-07-22 02:28:58 -0600

Seen: 752 times

Last updated: Jul 22 '14