2015 - Object Tracking Using Adaptive Template Matching PDF
2015 - Object Tracking Using Adaptive Template Matching PDF
net/publication/277648222
CITATIONS READS
8 741
4 authors, including:
Yo-Sung Ho
Gwangju Institute of Science and Technology
476 PUBLICATIONS 3,898 CITATIONS
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
Asia-Pacific Signal and Information Processing Association, Annual Summit and Conference (APSIPA ASC) 2016 View project
All content following this page was uploaded by Yo-Sung Ho on 15 January 2016.
Gwangju Institute of Science and Technology (GIST), 123 Cheomdan-gwagiro, Buk-gu, Gwangju 500-712, Korea
{wisarut, jhm, dongwonshin, hoyo}@gist.ac.kr
Received April 5, 2014; Revised June 13, 2014; Accepted November 19, 2014; Published February 28, 2015
* Regular Paper
Abstract: Template matching is used for many applications in image processing. One of the most
researched topics is object tracking. Normalized Cross Correlation (NCC) is the basic statistical
approach to match images. NCC is used for template matching or pattern recognition. A template
can be considered from a reference image, and an image from a scene can be considered as a source
image. The objective is to establish the correspondence between the reference and source images.
The matching gives a measure of the degree of similarity between the image and the template. A
problem with NCC is its high computational cost and occasional mismatching. To deal with this
problem, this paper presents an algorithm based on the Sum of Squared Difference (SSD) and an
adaptive template matching to enhance the quality of the template matching in object tracking. The
SSD provides low computational cost, while the adaptive template matching increases the accuracy
matching. The experimental results showed that the proposed algorithm is quite efficient for image
matching. The effectiveness of this method is demonstrated by several situations in the results
section.
Keywords: Template matching, Object tracking, Normalized cross correlation, Sum of squared difference,
Pattern recognition
1. Introduction
Nowadays, video surveillance systems are being
installed worldwide in many different sites, such as
airports, hospitals, banks, railway stations, and even at
homes. Surveillance cameras help a supervisor to oversee
many different areas in a single room and to quickly focus
on abnormal events taking place in the controlled space.
Intelligent video monitoring expresses a fairly large
research direction that is applied in different fields. On the
other hand, several question arise, such as how can the
intensity of the objects tracking with occlusion be Fig. 1. Shading real target by other objects.
improved. When an occlusion occurs, some objects are
partially or totally invisible. As shown in Fig. 1, this
phenomenon makes it difficult to localize the real object tracking consists of an estimation of the trajectory of
target accurately. moving objects in the sequence of frames generated from a
video [1].
Most tracking algorithms assume that the object motion
2. Object Tracking is smooth with no abrupt changes to simplify tracking [2].
For example, the traditional color histogram Mean Shift
Object tracking in real-time environment is a different (MS) algorithm only considers the object’s color statistical
task in different computer vision applications. Object information, and does not contain the object’s space
2 Chantara et al.: Object Tracking using Adaptive Template Matching
kernel. The procedure can calculate a result pixel using matched within the source image, I(x,y), of size p×q,
various matching methods. Eqs. (1)-(4) show the matching where (p>m and q>n). For each pixel location (x,y) in the
methods. image, the SSD distance is calculated as follows:
The objective of the proposed method is to reduce a 4.3 Adaptive Template Matching
computational cost and increase accurate matching. As a In this subsection, the FL parameter from section 4.2 is
similarity measure, the SSD is the most popular and considered to determine an appropriate template image.
widely used for several applications. NCC is more robust
against illumination changes than SSD; nevertheless, NCC Location flag = 0, it means that
is more time-consuming than SSD. ·The OL is the SLs or PL.
The following three key steps are involved in
·Assign the previous template with the current tem-
implementing of the proposed method.
plate.
·Detection of interesting object,
·Update the current template with the current object
·Tracking of object from frame to frame,
template.
·Updating of suitable template. Location flag = 1, it means that
·The OL is the CL from the SSD method.
4.1 Template Matching ·Assign the previous template with the current tem-
The SSD is a simple algorithm for measuring the plate
similarity between the template image (T) and sub-images ·Update the current template with the original tem-
in the source image (I). It works by taking the squared plate.
difference between each pixel in T and the corresponding The result image
pixel in the sub-images used for the comparison in I. These ·Green box is the PL position in the source image.
squared differences are summed to create a simple metric ·Red box is the OL position in the source image.
of similarity. Assume a 2-D m×n template, T(x,y) is The overall actions are described more detail in Fig. 5.
4 Chantara et al.: Object Tracking using Adaptive Template Matching
(a) (b)
Condition 1:
(a)
(b) (c)
5. Experiment Results
Fig. 7. Condition 1 (a) SSD result, (b) Object location,
This section shows the advantage of the proposed (c) Update the current template with the original
method to full track an interested object. Experiments were template.
performed to examine the matching accuracy. A template
image of 27x67 pixels (Fig. 4(b)) was used to match in a section 4.2. An illumination of (a), (b), and (c) in each
source image the sequences of size of 352x288 pixels, as figure shows the result of the SSD method, the position of
shown in Fig. 4(a). involved object and the updated template respectively.
Figs. 7-9 illustrate each condition that is explained in To illustrate the performance of the proposed algorithm,
IEIE Transactions on Smart Processing and Computing, vol. 4, no. 1, February 2015 5
Condition 2:
Fig. 8. Condition 2 (a) SSD result with the SLs, (b) Object location shows the PL in a green box and the current
location in a red box, (c) Update the current template with the current object template.
Condition 3:
Fig. 9. Condition 3 (a) SSD result with the SLs, (b) Object location shows the current location with the PL in a green
box, (c) Update the current template with the current object template.
the template matching algorithm like the NSSD and NCC image frames. The proposed method outperforms the two
were compared. The result is shown in Fig. 11. Fig. 10 conventional methods.
shows x and y object positions curves on a consecutive In addition, other experiment samples consisting of
6 Chantara et al.: Object Tracking using Adaptive Template Matching
F.1
F.10
F.35
F.64
F.177
F.250
(a) (b) (c) (d)
Fig. 11. Experiment result (a) NSSD, (b) NCC, (c) Ground truth [18], (d) Proposed method, the results are captured at
1st, 10th, 35th, 64th, 177th, and 250th frame respectively.
IEIE Transactions on Smart Processing and Computing, vol. 4, no. 1, February 2015 7
(a) (b)
Fig. 12. Result related to condition 3 (a) Template image, (b) Object tracking.
(a) (b)
Fig. 13. Result related to condition 2 (a) Template image, (b) Object tracking.
(a) (b)
Fig. 14. Result related to condition 1 (a) Template image, (b) Object tracking.
three source images and their templates with the proposed different sizes and different illuminations. Figs. 12-14
algorithm were implemented. These samples contain show the outcomes.
8 Chantara et al.: Object Tracking using Adaptive Template Matching