gradient vector flow a new external force for snakes

Upload: divya-kanuri

Post on 09-Apr-2018

224 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    1/35

    Gradient Vector Flow: A New

    External Force for Snakes

    Joseph 2006/09/13

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    2/35

    Outline

    Introduction

    Background (Active ContourModel)

    Gradient VectorFlow Field GVF Fields and GVF Snakes

    Conclusion

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    3/35

    Introduction

    Snakes, oractive contours, are used extensively in

    computervisionand image processing applications,

    particularly to locate object boundaries.

    There are two general types ofactive contourmodels inthe literature today:parametric active contours and

    geometric active contours .

    Inthis paper, we focus on parametric active contours,which synthesize parametric curves withinanimage

    domainand allow them to move toward desired features,

    usually edges.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    4/35

    Introduction

    The internal and external forces are defined so thatthesnake will conform to an object boundary orotherdesired features withinanimage.

    Typically, the curves are drawntoward the edges bypotential forces.

    Additional forces, such as pressure forces, togetherwiththe potential forces comprise the external forces.

    There are also internal forces designed to hold the curvetogether (elasticity forces) and to keep it from bendingtoo much (bending forces).

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    5/35

    Introduction

    There are two key difficulties with active contouralgorithms. First, the initial contourmust, in general, be close to the true

    boundary orelse it will likely converge to the wrong result.

    Second, the active contours have difficulties progressing intoconcave boundary regions .

    This paperdevelops anew external force foractivecontours, largely solving both problems.

    This external force, which we call gradientvector flow(GVF), is computed as a diffusion ofthe gradientvectorsofa gray-level orbinary edge map derived from theimage.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    6/35

    Parametric Snake Model

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    7/35

    Parametric Snake Model

    A traditional snake is a curve ,

    that moves through the spatial domain ofanimage to

    minimize the energy functional.

    where and are weighting parameters that control the

    snake's tensionand rigidity

    ]1,0[)],(),([)( ! ssysxsX

    E F

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    8/35

    Parametric Snake Model

    The external energy function is derived from the

    image so thatittakes onits smallervalues atthe

    features ofinterest, such as boundaries.

    Giv

    en

    a

    gra

    y-level

    im

    age ,

    isa

    two-d

    ime

    nsiona

    lGaussian function with standard deviation and is the

    gradient operator.

    Ifthe image is a line drawing (black on white)

    ),( yxI

    extE

    ),( yxGW W

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    9/35

    Parametric Snake Model

    A snake that minimizes Emust satisfy the Eulerequation

    This can be viewed as a force balance equation

    where and

    The internal force discourages stretching and bending while the

    external potential force pulls the snake towards the desired

    image contour.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    10/35

    Parametric Snake Model

    To find a solutionto (6), the snake is made dynamic bytreating x as function oftime tas well as s i.e. .

    A solutionto (7) can be found by discretizing the equationandsolving the discrete system iteratively.

    ),( ts

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    11/35

    Internal Energy

    Ifthe curve is represented by n points

    ,

    niyxviii

    ......1),( !!

    1} ii vvds

    dv112

    2

    2 } iii vvvds

    vd

    !

    !

    n

    i

    ernal iiiiiE vvvvv

    1

    22

    int 111 2FE

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    12/35

    External Energy

    !

    !n

    i

    external iiyiixE yxyx

    1

    22

    ),(),(

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    13/35

    Parametric Snake ModelAn example of the movement of a point, v

    i, in an active contour.

    The point, vi , is the location of minimum energy due to a large

    gradient at that point.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    14/35

    Parametric Snake Model

    The snake solutions shownin Figs. 1(a) and 1(b) both

    satisfy the Eulerequations (6) fortheirrespective energy

    model.

    In Fig. 1(a) shows a 64 64-pixel line-drawing ofa U-shaped object (shownin gray) having a boundary

    concavity atthe top.

    The potential force field where pixel

    is shownin Fig. 1(b).

    0.1!W

    v

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    15/35

    Parametric Snake Model

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    16/35

    Parametric Snake Model

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    17/35

    Generalized Force Balance Equations

    The choice of can have a profound impact on both

    the implementationand the behaviorofa snake.

    Broadly speaking, the external forces can be divided into

    two classes: static and dynamic. Static forces are those thatare computed from the image

    data, and do not change as the snake progresses.

    The most general static vector field can be decomposed

    into two components: anirrotational (curl-free)

    componentand a solenoidal (divergence-free)

    component.

    Fg

    ext

    )(

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    18/35

    Gradient Vector Flow Field

    We define below anew static external force

    field , which we call the gradient vector flow

    (GVF) field.

    To obtainthe corresponding dynamic snake equation, wereplace the potential force with , yielding

    This equationis solved in similar fashionto the traditionalsnakei.e., by discretizationand iterative solution.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    19/35

    Edge Map

    We begin by defining anedge map derived fromthe image having the property thatitis largernear

    the image edges.

    where 1, 2, 3, or4. First, the gradient ofan edge map has vectors

    pointing toward the edges, which are normal to the edgesatthe edges.

    Second, these vectors generally have large magnitudes

    only inthe immediate vicinity ofthe edges. Third, in homogeneous regions, where is nearly

    constant, is nearly zero.

    !i

    ),( yxf),( yxI

    f

    f

    ),( yxI

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    20/35

    Gradient Vector Flow

    We define the gradientvector flow field to be the vectorfield that minimizes the energyfunctional

    When is small, the energy is dominated by sum ofthe squares ofthe partial derivatives ofthe vector field,

    yielding a slowly varying field. Onthe otherhand, when is large, the second term

    dominates the integrand, and is minimized by setting

    .

    f

    f

    fV !

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    21/35

    Gradient Vector Flow

    Using the calculus of variations , it can be shownthatthe

    GVF field can be found by solving the following Euler

    equations

    where is the Laplacian operator

    We note thatina homogeneous region [where is

    constant], the second term in each equationis zerobecause the gradient of is zero.

    ),( yxI

    2

    ),( yxf

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    22/35

    Gradient Vector Flow

    Equations (13a) and (13b) can be solved by treating u

    and vas functions oftime and solving

    The equations are knownas generalized diffusion

    equations, and are knownto arise in such diverse fieldsas heat conduction, reactorphysics, and fluid flow.

    ]),(),([ 22 yxfyxf yx

    )],(),,([),,(),,( 2 yxftyxutyxutyxu xt ! Q

    )],(),,([),,(),,( 2 yxftyxvtyxvtyxv yt ! Q

    ]),(),([22

    yxfyxf yx

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    23/35

    Gradient Vector Flow

    Where

    Any digital image gradient operatorcan be used to calculate

    and .

    The coefficients , , and , canthen be

    computed and fixed forthe entire iterative process.

    yf xf

    ),( yxb ),(2 yxc),(1 yxc

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    24/35

    Gradient Vector Flow

    To set up the iterative solution, letthe indices , , and

    correspond to , , and , respectively, and letthe spacing

    between pixels be and the time step foreach iteration be .

    jx

    niy tx( y( t(

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    25/35

    Gradient Vector Flow

    Substituting these approximations into (15) gives ouriterativesolutionto GVF as follows:

    where ,

    Convergence can be made to be fasteron coarserimagesi.e.,when and are larger.

    When is large and the GVF is expected to be a smootherfield,the convergence rate will be slower(since must be kept small).

    x( y(Q

    t(

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    26/35

    GVF Fields and GVF Snakes

    In our first experiment, we computed the GVF field

    forthe line drawing of figure using .

    First, the GVF field has a much largercapture

    range. A second observationis thatthe GVF vectors are

    pointing somewhat downward into the top ofthe U-

    shape, which should cause anactive contourto

    move fartherinto this concave region.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    27/35

    Convergence to a Concave Region

    Fig. 3. (a) Convergence ofa snake using (b) GVF external forces,

    and (c) shown close-up withinthe boundary concavity.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    28/35

    Convergence to a Concave Region

    GVF external forcestraditional potential forces

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    29/35

    Convergence to a Concave Region

    Convergence ofa snake using

    traditional potential forcesConvergence ofa snake using

    GVF external forces

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    30/35

    Streamlines of external force fields

    Stream lines of particles in (a) a potential force field and (b) a GVF field.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    31/35

    Snake Initialization

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    32/35

    Snake Initialization

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    33/35

    Gray-level Images

    To compute GVF forgray-level images, the edge-map

    function must first be calculated.

    Two possible choices forthe edge-map are

    or .

    ),(),(1 yxIyxf !

    ),( yxf

    )),(),((),(

    2

    yxIyxGyxf

    ! W

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    34/35

    Gray-level Images

    (a) A magnetic resonance

    image of the left ventrical

    of a human heart (short-

    axis section).

    (b) The edge mapwith .

    (c) The computed GVF.

    (d) Initial and intermediate

    contours (gray curves)

    and the final contour

    (white curve) of the GVFsnake.

  • 8/8/2019 Gradient Vector Flow a New External Force for Snakes

    35/35

    Conclusion

    We have introduced anew external force model forsnakes called gradientvector flow (GVF).

    The field is calculated as a diffusion ofthe gradientvectors ofa gray-level orbinary edge map.

    We have shownthatitallows for flexible initializationofthe snake and encourages convergence toboundary concavities.

    Finally, the GVF framework might be useful in

    defining new connections between parametric andgeometric snakes, and might form the basis foranew geometric snake.