Вы находитесь на странице: 1из 19

TUTORIAL: ADIPCV

Tutorial - 1

Image noise
Gaussian

Uniform
Salt and Pepper
Speckle
Usage
Matlab: imnoise

Image Filtering
Linear

f (i, j ) w * h

w(m, n)h(i m, j n)

m a nb

Where, w is called a convolution kernel


Examples:
Gaussian
Average

Non-linear
Based on local image content
Examples: Median

Image Filtering
Example

100
200
300

400
500
200

400

600

800

Edge detection
Corresponds to object boundaries in image.
Set of pixels where image brightness changes abruptly.

Brightness vs. Spatial Coordinates

Edge Detection
Gradient
The gradient magnitude and gradient direction are

continuous image functions.


Gradient equation:
Direction:
Magnitude:

Edge Detection
Edge variation with gradients

I
x

2I
x 2

zero-crossing

x
x

Edge Detection
Digital Filters
Gradient
I 1

x 2

I 1

y 2

Laplacian

2I 2I
I 2 2
x y
2

Convolution masks :

2 I

or

1
6 2

20

Edge Detection
Sobel operator:
-1 0 1

x=

-2 0 2

1 2 1

y=

0 0 0

-1 0 1

-1 -2 -1

Roberts operator:
0

-1 0

-1

Prewitt operator:

1 1 1
y 0 0 0
1 1 1

1 0 1
x 1 0 1
1 0 1

Edge Detection
Laplacian operator

4NN:

0 1 0
1 4 1

0 1 0

8NN:

Laplacian of Gaussian
2
2
h f 2
2
x
x

h f

Zero crossings fron LoG

1 1 1
1 8 1

1 1 1

Edge Detection
1-D example

Edge Detection

Gaussian

Laplacian operator:

Derivative of Gaussian
(DoG)

Laplacian of
Gaussian

Edge Detection
Self study
Canny detection:
local edge normal directions
edge magnitudes
edge location by finding zero-crossings along the edge normal

directions (non-maximum suppression)

Edge Detection
Example

Corner Detector

flat region:
no change in
all directions

edge:
no change along
the edge direction

corner:
significant change
in all directions

Corner Detector
Change of intensity for the shift [u,v]:

E (u, v) w( x, y) I ( x u, y v) I ( x, y)

x, y

Solving for Taylors series expansion,

E(u,v) w(x, y)[I(x, y) uIx vIy I(x, y)]2


x,y

w(x, y)[uIx vIy ]2


x,y

Ix Ix
w(x, y)(u v)
Ix Iy
x,y

I x2
M w( x, y )
x, y
I x I y

Ix Iy u

Iy Iy v

IxI y
2
I y

Corner Detector
Measure of corner response:

R det M k trace M ;
2

det M 12
trace M 1 2

Find points with large corner response function R

(R > threshold)
Take the points of local maxima of R

Corner Detector
Example

Вам также может понравиться