Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Find an Image within an Image

Tags:

java

python

image

I am looking for the best way to detect an image within another image. I have a small image and would like to find the location that it appears within a larger image - which will actually be screen captures. Conceptually, it is like a 'Where's Waldo?' sort of search in the larger image.

Are there any efficient/quick ways to accomplish this? Speed is more important than memory.

Edit:

The 'inner' image may not always have the same scale but will have the same rotation.

It is not safe to assume that the image will be perfectly contained within the other, pixel for pixel.

like image 625
dmanxiii Avatar asked Jan 18 '09 02:01

dmanxiii


1 Answers

Wikipedia has an article on Template Matching, with sample code.

(While that page doesn't handle changed scales, it has links to other styles of matching, for example Scale invariant feature transform)

like image 141
Stephen Denne Avatar answered Sep 22 '22 04:09

Stephen Denne