SlideShare a Scribd company logo
Electrical &Computer
Engineering Department

University of Houston

Snakes in Images
Yan Xu

Bio-Image Analytics Laboratory
How snake works in images

http://www.iacl.ece.jhu.edu/~chenyang/research/levset/movie/index.html
How snake works in images
 Step 1: Model the shape by curve or surface
 Step 2: Define the energy function E along the curve
E = internal energy (curvature) + external energy (images)
 Step 3: Derive the curve to minimize the energy (calculus
of variations)
 Step 4: Propagate the curves (gradient descent) to reach
the minimum using level set (easier to implement in reality).

Keywords:
Curve

Energy

Level set
Snake -> Curves
Consider a closed planar curve C ( p) {x( p), y( p)}, p [0,1]
C(0.1)

S(p) is the arclength

C(0.2)

C(0.7)
C(0)

C(0.4)
C(0.95)

Cp =tangent
C(0.8)

Css

| Cp |

Css

N

N
1

C(0.9)

Cs

Cp

C

The geometric trace of the curve can be alternatively
represented implicitly as C {( x, y ) | ( x, y ) 0}
1
0
0

1
Properties of level sets

T

The level set normal

N

|


N

|

Proof. Along the level sets (equal 0) we have zero change,
that is s 0 , but by the chain rule
So,

s

|

( x, y )

|


,T

x

0

xs

|

y

|


,T

ys

T


N

|

|
Properties of Level Sets
The level set curvature
Css =div

|

|

Proof. zero change along the level sets,
ss

So,

( x, y )

d
( x xs
ds
,

|

|

y

|

ys )
|

[


,T

d
ds
x

xx s

xy

ys ,

ss


,T

d
ds
x

xy s

yy

ys ],

|

0 , also


, N

|

Numerical Geometry of Images:
http://webcourse.cs.technion.ac.il/236861/Winter2012-2013/en/ho_Tutorials.html
Constant Flow

Ct



N

Propagation of Curves

Change in topology

Curvature Flow

Ct

Grayson



N
Vanish at a
Circular
point

First becomes
convex

Gage-Hamilton
Curve propagation in Level Sets
dC
dt



VN

C(t)

d
dt

y

V

x

x, y, t

( x, y; t )
t

0

t


N

x

xt

y

yt

x xt

|

t

C(t) level set


, VN

, Ct

V

|

y

y yt


,N


,N

V

V

0

,

|

x

|

V|

|
Curve propagation in Level Sets
 Handles changes in topology
 Numeric grid points never collide
or drift apart.

Parametric Curve -> Level set in plane -> add time axis for propagation
Curve propagation in Level Sets
Some flows

Ct


VN

Ct


N

Ct

g

t

t

 
g, N N

V
2
xx y

div

t

2

xy x y
2
2
x
y

2
yy x

div g
g

2
xx y

2

xy x y
2
2
x
y

2
yy x

g,
Snake Model
1

arg min
C

Cp
0

2

C pp

tension

2

rigidity

2 g (C ) dp
external energy from the image

Energy

g (C )

|

[G (C ) * I (C )] |2

A snake that minimize E must satisfy the Euler equation

Cpp

Cpppp

g C

0

To find a solution

dC
dt

C pp

C pppp

g C

When C stabilizes and the term Ct vanishes, a solution is achieved.
Snakes: Active Contour Models, 1988
Geodesic Active Contour
arg min
C

L C
0

g C ds

ds is the Euclidean arc-length.

Trying to find minimum weighted distance

I(x)

Euler Lagrange gradient descent

Ct


g (C) n

 
g (C), n n

x
g(x)

d
dt

div g x, y

Geodesic Active Contours, 1997

x
GVF Snakes
Replace the external force with gradient vector flow (GVF) force v.

dC
dt

C pp

C pppp

g C

V(x,y) = [u(x,y),v(x,y)]
Why?
f generally have large magnitudes only in the vicinity of the edges, the
capture range would be small.
It’s nearly zero in homogeneous regions.
V(x,y) = [u(x,y), v(x,y)] is defined as the vector field that minimizes
the energy functional:

http://www.iacl.ece.jhu.edu/static/gvf/
GVF Snake Results
Original Snake Model

2d GVF vector field

GVF Snake Model
itk Implementation for
GVF Geodesic Active Contour
Original Image

Gradient Magnitude

Gradient

Initial Contour

Sigmoid
Rescaling

Geodesic
Active
Contour

Gradient
Vector Flow
Thresholding

Insight Segmentation and Registration Toolkit (ITK)
itk Implementation for
GVF Geodesic Active Contour
gvfFilter->Update();
GeoAC->SetInput(initialContour->GetOutput());
GeoAC->SetAutoGenerateSpeedAdvection(false);
GeoAC->SetFeatureImage(sigmoid->GetOutput());
GeoAC->GenerateSpeedImage();
GeoAC->SetAdvectionImage(gvfFilter->GetOutput());
Recommended:
Numerical Geometry of Images:
http://webcourse.cs.technion.ac.il/236861/Winter2012-2013/en/ho_Tutorials.html
Calculus of Variations
Generalization of Calculus that seeks to find the
path, curve, surface, etc., for which a given Functional has
a minimum or maximum.
Goal: find extrema values of integrals of the form

F (u, u x )dx
It has an extremum only if the Euler-Lagrange
Differential Equation is satisfied,

u

d
F ( u, u x )
dx u x

0
Calculus of Variations
Example: Find the shape of the curve {x,y(x)} with
shortest length:
x1
y ( x1 )
2
1 y x dx ,
y ( x0 )
x0
given y(x0),y(x1)

x0
Solution: a differential equation that y(x) must
satisfy,
y xx
0
yx a
y ( x ) ax b
3/ 2
2
1 yx

x1

More Related Content

What's hot

Morphological Image Processing
Morphological Image ProcessingMorphological Image Processing
Morphological Image Processing
kumari36
 
Scale Invariant feature transform
Scale Invariant feature transformScale Invariant feature transform
Scale Invariant feature transform
Shanker Naik
 
Introduction to digital image processing
Introduction to digital image processingIntroduction to digital image processing
Introduction to digital image processing
Hossain Md Shakhawat
 
Morphological operations
Morphological operationsMorphological operations
Image processing fundamentals
Image processing fundamentalsImage processing fundamentals
Image processing fundamentals
A B Shinde
 
Back propagation
Back propagationBack propagation
Back propagation
Nagarajan
 
Chapter 9 morphological image processing
Chapter 9   morphological image processingChapter 9   morphological image processing
Chapter 9 morphological image processing
Ahmed Daoud
 
Dda algorithm
Dda algorithmDda algorithm
Dda algorithm
Mani Kanth
 
Morphological image processing
Morphological image processingMorphological image processing
Morphological image processing
Raghu Kumar
 
3d transformation computer graphics
3d transformation computer graphics 3d transformation computer graphics
3d transformation computer graphics
University of Potsdam
 
Digital Image Processing
Digital Image ProcessingDigital Image Processing
Digital Image Processing
Sahil Biswas
 
2.2 decision tree
2.2 decision tree2.2 decision tree
2.2 decision tree
Krish_ver2
 
Image processing
Image processingImage processing
Image processingabuamo
 
Digital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationDigital Image Processing: Image Segmentation
Digital Image Processing: Image Segmentation
Mostafa G. M. Mostafa
 
Digital Image Processing - Image Restoration
Digital Image Processing - Image RestorationDigital Image Processing - Image Restoration
Digital Image Processing - Image Restoration
Mathankumar S
 
Digital image processing ppt
Digital image processing pptDigital image processing ppt
Digital image processing ppt
khanam22
 
Fundamentals steps in Digital Image processing
Fundamentals steps in Digital Image processingFundamentals steps in Digital Image processing
Fundamentals steps in Digital Image processing
KarthicaMarasamy
 
Unsupervised learning
Unsupervised learningUnsupervised learning
Unsupervised learning
amalalhait
 
Introduction to image contrast and enhancement method
Introduction to image contrast and enhancement methodIntroduction to image contrast and enhancement method
Introduction to image contrast and enhancement method
Abhishekvb
 

What's hot (20)

Morphological Image Processing
Morphological Image ProcessingMorphological Image Processing
Morphological Image Processing
 
Scale Invariant feature transform
Scale Invariant feature transformScale Invariant feature transform
Scale Invariant feature transform
 
Introduction to digital image processing
Introduction to digital image processingIntroduction to digital image processing
Introduction to digital image processing
 
Vgg
VggVgg
Vgg
 
Morphological operations
Morphological operationsMorphological operations
Morphological operations
 
Image processing fundamentals
Image processing fundamentalsImage processing fundamentals
Image processing fundamentals
 
Back propagation
Back propagationBack propagation
Back propagation
 
Chapter 9 morphological image processing
Chapter 9   morphological image processingChapter 9   morphological image processing
Chapter 9 morphological image processing
 
Dda algorithm
Dda algorithmDda algorithm
Dda algorithm
 
Morphological image processing
Morphological image processingMorphological image processing
Morphological image processing
 
3d transformation computer graphics
3d transformation computer graphics 3d transformation computer graphics
3d transformation computer graphics
 
Digital Image Processing
Digital Image ProcessingDigital Image Processing
Digital Image Processing
 
2.2 decision tree
2.2 decision tree2.2 decision tree
2.2 decision tree
 
Image processing
Image processingImage processing
Image processing
 
Digital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationDigital Image Processing: Image Segmentation
Digital Image Processing: Image Segmentation
 
Digital Image Processing - Image Restoration
Digital Image Processing - Image RestorationDigital Image Processing - Image Restoration
Digital Image Processing - Image Restoration
 
Digital image processing ppt
Digital image processing pptDigital image processing ppt
Digital image processing ppt
 
Fundamentals steps in Digital Image processing
Fundamentals steps in Digital Image processingFundamentals steps in Digital Image processing
Fundamentals steps in Digital Image processing
 
Unsupervised learning
Unsupervised learningUnsupervised learning
Unsupervised learning
 
Introduction to image contrast and enhancement method
Introduction to image contrast and enhancement methodIntroduction to image contrast and enhancement method
Introduction to image contrast and enhancement method
 

Viewers also liked

IMAGE SEGMENTATION.
IMAGE SEGMENTATION.IMAGE SEGMENTATION.
IMAGE SEGMENTATION.
Tawose Olamide Timothy
 
Mesh Processing Course : Active Contours
Mesh Processing Course : Active ContoursMesh Processing Course : Active Contours
Mesh Processing Course : Active Contours
Gabriel Peyré
 
CVIM mean shift-3
CVIM mean shift-3CVIM mean shift-3
CVIM mean shift-3
正志 坪坂
 
Image Segmentation
Image SegmentationImage Segmentation
Image Segmentationashek1520
 
Meanshift Tracking Presentation
Meanshift Tracking PresentationMeanshift Tracking Presentation
Meanshift Tracking Presentationsandtouch
 
Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...
Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...
Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...Habibur Rahman
 
various methods for image segmentation
various methods for image segmentationvarious methods for image segmentation
various methods for image segmentationRaveesh Methi
 
Image Processing Using MATLAB
Image Processing Using MATLABImage Processing Using MATLAB
Image Processing Using MATLAB
Amarjeetsingh Thakur
 
A version of watershed algorithm for color image segmentation
A version of watershed algorithm for color image segmentationA version of watershed algorithm for color image segmentation
A version of watershed algorithm for color image segmentation
Habibur Rahman
 
36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...
36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...
36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...Avinash Nandakumar
 
Image segmentation
Image segmentationImage segmentation
Image segmentation
khyati gupta
 
Microscopic Digital Image Segmentation And feature Extraction of Acute Leukemia
Microscopic Digital Image Segmentation And feature Extraction of Acute LeukemiaMicroscopic Digital Image Segmentation And feature Extraction of Acute Leukemia
Microscopic Digital Image Segmentation And feature Extraction of Acute Leukemia
Editor IJCATR
 
Water conservation
Water conservationWater conservation
Water conservation
Aswin Shenoy
 
Evaluation question 6..
Evaluation question 6..Evaluation question 6..
Evaluation question 6..Georgii_Kelly
 
What’s New in iOS 8 SDK ?
What’s New in iOS 8 SDK ?What’s New in iOS 8 SDK ?
What’s New in iOS 8 SDK ?
E2LOGY
 

Viewers also liked (20)

Dip Image Segmentation
Dip Image SegmentationDip Image Segmentation
Dip Image Segmentation
 
IMAGE SEGMENTATION.
IMAGE SEGMENTATION.IMAGE SEGMENTATION.
IMAGE SEGMENTATION.
 
Mesh Processing Course : Active Contours
Mesh Processing Course : Active ContoursMesh Processing Course : Active Contours
Mesh Processing Course : Active Contours
 
CVIM mean shift-3
CVIM mean shift-3CVIM mean shift-3
CVIM mean shift-3
 
Chapter1 4.6
Chapter1 4.6Chapter1 4.6
Chapter1 4.6
 
Image Segmentation
Image SegmentationImage Segmentation
Image Segmentation
 
Meanshift Tracking Presentation
Meanshift Tracking PresentationMeanshift Tracking Presentation
Meanshift Tracking Presentation
 
Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...
Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...
Segmentation of Color Image using Adaptive Thresholding and Masking with Wate...
 
various methods for image segmentation
various methods for image segmentationvarious methods for image segmentation
various methods for image segmentation
 
Image Processing Using MATLAB
Image Processing Using MATLABImage Processing Using MATLAB
Image Processing Using MATLAB
 
A version of watershed algorithm for color image segmentation
A version of watershed algorithm for color image segmentationA version of watershed algorithm for color image segmentation
A version of watershed algorithm for color image segmentation
 
36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...
36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...
36324442 biosignal-and-bio-medical-image-processing-matlab-based-applications...
 
Image segmentation
Image segmentationImage segmentation
Image segmentation
 
Microscopic Digital Image Segmentation And feature Extraction of Acute Leukemia
Microscopic Digital Image Segmentation And feature Extraction of Acute LeukemiaMicroscopic Digital Image Segmentation And feature Extraction of Acute Leukemia
Microscopic Digital Image Segmentation And feature Extraction of Acute Leukemia
 
Water conservation
Water conservationWater conservation
Water conservation
 
Unidad 5.
Unidad 5.Unidad 5.
Unidad 5.
 
โทรศัพท์และสัญญาณ
โทรศัพท์และสัญญาณโทรศัพท์และสัญญาณ
โทรศัพท์และสัญญาณ
 
Evaluation question 6..
Evaluation question 6..Evaluation question 6..
Evaluation question 6..
 
Soldar.
Soldar.Soldar.
Soldar.
 
What’s New in iOS 8 SDK ?
What’s New in iOS 8 SDK ?What’s New in iOS 8 SDK ?
What’s New in iOS 8 SDK ?
 

Similar to Snakes in Images (Active contour tutorial)

On approximating the Riemannian 1-center
On approximating the Riemannian 1-centerOn approximating the Riemannian 1-center
On approximating the Riemannian 1-center
Frank Nielsen
 
ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...
ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...
ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...
sipij
 
Adaptive Restore algorithm & importance Monte Carlo
Adaptive Restore algorithm & importance Monte CarloAdaptive Restore algorithm & importance Monte Carlo
Adaptive Restore algorithm & importance Monte Carlo
Christian Robert
 
sublabel accurate convex relaxation of vectorial multilabel energies
sublabel accurate convex relaxation of vectorial multilabel energiessublabel accurate convex relaxation of vectorial multilabel energies
sublabel accurate convex relaxation of vectorial multilabel energies
Fujimoto Keisuke
 
TAO Fayan_X-Ray and MIP volume rendering
TAO Fayan_X-Ray and MIP volume renderingTAO Fayan_X-Ray and MIP volume rendering
TAO Fayan_X-Ray and MIP volume renderingFayan TAO
 
Iterative methods with special structures
Iterative methods with special structuresIterative methods with special structures
Iterative methods with special structures
David Gleich
 
Fast Object Recognition from 3D Depth Data with Extreme Learning Machine
Fast Object Recognition from 3D Depth Data with Extreme Learning MachineFast Object Recognition from 3D Depth Data with Extreme Learning Machine
Fast Object Recognition from 3D Depth Data with Extreme Learning Machine
Soma Boubou
 
Divergence clustering
Divergence clusteringDivergence clustering
Divergence clustering
Frank Nielsen
 
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docxSAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
anhlodge
 
QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...
QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...
QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...
The Statistical and Applied Mathematical Sciences Institute
 
How to design a linear control system
How to design a linear control systemHow to design a linear control system
How to design a linear control system
Alireza Mirzaei
 
Computing the masses of hyperons and charmed baryons from Lattice QCD
Computing the masses of hyperons and charmed baryons from Lattice QCDComputing the masses of hyperons and charmed baryons from Lattice QCD
Computing the masses of hyperons and charmed baryons from Lattice QCD
Christos Kallidonis
 
ABC-Gibbs
ABC-GibbsABC-Gibbs
ABC-Gibbs
Christian Robert
 
Trilinear embedding for divergence-form operators
Trilinear embedding for divergence-form operatorsTrilinear embedding for divergence-form operators
Trilinear embedding for divergence-form operators
VjekoslavKovac1
 
Ch06 ssm
Ch06 ssmCh06 ssm
Ch06 ssm
Marta Díaz
 
Capitulo 4, 7ma edición
Capitulo 4, 7ma ediciónCapitulo 4, 7ma edición
Capitulo 4, 7ma edición
Sohar Carr
 
QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...
QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...
QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...
The Statistical and Applied Mathematical Sciences Institute
 
Skewed plate problem
Skewed plate problemSkewed plate problem
Skewed plate problem
SONAM PALJOR
 

Similar to Snakes in Images (Active contour tutorial) (20)

On approximating the Riemannian 1-center
On approximating the Riemannian 1-centerOn approximating the Riemannian 1-center
On approximating the Riemannian 1-center
 
ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...
ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...
ALEXANDER FRACTIONAL INTEGRAL FILTERING OF WAVELET COEFFICIENTS FOR IMAGE DEN...
 
Adaptive Restore algorithm & importance Monte Carlo
Adaptive Restore algorithm & importance Monte CarloAdaptive Restore algorithm & importance Monte Carlo
Adaptive Restore algorithm & importance Monte Carlo
 
sublabel accurate convex relaxation of vectorial multilabel energies
sublabel accurate convex relaxation of vectorial multilabel energiessublabel accurate convex relaxation of vectorial multilabel energies
sublabel accurate convex relaxation of vectorial multilabel energies
 
TAO Fayan_X-Ray and MIP volume rendering
TAO Fayan_X-Ray and MIP volume renderingTAO Fayan_X-Ray and MIP volume rendering
TAO Fayan_X-Ray and MIP volume rendering
 
Iterative methods with special structures
Iterative methods with special structuresIterative methods with special structures
Iterative methods with special structures
 
Fast Object Recognition from 3D Depth Data with Extreme Learning Machine
Fast Object Recognition from 3D Depth Data with Extreme Learning MachineFast Object Recognition from 3D Depth Data with Extreme Learning Machine
Fast Object Recognition from 3D Depth Data with Extreme Learning Machine
 
Divergence clustering
Divergence clusteringDivergence clustering
Divergence clustering
 
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docxSAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
 
QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...
QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...
QMC: Transition Workshop - Applying Quasi-Monte Carlo Methods to a Stochastic...
 
Fir 05 dynamics
Fir 05 dynamicsFir 05 dynamics
Fir 05 dynamics
 
cswiercz-general-presentation
cswiercz-general-presentationcswiercz-general-presentation
cswiercz-general-presentation
 
How to design a linear control system
How to design a linear control systemHow to design a linear control system
How to design a linear control system
 
Computing the masses of hyperons and charmed baryons from Lattice QCD
Computing the masses of hyperons and charmed baryons from Lattice QCDComputing the masses of hyperons and charmed baryons from Lattice QCD
Computing the masses of hyperons and charmed baryons from Lattice QCD
 
ABC-Gibbs
ABC-GibbsABC-Gibbs
ABC-Gibbs
 
Trilinear embedding for divergence-form operators
Trilinear embedding for divergence-form operatorsTrilinear embedding for divergence-form operators
Trilinear embedding for divergence-form operators
 
Ch06 ssm
Ch06 ssmCh06 ssm
Ch06 ssm
 
Capitulo 4, 7ma edición
Capitulo 4, 7ma ediciónCapitulo 4, 7ma edición
Capitulo 4, 7ma edición
 
QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...
QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...
QMC: Transition Workshop - Density Estimation by Randomized Quasi-Monte Carlo...
 
Skewed plate problem
Skewed plate problemSkewed plate problem
Skewed plate problem
 

More from Yan Xu

Kaggle winning solutions: Retail Sales Forecasting
Kaggle winning solutions: Retail Sales ForecastingKaggle winning solutions: Retail Sales Forecasting
Kaggle winning solutions: Retail Sales Forecasting
Yan Xu
 
Basics of Dynamic programming
Basics of Dynamic programming Basics of Dynamic programming
Basics of Dynamic programming
Yan Xu
 
Walking through Tensorflow 2.0
Walking through Tensorflow 2.0Walking through Tensorflow 2.0
Walking through Tensorflow 2.0
Yan Xu
 
Practical contextual bandits for business
Practical contextual bandits for businessPractical contextual bandits for business
Practical contextual bandits for business
Yan Xu
 
Introduction to Multi-armed Bandits
Introduction to Multi-armed BanditsIntroduction to Multi-armed Bandits
Introduction to Multi-armed Bandits
Yan Xu
 
A Data-Driven Question Generation Model for Educational Content - by Jack Wang
A Data-Driven Question Generation Model for Educational Content - by Jack WangA Data-Driven Question Generation Model for Educational Content - by Jack Wang
A Data-Driven Question Generation Model for Educational Content - by Jack Wang
Yan Xu
 
Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...
Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...
Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...
Yan Xu
 
Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...
Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...
Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...
Yan Xu
 
Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...
Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...
Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...
Yan Xu
 
Introduction to Autoencoders
Introduction to AutoencodersIntroduction to Autoencoders
Introduction to Autoencoders
Yan Xu
 
State of enterprise data science
State of enterprise data scienceState of enterprise data science
State of enterprise data science
Yan Xu
 
Long Short Term Memory
Long Short Term MemoryLong Short Term Memory
Long Short Term Memory
Yan Xu
 
Deep Feed Forward Neural Networks and Regularization
Deep Feed Forward Neural Networks and RegularizationDeep Feed Forward Neural Networks and Regularization
Deep Feed Forward Neural Networks and Regularization
Yan Xu
 
Linear algebra and probability (Deep Learning chapter 2&3)
Linear algebra and probability (Deep Learning chapter 2&3)Linear algebra and probability (Deep Learning chapter 2&3)
Linear algebra and probability (Deep Learning chapter 2&3)
Yan Xu
 
HML: Historical View and Trends of Deep Learning
HML: Historical View and Trends of Deep LearningHML: Historical View and Trends of Deep Learning
HML: Historical View and Trends of Deep Learning
Yan Xu
 
Secrets behind AlphaGo
Secrets behind AlphaGoSecrets behind AlphaGo
Secrets behind AlphaGo
Yan Xu
 
Optimization in Deep Learning
Optimization in Deep LearningOptimization in Deep Learning
Optimization in Deep Learning
Yan Xu
 
Introduction to Recurrent Neural Network
Introduction to Recurrent Neural NetworkIntroduction to Recurrent Neural Network
Introduction to Recurrent Neural Network
Yan Xu
 
Convolutional neural network
Convolutional neural network Convolutional neural network
Convolutional neural network
Yan Xu
 
Introduction to Neural Network
Introduction to Neural NetworkIntroduction to Neural Network
Introduction to Neural Network
Yan Xu
 

More from Yan Xu (20)

Kaggle winning solutions: Retail Sales Forecasting
Kaggle winning solutions: Retail Sales ForecastingKaggle winning solutions: Retail Sales Forecasting
Kaggle winning solutions: Retail Sales Forecasting
 
Basics of Dynamic programming
Basics of Dynamic programming Basics of Dynamic programming
Basics of Dynamic programming
 
Walking through Tensorflow 2.0
Walking through Tensorflow 2.0Walking through Tensorflow 2.0
Walking through Tensorflow 2.0
 
Practical contextual bandits for business
Practical contextual bandits for businessPractical contextual bandits for business
Practical contextual bandits for business
 
Introduction to Multi-armed Bandits
Introduction to Multi-armed BanditsIntroduction to Multi-armed Bandits
Introduction to Multi-armed Bandits
 
A Data-Driven Question Generation Model for Educational Content - by Jack Wang
A Data-Driven Question Generation Model for Educational Content - by Jack WangA Data-Driven Question Generation Model for Educational Content - by Jack Wang
A Data-Driven Question Generation Model for Educational Content - by Jack Wang
 
Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...
Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...
Deep Learning Approach in Characterizing Salt Body on Seismic Images - by Zhe...
 
Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...
Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...
Deep Hierarchical Profiling & Pattern Discovery: Application to Whole Brain R...
 
Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...
Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...
Detecting anomalies on rotating equipment using Deep Stacked Autoencoders - b...
 
Introduction to Autoencoders
Introduction to AutoencodersIntroduction to Autoencoders
Introduction to Autoencoders
 
State of enterprise data science
State of enterprise data scienceState of enterprise data science
State of enterprise data science
 
Long Short Term Memory
Long Short Term MemoryLong Short Term Memory
Long Short Term Memory
 
Deep Feed Forward Neural Networks and Regularization
Deep Feed Forward Neural Networks and RegularizationDeep Feed Forward Neural Networks and Regularization
Deep Feed Forward Neural Networks and Regularization
 
Linear algebra and probability (Deep Learning chapter 2&3)
Linear algebra and probability (Deep Learning chapter 2&3)Linear algebra and probability (Deep Learning chapter 2&3)
Linear algebra and probability (Deep Learning chapter 2&3)
 
HML: Historical View and Trends of Deep Learning
HML: Historical View and Trends of Deep LearningHML: Historical View and Trends of Deep Learning
HML: Historical View and Trends of Deep Learning
 
Secrets behind AlphaGo
Secrets behind AlphaGoSecrets behind AlphaGo
Secrets behind AlphaGo
 
Optimization in Deep Learning
Optimization in Deep LearningOptimization in Deep Learning
Optimization in Deep Learning
 
Introduction to Recurrent Neural Network
Introduction to Recurrent Neural NetworkIntroduction to Recurrent Neural Network
Introduction to Recurrent Neural Network
 
Convolutional neural network
Convolutional neural network Convolutional neural network
Convolutional neural network
 
Introduction to Neural Network
Introduction to Neural NetworkIntroduction to Neural Network
Introduction to Neural Network
 

Recently uploaded

UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Nexer Digital
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)
Ralf Eggert
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..
UiPathCommunity
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
Sri Ambati
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
UiPathCommunity
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
Adtran
 
Enhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZEnhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZ
Globus
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex Proofs
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex ProofszkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex Proofs
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex Proofs
Alex Pruden
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
Peter Spielvogel
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Aggregage
 

Recently uploaded (20)

UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..UiPath Community Day Dubai: AI at Work..
UiPath Community Day Dubai: AI at Work..
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
 
Enhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZEnhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZ
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex Proofs
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex ProofszkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex Proofs
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex Proofs
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
 

Snakes in Images (Active contour tutorial)

  • 1. Electrical &Computer Engineering Department University of Houston Snakes in Images Yan Xu Bio-Image Analytics Laboratory
  • 2. How snake works in images http://www.iacl.ece.jhu.edu/~chenyang/research/levset/movie/index.html
  • 3. How snake works in images  Step 1: Model the shape by curve or surface  Step 2: Define the energy function E along the curve E = internal energy (curvature) + external energy (images)  Step 3: Derive the curve to minimize the energy (calculus of variations)  Step 4: Propagate the curves (gradient descent) to reach the minimum using level set (easier to implement in reality). Keywords: Curve Energy Level set
  • 4. Snake -> Curves Consider a closed planar curve C ( p) {x( p), y( p)}, p [0,1] C(0.1) S(p) is the arclength C(0.2) C(0.7) C(0) C(0.4) C(0.95) Cp =tangent C(0.8) Css | Cp | Css N N 1 C(0.9) Cs Cp C The geometric trace of the curve can be alternatively represented implicitly as C {( x, y ) | ( x, y ) 0} 1 0 0 1
  • 5. Properties of level sets  T The level set normal  N |  N | Proof. Along the level sets (equal 0) we have zero change, that is s 0 , but by the chain rule So, s | ( x, y ) |  ,T x 0 xs | y |  ,T ys  T  N | |
  • 6. Properties of Level Sets The level set curvature Css =div | | Proof. zero change along the level sets, ss So, ( x, y ) d ( x xs ds , | | y | ys ) | [  ,T d ds x xx s xy ys , ss  ,T d ds x xy s yy ys ], | 0 , also  , N | Numerical Geometry of Images: http://webcourse.cs.technion.ac.il/236861/Winter2012-2013/en/ho_Tutorials.html
  • 7. Constant Flow Ct   N Propagation of Curves Change in topology Curvature Flow Ct Grayson   N Vanish at a Circular point First becomes convex Gage-Hamilton
  • 8. Curve propagation in Level Sets dC dt   VN C(t) d dt y V x x, y, t ( x, y; t ) t 0 t  N x xt y yt x xt | t C(t) level set  , VN , Ct V | y y yt  ,N  ,N V V 0 , | x | V| |
  • 9. Curve propagation in Level Sets  Handles changes in topology  Numeric grid points never collide or drift apart. Parametric Curve -> Level set in plane -> add time axis for propagation
  • 10. Curve propagation in Level Sets Some flows Ct  VN Ct  N Ct g t t   g, N N V 2 xx y div t 2 xy x y 2 2 x y 2 yy x div g g 2 xx y 2 xy x y 2 2 x y 2 yy x g,
  • 11. Snake Model 1 arg min C Cp 0 2 C pp tension 2 rigidity 2 g (C ) dp external energy from the image Energy g (C ) | [G (C ) * I (C )] |2 A snake that minimize E must satisfy the Euler equation Cpp Cpppp g C 0 To find a solution dC dt C pp C pppp g C When C stabilizes and the term Ct vanishes, a solution is achieved. Snakes: Active Contour Models, 1988
  • 12. Geodesic Active Contour arg min C L C 0 g C ds ds is the Euclidean arc-length. Trying to find minimum weighted distance I(x) Euler Lagrange gradient descent Ct  g (C) n   g (C), n n x g(x) d dt div g x, y Geodesic Active Contours, 1997 x
  • 13. GVF Snakes Replace the external force with gradient vector flow (GVF) force v. dC dt C pp C pppp g C V(x,y) = [u(x,y),v(x,y)] Why? f generally have large magnitudes only in the vicinity of the edges, the capture range would be small. It’s nearly zero in homogeneous regions. V(x,y) = [u(x,y), v(x,y)] is defined as the vector field that minimizes the energy functional: http://www.iacl.ece.jhu.edu/static/gvf/
  • 14. GVF Snake Results Original Snake Model 2d GVF vector field GVF Snake Model
  • 15. itk Implementation for GVF Geodesic Active Contour Original Image Gradient Magnitude Gradient Initial Contour Sigmoid Rescaling Geodesic Active Contour Gradient Vector Flow Thresholding Insight Segmentation and Registration Toolkit (ITK)
  • 16. itk Implementation for GVF Geodesic Active Contour gvfFilter->Update(); GeoAC->SetInput(initialContour->GetOutput()); GeoAC->SetAutoGenerateSpeedAdvection(false); GeoAC->SetFeatureImage(sigmoid->GetOutput()); GeoAC->GenerateSpeedImage(); GeoAC->SetAdvectionImage(gvfFilter->GetOutput());
  • 17. Recommended: Numerical Geometry of Images: http://webcourse.cs.technion.ac.il/236861/Winter2012-2013/en/ho_Tutorials.html
  • 18. Calculus of Variations Generalization of Calculus that seeks to find the path, curve, surface, etc., for which a given Functional has a minimum or maximum. Goal: find extrema values of integrals of the form F (u, u x )dx It has an extremum only if the Euler-Lagrange Differential Equation is satisfied, u d F ( u, u x ) dx u x 0
  • 19. Calculus of Variations Example: Find the shape of the curve {x,y(x)} with shortest length: x1 y ( x1 ) 2 1 y x dx , y ( x0 ) x0 given y(x0),y(x1) x0 Solution: a differential equation that y(x) must satisfy, y xx 0 yx a y ( x ) ax b 3/ 2 2 1 yx x1