Edge Detect
Edge Detect
CS 111
depth discontinuity
illumination discontinuity
By finite differences
f(x+1,y) f(x,y)
f(x, y+1) f(x,y)
The Sobel operator
Better approximations of the derivatives exist
The Sobel operators below are very
commonly used
-1 0 1 1 2 1
-2 0 2 0 0 0
-1 0 1 -1 -2 -1
Poor Localization
(Trigger response in
multiple adjacent pixels)
Laplacian of Gaussian
operator
2D edge detection filters
Laplacian of Gaussian
original
Edge detection by subtraction
Why does
this work?
smoothed original
(scaled by 4, offset +128) filter demo
Gaussian - image filter
Laplacian of Gaussian
Pros and Cons
Assume:
Linear filtering
Additive Gaussian noise
Edge detector should have:
Good Detection. Filter responds to edge,
not noise.
Good Localization: detected edge near true
edge.
Minimal Response: one per edge
Detection/Localization trade-off
More smoothing improves detection
And hurts localization.
Canny Edge Detector
Suppress Noise
Compute gradient magnitude and
direction
Apply Non-Maxima Suppression
Assures minimal response
Use hysteresis and connectivity
analysis to detect edges
Non-Maxima Supression
larger
(0,0)
Basic Hough Transform