Professional Documents
Culture Documents
(CVPR'97)
where and are weighting parameters that control the 2.2 Generalized Force Balance Equations
snake's tension and rigidity, respectively. x 0 (s) and x00 (s)
denote the first and second derivatives of x(s) with respect The external forces generated from the variational for-
to s. The external energy function E ext is derived from the mulation (1) must enter the force balance equation (6) as a
image so that it takes on its smaller values at the features of static irrotational field.1 To add additional flexibility to the
interest, such as boundaries. snake model, it is possible to start from the force balance
Given a gray-level image I (x y ) (viewed as a function equation directly, and to replace F 1ext with another force
of continuous position variables (x y )), typical external en- F2ext , which need not be irrotational, as follows
ergies designed to lead an active contour toward step edges
are [10]: Fint + F2ext = 0 (8)
xt (s t) = x 00
(s t) ; x 0000
(s t) ; rEext (7) with = 1:0 (pixels), for this example is depicted. Al-
though the field correctly points toward the object boundary,
When the solution x(s t) stabilizes, the term xt (s t) van- in the concave portion the forces point horizontally in oppo-
ishes and we achieve a solution of (6). This dynamic equa- site directions. Thus, the curve is “pulled” apart toward the
tion can also be viewed as a gradient descent algorithm [3] U-shape, but not made to progress downward into the con-
designed to solve (1). A solution to (7) can be found by cave region. The poor performance in this example lies in
discretizing the equation and solving the discrete system it- 1 An irrotational field is the gradient of a scalar field. Sometimes these
(10)
This variational formulation follows a standard principle,
that of making the result smooth when there is no data. In
particular, we see that when jrf j is small, the energy is
(c) (b) dominated by partial derivatives of the vector field, yield-
ing a smooth field. On the other hand, when jrf j is large,
Figure 1. A snake with traditional potential the second term dominates the integrand, and is minimized
forces cannot move into the concave bound- by setting v = rf . The parameter is a regularization
ary region. parameter governing the tradeoff between the first term and
the second term. This parameter should be set according
to the amount of noise present in the image (more noise,
increase ).
the problem formulation, not its method of solution. In the We note that the smoothing term — the first term within
following section, we introduce a new external force formu- the integrand of (10) — is the same term used by Horn and
lation which largely solves the problems discussed above. Schunk in their classical formulation of optical flow [9]. On
one hand, it is known that this term leads to the Laplacian
3 Gradient Vector Flow Field operator in the corresponding Euler equations. On the other
hand, it has recently been shown that this term corresponds
Our overall approach is to define a new non-irrotational to an equal penalty on the divergence and curl of the vec-
external force field, which we call the gradient vector flow tor field [8]. Therefore, the external field resulting from
(GVF) field. Using a force balance condition as a starting this minimization can be expected to be neither entirely ir-
point (rather than a variational formulation) we then let the rotational (as are the traditional snake potential fields) nor
GVF field replace the potential force field in (7), defining a entirely solenoidal.
new snake, which we call the GVF snake. The GVF field Using the calculus of variations [6], it can be shown that
points toward the object boundary when very near to the the GVF can be found by solving the following Euler equa-
boundary, but varies smoothly over homogeneous image re- tions
gions, extending to the image border. The main advantages
of the GVF field are that it can capture a snake from a long r2 u ; (u ; fx )(fx 2 + fy 2 ) = 0 (11a)
r v ; (v ; fy )(fx + fy )
2 2 2
range — from either side of the object boundary — and can = 0 (11b)
force it into concave regions.
where r2 is the Laplacian operator. These equations give us
3.1 Edge Map another intuition behind the GVF formulation. We note that
in homogeneous regions, the second term of both equations
We begin by defining an edge map f (x y ) derived from (11a) and (11b) is zero (because the gradient of f (x y ) is
the image I (x y ) having the property that it is larger near zero). Therefore, within these regions, u and v are each
the image edges2 . Accordingly, we can use determined by Laplace's equation. This results in a type of
“filling-in” of information taken from the boundaries of the
f (x y ) =
i (x y )
;Eext (9) region.
The field rf has vectors point-
Equations (11a) and (11b) can be solved by treating u
where i = 1, 2, 3, or 4.
and v as functions of time and solving
ing toward the edges, but it has a narrow capture range, in
general. Furthermore, in homogeneous regions, I (x y ) is
constant, rf is zero, and therefore no information about
ut (x y t) = r2 u(x y t) ; (u(x y t) ; fx(x y ))
yielding
xt (s t) = x
00
(s t) ; x0000
(s t) +v (13) in an analogous fashion when viewed from the inside. That
is, the vectors are pointing toward the boundary from as far
We call the parametric curve solving the above dynamic away as possible and are pointing upward into the concave
equation as a GVF snake. This equation is solved in sim- regions (the fingers of the U-shape) as viewed from the in-
ilar fashion to the traditional snake — i.e., by discretization side.
and iterative solution.
Fig. 2c shows the result of applying a GVF snake with
We note that in [18], we generalized GVF to three di-
parameters = 0:6 and = 0:0 to the line drawing shown
mensions and implemented a GVF deformable surface.
in Fig. 2a (using the external GVF field of Fig. 2b). In this
case, the snake was initialized farther away from the object
4 GVF Fields and GVF Snakes than the initialization in Fig. 1c, and yet it converges very
well to the boundary of the U-shape. It should be noted
This section shows several examples of GVF external that the blocky appearance of the U-shape results from the
field computations on simple objects as well as on one real fact that the image is only 64 64 pixels. The snake itself
medical image and demonstrates the performance of GVF moves through the continuum (using bilinear interpolation
snakes. The parameters (for GVF) and and (for the to derive external field forces which are not at grid points)
snake) are specified in each case. All the edge map func- to arrive at a sub-pixel interpolation of the boundary.
tions used for computing GVF are pre-normalized to the
range 0 1].
4.2 Streamlines of external force fields
4.1 Convergence to a Concave Region
In our first experiment, we computed the GVF field for It is interesting to compare the capture range between
the line drawing of Fig. 2a using = 0:2. Comparing the the traditional potential force fields and GVF fields by look-
resulting field, shown in Fig. 2b, to the potential force field ing at their streamlines. The streamlines are the paths over
of Fig. 1b, reveals several key differences. First, the GVF which a dense number of free particles move under the in-
field has a much larger capture range. It is clear that in order fluence of external forces when placed in the external force
to get this extent using traditional potential force fields, one field.
would have to use a large in the Gaussian filter. But this Fig. 3a gives the streamlines for the potential force field
would have the effect of blurring (or perhaps even obliterat- of Fig. 1b, and Fig. 3b gives the streamlines for the GVF
ing) the edges, which is not happening in the GVF field. field of Fig. 2b. Two effects are clear from this figure. First,
A second observation is that the GVF vectors are point- the capture range of GVF is clearly much larger than that
ing somewhat downward into the top of the U-shape, which of the potential forces. Second, GVF provides downward
should cause an active contour to move farther into this con- forces within the concave region at the top of the U-shape,
cave region. Finally, it is clear that the GVF field behaves while potential forces only provide sideways forces.
70 IEEE Proc. Conf. on Comp. Vis. Patt. Recog. (CVPR'97)
(a) (b)
(a) (b)
Figure 5. A GVF snake can also be initialized
Figure 3. Stream lines of particles in (a) a po-
across the object boundary.
tential force field and (b) a GVF field.
References