hough transform procedure to find a shape in an image shape can be described in parametric form...

13
Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions A voting scheme is used to determine the correct parameters

Upload: grant-wilkinson

Post on 21-Jan-2016

218 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform

Procedure to find a shape in an imageShape can be described in parametric formShapes in image correspond to a family of parametric solutionsA voting scheme is used to determine the correct parameters

Page 2: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform for Linesy ax b b y ax

y

x

3 3( , )x y

2 2( , )x y

1 1( , )x y

a

b

3 3b y ax

0 0( , )a b

0 0y a x b

2 2b y ax 1 1b y ax

Page 3: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform for Lines

Quantize spaceEach bin represents a line defined by Accumulate values in bin according to edge points Each bin contains the amount of points in image that would form a line defined by

b

3 3b y ax

( , )i ia b

2 2b y ax

1 1b y ax

( , )i ia b

( , )j jx y

( , )a b

( , )i ia b

Page 4: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform for Lines

Problem with vertical lines Normal form

a

cos( ) sin( )r x y y

x

( , )r

0 0

0

cos( )

sin( )

r xy

0r

11r

1 1( , )x y

0

2 2( , )x y

0 0( , )x y1 1cos( ) sin( )r x y

Page 5: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform for Lines

y

x

0r

1 1( , )x y

0

2 2( , )x y

0 0( , )x y

1 1cos( ) sin( )r x y

-3 -2 -1 1 2 3

-2

-1

1

2

r

1 1( , )x y

0 0( , )x y

2 2( , )x y

0 0( , )r

0 0( , )r

Page 6: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform for Lines

y

x1

1r

1 1( , )x y

3 3( , )x y4 4( , )x y

-3 -2 -1 1 2 3

-4

-2

2

4

1 1( , )x y

r1 1cos( ) sin( )r x y

3 3( , )x y

4 4( , )x y 1 1( , )r

1 1( , )r

Page 7: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Pick in the parametric space that corresponds

to the line

Page 8: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform for Lines

Domain of the parametric space:

M and N image resolution

Not just lines, any parametric curve!

However increase of dimensions of the parametric space

2 2 2 2, , ,2 2

r M N M N

Page 9: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform of Circles

Circle is define by its center and radius -3D Hough parametric space

2 2 2( ) ( )x a y b r

( , )a br

0r

1r0 0( , )a b

1 1( , )a b

0 0( , )x y2 2 2

0 0 0( ) ( )x a y b r

2 2 21 1 1( ) ( )x a y b r

( , , )a b r

Page 10: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform of Circles

0r

1r0 0( , )a b

1 1( , )a b

y

x

a

br

0r r

0 0( , )x y0 0( , )x y

1 1( , )x y

1 1( , )x y

0 0 0( , , )a b r

cosa x r sinb y r

Page 11: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

a

br

Hough Transform of Circles

0r

1r0 0( , )a b

1 1( , )a b

y

x

1r r

0 0( , )x y

1 1( , )x y

0 0( , )x y

1 1( , )x y

1 1 1( , , )a b rcosa x r sinb y r

Page 12: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions

Hough Transform

Find parametric shapes in an imageSlow but robust to noise and occlusionQuantization of the parameters controls accuracy and speed

Page 13: Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions