A Tutorial on Active Contours

Similar documents
Segmentation using deformable models

Outline Introduction Edge Detection A t c i ti ve C Contours

MATH H53 : Final exam

Math 10C - Fall Final Exam

Chapter 2. First-Order Partial Differential Equations. Prof. D. C. Sanyal

Nonlinear Diffusion. Journal Club Presentation. Xiaowei Zhou

Lecture No 1 Introduction to Diffusion equations The heat equat

Exact Solutions of the Einstein Equations

Print Your Name: Your Section:

Math 115 ( ) Yum-Tong Siu 1. Euler-Lagrange Equations for Many Functions and Variables and High-Order Derivatives

arxiv: v1 [cs.cv] 17 Jun 2012

(a) The points (3, 1, 2) and ( 1, 3, 4) are the endpoints of a diameter of a sphere.

e x3 dx dy. 0 y x 2, 0 x 1.

MATH 332: Vector Analysis Summer 2005 Homework

ENGI Partial Differentiation Page y f x

Modulation-Feature based Textured Image Segmentation Using Curve Evolution

CN780 Final Lecture. Low-Level Vision, Scale-Space, and Polyakov Action. Neil I. Weisenfeld

1. (a) (5 points) Find the unit tangent and unit normal vectors T and N to the curve. r (t) = 3 cos t, 0, 3 sin t, r ( 3π

Review Sheet for the Final

Math 210, Final Exam, Spring 2012 Problem 1 Solution. (a) Find an equation of the plane passing through the tips of u, v, and w.

Disclaimer: This Final Exam Study Guide is meant to help you start studying. It is not necessarily a complete list of everything you need to know.

MAT 211 Final Exam. Fall Jennings.

Allen Cahn Equation in Two Spatial Dimension

12/19/2009, FINAL PRACTICE VII Math 21a, Fall Name:

Math 417 Midterm Exam Solutions Friday, July 9, 2010

WORKSHEET #13 MATH 1260 FALL 2014

Image Analysis. Feature extraction: corners and blobs

+ 2gx + 2fy + c = 0 if S

Chapter 3. Riemannian Manifolds - I. The subject of this thesis is to extend the combinatorial curve reconstruction approach to curves

Exercise 1 (Formula for connection 1-forms) Using the first structure equation, show that

7a3 2. (c) πa 3 (d) πa 3 (e) πa3

MATH 2203 Exam 3 Version 2 Solutions Instructions mathematical correctness clarity of presentation complete sentences

Multivariable Calculus Notes. Faraad Armwood. Fall: Chapter 1: Vectors, Dot Product, Cross Product, Planes, Cylindrical & Spherical Coordinates

Contents. MATH 32B-2 (18W) (L) G. Liu / (TA) A. Zhou Calculus of Several Variables. 1 Multiple Integrals 3. 2 Vector Fields 9

1. For each function, find all of its critical points and then classify each point as a local extremum or saddle point.

Derivatives and Integrals

The University of British Columbia Final Examination - December 17, 2015 Mathematics 200 All Sections

Calculus of Variations and Computer Vision

Mathematical Tripos Part IA Lent Term Example Sheet 1. Calculate its tangent vector dr/du at each point and hence find its total length.

MTH4101 CALCULUS II REVISION NOTES. 1. COMPLEX NUMBERS (Thomas Appendix 7 + lecture notes) ax 2 + bx + c = 0. x = b ± b 2 4ac 2a. i = 1.

SOME PROBLEMS YOU SHOULD BE ABLE TO DO

MAT 211 Final Exam. Spring Jennings. Show your work!

(b) Find the range of h(x, y) (5) Use the definition of continuity to explain whether or not the function f(x, y) is continuous at (0, 0)

APPM 2350 Final Exam points Monday December 17, 7:30am 10am, 2018

A Pseudo-distance for Shape Priors in Level Set Segmentation

Exercises for Multivariable Differential Calculus XM521

1 First and second variational formulas for area

Math 265H: Calculus III Practice Midterm II: Fall 2014

x + ye z2 + ze y2, y + xe z2 + ze x2, z and where T is the

Calculus of Variations Summer Term 2014

MA3D9. Geometry of curves and surfaces. T (s) = κ(s)n(s),

MLC Practice Final Exam

Numerical Methods of Applied Mathematics -- II Spring 2009

MATH 353 LECTURE NOTES: WEEK 1 FIRST ORDER ODES

Page Points Score Total: 210. No more than 200 points may be earned on the exam.

Final Exam. Monday March 19, 3:30-5:30pm MAT 21D, Temple, Winter 2018

SOLUTIONS TO THE FINAL EXAM. December 14, 2010, 9:00am-12:00 (3 hours)

PRACTICE PROBLEMS. Please let me know if you find any mistakes in the text so that i can fix them. 1. Mixed partial derivatives.

Archive of Calculus IV Questions Noel Brady Department of Mathematics University of Oklahoma

Sec. 1.1: Basics of Vectors

Faculty of Engineering, Mathematics and Science School of Mathematics

Math 53 Homework 5 Solutions

CS 468. Differential Geometry for Computer Science. Lecture 17 Surface Deformation

1MA6 Partial Differentiation and Multiple Integrals: I

Edge Detection. CS 650: Computer Vision

CURRENT MATERIAL: Vector Calculus.

Review for the First Midterm Exam

Practice Final Solutions

Review problems for the final exam Calculus III Fall 2003

Multiple Integrals and Vector Calculus (Oxford Physics) Synopsis and Problem Sets; Hilary 2015

Mathematical Notation Math Calculus & Analytic Geometry III

An improved active contour model based on level set method

Math 210, Final Exam, Practice Fall 2009 Problem 1 Solution AB AC AB. cosθ = AB BC AB (0)(1)+( 4)( 2)+(3)(2)

Formulas for probability theory and linear models SF2941

CANONICAL EQUATIONS. Application to the study of the equilibrium of flexible filaments and brachistochrone curves. By A.

Major Ideas in Calc 3 / Exam Review Topics

Ideas from Vector Calculus Kurt Bryan

Direction of maximum decrease = P

Math 4263 Homework Set 1

Final Review Worksheet

Name: Instructor: Lecture time: TA: Section time:

Active Contours Snakes and Level Set Method

Module 2: First-Order Partial Differential Equations

Line, surface and volume integrals

Solutions to Sample Questions for Final Exam

Mathematical Notation Math Calculus & Analytic Geometry III

Final Exam May 4, 2016

KillingFusion: Non-rigid 3D Reconstruction without Correspondences. Supplementary Material

Practice Problems for the Final Exam

Lecture 11: Differential Geometry

MATH 32A: MIDTERM 2 REVIEW. sin 2 u du z(t) = sin 2 t + cos 2 2

Topics. CS Advanced Computer Graphics. Differential Geometry Basics. James F. O Brien. Vector and Tensor Fields.

Total Variation Theory and Its Applications

Motion Estimation (I) Ce Liu Microsoft Research New England

LEVEL SET BASED MULTISPECTRAL SEGMENTATION WITH CORNERS

MATH 452. SAMPLE 3 SOLUTIONS May 3, (10 pts) Let f(x + iy) = u(x, y) + iv(x, y) be an analytic function. Show that u(x, y) is harmonic.

Math 115 ( ) Yum-Tong Siu 1. Canonical Transformation. Recall that the canonical equations (or Hamiltonian equations) = H

Weighted Minimal Surfaces and Discrete Weighted Minimal Surfaces

Maxima and Minima. (a, b) of R if

1. If the line l has symmetric equations. = y 3 = z+2 find a vector equation for the line l that contains the point (2, 1, 3) and is parallel to l.

Transcription:

Elham Sakhaee March 4, 14 1 Introduction I prepared this technical report as part of my preparation for Computer Vision PhD qualifying exam. Here we discuss derivation of curve evolution function for some well-known energy functionals. Parametric Curves A parametric curve is represented by C(s) (x(s),y(s)) with s being the arc length parametrization. Beitaspacecurveoraplanarcurve, onecanchangearc length parametrization to any arbitrary parametrization p using the following: ds dx +dy ds 1+( dy dx ) dx 1+y dx or ds ( dx dp ) +( dy dp ) dp x p +ypdp (1) WeknowthatcurvelengthisdefinedtobeL dsinarclengthparametrization. Replacing from the given infinitesimal length element ds we get L x p +y pdp C p dp Let s first show that minimizer of such length functional is κ. n L C p dp x p +y pdp () 1

Euler-Lagrange Formula L C(p) { L x d L dp x p L y d L dp y p d x p dp x p +yp d y p dp x p +yp x pp x p +yp x p xpp+xpypypp x p +y p x p +y p y pp x p +yp xpypxpp+y p ypp x p +y p x p +y p x ppy p+x py pp (x p +y p )3 y ppx p y px pp (x p +y p )3.( y p ).(x p ) x ppx p +xppy p x p xpp xpypypp (x p +y p )3 y ppx p +yppy p xpypxpp y p ypp (x p +y p )3 y ppx p y p x pp. n κ. n (x p +yp) 3 The above formula is the length minimization problem for a 3D curve. 3 Geodesic Active Contours x ppy p xpypypp (x p +y p )3 y ppx p xpypxpp (x p +y p )3 As we discussed in Differential Geometry tutorial, geodesics are minimal length space curves lying on a surface and connecting two points on that given surface. (3) Figure 1: a geodesic curve on a cone (blue) The formula derived in(3) is for a length minimization problem, however in geodesic active contours we are interested in finding a minimizer that takes the image characteristics (e.g. edges) into account. Let s define a general edge detector function g(c(s)) which can be any function that decreases at edges and increases elsewhere. 1 For example g(c(s)) 1+ I or more traditionally g(c(s)) I The energy functional that we are looking for would be: E α C p dp+λ g( I(C(p)) ) dp (4)

Let s define L α C p + λg(c) C p. It can be shown through Maupertuis Principle and Fermat s Principle from dynamicall systems, that minimizing the above energy functional is equivalent to minimizing intrinsic problem g(c(p)) C p dp. The details of proof of this equivalence is out of scope if this report, we refer the reader to ([1]) section.. and appendix A. Asdiscussedabove, solutionof(4)isgivenbyageodesiccurveinriemannian space. In order to minimize L R g(c(p)) C p dp we search for its gradient descent direction which is a way of minimizing the weighted length via steepest descent method. To do so we need to compute Euler-Lagrange formula. g(c(s))ds g(c(p)) C p dp we note that g p g x x p + g y y p g xx p +g y y p g(x(p),y(p))( x p +yp) dp L R C(p)... y ppx p y px pp (x p +y p )3 L R x(p) g x. x p +yp d dp ( x p x p +yp).g(x(p),y(p)) L R y(p) g y. x p +yp d dp ( y p x p +yp).g(x(p),y(p)) g x ( y p )+(g x ( y p )+g y x p )( y p ) y ppx p y px pp g x (x p )+(g x ( y p )+g y x p )(x p ) (x p +y p )3 (κ.g(c(p)) < g(c(p)), n > ) ( y p ) (κ.g(c(p)) < g(c(p)), n >)(x p ) (5) C t (κ.g < g, n >) n Where the n is the inward normal vector at any point of the curve. The geometric intuition of this gradient descent equation is that if we want to reach at a curve with minimal length the best way to evolve the curve C is to follow C(p) t (κ.g(c(p)) < g(c(p)), n >) n since it is the steepest descent equation and will lead to local minimum length curve. The detected object is the steady state solution of (5) when C(p) t. 4 Level-set framework Suppose a planar curve C(t) is represented by cross section of a 3D surface. 3

Figure : A curve can be implicitly defined as a level set of a surface Such representation of curve C is advantageous since it is independent of parametrization and hence is intrinsic. On the zero level-set plane, assume φ(x,y,t) is negative inside the zero level-set and positive outside, and by definition zero on the front(curve) itself. One can think of signed distance function as a potential φ. 4.1 Leve-set properties By definition (above) φ(x,y,t i ) is zero along the curve C for any fixed t i. Taking derivative with respect to t, we will get φ x x t +φ y y t hence [x t,y t ] T φ. But we know that the vector [x t,y t ] T is the tangent to the curve, therefore from [x t,y t ] T. φ we conclude that φ is normal to the curve. Accordingly, one can replace the inward normal n by normalized gradient of zero level-set as: φ φ n (6) Now, let s turn our attention to curvature of a level-set. From geometry of curves and surfaces we know that C s is the tangent to curve and C ss is the curvature of the curve. Given above definition for level-set, curvature of a level-set is also φ s in arc length parametrization. φ s s (φ xx s +φ y y s ) (φ xx x s +φ xy y s )x s +φ x x ss +(φ yx x s +φ yy y s )y s +y ss φ y φ xx x s +φ xy y s x s +φ yy y s+ < φ,c ss > (7) In order to simplify this equation we note that C ss κ n and φ φ n which allows for replacing x s with φy φ and y s with φx φ. Therefore we get the curvature of level-set to be κ φ xxφ y φ xy φ x φ y +φ yy φ x φ 3 (8) 4

One can simply work this out and get the well-known equation for curvature of the level-set, κ, to be κ. φ φ div( φ φ ) (9) 4. Level-set evolution Now we need to derive evolution equation of the embedding function φ such that evolving curve (C(t)) is represented by evolution of zero level-set of φ. by definition of zero level-set, we have φ(x,y,t) taking total derivative with respect to t we get φ x x t + φ y y t + dφ dt φ t (φ x x t +φ y y t ) [x t,y t ] T φ C t φ (1) In section (3) we derived C t (κg < g, n >) n. Replacing this in (1) we get: φ t (κg < g, n >) n. φ (κg < g, n >) φ φ. φ (κg < g, n >) φ κ φ g+ < g, φ > Replacing κ from (9) we finalize level-set evolution equation φ t as: (11) φ t div( φ ) φ g+ < g, φ > (1) φ 5 Closed Active Contours Beyond Gradient Vector Flow [] and traditional snakes, there are closed active contours that align themselves with the contour of the smoothed gradient vector field [3]. In order to intuitively understand why this alignment improves object detection, we can draw the following image: Figure 3: contour normal being aligned with image gradient 5

which shows that boundaries are more likely to lie where gradient of the object is aligned with the contour normal. Maximizing the alignment of the normal vector and gradient of the image is equivalent to minimizing the negative of the inner product of the two. 5.1 a simple case of closed active contours In case of closed active contours the functional to be minimized can be written as[3]: E ρ(< v, n >)ds (13) here n is the inward normal vector and v (u,v) is a vector flow. For now let s assume ρ(α) α. In the next section we deal with a more robust case where ρ(α) α and general case ρ(α). To derive the minimizer of the following energy functional: < v, n > ds [u(x,v),v(x,y)] T.[ y s,x s ]ds [u(x,y),v(x,y)] T 1. C p [ y p,x p ] C p dp [u(x,y),v(x,y)] T.[ y p,x p ] dp v(x,y)x p u(x,y)y p dp (14) d using chain rule for dp v(x,y) and d dpu(x,y), we find the Euler-Lagrange formula to be: { E E C(p) x d dp v(x,y) E y d dp u(x,y) { vx x p u x y p (v x x p +v y y p ) v y x p u y y p +(u x x p )+u y y p ) { (ux +v y )y p (u (u x +v y )x x +v y ). n p if one chooses v I E C(p) I. n { ux y p v y y p v y x p +u x x p (15) As described in section(3), the object edges are steady state solution of I. n E when C(p) since n we conclude that the object edges are I which are zero crossings of Laplacian of the image. 6

5. Generalized Closed Active Contours Now assume that ρ(α) α and note the fact u sign(u).u < v, n > ds v(x,y)x p u(x,y)y p dp { E sign(< v, n C >).(vx x p u x y p ) d dp (sign(< v, n >).v(x,y)) sign(< v, n >).(v y x p u y y p ) d dp (sign(< v, n >).u(x,y)) We also note that d dp sign(g(p)) g.δ(g(p)) and is assuming g(p) { sign(v(x,y)xp u(x,y)y p ).( u x y p v y y p ) sign(v(x,y)x p u(x,y)y p ).(v y x p +u x x p ) sign(v(x,y)x p u(x,y)y p )div(v). n Now Let s derive the evolution equation for a generic function ρ(α). ψ ρ (C) ρ(α)ds ρ(α) C p dp ψ C dρ dα. α C C p d dp ( C p C p.ρ(α)+ dρ dα. α C p C p ) We notice the following unities:... C p 1 C p C p.c p t unit tangent α 1 C p C p < v, t >. n (16) (17) (18) (19) 6 Region Based Active Contours Figure 4: Region-Based Image Segmentation 7

We assume that there are two regions in the image. we represent their average intensities with µ 1 and µ. The goal is to find the evolution equation of the contours in terms of known values µ 1 and µ and I(x,y). First Let s pose Green s theorem which we find useful in relating line integral along curve C to double integral on the region Ω enclosed by curve C L dx+m dy M x L y dx dy () C Just keep in mind what follows is Chan-Vese segmentation model WITHOUT regularization terms. Although not the exact Chan-Vese model [4] but gives an idea how region-based models can be worked out. Exact Chan-Vese segmentation model is given by: F(µ 1,µ,C) γ.length(c)+ν.area+λ 1 Ω (I µ 1 ) dxdy +λ Ω/ (I µ ) dxdy (1) And is minimzed through level set formulation which is beyond scope of this tutorial. So without regularization terms and setting λ 1 λ 1, energy functional of segmentation model would be: F(C) 1 (I µ 1 ) 1 dxdy + (I µ ) dxdy () Ω/ Opening the integrals, we get: F(C) 1 (I µ 1 ) 1 dxdy + (I µ ) dxdy (I µ ) dxdy (3) Ω and finally: 1 F(C) (µ µ 1) I(µ 1 µ ) dxdy µ +µ 1 (µ µ 1 )(I ) dxdy (4) We now apply Green s theorem to show that evolution equation is F(C) (µ µ 1 )(I µ+µ1 ). n Let M x f(x,y) and L y f(x,y) by Green s theorem we get: C 8

f(x,y) dxdy M x L y dxdy C L dx+m dy (5) Now use the fact that dx x s ds and dy y s ds replacing this into (5) we get L.x s +M.y s ds < [ M,L] T, n > ds (6) C From closed active contours section, we know that minimizer of C < v, n > ds is div(v). n,therefore minimizer of above functional is: C F(C) C div([ M,L]). n ( M x +L y ). n f(x,y). n (7) which is the desired result for evolving the regions. References [1] Caselles, V., Kimmel, R., Sapiro, G. (1997). Geodesic active contours. International journal of computer vision, (1), 61-79. [] Xu, C., Prince, J. L. (1998). Snakes, shapes, and gradient vector flow. Image Processing, IEEE Transactions on, 7(3), 359-369. [3] Kimmel, R., Bruckstein, A. M. (3). Regularized Laplacian zero crossings as optimal edge integrators. International Journal of Computer Vision, 53(3), 5-43. [4] Chan, T. F., Vese, L. A. (1). Active contours without edges. Image processing, IEEE transactions on, 1(), 66-77. 9