A Fast Algorithm for Variational Level Set Image Segmentation

advertisement

A Fast Algorithm for Variational Level Set Segmentation

Tony F. Chan

Department of Mathematics, Univ. Calif. Los Angeles

SONAD 2003

McMaster University, Ontario, Canada

May 2, 2003

Reprints: www.math.ucla.edu/~imagers

Supported by ONR and NSF

(Joint work with Bing Song)

OUTLINE

• Review of Variational Level Set Segmentation

• Fast Algorithm

What is an “active contour” ?

 giving an image u

0

:

  

 evolve a curve C to detect objects in u

0

the curve has to stop on the boundaries of the objects

Initial Curve Evolutions Detected Objects

A fitting term “without edges”

 inside (

|

C u

0

)

 c

1

| where

2 dxdy

  outside (

|

C u

0

)

 c

2

|

2 c c

2

1

 average ( u

0

) inside

 average ( u

0

) outside

C

C dxdy

Fit > 0 Fit > 0 Fit > 0 Fit ~ 0

Minimize: (Fitting +Regularization)

Fitting not depending on gradient detects “contours without gradient”

An active contour model “without edges”

(C. + Vese 98)

Fitting + Regularization terms (length, area) c

1

, inf c

2

, C

F ( c

1

, c

2

, C )

  

| C |

  

Area ( inside ( C ))

   inside ( C )

| u

0

 c

1

|

2 dxdy

  

|

)

0

 outside ( C u c

2

|

2 dxdy

C = boundary of an open and bounded domain

|C| = the length of the boundary-curve C

Advantages

- detects objects without sharp edges

- detects cognitive contours

- robust to noise; no need for pre-smoothing

Examples

C

Level Set Representation (S. Osher - J. Sethian ‘87)

( x , y ) |

( x , y )

0

 n

 

0

Outside C

 

0

Outside C

 

0

 n

C

0

 n

C = boundary of an open domain

Normal

 n

|

 

 

|

, Curvature K

 div



|

 

 

|



Example: mean curvature motion

* Allows automatic topology changes, cusps, merging and breaking.

•Originally developed for tracking fluid interfaces.

C

Variational Formulations and Level Sets

(Following Zhao, Chan, Merriman and Osher ’96)

( x , y )

 

:

( x , y )

0

The Heaviside function

H (

)

 

1

0 ,

, if if

0

0 u ( x , y )

 c

1

H (

( x , y ))

Length | C |

|

H (

) |

Area ( inside ( C ))

H (

) dxdy

 c

2

( 1

H (

( x , y )))

The level set formulation of the active contour model c

1 inf

, c

2

,

F ( c

1

, c

2

,

)

F ( c

1

, c

2

,

)

 

|

H (

) |

 

H (

) dxdy

 

| u

0

( x , y )

 c

1

|

2

H (

) dxdy

 

| u

0

( x , y )

 c

2

|

2

( 1

H (

)) dxdy

The Euler-Lagrange equations c

1 inf

, c

2 ,

F ( c

1

, c

2

,

) Using smooth approximations for the Heaviside and Delta functions c

1

Equations

(

)

 u

0

H

H

(

 for c

1

(

) dxdy

) dxdy

, c

2 and c

2

(

)

 

 u

0

( 1

( 1

H

H

(

(

))

)) dxdy dxdy

Equation for

  

( t , x , y )

 

 t

( 0 ,

 x ,

 y )

(

)

0

( x , div

 y )

|

 

 

|



   

( u

0

 c

1

)

2  

( u

0

 c

2

)

2

Evolution of C

Experimental Results

Averages ( c

1

, c

2

) Advantages

Automatically detects interior contours!

Works very well for concave objects

Robust w.r.t. noise

Detects blurred contours

The initial curve can be placed anywhere!

Allows for automatical change of topolgy

A plane in a noisy environment

A galaxy

From Active Contours (2D) to Active Surfaces (3D)

MRI DATA FROM

LONI-UCLA

Extension to Vector-Valued Images

Tony F. CHAN & Luminita VESE & B. Yezrielev SANDBERG

Applications

* Color images (RGB)

F

( c

1

,

 i

 c

1

* Multi-spectral (PET, MRI, CT)

Vector-Valued image:

 u

0

( u

0 , 1

, c

2 are constant v ectors

, u

0 , 2

,..., u

0 , N

), N channels

(averages of each channel inside

The model

 c

1 inf

, c

2

, C

F (

 c

1

,

 and outside the curve) c

2

, C )

 c

2

, C )

  

Length ( C )

  

Area ( inside ( C ))

  inside ( C )

| u

0 , i

 c

1 , i

|

2 dxdy

  outside (

| u

0 , i

C )

 c

2 , i

|

2

 dxdy

* The model can be solved using level sets, similar with the scalar case

Extension to Vector-Valued Images

Channel 1 with occlusion Channel 2 with noise

Recovered object and averages

Color Images

Color (RGB) picture Intensity (gray-level) picture

R G B

Recovered objects and contours in RGB mode

Active Contour for Texture

45 transforms of image with Gabor function

F

120 s.0075

q 0 p/6 p/4 p/3 p/2 s.005

F

120 q 0 p/6 p/4 p/3 p/2

150 150

180 180

F

120 s.0025

q 0 p/6 p/4 p/3 p/2

150

180

User Picked Gabor transforms yield final contour

Logic Operators on Multi-Channel Active Contour

(Chan, Sandberg 2001)

• An Example for two channel logical segmentation:

A

1

A

2

(a) A 

1

A

2

(b) A 

1

A

2

(c) A

1

 ~ A

2

A

1

Example of an Application

A

2

Original image with contour overlapping

Contour only

Time evolution for finding the “tumor” in the first image that is not in the second.

Multiphase level set representations and partitions allows for triple junctions, with no vacuum and no overlap of phases

 

(

1

,...,

 n

)

2 n phases

Curves

{

 

0 }

:

Curves

{

1

0 }

:

{

2

4-phase segmentation

0 }

2 level set functions

2-phase segmentation

1 level set function

 

0

 

0

 

1

2

0

0

 

1

2

0

0

 

1

2

0

0

 

1

2

0

0

Example: two level set functions and four phases

2 level set functions

1

0 ,

2

0 ,

1

(

1

,

2

0 ,

2

)

4 phases or segments

0 ,

1

0 ,

2

0 ,

1

 

(

1

,

2

) The level set functions c

( c

11

, c

10

, c

01

, c

00

) Constant vector

:

0 ,

2

0 u

 c

11

H (

1 c

01

( 1

) H (

2

)

H (

1

)) H

 c

10

H

(

2

)

(

1

)( 1

 c

00

( 1

H (

2

))

H (

1

))( 1

H (

2

))

Energy

Inf

( c ,

)

F ( c ,

)

| u

0

 c

01

| 2

| u

0

 c

11

|

2

H (

1

) H (

2

) dxdy

| u

0

( 1

H (

1

)) H (

2

) dxdy

| u

0

 c

00

| 2

 c

10

|

2

H (

1

)( 1

H (

2

)) dxdy

( 1

H (

1

))( 1

H (

2

)) dxdy

 

|

H (

1

) |

 

|

H (

2

) |

An MRI brain image

Phase 11 Phase 10 Phase 01 Phase 00 mean(11)=45 mean(10)=159 mean(01)=9 mean(00)=103

Three level set functions representing up to eight phases

Six phases are detected, together with the triple junctions.

Evolution of the 3 level sets

T

Segmented image

Evolution of the 3 individual level sets

.

OUTLINE

• Review of Variational Level Set Segmentation

• Fast Algorithm

A Fast Algorithm for Level Set

Based Optimization

(Bing Song and Tony Chan, 2003)

Available at www.math.ucla.edu/applied/cam/index.html

CAM 02-68

(Related work by Gibou & Fedkiw)

Motivation

• Minimize level set based functional min

F ( H (

))

• Examples:

– Image segmentation

– Inverse problem

– Shape analysis and optimization

– Data Clustering

– …

How to solve it?

• Usually use gradient descent flow

 t

 

F ( H (

))

• Drawback

– Slow (CFL)

F need to be differentiable

An Insight

• Segmentation only needs sign of but not its value

Direct search making use of objective function does not require derivatives of functional

New Algorithm

and  

0

2. Advance. For each point x in the domain, if the energy F lower when we change

3. Repeat step 2 until the energy F remains unchanged

An example: Chan-Vese model

F ( H (

), c

1

, c

2

)

 

(

|

H (

) |

 

1

| u

0

 

2

| u

0

 c

2

|

2

 c

1

|

2

( 1

H (

))

H (

)

Core Step of Algorithm

 

0

 

0

 

0

1

2

 c

1 c

2

 c

1 n

 u m c

2

1

 u

1

~

F

1

F

1

( u

 c

1

)

2 m m

1

~

F

2

F

2

( u

 c

2

)

2 n n

1

F

12

( u

 c

2

)

2 n n

1

( u

 c

1

)

2 m m

1

 change in length

How to calculate length term?

|

H (

 ij

) |

( H (

 i

1 , j

)

H (

 i , j

))

2 

( H (

 i , j

1

)

H (

 i

1 , j

))

2

Change in length term can be updated locally.

Only possible value for length term locally is 0, 1, sqrt(2) depending the 3 points in the length term belong to the same region or not.

A 2-phase example

(a), (b), (c), (d) are four different initial condition.

All of them converge in one sweep!

Example with Noise

Converged in 4 steps.

(Gradient Descent on Euler-Lagrange took > 400 steps.)

Convergence of the algorithm

Theorem : For a two phase image, the algorithm will converge in one sweep, independent of sweeping order.

Proof considers the following 2 cases:

Green part of inside of contour will flip sign.

Only one of the 2 black parts can change sign

 

0

 

0

 

0

 

0

Why is 1-step convergence possible?

• Problem is global: usually cannot have finite step convergence based on local updates only

• But, in our case, we can exactly calculate the global energy change via local update

(can update global average locally)

Application to piecewise linear CV model

(Vese 2002)

F ( H (

), c

1

, c

2

)

 

(

|

H (

) |

 

1

| u

0

 

2

| u

0

 b

0

 a

0

 b

1 x

 b

2 y |

2

 a

1 x

 a

2 y |

2

( 1

H (

))

H (

)

Original P.W.Constant

Converged in 4 steps

P.W. Linear

Converged in 6 steps

Application to multiphase CV model

(C.- Vese 2000)

• Using n level set to represent 2 n phases.

F n

( c ,

)

1

I

 

 n

2 m

| u

0

 c

I

|

2

I dxdy

1

I

 

 m

|

H (

 i

) |

Multiphase CV model (cont’d)

Converged in 1 step.

Gibou and Fedkiw’s method (02)

• First, discard the stiff length term in E-L: d

2 2   

1

( u

 c

1

)

 

2

( u

 c

2

) :

V ( x ) dt

• Take large time step enough to change sign

( x )

  sign (

( x ))

• Followed by anisotropic diffusion to handle noise

• Difference (Ours wrt GF):

– A unified framework to handle length term

– F does not need to be differentiable

Conclusion

• A fast algorithm to solve the Chan-Vese segmentation models.

• 1-step convergence for 2 phase images (no reg.).

• Robust wrt noise: 3-4 step convergence.

• The gradient of functional is not needed.

• We think it can be applied to more general level set based optimization problems.

• In general, cannot expect finite step convergence

(need global change from local update). Can get stuck in local minima.

That’s all.

Thank you for your patience!

Download