chapter 10, part i. segmentation subdivides an image into its constituent regions or objects. ...

22
Chapter 10, Part I

Upload: mark-stokes

Post on 13-Jan-2016

232 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Chapter 10, Part I

Page 2: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Segmentation subdivides an image into its constituent regions or objects.

Image segmentation methods are generally based on two properties.◦ Discontinuity: abrupt changes in intensity, such as

edges.◦ Similarity: finding similar regions similar according to a

set of predefined criteria, such as thresholding, region growing, region splitting and merging.

Page 3: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Three types of gray-level discontinuities: points, lines and edges.

The response of the mask at any point in the image is given by

R=w1z1+w2z2+…+w9z9

where zi is the gray level of the pixel associated with mask coefficient wi.

Page 4: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

10.1.2 Line Detection10.1.2 Line Detection• If the first mask was moved around an image, it would

respond more strongly to lines oriented horizontally.

Page 5: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Let Ri denote the response the i-th mask generates.

If |Ri| > |Rj|, for all j≠i, that point is said to be more likely associated with a line in the direction of Ri. ◦ A threshold value T may be used to sift the

response on each point for differentiating points on edges.

Alternatively, we may use this scheme to detect lines in a specific direction.

Page 6: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Line Detection in a Specific DirectionLine Detection in a Specific Direction

Page 7: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

An edge is a set of pixels that lie on the boundary of two regions.

Edge detection is a process to measure the grey-level transitions◦ Ideal edge: a clear transition in grey level.◦ ramp edge: edges that are blurred.

First derivative and second derivative can be used to detect edges.

“Zero-crossing” property of second derivative is used to identify the location of edge.

Page 8: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

The slope of the ramp is inversely proportional to the degree of blurring in the edges.

Basic FormulationBasic Formulation

Page 9: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

• First derivative:– Constant for points in the ramp.– The thickness of edge = the length of ramp.

• Second derivative: – Producing two values for every edge.– Zero-crossing point is near the midpoint of

edge. Zero-crossing

Page 10: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

•Derivatives are sensitive to noise, especially second derivative.

•Fairly little noise can result great difficulties on edge detection using derivatives.

Image smoothing is requires.

Page 11: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

A 2-D gradient defined as:

The magnitude of this vector isf = mag(f) = [Gx

2 + Gy

2 ]1/2

The direction is (x, y) = tan-1(Gx/Gy)

◦ The direction of an edge at (x, y) is perpendicular to the gradient.

y

fx

f

G

Gf

y

x

Page 12: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Robert cross-gradient operators:Gx=(z9 –z5 ) and Gy=(z8 –z6)

◦ It does not have a clear center. Prewitt 3x3 operators

Gx=(z7+z8+z9 )–(z1+z2+z3 ) and Gy= (z3+z6+z9 )–(z1+z4+z37 )

Sobel operatorsGx=(z7+2z8+z9 )–(z1+2z2+z3 ) and Gy= (z3+2z6+z9 )–(z1+2z4+z37 )

The gradient is f Gx + Gy◦ computationally attractive

Page 13: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

• The price of gradient operator is that the original Prewitt and Sobel masks are not isotropic (invariant to rotation).

Page 14: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Masks for Detecting Diagonal Edges.Masks for Detecting Diagonal Edges.

Page 15: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Example 10.4Example 10.4

Page 16: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Example 10.4Example 10.4

Page 17: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Example 10.4Example 10.4

Page 18: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

The LaplacianThe Laplacian

• Digital approximation for 3 x 3 region is

2f = 4z5 - (z2+z4+z6+z8), or

2f = 8z5 - (z2+z4+z6+z8 +z1+z3+z7+z9)

2

2

2

2

2

y

fx

f

f

Page 19: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

The Laplacian is generally not used for edge detection since◦ Sensitive to noise.◦ The effect of double edges.◦ Unable to detect edge direction.

The main usage:◦ Using zero-crossing property for edge locating.◦ Using it to determine whether a pixel is on the dark or

light size of an edge.

Page 20: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Gaussian: h(r)=-e-r2/22 where r2=x2+y2

◦ Convolving the Gaussian with the image will blur the image.

The second derivative of h(r) is

◦ the Lapalcian of a Gaussian (LoG) The Laplacian provides an image with zero crossings for

edge location. The Gaussian is used to supress noise.

2

2

24

222 )(

r

er

rh

Page 21: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two

Plots of a Log OperatorPlots of a Log Operator

Certain aspects of human vision can be models mathematically in this form.

Page 22: Chapter 10, Part I.  Segmentation subdivides an image into its constituent regions or objects.  Image segmentation methods are generally based on two