+ All Categories
Home > Documents > Segmentation 268

Segmentation 268

Date post: 30-May-2018
Category:
Upload: hckhoa1238
View: 223 times
Download: 0 times
Share this document with a friend

of 12

Transcript
  • 8/14/2019 Segmentation 268

    1/12

    1

    268

    Segmentation 268

    Segmentation

    Image Processing & Computer Vision Lecture

    269

    Segmentation 269

    Image Processing & Computer Vision

    Introduction

    -. Introduction

    -. Automatic Thresholding Methods

    -. Region Representation

    -. Split and Merge

    -. Region Growing

  • 8/14/2019 Segmentation 268

    2/12

    2

    270

    Segmentation 270

    Image Processing & Computer Vision

    Introduction (cont.)

    n Segmentation problem

    Partition an imageI into homogeneous regions.

    n Description:

    Given an imageI and a homogeneity predicateP(), find a partition S ofthe imageI into a set ofNregionsRi such that

    ng)partitionie(exhaustiv1

    IRN

    i

    i=

    =

    U

    ng)partitioni(exclusivefor,0 jiRR ji =I

    property)ty(homogenei,)(

    ,)(

    ==

    jiFalseRRP

    iTrueRP

    ji

    i

    U

    271

    Segmentation 271

    Image Processing & Computer Vision

    Introduction (cont.)

    n Attributes orP()

    Intensity, texture, color, motion, etc.

    n Qualitative guideline

    Uniform & homogeneous

    Simple region interior

    Significantly different adjacent regions

    Simple and accurate boundary

    n Techniques

    Threshold-based segmentation

    Region-based segmentation

    Boundary extraction

  • 8/14/2019 Segmentation 268

    3/12

    3

    272

    Segmentation 272

    Image Processing & Computer Vision

    Threshold-based segmentation

    n P-tile segmentation method

    Simply use the size information of

    the object

    Suppose the object occupies about

    p% of the image area, then setthreshold to assignp% of the pixelsto the object

    n Mode method

    Assume Gaussian distribution forthe object and background withsimilar size

    Then, detect the peaks and thevalleys, and set the threshold by

    the valley point

    Bayes decision theory

    h

    xP %

    T

    h

    xgi gk gj

    T

    ( ) ( )=

    =255

    areaimageentireTx

    pxh

    Histogram

    Intensity

    273

    Segmentation 273

    Image Processing & Computer Vision

    Threshold-based segmentation

    Peakness detection algorithm for

    threshold selection:

    Find two local maxima gi and gjwhich are some distance apart

    Find the lowest point gk betweengi and gj

    Determine the peakness definedas min(h(gi ),h(gj))/h(gk)

    Find the highest peaknesscombination(g

    i

    , gj

    , gk

    ), and setthe threshold T= gk

    Segmentation result with T=90

  • 8/14/2019 Segmentation 268

    4/12

    4

    274

    Segmentation 274

    Image Processing & Computer Vision

    Threshold-based segmentation (cont.)

    n Practical problems of global

    thresholding techniques

    Noise

    Uneven illumination problem

    Original Text Threshold=90

    Threshold=150 Threshold=230

    Uneven illumination problem

    275

    Segmentation 275

    Image Processing & Computer Vision

    Threshold-based segmentation (cont.)

    n Iterative threshold selection method

    Refines the threshold iteratively using the statistics of the segmented

    regions in the previous iteration.

    Algorithm:

    1. Set initial threshold T (the average intensity of the image)

    2. Partition the image into two regions R1 and R2using T

    3. Determine the means1 and2 of R1 and R2, respectively.

    4. Update new threshold T= (1 +2 )/2.5. Repeat steps 2-4, until the means1 and2 in successive iterations do not

    change.

  • 8/14/2019 Segmentation 268

    5/12

    5

    276

    Segmentation 276

    Image Processing & Computer Vision

    Threshold-based segmentation (cont.)

    n Adaptive thresholding method

    Partition the image intomxm

    subimages

    Select a threshold Tijfor each

    subimage based on its histogram

    Threshold levels for each pixel aredetermined by interpolation

    between the block centers

    277

    Segmentation 277

    Image Processing & Computer Vision

    Threshold-based segmentation (cont.)

    n Variable thresholding

    (background normalization)

    Approximate the background

    intensity by simple functionsuch as plane or biquadratic

    Then normalize the

    background by subtractingthe fitted function to theimage

    Now, a global thresholdingtechnique can be applied to

    segment the normalizedimage

    22fyexydxcybxaI +++++=

  • 8/14/2019 Segmentation 268

    6/12

    6

    278

    Segmentation 278

    Image Processing & Computer Vision

    Threshold-based segmentation (cont.)

    n Double Thresholding

    Single threshold segmentation failswhen the same intensities belong toeither objects or the background.

    Save marginal histogram region forthese intensities and decideassignment by consideringgeometric properties.

    Double thresholding algorithm

    1. Select two thresholds T1 and T2

    2. Partition the image into three regionsR1, R2 and R3 using T1 and T2

    3. For each pixel in the middle regionR2, assign it to R1 if it is a neighborof R1

    4. Repeat until no changes inreassigning

    5. Reassign any pixel left in R2 to R3

    Double thresholding example

    279

    Segmentation 279

    Image Processing & Computer Vision

    Threshold-based segmentation (cont.)

    n Ostu s method (N=2)

    Determine thresholdTwhich minimizes the within-class variation while

    maximizes the between-class variation s.t.,

    where

    22 /BW

    JMinimize =

    )(0110

    2

    2

    11

    2

    00

    2

    =

    +=

    B

    W

    222

    WBT +=

    =

    =1

    0

    0

    2

    0

    2

    0 )()(T

    x

    xpx

    =

    =255

    1

    2

    1

    2

    1 )()(Tx

    xpx

    =

    =1

    0

    0 )(T

    x

    xp

    =

    =255

    1)(

    Tx

    xp

    =

    =

    =

    1

    0

    1

    0

    0 )()(T

    x

    T

    x

    xhxxh

    =

    ==

    25 525 5

    1 )()(TxTx

    xhxxh

    =

    =255

    0

    )()()(x

    xhxhxp

  • 8/14/2019 Segmentation 268

    7/12

    7

    280

    Segmentation 280

    Image Processing & Computer Vision

    Region-based Segmentation

    n Quad Tree representation of

    regions

    Tree-structure representationof recursive subregions

    281

    Segmentation 281

    Image Processing & Computer Vision

    Region-based Segmentation

    n Region Adjacency Graphs (RAG)

    represent region and mutual relationships

    node: regions

    arcs: boundary between regions

  • 8/14/2019 Segmentation 268

    8/12

    8

    282

    Segmentation 282

    Image Processing & Computer Vision

    Region-based Segmentation

    n Region Split and Merge

    The basic idea: break the image into a

    set of disjoint regions which arecoherent within themselves

    Top-down approach

    Algorithmic Steps:

    1. Start with the entire image as a singleregion.

    2. For each region Ri. If P(Ri)=FALSE,then split Ri into four subregions.

    3. If for any adjacent subregions Rj andRk, P(RjU Rk)=TRUE, then mergethem into a single region.

    4. Repeat until no further split and mergetake place.

    R1 R2

    R41 R42

    R44R43R3

    R1 R2

    R41 R42

    R43R3

    R

    R1 R2

    R3 R4

    Whole image First split

    Second split Merge

    283

    Segmentation 283

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Region Split and Merge (Cont.)

    Modified quadtree structure.

    Each non-terminal node in the treehas at most four descendants,

    although it may have less due tomerging.

    Corresponding quadtree

    R

    R1

    R41 R42 R43

    R4R3R2

  • 8/14/2019 Segmentation 268

    9/12

    9

    284

    Segmentation 284

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Similarity measures between regions

    Mean intensity comparison

    If |1 -2 | < Th, then similar. Otherwise dissimilar.

    Statistical hypothesis testing

    Consider Two regions R1,R2with m1 and m2pixels, respectively

    Then, two hypothesesH0andH1 are possible

    H0: Both regions belong to the same region

    Intensities are from a single Gaussian distribution with( 0,0)

    The joint pdf under H0becomes

    2

    0

    2

    )(

    0

    2

    )(

    1 0

    1

    0021

    )21(

    21

    20

    21

    1

    20

    21

    2

    0

    2

    021

    21

    21

    )2(

    1

    )2(

    1

    21

    )|()|,...,,(

    mm

    mm

    ii

    i

    e

    e

    e

    HgpHgggp

    mm

    g

    mm

    gmm

    i

    mm

    i

    imm

    +

    +

    =

    +

    +

    +

    =

    +

    =+

    =

    =

    =

    =

    285

    Segmentation 285

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Similarity measures between regions (cont.)H1 : Two regions are different:

    Intensities of each regions are from different Gaussian distribution

    with( 1,1) and ( 2,2)

    The joint pdf becomes

    Define the likely-hood ratio

    Then, decide to merge ifL< Th. Otherwise, do not merge.

    2

    21

    2

    2

    2

    1

    1121

    )21(

    2121

    2

    2

    1

    12111

    )2(

    1

    )2(

    1

    )2(

    1)|,...,,,...,,(

    mm

    e

    eeHgggggp

    mmmm

    m

    m

    m

    mmmmm

    +

    +

    ++

    =

    =

    21

    21

    21

    21

    21

    0

    021

    121

    )|,...,,(

    )|,...,,(mm

    mm

    mm

    mm

    Hgggp

    HgggpL

    +

    +

    + ==

  • 8/14/2019 Segmentation 268

    10/12

    10

    286

    Segmentation 286

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Removing Weak Edges (Boundaries)

    4Approach 1:

    Merge R1 and R2 if

    W: length of the weak boundaryS = min(S1,S2): threshold ( =0.5)

    >S

    W

    4Approach 2:

    Merge R1 and R2 if

    W: length of the weakS = common boundary: threshold ( =0.75)

    >S

    W

    Not merge Merge Not merge Merge

    S1

    S2

    w wS

    287

    Segmentation 287

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Region Split and Merge Examples

    original segmentation

    Split and Merge Example

  • 8/14/2019 Segmentation 268

    11/12

    11

    288

    Segmentation 288

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Region Growing

    Basic Idea: the opposite of the split and merge approach

    An initial set of small areas are iteratively merged according tosimilarity constraints.

    A bottom up method.

    Algorithmic Steps:

    1. Start by choosing an arbitrary seed pixel and compare it withneighbouring pixels.

    2. Region is grown from the seed pixel by adding in neighboring pixelsthat are similar, increasing the size of the region.

    3. When the growth of one region stops we simply choose another seedpixel which does not yet belong to any region and start again.

    4. This whole process is continued until all pixels belong to some region.

    289

    Segmentation 289

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Region Growing (Cont.)

    Region growing methods oftengive very good segmentationsthat correspond well to the

    observed edges.

    However, starting with a

    particular seed pixel andletting this region growcompletely before trying other

    seeds biases thesegmentation in favor of the

    regions which are segmentedfirst.

  • 8/14/2019 Segmentation 268

    12/12

    12

    290

    Segmentation 290

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Region Growing (cont.)

    Undesirable effects:

    Current region dominates the growth process -- ambiguities around edgesof adjacent regions may not be resolved correctly.

    Different choices of seeds may give different segmentation results.

    Problems can occur if the (arbitrarily chosen) seed point lies on an edge.

    simultaneous region growing techniques

    Similarities of neighbouring regions are taken into account in the growingprocess.

    No single region is allowed to completely dominate the proceedings. .

    291

    Segmentation 291

    Image Processing & Computer Vision

    Region-based Segmentation (cont.)

    n Region Growing (cont.)

    Simultaneous region growing technique (cont.)

    A number of regions are allowed to grow at the same time.

    Similar regions will gradually coalesce into expanding regions.

    Easy and efficient to implement on parallel computers

    Segmentation results by region growing


Recommended