You are on page 1of 52

Image Segmentation using a Generalized Fast Marching

Method

Nicolas Forcadel (ENPC-CERMICS, Paris), Carole Le Guyader (INSA


Rennes), Christian Gout (INRIA, France)

Multivariate Approximation: Theory and Applications

April 26 - May 01, 2007

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Evolution of a front

c ∆ t n Γt
                        

                        

                        

                        

                        

                        

                        

                        

Ωt
                        

                        

                        

                        

                        

                        

Γt+ ∆t
                        

                        

                        

Γt
                        

dΓt
= c nΓt
dt

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Mathematical difficulty

How to define the evolution with change of topology?

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Mathematical difficulty

Change of topology = frightening

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Level set Method

Level set formulation:

Γt = {x, u(x, t) = 0}.

Formally :
∂Γt
u(Γt , t) = 0 ⇒ ut + ∇u · = 0.
∂t
∂Γt ∇u
with = c(x)~n, ~n = − .
∂t |∇u|
Level set equation for moving fronts:

ut = c(x)|∇u|.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Level set Method

Level set formulation:

Γt = {x, u(x, t) = 0}.

Formally :
∂Γt
u(Γt , t) = 0 ⇒ ut + ∇u · = 0.
∂t
∂Γt ∇u
with = c(x)~n, ~n = − .
∂t |∇u|
Level set equation for moving fronts:

ut = c(x)|∇u|.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Level set Method

Level set formulation:

Γt = {x, u(x, t) = 0}.

Formally :
∂Γt
u(Γt , t) = 0 ⇒ ut + ∇u · = 0.
∂t
∂Γt ∇u
with = c(x)~n, ~n = − .
∂t |∇u|
Level set equation for moving fronts:

ut = c(x)|∇u|.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Level set Method

Level set formulation:

Γt = {x, u(x, t) = 0}.

Formally :
∂Γt
u(Γt , t) = 0 ⇒ ut + ∇u · = 0.
∂t
∂Γt ∇u
with = c(x)~n, ~n = − .
∂t |∇u|
Level set equation for moving fronts:

ut = c(x)|∇u|.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Stationary approach
1
Setting u(x, t) = t − T (x) ⇒ |∇T (x)| = .
c(x)
T (x) = time when the front cross the point x.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Stationary approach
1
Setting u(x, t) = t − T (x) ⇒ |∇T (x)| = .
c(x)
T (x) = time when the front cross the point x.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Discretization

∆x
I
G D
∆x

B
max(TI − TG , TI − TD , 0)2  2
∆x
+ = (1)
cI
max(TI − TH , TI − TB , 0)2
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Processing the nodes in a special ordering, one can compute the


solution in just one iteration.
This special ordering corresponds to the increasing values of T
Idea : Compute the time only near the front.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Processing the nodes in a special ordering, one can compute the


solution in just one iteration.
This special ordering corresponds to the increasing values of T
Idea : Compute the time only near the front.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Processing the nodes in a special ordering, one can compute the


solution in just one iteration.
This special ordering corresponds to the increasing values of T
Idea : Compute the time only near the front.
Far

Accepted
Narrow Band
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Far

Accepted
Narrow Band
Computation of TI on NB
Call tn the minimal time TI on the NB
and accept at the time tn the minimizing points I
The new NB is defined as the boundary of the new accepted region
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Far

Accepted
Narrow Band
Computation of TI on NB
Call tn the minimal time TI on the NB
and accept at the time tn the minimizing points I
The new NB is defined as the boundary of the new accepted region
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Far

Accepted
Narrow Band
Computation of TI on NB
Call tn the minimal time TI on the NB
and accept at the time tn the minimizing points I
The new NB is defined as the boundary of the new accepted region
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Far

Accepted
Narrow Band
Computation of TI on NB
Call tn the minimal time TI on the NB
and accept at the time tn the minimizing points I
The new NB is defined as the boundary of the new accepted region
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Far

Accepted
Narrow Band
Computation of TI on NB
Call tn the minimal time TI on the NB
and accept at the time tn the minimizing points I
The new NB is defined as the boundary of the new accepted region
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Introduction of the Narrow Band

Far

Accepted
Narrow Band
Computation of TI on NB
Call tn the minimal time TI on the NB
and accept at the time tn the minimizing points I
The new NB is defined as the boundary of the new accepted region
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

References

[Sethian]: http://math.berkeley.edu/∼sethian/
[Vladimirsky] : case c = c(x, t) > 0
[Cristiani, Falcone] : Proof of convergence

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Dependence in time of the velocity

The time is given implicitly by the algorithm!

tn = min TI
I∈N B

Two difficulties:
tn cans be smaller than tn−1 :

tn := tn−1

tn can be very large:

⇒ Introduction of a time step ∆t :

if tn ≥ tn−1 + ∆t ⇒ tn := tn−1 + ∆t

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Dependence in time of the velocity

The time is given implicitly by the algorithm!

tn = min TI
I∈N B

Two difficulties:
tn cans be smaller than tn−1 :

tn := tn−1

tn can be very large:

⇒ Introduction of a time step ∆t :

if tn ≥ tn−1 + ∆t ⇒ tn := tn−1 + ∆t

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Dependence in time of the velocity

The time is given implicitly by the algorithm!

tn = min TI
I∈N B

Two difficulties:
tn cans be smaller than tn−1 :

tn := tn−1

tn can be very large:

⇒ Introduction of a time step ∆t :

if tn ≥ tn−1 + ∆t ⇒ tn := tn−1 + ∆t

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Dependence in time of the velocity

The time is given implicitly by the algorithm!

tn = min TI
I∈N B

Two difficulties:
tn cans be smaller than tn−1 :

tn := tn−1

tn can be very large:

⇒ Introduction of a time step ∆t :

if tn ≥ tn−1 + ∆t ⇒ tn := tn−1 + ∆t

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Change of the sign of the velocity


c=0
c>0 c<0

θ = −1

θ=1

Narrow Band

Introduction of a field θIn ∈ {−1, 1}


Regularisation of the velocity in space
Double Narrow band
The time is defined in each side of the front
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Change of the sign of the velocity


c=0
c>0 c<0

θ = −1

θ=1

Narrow Band

Introduction of a field θIn ∈ {−1, 1}


Regularisation of the velocity in space
Double Narrow band
The time is defined in each side of the front
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Change of the sign of the velocity


c=0
c>0 c<0

θ = −1

θ=1

Narrow Band

Introduction of a field θIn ∈ {−1, 1}


Regularisation of the velocity in space
Double Narrow band
The time is defined in each side of the front
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Change of the sign of the velocity


c=0
c>0 c<0

θ = −1

θ=1

Narrow Band

Introduction of a field θIn ∈ {−1, 1}


Regularisation of the velocity in space
Double Narrow band
The time is defined in each side of the front
N. Forcadel C. Le Guyader, C. Gout Image Segmentation
Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Exemple

c=0 c=0
c>0 c<0 c>0 c<0

θ = −1 θ = −1

θ=1 θ=1

Narrow Band Accepted Points

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Reference

1 E. Carlini, M. Falcone, N. Forcadel, R. Monneau, Convergence of a


Generalized Fast Marching Method for a non-convex eikonal equation
(submitted, http://cermics.enpc.fr/ forcadel/publications.html).
2 E. Carlini, E. Cristiani, N. Forcadel, A non-monotone Fast Marching
scheme for a Hamilton-Jacobi equation modeling dislocation dynamics,
ENUMATH 2005.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

A straight line

c(x, t) = x1

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

A circle

c(x, t) = −x1

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Two circles

c(x, t) = 1 − t

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Image Segmentation with classical FMM

Given an image I, define the velocity as

c(x) = g(|∇I(x)|)

where g is an edge-detector function satisfying


g : [0, +∞[→ [0, +∞[, g(0) = 1, g strictly decreasing and
limr→∞ g(r) = 0.
Very efficient method
But problem of the sign of the velocity implies constaints on initial data.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Image Segmentation with classical FMM

Given an image I, define the velocity as

c(x) = g(|∇I(x)|)

where g is an edge-detector function satisfying


g : [0, +∞[→ [0, +∞[, g(0) = 1, g strictly decreasing and
limr→∞ g(r) = 0.
Very efficient method
But problem of the sign of the velocity implies constaints on initial data.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Image Segmentation with classical FMM

Given an image I, define the velocity as

c(x) = g(|∇I(x)|)

where g is an edge-detector function satisfying


g : [0, +∞[→ [0, +∞[, g(0) = 1, g strictly decreasing and
limr→∞ g(r) = 0.
Very efficient method
But problem of the sign of the velocity implies constaints on initial data.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Image Segmentation with generalized FMM

The gradient field of −∇g(|∇(I)|) give the direction of the edges:

The vectors point towards the middle of the boundaries.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Image Segmentation with generalized FMM

The gradient field of −∇g(|∇(I)|) give the direction of the edges:

The vectors point towards the middle of the boundaries.

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Image Segmentation with generalized FMM

Define the velocity as


 
R ||r−x||2
Q(x) h−∇g(|∇I(r)|), ~
n (x, t)i exp − 2σ 2
dr
c(x, t) = g(|∇I(x)|) R  
||r−x||2
Q(x) h−∇g(|∇I(r)|), ~n(x, t)i exp − 2σ2 dr

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Plan

1 Fast Marching Method

2 Generalized Fast Marching Method

3 Image segmentation

4 Numerical results

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Geophysics data

20 20

40 40

60 60

80 80

100 100

120 120

140 140
−20 0 20 40 60 80 100 120 140 −20 0 20 40 60 80 100 120 140

Figure: Initial data Figure: Final result

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Medical data

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

Medical data

20 20

40 40

60 60

80 80

100 100

120 120

140 140

−20 0 20 40 60 80 100 120 140 160 −20 0 20 40 60 80 100 120 140 160

Figure: Initial data Figure: Final result

N. Forcadel C. Le Guyader, C. Gout Image Segmentation


Fast Marching Method
Generalized Fast Marching
Image segmentation
Numerical results

From the initial condition to the final result

N. Forcadel C. Le Guyader, C. Gout Image Segmentation

You might also like