Find occurrences of smaller image in a bigger image


#1

What procedure is needed if I want to find a template in an image?
A subimage in a bigger image?
For example in an image of a pdf with text, find all the occurrences of the letter “a”.


(segovia) #2

Although I am not exactly sure, I think this is a classic pattern recognition problem in computer version, and it can be achieved by opencv-does not have to use DL.


(Elizabeth) #3

If you’re not just working with text, you might be looking for image segmentation, e.g. faster r-cnn, which locates (& IDs) objects within an image.

See this forum for more examples & details


(David Gutman) #4

If you’re really just looking for smaller versions of an image in a bigger image, you should look into features like SIFT, SURF, ORB, etc.

It sounds like this tutorial is pretty close to what you’re looking for…

http://docs.opencv.org/3.0-beta/doc/py_tutorials/py_feature2d/py_feature_homography/py_feature_homography.html#py-feature-homography


#5

Those won’t work on text (document image).

This is a computer vision problem but the old way is feature engineering, that’s why I’m asking for a DL method.


(David Gutman) #6

Don’t see why key point extraction wouldn’t work for your example (especially if looking for individual letters). You could also just do cross correlation with the letter at a few scales and rotations.

If all the same font, deep learning is really over powered for this problem.


(Jeremy Howard (Admin)) #7

The methods used in lesson 7 should work.


#8

Any new code/projects for template matching?