The Greedy Snake Algorithm Nick Govier David Newman

  • Slides: 15
Download presentation
The “Greedy Snake” Algorithm Nick Govier David Newman

The “Greedy Snake” Algorithm Nick Govier David Newman

Overview l What is “Greedy Snake”? l How does it Work? l Problems of

Overview l What is “Greedy Snake”? l How does it Work? l Problems of Greedy Snake l References l Demo l Questions? ?

What is “Greedy Snake”? l. A Feature Extraction technique l Sometimes l Works called

What is “Greedy Snake”? l. A Feature Extraction technique l Sometimes l Works called “Active Contours” like stretched Elastic Band being released

“Greedy Snake” Theory (1) l Initial Points defined around Feature to be extracted –

“Greedy Snake” Theory (1) l Initial Points defined around Feature to be extracted – Explicitly defined – Approximation of an Ellipse l Pre-defined generated number of Points

“Greedy Snake” Theory (2) l Points are moved through an Iterative Process l “Energy

“Greedy Snake” Theory (2) l Points are moved through an Iterative Process l “Energy Function” for each point in the Local Neighbourhood is calculated l Move to point with lowest Energy Function l Repeat for every point l Iterate until Termination Condition met – Defined number of iterations – Stability of the position of the points

Energy Function l Three Components – Continuity – Curvature – Image (Gradient) l Each

Energy Function l Three Components – Continuity – Curvature – Image (Gradient) l Each Weighted by Specified Parameter l Total Energy = α · Continuity + β · Curvature + γ · Image

Continuity l Abs(avg_dist_btw_nodes – dist(V(i), V(i-1)) l Value = Smaller Distance between Points l

Continuity l Abs(avg_dist_btw_nodes – dist(V(i), V(i-1)) l Value = Smaller Distance between Points l The higher α, the more important the distance between points is minimized Neighbouring Points Current Point Possible New Points

Curvature l Norm(V(i-1) -2·V(i) + V(i+1))2 l Normalised by greatest value in neighbourhood l

Curvature l Norm(V(i-1) -2·V(i) + V(i+1))2 l Normalised by greatest value in neighbourhood l The higher β, the more important that angles are maximized Neighbouring Points Current Point Possible New Points

Image (Gradient) l- Img_grad (V(i)) Assume Gradient Measured on 3 x 3 Template l

Image (Gradient) l- Img_grad (V(i)) Assume Gradient Measured on 3 x 3 Template l High Image Gradient = Low Energy value Low Image Gradient l The higher γ, the more important image edges are High Image Gradient

Drawing Corners l For each Snake Point take Curvature Value l IF Greater than

Drawing Corners l For each Snake Point take Curvature Value l IF Greater than other points – AND specified Angular Threshold – AND Image Gradient high enough l THEN set β for that Snake point to 0, allowing a Corner

Varying α, β and γ l Choose different values dependent on Feature to extract

Varying α, β and γ l Choose different values dependent on Feature to extract l Set α high if there is a deceptive Image Gradient l Set β high if smooth edged Feature, low if sharp edges l Set γ high if contrast between Background and Feature is low

“Greedy Snake” Problems l Very sensitive to Noise – Both Gaussian and Salt &

“Greedy Snake” Problems l Very sensitive to Noise – Both Gaussian and Salt & Pepper l Before defining initial points – Firstly Gaussian Blur image – Then apply a Median Filter

References [1]: http: //www. markschulze. net/snakes/ - Snake Applet & Explanation of Algorithm l

References [1]: http: //www. markschulze. net/snakes/ - Snake Applet & Explanation of Algorithm l [2]: http: //torina. fe. uni-lj. si/~tomo/ac/Snakes. html Another Snake Applet l [3]: http: //web. mit. edu/stanrost/www/cs 585 p 3/p 3. html – Explanation + Matlab Implementation l [4]: http: //homepages. inf. ed. ac. uk/cgi/rbf/CVONLINE /entries. pl? TAG 709 – Repository of Greedy Snake Links l

Demo l www. ecs. soton. ac. uk/~drn 101/Snakes. html

Demo l www. ecs. soton. ac. uk/~drn 101/Snakes. html

Questions ? ?

Questions ? ?