23-01-2013, 11:39 AM
On the Canny edge detector
On the Canny edge.pdf (Size: 307.93 KB / Downloads: 67)
Abstract
The Canny edge detector is widely used in computer vision to locate sharp intensity changes and to "nd object
boundaries in an image. The Canny edge detector classi"es a pixel as an edge if the gradient magnitude of the pixel is
larger than those of pixels at both its sides in the direction of maximum intensity change. In this paper we will show that
de"ning edges in this manner causes some obvious edges to be missed. We will also show how to revise the Canny edge
detector to improve its detection accuracy. ( 2001 Pattern Recognition Society. Published by Elsevier Science Ltd. All
rights reserved.
Introduction
Edge detection is one of the fundamental operations in
computer vision with numerous approaches to it. In an
historical paper, Marr and Hildreth [1] introduced the
theory of edge detection and described a method for
determining the edges using the zero-crossings of the
Laplacian of Gaussian of an image. Haralick [2] determined
edges by "tting polynomial functions to local
image intensities and "nding the zero-crossings of the
second directional derivative of the functions. Canny [3]
determined edges by an optimization process and proposed
an approximation to the optimal detector as the
maxima of gradient magnitude of a Gaussian-smoothed
image. Clark [4] and Ulupinar and Medioni [5] independently
found a method to "lter out false edges obtained
by the Laplacian of Gaussian operator.
Results
To compare results obtained by the original Canny
edge detector and the revised Canny edge detector,
a number of experiments were carried out. In these experiments,
the same Gaussian smoother was used in both
edge detectors. Also, the same hysteresis thresholds were
used in both edge detectors. Fig. 3(a) shows a synthetic
image of homogeneous blocks, and Fig. 4(a) shows an
image of printed text. Thirty-two homogeneous regions
are present in Fig. 3(a). The boundaries of the regions are
clearly de"ned, and because the image is not noisy, we
expect an edge detector to obtain horizontal and vertical
lines representing the edge contours in the image. Edges
obtained by the Canny edge detector with a Gaussian of
standard deviation 2 pixels is shown in Fig. 2(b). As
expected, edges near the branch points are missed. It is
interesting to note that discontinuities in the edge contours
are vertical and not horizontal. Since gradients are
stronger vertically, it is desired that the detected edge
contours be horizontal.
Discussion and conclusion
To ensure that closed edge contours are obtained, one
may use the zero-crossings of the Laplacian of Gaussian
[1] of the image. The zero-crossings of the Laplacian of
Gaussian of Fig. 4(a) after hysteresis thresholding is
shown in Fig. 5(a). As can be observed, the characters are
well delineated. A small number of the zero-crossings do
not correspond to locally maximum intensity changes
but rather correspond to locally minimum intensity changes.
Edges corresponding to locally minimum intensity
changes are referred to as phantom edges [4]. After
removing the phantom edges, we obtain the image shown
in Fig. 5(b). The phantom edges have appeared only in
the &w's'. Fewer edges have been missed by the Clark
method than by the Canny method.