c
c
c
c
=
(
= V
Some properties about this gradient vector
Magnitude
y x y x
G G G G f mag + ~ + = V
2 2
) (
Angle


.

\

=
x
y
G
G
y x
1
tan ) , ( o
Definition of the gradient
 The gradient is a vector which has certain magnitude and direction:
Properties of the gradient
 The magnitude of gradient provides information about the strength of the edge.
 The direction of gradient is always perpendicular to the direction of the edge (the edge
direction is rotated with respect to the gradient direction by 90 degrees).
Note :
The gradient has a large peak centered around the edge, the edge has become
"thick" due to the thresholding.
The edge occurs at the peak, we can localize it by computing the laplacian (in one
dimension, the second derivative with respect to t) and finding the zero crossings.
2
nd
order derivative :
Edge points can be detected by finding the zerocrossings of the second derivative.
Laplacian Operator
2
2
2
2
2
y
f
x
f
f
c
c
+
c
c
= V
 The Laplacian is usually used to establish whether a pixel is on the dark or light
side of an edge.
 The Laplacian method searches for zero crossings in the second derivative of the
image to find edges.
 An edge has the onedimensional shape of a ramp and calculating the derivative of
the image can highlight its location.
Properties of the Laplacian
 It is an isotropic operator.
 It is cheaper to implement (one mask only).
 It does not provide information about edge direction.
 It is more sensitive to noise (differentiates twice).
The LaplacianofGaussian (LOG)
 To reduce the noise effect, the image is first smoothed with a lowpass filter.
 In the case of the LOG, the lowpass filter is chosen to be a Gaussian.
Steps :
 Smooth the image to reduce noise
 Then calculate the 2nd derivative
 Finally, find the zerocrossing
Gradient vs LOG: a comparison
 Gradient works well when the image contains sharp intensity transitions and low noise
 Zerocrossings of LOG offer better localization, especially when the edges are not very
sharp(Edges are blurry) .
Some Advantages and Disadvantages of Edge Detectors
Operator Advantages Disadvantages
Classical (Sobel,
prewitt, robert,)
Simplicity,
Detection of
edges and their
orientations
Sensitivity to
noise, Inaccurate
Zero
Crossing(Laplacian,
Second directional
derivative)
Detection of
edges and their
orientations.
Having fixed
characteristics in
all directions, edges
are thinner.,
noise reduction
capability;
Responding to
some of the
existing edges,
Sensitivity to
Noise, computation
complex.
Laplacian of
Gaussian(LoG)
Finding the
correct places of
edges, Testing
wider area
around the pixel
Malfunctioning
at the corners, curves
and
where the gray
level intensity
function varies.
Not finding the
orientation of
edge because of
using the
Laplacian filter
Gaussian(Canny,
.)
Using
probability for
finding error
rate,
Localization and
response.
Improving signal
to noise ratio,
Better detection
specially in
noise conditions
Complex
Computations,
False zero
crossing, Time
consuming