Skip to main content
Log in

Efficient Algorithms for Image Template and Dictionary Matching

  • Published:
Journal of Mathematical Imaging and Vision Aims and scope Submit manuscript

Abstract

Given a large text image and a small template image, the Template Matching Problem is that of finding every location within the text which looks like the pattern. This problem, which has received attention for low-level image processing, has been formalized by defining a distance metric between arrays of pixels and finding all subarrays of the large image which are within some threshold distance of the template. These so-called metric methods tends to be too slow for many applications, since evaluating the distance function can take too much time. We present a method for quickly eliminating most positions of the text from consideration as possible matches. The remaining candidate positions are then evaluated one by one against the template for a match. We are still guaranteed to find all matching positions, and our method gives significant speed-ups. Finally, we consider the problem of matching a dictionary of templates against a text. We present methods which are much faster than matching the templates individually against the input image.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Institutional subscriptions

Similar content being viewed by others

References

  1. D.H. Ballard and C.M. Brown, Computer Vision. Prentice-Hall Inc., 1982.

  2. D.I. Barnea and H.F. Silverman, “A class of algorithms for fast digital image registration,” IEEE Trans. Comput., Vol. 21, pp. 179–186, 1972.

    Google Scholar 

  3. R. Boyle and R. Thomas, Computer Vision A First Course. Blackwell Scientific Publications, 1988.

  4. A.J. Broder, “Strategies for efficient incremental nearest neighbor search,” Pattern Recognition, Vol. 23, No. 12, pp. 171–178, 1990.

    Google Scholar 

  5. T. Chiueh, “Content-based image indexing,” in Proceedings of the Twentieth International Conference on Very Large Databases, Santiago, Chile, 1994, pp. 582–593.

  6. B.V. Dasarathy, “Visiting nearest neighbors-a survery of nearest neighbor pattern classification techniques,” in Proceedings of the International Conference on Cybernetics and Society, September 1977, IEEE, pp. 630–636.

  7. B.V. Dasarathy, Nearest Neighbor Pattern Classification Techniques, IEEE Computer Society Press, 1991.

  8. A. Faragó, T. Linder, and G. Lugosi, “Fast nearest neighbor search in dissimilarity spaces,” IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 15, pp. 957–962, 1993.

    Google Scholar 

  9. M. Flickner, H. Sawhney, W. Niblack, J. Ashley, Q. Huang, B. Dom, M. Gorkani, J. Hafner, D. Lee, D. Petkovic, D. Steele, and P. Yanker, “Query by image and video content: the qbic,” Computer, Vol. 28, pp. 23–32, September 1995.

    Google Scholar 

  10. K. Fukunaga and P. Narendra, “A branch and bound algorithm for computing k-nearest neighbors,” IEEE Transactions on Computers, Vol. 24, pp. 750–753, 1975.

    Google Scholar 

  11. R. Jain, S.J. Murthy, and P.L.-J. Chen, “Similarity measures for image databases,” SPIE, Vol. 2420, pp. 58–65, 1995.

    Google Scholar 

  12. B.S. Kim and S.B. Park, “A fast k-nearest neighbor finding algorithm based on the ordered partition,” IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 8, pp. 761–766, November 1986.

    Google Scholar 

  13. W. Niblack, Digital Image Processing. Prentice Hall International (UK), Birkeroed, Denmark, 1986.

    Google Scholar 

  14. W. Niblack, “Comments on cross correlation vs. differencing methods,” Personal Communication, 1996.

  15. H. Niemann and R. Goppert, “An efficient branch-and-bound nearest neighbour classifier,” Pattern Recognition Letters, Vol. 7, pp. 67–72, 1988.

    Google Scholar 

  16. W.K. Pratt, “Correlator techniques of image registration,” IEEE Trans. Aerosp. Electron. Syst., Vol. 10, pp. 353–358, 1974.

    Google Scholar 

  17. H.K. Ramapriyan, “A multilevel approach to sequential detection of pictorial features,” IEEE Trans. Comput., Vol. 25, pp. 66–78, 1976.

    Google Scholar 

  18. E. Vidal, H. Rulot, F. Casacuberta, and J. Bened´i, “Searching for nearest neighbors in constant average time with applications to discrete utterance speech recognition,” in Proceedings of International Conference on Pattern Recognition, October 1986, IEEE, pp. 808–810.

  19. R. Wong, “Sequential pattern recognition as applied to scene matching,” Ph.D. thesis, Univ. of Southern California, L.A., December 1976.

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

About this article

Cite this article

Cha, SH. Efficient Algorithms for Image Template and Dictionary Matching. Journal of Mathematical Imaging and Vision 12, 81–90 (2000). https://doi.org/10.1023/A:1008309026555

Download citation

  • Issue Date:

  • DOI: https://doi.org/10.1023/A:1008309026555

Navigation