Escolar Documentos
Profissional Documentos
Cultura Documentos
VOL. 36,
NO. 11,
NOVEMBER 2014
2159
INTRODUCTION
dp x; y
X
n
j xi yi j
1=p
;
(1)
i1
where x and y are n-tuples, i is used to denote their n coordinates (or dimensions), and 1 p 1 [13], [22], [24]. The
T.E. Schouten is with the Institute for Computing and Information Science
(ICIS), Radboud University, PO Box 9010, 6500 GL, Nijmegen, The Netherlands. E-mail: ths@cs.ru.nl.
E.L. van den Broek is with the Department of Information and Computing
Sciences, Utrecht University; Human Media Interaction (HMI), University of Twente; and Karakter University Center, Radboud University Medical Center Nijmegen, The Netherlands. E-mail: vandenbroek@acm.org.
(2)
2)
3)
0162-8828 2014 IEEE. Translations and content mining are permitted for academic research only. Personal use is also permitted, but republication/redistribution
requires IEEE permission. See http://www.ieee.org/publications_standards/publications/rights/index.html for more information.
2160
NOVEMBER 2014
TABLE 1
Ten Distance Transforms (DT), Including i) Three Baseline DT (b) that Are Well Known Baseline Algorithms, ii) Three Approximate
Euclidean DT (EDT) (a), and iii) Four Exact EDT (), Including the FEED Class Algorithms
reference
[1], [2] 1966, 1968 Rosenfeld and Pfaltz
T
b
C
R
Danielsson
Borgefors
[16]
1988
Ye
[17]
1998
Coiras, Santamaria,
and Miravet
[6], [11]
2003
Shih and Wu
[22]
2007
[25]
2009
Lucet
[26]
2004
[15]
1980
code
CH11
CH11 and CH34 denote respectively the city block (or Chamfer 1,1 Distance) and the Chamfer 3,4 Distance [13], [14] A brief introduction to them is provided
including their reference, the author(s), type (T), class (C) code (name), a brief description, and notes. The DT classes R, P, and S denote respectively: raster
scanning, ordered propagation, and independent scanning (see also Section 1).
SCHOUTEN AND BROEK: FAST EXACT EUCLIDEAN DISTANCE (FEED): A NEW CLASS OF ADAPTABLE DISTANCE TRANSFORMS
(3)
(4)
The determination of a suitable Ab requires the development of strategies to search for the object pixels qs that give
the largest reduction of Ab . The gain that can be achieved in
this way depends on the distribution of the object pixels
over the image. The same is valid for the parameters that
determine when to stop reducing the size of Ab . The most
efficient strategy has to be experimentally determined on a
representative sample of the kind of images one wants to
process for a given application. Hence, from the basic FEED
class defined in (5), various distinct FEED class algorithms
can be derived. These tailored FEED class algorithms, all
providing exact EDMs, are adapted to the type of images
such that their execution time is minimized.
3
This naive algorithm achieves the correct result; but, it is
also very slow. Fortunately, several methods are available
to speed up this naive algorithm considerably. The three
basic methods are the following:
2161
2162
NOVEMBER 2014
Fig. 1. Using the rotational invariance of the ED2 metric. Black circles indicate object pixels, the other circles are background pixels. (a) Only pixels on
and to the left of the bisection line between the border object pixel b and the object pixel q have to be fed by b, they are indicated by gray circles. (b)
Using four additional bisection lines.
rows and the center of each pixel being on integer coordinates i; j. An object pixel q then gives the bisection line
defined by
2qi x 2qj y qi2 qj2 :
(6)
SCHOUTEN AND BROEK: FAST EXACT EUCLIDEAN DISTANCE (FEED): A NEW CLASS OF ADAPTABLE DISTANCE TRANSFORMS
2163
Fig. 2. Using the bounding box bb. (a) The large rectangle is the original bb. Bisection line b1 between object pixels b and 1 does not change bb. Bisection line b2 decreases the size of bb as indicated by the arrow 2: Also b3 changes bb. The intersection between b1 and b3 also decreases the size of bb.
(b) The filling process: for each scanline in bb each bisection line defines a range of pixels where b should feed to. The gray pixels are fed by b.
2164
NOVEMBER 2014
SCHOUTEN AND BROEK: FAST EXACT EUCLIDEAN DISTANCE (FEED): A NEW CLASS OF ADAPTABLE DISTANCE TRANSFORMS
2165
2166
NOVEMBER 2014
TABLE 2
The Complete Timing Results on the Fabbri et al. [5] Data Set of the Five Exact DT that Were Included in the Benchmark
images
specification
Maurer
turning line
turning line, inverse
turning line
turning line, inverse
inscribed circle
inscribed circle, inverse
random squares
random squares,inverse
random points
point in corner
point in corner, inverse
half-filled image
Lenna (or Lena)s edges
Lenna (or Lena)s edges, inverse
LLT*
SEDT
FEED
FEEDo
ave
rms ave
rms ave
rms ave
rms
ave
rms
33.76
30.35
35.98
32.34
40.63
34.26
37.05
37.63
43.25
21.62
31.04
28.99
39.28
28.52
6.13
0.11
6.36
0.08
0.95
1.48
2.33
2.41
6.26
0.01
0.06
2.34
6.88
0.16
6.56
0.05
2.04
2.59
1.44
1.55
3.89
0.00
0.04
4.24
2.22
0.08
2.72
0.07
1.99
2.27
1.33
1.39
4.84
2.48
0.03
0.81
17.80
0.11
33.83
0.08
45.96
1.30
10.26
8.13
12.52
0.02
0.00
1.21
27.25
3.76
44.66
3.78
51.43
7.43
9.99
10.44
34.40
5.92
3.75
6.10
20.60
8.62
11.47
0.10
20.31
0.07
20.37
0.41
5.22
4.65
22.46
0.01
0.11
2.29
33.28
41.66
35.46
44.01
43.58
43.63
43.95
43.84
49.81
19.60
41.60
34.87
37.74
35.74
35.45
32.32
37.67
35.07
41.09
35.68
38.50
38.91
43.34
33.19
31.19
32.68
38.37
29.40
42.40
4.24
73.99
4.95
95.52
9.49
15.95
15.84
30.41
4.79
4.13
5.67
22.89
9.54
See Table 1 for a description of the DT algorithms. Numbers indicate the average processing time with their root mean square (rms; between brackets)
in ns per pixel. Abbreviations.ave: average processing time in ns=pixel; rms: root mean square in ns/pixel, which indicates the variance in processing
time. Note. rms is not reported for the Lenna (or Lena)s edges image as this concerns only one image instead of a set of images.
SCHOUTEN AND BROEK: FAST EXACT EUCLIDEAN DISTANCE (FEED): A NEW CLASS OF ADAPTABLE DISTANCE TRANSFORMS
2167
TABLE 3
The Complete Timing and Error Results (Compared to the Euclidean Distance, ED)
of the 11 DT that Were Included in the Benchmark
Timing (in ns/pixel)
Algorithm
O
total rms
CH11
4SED
CH34
4SED
HexaD
Maurer
EDT-2
SEDT
LLT*
FEED
FEEDo
5.52
29.70
8.79
21.23
40.42
32.92
29.09
33.17
39.21
11.40
7.74
1.22
1.13
2.69
3.69
14.40
2.33
9.31
1.51
4.14
2.58
1.85
O
total rms
5.84
29.67
9.88
21.72
41.74
34.79
29.86
35.02
40.37
12.42
8.64
1.30
1.11
2.97
3.80
14.98
2.82
9.56
2.15
4.11
2.84
2.05
O
total rms
5.93
30.21
9.58
22.58
44.11
33.86
31.30
33.87
39.50
12.72
8.72
0.68
0.44
1.60
1.80
9.02
2.07
6.23
0.72
4.38
1.19
0.72
all O
total rms
O
total rms
6.31
30.19
10.85
23.23
45.57
34.95
32.03
36.01
40.66
13.89
9.86
0.64
0.49
1.56
1.65
9.24
2.34
6.13
1.15
4.53
1.22
0.97
5.90
29.94
9.77
22.19
42.91
34.38
30.57
34.52
39.93
12.61
8.74
0.96
0.81
2.21
2.73
11.91
2.40
7.81
1.38
4.29
1.96
1.35
:ED
55.36
0.17
54.74
0.17
54.19
5.46
relative (in %)
ave.
max.
ave.
max.
6.20
da
0.85
da
0.25
0.06
135.20
0.32
20.41
0.32
10.06
12.19
13.24
dr
1.77
dr
1.03
0.12
38.59
11.00
5.33
11.00
38.59
7.50
See Table 1 for a description of the DT algorithms. Abbreviations. total: Total processing time in seconds; rms: root mean square, which indicates the
variance in processing time; abs.: absolute; ave.: average; and max.: maximum. Table 1 provides a description for the abbreviations of the algorithms.
Notes. :ED is reported in percent pixels. The exact average errors produced by 4SED [15] and 4SED [16] are da 0:000113 (absolute) and
dr 0:002459 (relative). With is denoted that no (or 0) errors have been generated.
2168
NOVEMBER 2014
Fig. 3. Top row: Four object like images from set O of size 1;036 1;036, with respectively 1:82, 5:92, 50:87, and 94:08 percent object pixels. These
serve as the foundation of the newly generated data set. Bottom row: A sample segment from the third image seen from left of the top row and its
three derivatives versions.
TABLE 4
A One-on-One Comparison between All DT Algorithms on Their Average Processing Time on the Four Image Sets
CH11
CH11
4SED
CH34
4SED
HexaD
Maurer
EDT-2
SEDT
LLT*
FEED
FEEDo
0.20
0.60
0.27
0.14
0.17
0.19
0.17
0.15
0.47
0.68
4SED
CH34
4SED
HexaD
Maurer
EDT-2
SEDT
LLT*
FEED
5.07
1.66
0.33
3.76
0.74
2.27
7.27
1.43
4.39
1.93
5.83
1.15
3.52
1.55
0.80
5.18
1.02
3.13
1.38
0.71
0.89
5.85
1.15
3.53
1.56
0.80
1.00
1.13
6.77
1.33
4.09
1.80
0.93
1.16
1.31
1.16
2.14
0.42
1.29
0.57
0.29
0.37
0.41
0.37
0.32
3.06
1.35
0.70
0.87
0.98
0.87
0.75
2.37
3.43
0.44
0.23
0.28
0.32
0.28
0.24
0.77
1.12
0.52
0.65
0.73
0.64
0.56
1.76
2.54
1.25
1.40
1.24
1.07
3.40
4.91
1.12
1.00
0.86
2.73
3.93
Note. Table 1 provides a description for the algorithms, denoted with their abbreviations.
0.89
0.77
2.42
3.50
0.86
2.74
3.95
3.17
4.57
1.44
FEEDo
1.48
0.29
0.89
0.39
0.20
0.25
0.29
0.25
0.22
0.69
SCHOUTEN AND BROEK: FAST EXACT EUCLIDEAN DISTANCE (FEED): A NEW CLASS OF ADAPTABLE DISTANCE TRANSFORMS
2169
Fig. 4. The average execution time in ns/pixel as function of the percent of object pixels in the images of the four sets of object O images described in
Section 8, and illustrated in Fig. 3.
2170
10
NOVEMBER 2014
DISCUSSION
SCHOUTEN AND BROEK: FAST EXACT EUCLIDEAN DISTANCE (FEED): A NEW CLASS OF ADAPTABLE DISTANCE TRANSFORMS
not suffer from disconnected Voronoi tiles, and can be tailored to the images under investigation. Two exhaustive
benchmarks have been executed, which confirmed these
claims. This quartet of proven properties marks this new
class of DT as promising. l
ACKNOWLEDGMENTS
This publication was supported by both the Dutch NWO
ToKeN project Eidetic (634.000.001) and the Dutch national
program COMMIT. The authors gratefully acknowledge
Andras Hajdu and Attila Fazekasl (University of Debrecen,
Hungary) and Robin Strand and Gunilla Borgefors
(Uppsala University, Sweden) for their helpful comments
and suggestions on an earlier draft of this paper. They thank
the two anonymous reviewers who provided them detailed
feedback on an earlier version of this paper. This enabled
them to improve this paper substantially. Additionally,
they also thank Lynn Packwood (University of Twente, The
Netherlands) for her careful proofreading.
REFERENCES
[1]
[2]
[3]
[4]
[5]
[6]
[7]
[8]
[9]
[10]
[11]
[12]
[13]
[14]
[15]
[16]
A. Rosenfeld and J. L. Pfaltz, Sequential operations in digital picture processing, J. ACM, vol. 13, no. 4, pp. 471494, 1966.
A. Rosenfeld and J. L. Pfaltz, Distance functions on digital
pictures, Pattern Recognit., vol. 1, no. 1, pp. 3361, 1968.
J. Mukherjee, On approximating Euclidean metrics by weighted
t-cost distances in arbitrary dimension, Pattern Recognit. Lett.,
vol. 32, no. 6, pp. 824831, 2011.
O. Cuisenaire and B. Macq, Fast Euclidean transformation by
propagation using multiple neighborhoods, Comput. Vis. Image
Understanding, vol. 76, no. 2, pp. 163172, 1999.
R. Fabbri, L. da F. Costa, J. C. Torelli, and O. M. Bruno, 2D
Euclidean distance transform algorithms: A comparative survey,
ACM Comput. Surveys, vol. 40, no. 1, p. Article 2, 2008.
C. R. Maurer J, R. Qi, and V. Raghavan, A linear time algorithm
for computing exact Euclidean distance transforms of binary
images in arbitrary dimensions, IEEE Trans. Pattern Anal. Mach.
Intell., vol. 25, no. 2, pp. 265270, Feb. 2003.
E. L. van den Broek and T. E. Schouten, Distance transforms:
Academics versus industry, Recent Patents Comput. Sci., vol. 4,
no. 1, pp. 115, 2011.
G. Peyre, M. Pechaud, R. Keriven, and L. D. Cohen, Geodesic
methods in computer vision and graphics, Found. Trends Comput.
Graph. Vis., vol. 5, no. 3/4, pp. 197397, 2010.
J. Gao and L. Guibas, Geometric algorithms for sensor networks,
Philosoph. Trans. Roy. Soc. A: Math., Phys. Eng. Sci., vol. 370, no.
1958, pp. 2751, 2012.
Z. Zhang, H. S. Seah, C. K. Quah, and J. Sun, GPU-accelerated
real-time tracking of full-body motion with multi-layer search,
IEEE Trans. Multimedia, vol. 15, no. 1, pp. 106119, Jan. 2013.
K. C. Ciesielski, X. Chen, J. K. Udupa, and G. J. Grevera, Linear
time algorithms for exact distance transform, J. Math. Imaging
Vis., vol. 39, no. 3, pp. 193209, 2011.
H. Zhang, A. K. Abiose, D. Gupta, D. N. Campbell, J. B. Martins,
M. Sonka, and A. Wahle, Novel indices for left-ventricular dyssynchrony characterization based on highly automated segmentation from real-time 3-D echocardiography, Ultrasound Med. Biol.,
vol. 39, no. 1, pp. 7288, 2013.
G. Borgefors, Distance transformations in arbitrary dimensions,
Comput. Vis., Graph., Image Process., vol. 27, no. 3, pp. 321345,
1984.
G. Borgefors, Distance transformations in digital images, Comput. Vis., Graph., Image Process., vol. 34, no. 3, pp. 344371, 1986.
P.-E. Danielsson, Euclidean distance mapping, Comput. Graph.
Image Process., vol. 14, no. 3, pp. 227248, 1980.
Q.-Z. Ye, The signed Euclidean distance transform and its
applications, in Proc. 9th Int. Conf. Pattern Recognit., vol. 1, Rome,
Italy, Nov. 1417, 1988, pp. 495499.
2171
2172
NOVEMBER 2014