Mesh Processing Course : Geodesics

Preview:

DESCRIPTION

Slides for a course on mesh processing.

Citation preview

Geodesic Data Processing

Gabriel PeyréCEREMADE, Université Paris-Dauphine

www.numerical-tours.com

Local vs. Global Processing

2

Local Processing Differential Computations

Global Processing Geodesic Computations

Surface filtering

Fourier on Meshes

Front Propagation on Meshes

Surface Remeshing

Overview

•Metrics and Riemannian Surfaces.

• Geodesic Computation - Iterative Scheme

• Geodesic Computation - Fast Marching

• Shape Recognition with Geodesic Statistics

• Geodesic Meshing3

Parametric Surfaces

4

Parameterized surface: u ⇥ R2 ⇤� �(u) ⇥M.

u1

u2 �⇥�

⇥u1

⇥�

⇥u2

Parametric Surfaces

4

Parameterized surface: u ⇥ R2 ⇤� �(u) ⇥M.

Curve in parameter domain: t ⇥ [0, 1] ⇤� �(t) ⇥ D.

u1

u2 �⇥�

⇥u1

⇥�

⇥u2

� �

Parametric Surfaces

4

Parameterized surface: u ⇥ R2 ⇤� �(u) ⇥M.

Curve in parameter domain: t ⇥ [0, 1] ⇤� �(t) ⇥ D.

Geometric realization: �(t) def.= ⇥(�(t)) �M.

u1

u2 �⇥�

⇥u1

⇥�

⇥u2

��

� �

Parametric Surfaces

4

Parameterized surface: u ⇥ R2 ⇤� �(u) ⇥M.

Curve in parameter domain: t ⇥ [0, 1] ⇤� �(t) ⇥ D.

Geometric realization: �(t) def.= ⇥(�(t)) �M.

For an embedded manifoldM � Rn:First fundamental form: I� =

�� ⇥�

⇥ui,

⇥�

⇥uj⇥⇥

i,j=1,2

.

u1

u2 �⇥�

⇥u1

⇥�

⇥u2

L(�) def.=� 1

0||��(t)||dt =

� 1

0

⇥��(t)I�(t)��(t)dt.

Length of a curve

��

� �

Isometric and Conformal

M is locally isometric to the plane: I� = Id.Exemple: M =cylinder.

Surface not homeomorphic to a disk:

Isometric and Conformal

M is locally isometric to the plane: I� = Id.Exemple: M =cylinder.

⇥ is conformal: I�(u) = �(u)Id.Exemple: stereographic mapping plane�sphere.

Surface not homeomorphic to a disk:

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

W (x)

Euclidean space: M = Rn, H(x) = Idn.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

W (x)

Euclidean space: M = Rn, H(x) = Idn.2-D shape: M � R2, H(x) = Id2.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

W (x)

Euclidean space: M = Rn, H(x) = Idn.2-D shape: M � R2, H(x) = Id2.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Isotropic metric: H(x) = W (x)2Idn.

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

W (x)

Euclidean space: M = Rn, H(x) = Idn.2-D shape: M � R2, H(x) = Id2.

Image processing: image I, W (x)2 = (� + ||�I(x)||)�1.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Isotropic metric: H(x) = W (x)2Idn.

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

W (x)

Euclidean space: M = Rn, H(x) = Idn.2-D shape: M � R2, H(x) = Id2.

Parametric surface: H(x) = Ix (1st fundamental form).Image processing: image I, W (x)2 = (� + ||�I(x)||)�1.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Isotropic metric: H(x) = W (x)2Idn.

Riemannian Manifold

6

Length of a curve �(t) �M: L(�) def.=� 1

0

⇥��(t)TH(�(t))��(t)dt.

W (x)

Euclidean space: M = Rn, H(x) = Idn.2-D shape: M � R2, H(x) = Id2.

Parametric surface: H(x) = Ix (1st fundamental form).Image processing: image I, W (x)2 = (� + ||�I(x)||)�1.

DTI imaging: M = [0, 1]3, H(x)=di�usion tensor.

Riemannian manifold: M � Rn (locally)Riemannian metric: H(x) � Rn�n, symmetric, positive definite.

Isotropic metric: H(x) = W (x)2Idn.

Geodesic Distances

7

Geodesic distance metric overM � Rn

Geodesic curve: �(t) such that L(�) = dM(x, y).

Distance map to a starting point x0 �M: Ux0(x) def.= dM(x0, x).

dM(x, y) = min�(0)=x,�(1)=y

L(�)

Geodesic Distances

7

Geodesic distance metric overM � Rn

Geodesic curve: �(t) such that L(�) = dM(x, y).

Distance map to a starting point x0 �M: Ux0(x) def.= dM(x0, x).

met

ric

geod

esic

s

dM(x, y) = min�(0)=x,�(1)=y

L(�)

Euclidean

Geodesic Distances

7

Geodesic distance metric overM � Rn

Geodesic curve: �(t) such that L(�) = dM(x, y).

Distance map to a starting point x0 �M: Ux0(x) def.= dM(x0, x).

met

ric

geod

esic

s

dM(x, y) = min�(0)=x,�(1)=y

L(�)

Euclidean Shape

Geodesic Distances

7

Geodesic distance metric overM � Rn

Geodesic curve: �(t) such that L(�) = dM(x, y).

Distance map to a starting point x0 �M: Ux0(x) def.= dM(x0, x).

met

ric

geod

esic

s

dM(x, y) = min�(0)=x,�(1)=y

L(�)

Euclidean Shape Isotropic

Geodesic Distances

7

Geodesic distance metric overM � Rn

Geodesic curve: �(t) such that L(�) = dM(x, y).

Distance map to a starting point x0 �M: Ux0(x) def.= dM(x0, x).

met

ric

geod

esic

s

dM(x, y) = min�(0)=x,�(1)=y

L(�)

Euclidean Shape Isotropic Anisotropic

Geodesic Distances

7

Geodesic distance metric overM � Rn

Geodesic curve: �(t) such that L(�) = dM(x, y).

Distance map to a starting point x0 �M: Ux0(x) def.= dM(x0, x).

met

ric

geod

esic

s

dM(x, y) = min�(0)=x,�(1)=y

L(�)

Euclidean Shape Isotropic Anisotropic Surface

Anisotropy and Geodesics

8

H(x) = �1(x)e1(x)e1(x)T + �2(x)e2(x)e2(x)T with 0 < �1 � �2,Tensor eigen-decomposition:

x e1(x)

M

e2(x)

�2(x)�12

�1(x)�12

{� \ ��H(x)� � 1}

Anisotropy and Geodesics

8

H(x) = �1(x)e1(x)e1(x)T + �2(x)e2(x)e2(x)T with 0 < �1 � �2,Tensor eigen-decomposition:

x e1(x)

M

e2(x)

�2(x)�12

�1(x)�12

{� \ ��H(x)� � 1}

Geodesics tend to follow e1(x).

Anisotropy and Geodesics

8

H(x) = �1(x)e1(x)e1(x)T + �2(x)e2(x)e2(x)T with 0 < �1 � �2,Tensor eigen-decomposition:

Local anisotropy of the metric:

4 ECCV-08 submission ID 1057

Figure 2 shows examples of geodesic curves computed from a single starting77 77

point S = {x1} in the center of the image � = [0, 1]2 and a set of points on the78 78

boundary of �. The geodesics are computed for a metric H(x) whose anisotropy79 79

⇥(x) (defined in equation (2)) is increasing, thus making the Riemannian space80 80

progressively closer to the Euclidean space.81 81

Image f � = .1 � = .2 � = .5 � = 1

Fig. 2. Examples of geodesics for a tensor metric with an increasing anisotropy � (seeequation (2) for a definition of this parameter). The tensor field H(x) is computed fromthe structure tensor of f as defined in equation (8), its eigenvalues fields ⇥i(x) are thenmodified to impose the anisotropy �.

For the particular case of an isotropic metric H(x) = W (x)Idx, the geodesic82 82

distance and the shortest path satisfy83 83

||⇥xUS || = W (x) and ⇤�(t) = � ⇥xUS||⇥xUS ||

. (6)

This corresponds to the Eikonal equation, that has been used to compute mini-84 84

mal paths weighted by W [1].85 85

1.3 Numerical Computations of Geodesic Distances86 86

In order to make all the previous definitions e�ective in practical situations,87 87

one needs a fast algorithm to compute the geodesic distance map US . The Fast88 88

Marching algorithm, introduced by Sethian [2] is a numerical procedure to e⇥-89 89

ciently solve in O(n log(n)) operations the discretization of equation (6) in the90 90

isotropic case. Several extensions of the Fast Marching have been proposed in91 91

order to solve equation (4) for a generic metric, see for instance Kimmel and92 92

Sethian [3] for triangulated meshes and Spira and Kimel [4], Bronstein et al. [5]93 93

for parametric manifolds.94 94

We use the Fast Marching method developed by Prados et al. [6], which is a95 95

numerical scheme to compute the geodesic distance over a generic parameteric96 96

Riemannian manifold in 2D and 3D in O(n log(n)) operations. As any Fast97 97

Marching method, it computes the distance US by progressively propagating a98 98

front, starting from the initial points in S. Figure 3 shows an example of Fast99 99

Marching computation with an anisotropic metric. The front propagates faster100 100

along the direction of the texture. This is because the Riemannian tensor is101 101

computed following equation (8) in order for the principal direction e1 to align102 102

with the texture patterns.103 103

Image f � = .5 � = 0� = .95 � = .7

�(x) =⇥1(x)� ⇥2(x)⇥1(x) + ⇥2(x)

� [0, 1]

x e1(x)

M

e2(x)

�2(x)�12

�1(x)�12

{� \ ��H(x)� � 1}

Geodesics tend to follow e1(x).

Isotropic Metric Design

9

Image f Metric W (x) Distance Ux0(x) Geodesic curve �(t)

Image-based potential: H(x) = W (x)2Id2, W (x) = (� + |f(x)� c|)�

Isotropic Metric Design

9

Image f Metric W (x) Distance Ux0(x) Geodesic curve �(t)

Image f Metric W (x) U{x0,x1}

Image-based potential: H(x) = W (x)2Id2, W (x) = (� + |f(x)� c|)�

Geodesics

Gradient-based potential: W (x) = (� + ||�xf ||)��

Isotropic Metric Design: Vessels

10

f f W = (� + max(f , 0))��

Remove background: f = G� ⇥ f � f , � ⇥vessel width.

Isotropic Metric Design: Vessels

10

f f W = (� + max(f , 0))��

3D Volumetric datasets:

Remove background: f = G� ⇥ f � f , � ⇥vessel width.

Overview• Metrics and Riemannian Surfaces.

•Geodesic Computation - Iterative Scheme

• Geodesic Computation - Fast Marching

• Shape Recognition with Geodesic Statistics

• Geodesic Meshing11

Eikonal Equation and Viscosity Solution

12

U(x) = d(x0, x)Distance map:

Theorem: U is the unique viscosity solution of||�U(x)||H(x)�1 = 1 with U(x0) = 0

where ||v||A =�

v�Av

Eikonal Equation and Viscosity Solution

12

Geodesic curve � between x1 and x0 solves

��(t) = �⇥t H(�(t))�1�Ux0(�(t))�(0) = x1

�t > 0with

U(x) = d(x0, x)Distance map:

Theorem: U is the unique viscosity solution of||�U(x)||H(x)�1 = 1 with U(x0) = 0

where ||v||A =�

v�Av

Eikonal Equation and Viscosity Solution

12

Geodesic curve � between x1 and x0 solves

Example: isotropic metric H(x) = W (x)2Idn,

��(t) = �⇥t H(�(t))�1�Ux0(�(t))�(0) = x1

�t > 0

||�U(x)|| = W (x) ��(t) = �⇥t�U(�(t))and

with

U(x) = d(x0, x)Distance map:

Theorem: U is the unique viscosity solution of||�U(x)||H(x)�1 = 1 with U(x0) = 0

where ||v||A =�

v�Av

Simplified Proof

V solving�

||⇤V (x)||2H�1 = �H�1(x)⇤V (x), ⇤V (x)⇥ = 1,V (x0) = 0.

U(x) = min�:x0�x

L(�) =� 10

��H(�(t))��(t), ��(t)�dt

Simplified Proof

V solving�

||⇤V (x)||2H�1 = �H�1(x)⇤V (x), ⇤V (x)⇥ = 1,V (x0) = 0.

U � V

���, ⇤V ⇥ = �H1/2��, H�1/2⇤V ⇥ � ||H1/2��||||H�1/2⇤V ||C.S.

= 1

If V is smooth on �:

Let � : x0 � x be any smooth curve.

U(x) = min�:x0�x

L(�) =� 10

��H(�(t))��(t), ��(t)�dt

Simplified Proof

V solving�

||⇤V (x)||2H�1 = �H�1(x)⇤V (x), ⇤V (x)⇥ = 1,V (x0) = 0.

U � V

���, ⇤V ⇥ = �H1/2��, H�1/2⇤V ⇥ � ||H1/2��||||H�1/2⇤V ||

=� U(x) = min�

L(�) � V (x)

C.S.

= 1

= 0

L(�) =� 10 ||H1/2��|| �

� 10 ⇥�

�, ⌅V ⇤ = V (�(1))� V (�(0)) = V (x)

If V is smooth on �:

Let � : x0 � x be any smooth curve.

U(x) = min�:x0�x

L(�) =� 10

��H(�(t))��(t), ��(t)�dt

Simplified Proof (cont.)

U � VDefine: ��(t) = �H�1(�(t))�V (�(t))

x0

x�(0) = x

Let x be arbitrary.

Simplified Proof (cont.)

U � VDefine: ��(t) = �H�1(�(t))�V (�(t))

x0

x�(0) = x

Let x be arbitrary.

dV (�(t))dt

= ���(t), �V (�(t))� = �1

If V is smooth on �([0, tmax)), then

=� �(tmax) = x0

Simplified Proof (cont.)

1413

U � VDefine:

= 1

= 0

��(t) = �H�1(�(t))�V (�(t))

x0

�H��, ��� = �H�1�V, �V � = 1

x�(0) = x

Let x be arbitrary.

dV (�(t))dt

= ���(t), �V (�(t))� = �1

If V is smooth on �([0, tmax)), then

=� �(tmax) = x0

= �� tmax

0 ���, �V � = �V (�(tmax)) + V (�(0)) = V (x)

One has:

U(x) � L(�) =� tmax

0

��H��, ��� =

� tmax

0 �H��, ���

Discretization

15

x

x0�B(x)Control (derivative-free) formulation:

U(x) = d(x0, x) is the unique solution ofy

U(x) = �(U)(x) = miny�B(x)

U(y) + d(x, y)

Discretization

15

x

x0�B(x)

xj

xixk

B(x)

Control (derivative-free) formulation:U(x) = d(x0, x) is the unique solution of

Manifold discretization: triangular mesh.

U discretization: linear finite elements.

H discretization: constant on each triangle.

y

U(x) = �(U)(x) = miny�B(x)

U(y) + d(x, y)

Discretization

15

x

x0�B(x)

xj

xixk

B(x)

Control (derivative-free) formulation:U(x) = d(x0, x) is the unique solution of

Manifold discretization: triangular mesh.

U discretization: linear finite elements.

H discretization: constant on each triangle.

Ui = �(U)i = minf=(i,j,k)

Vi,j,k

Vi,j,k = min0�t�1

tUj + (1� t)Uk

� on regular grid: equivalent to upwind FD.

� explicit solution (solving quadratic equation).

xj

xk

xi

txj + (1� t)xk

y

+||txj + (1� t)xk � xi||Hijk

U(x) = �(U)(x) = miny�B(x)

U(y) + d(x, y)

Update Step on a triangulation

16

Vi,j,k = min0�t�1

tUj + (1� t)Uk

�(U)i = minf=(i,j,k)

Vi,j,k

xi

xj

xk

+||txj + (1� t)xk � xi||Hijk

Discrete Eikonal equation:

Update Step on a triangulation

16

Vi,j,k = min0�t�1

tUj + (1� t)Uk

Distance function in (i, j, k):

�(U)i = minf=(i,j,k)

Vi,j,k

xi

xj

xk

+||txj + (1� t)xk � xi||Hijk

g

Unknowns:

Discrete Eikonal equation:

= Vi,j,k

U(x) = �x � xi, g� + d

gradient

Update Step on a triangulation

16

Vi,j,k = min0�t�1

tUj + (1� t)Uk

Distance function in (i, j, k):

�(U)i = minf=(i,j,k)

Vi,j,k

X = (xj � xi, xk � xi) � Rd�2

u = (Uj , Uk) � R2

S = (X�X)�1 � R2�2

I = (1, 1) � R2

xi

xj

xk

+||txj + (1� t)xk � xi||Hijk

g

Notations:Unknowns:

Discrete Eikonal equation:

= Vi,j,k

U(x) = �x � xi, g� + d

gradient

Hi,j,k = w2Id3 (for simplifity)

Update Step on a triangulation (cont.)

17

xi

xj

xk

� � 0

X�g + dI = u =� � = S(u� dI)

Find g = X�, � � R2 and d = Vi,j,k.

Update Step on a triangulation (cont.)

17

xi

xj

xk

� � 0

X�g + dI = u =� � = S(u� dI)

Find g = X�, � � R2 and d = Vi,j,k.

||�U(xi)|| = ||g|| = w

Discrete Eikonal equation:

��

Update Step on a triangulation (cont.)

17

xi

xj

xk

� � 0

X�g + dI = u =�

d2 � 2bd + c = 0

��

a = �SI, I�b = �SI, u�c = �Su, u� � w2=�

� = S(u� dI)

Quadratic equation:

Find g = X�, � � R2 and d = Vi,j,k.

||�U(xi)|| = ||g|| = w

Discrete Eikonal equation:

��

||XS(u� dI)||2 = w2

Update Step on a triangulation (cont.)

17

� = b2 � acd =b +�

aAdmissible solution:

dj = Uj + Wi||xi � xj ||�(ui) =�

d if � � 0min(dj , dk) otherwise.

xi

xj

xk�1 � 0

� � 0

X�g + dI = u =�

d2 � 2bd + c = 0

��

a = �SI, I�b = �SI, u�c = �Su, u� � w2=�

� = S(u� dI)

Quadratic equation:

Find g = X�, � � R2 and d = Vi,j,k.

||�U(xi)|| = ||g|| = w

Discrete Eikonal equation:

��

||XS(u� dI)||2 = w2

Numerical Schemes

18

Fixed point equation: U = �(U)� is monotone: U � V =� �(U) � �(V )

U (�+1) = �(U (�))

U (�) � U solving �(U) = U

U (0) = 0,

U (�)

Iterative schemes: ||�(U (�))� U (�)||=� U (�+1) � U (�) � C < +�

Numerical Schemes

18

Fixed point equation: U = �(U)� is monotone: U � V =� �(U) � �(V )

U (�+1) = �(U (�))

U (�) � U solving �(U) = U

U (0) = 0,

U (�)

Iterative schemes: ||�(U (�))� U (�)||

Minimal path extraction:

�(�+1) = �(�) � ⇥� H(�(�))�1�U(�(�))

=� U (�+1) � U (�) � C < +�

Numerical Examples on Meshes

19

Discretization Errors

20

For a mesh with N points: U [N ] � RN solution of �(U [N ]) = U [N ]

Linear interpolation: U [N ](x) =�

i

U [N ]i �i(x)

Uniform convergence: ||U [N ] � U ||�N�+��⇥ 0

Continuous geodesic distance U(x).

Discretization Errors

20

1N

i

|UNi � U(xi)|2

For a mesh with N points: U [N ] � RN solution of �(U [N ]) = U [N ]

Linear interpolation: U [N ](x) =�

i

U [N ]i �i(x)

Uniform convergence: ||U [N ] � U ||�N�+��⇥ 0

Numerical evaluation:

Continuous geodesic distance U(x).

Overview

• Metrics and Riemannian Surfaces.

• Geodesic Computation - Iterative Scheme

•Geodesic Computation - Fast Marching

• Shape Recognition with Geodesic Statistics

• Geodesic Meshing21

Causal Updates

22

� j � i, �(U)i � UjCausality condition:

� The value of Ui depends on {Uj}j with Uj � Ui.

� Compute �(U)i using an optimal ordering.� Front propagation, O(N log(N)) operations.

Causal Updates

22

� j � i, �(U)i � UjCausality condition:

� The value of Ui depends on {Uj}j with Uj � Ui.

� Compute �(U)i using an optimal ordering.� Front propagation, O(N log(N)) operations.

u = �(U)i is the solution of

max(u� Ui�1,j , u� Ui+1,j , 0)2+max(u� Ui,j�1, u� Ui,j+1, 0)2 = h2W 2

i,j

(upwind derivatives)

Isotropic H(x) = W (x)2Id, square grid.

xi+1,j

xi,j+1

xi,j

Causal Updates

22

� j � i, �(U)i � UjCausality condition:

� The value of Ui depends on {Uj}j with Uj � Ui.

� Compute �(U)i using an optimal ordering.� Front propagation, O(N log(N)) operations.

triangulation with no obtuse angles.

Bad

Goodu = �(U)i is the solution of

max(u� Ui�1,j , u� Ui+1,j , 0)2+max(u� Ui,j�1, u� Ui,j+1, 0)2 = h2W 2

i,j

(upwind derivatives)

Isotropic H(x) = W (x)2Id, square grid.

Surface (first fundamental form)

xi

xj

xk

GoodBad

xi+1,j

xi,j+1

xi,j

Front Propagation

23

x0

Algorithm: Far � Front � Computed.

2) Move from Front to Computed .

Iter

atio

nFront �Ft, Ft = {i \ Ui � t}

�Ft

State Si � {Computed, Front, Far}

3) Update Uj = �(U)j for neighbors

1) Select front point with minimum Ui

and

Fast Marching on an Image

24

Fast Marching on Shapes and Surfaces

25

Volumetric Datasets

26

Propagation in 3D

27

Overview• Metrics and Riemannian Surfaces.

• Geodesic Computation - Iterative Scheme

• Geodesic Computation - Fast Marching

•Shape Recognition with Geodesic Statistics

• Geodesic Meshing28

Bending Invariant Recognition

29

[Zoopraxiscope, 1876]

Shape articulations:

Bending Invariant Recognition

29

[Zoopraxiscope, 1876]

Shape articulations:

x1

x2M

Surface bendings:

[Elad, Kimmel, 2003]. [Bronstein et al., 2005].

2D Shapes

30

2D shape: connected, closed compact set S � R2.Piecewise-smooth boundary �S.

Geodesic distance in S for uniform metric:dS(x, y) def.= min

�⇥P(x,y)L(�) where L(�) def.=

� 1

0|��(t)|dt,

Shap

eS

Geo

desi

cs

Distribution of Geodesic Distances

31

0

20

40

60

80

0

20

40

60

80

0

20

40

60

80

Distribution of distancesto a point x: {dM(x, y)}y�M

Distribution of Geodesic Distances

31

0

20

40

60

80

0

20

40

60

80

0

20

40

60

80

Distribution of distances

Extract a statistical measure

to a point x: {dM(x, y)}y�M

Min Median Max

a0(x) = miny

dM(x, y).

a1(x) = mediany

dM(x, y).

a2(x) = maxy

dM(x, y).

x x x

Distribution of Geodesic Distances

31

0

20

40

60

80

0

20

40

60

80

0

20

40

60

80

Distribution of distances

Extract a statistical measure

to a point x: {dM(x, y)}y�M

Min Median Max

a0(x) = miny

dM(x, y).

a1(x) = mediany

dM(x, y).

a2(x) = maxy

dM(x, y).a(x)

a0

a1

a2

x x x

Benging Invariant 2D Database

32

0 20 40 60 80 1000

20

40

60

80

100

Aver

age

Prec

isio

n

Average Recall

1D4D

0 10 20 30 400

20

40

60

80

100

Image Rank

Aver

age

Rec

all

1D4D

[Ling & Jacobs, PAMI 2007]

(min,med,max)Our method

max only[Ion et al. 2008]

� State of the art retrieval rates on this database.

Perspective: Textured Shapes

33Max Min||�f(x)||

Image f(x)

Euclidean

Weighted

Take into account a texture f(x) on the shape.

Compute a saliency field W (x), e.g. edge detector.

Compute weighted curve lengths: L(�) def.=� 1

0W (�(t))||��(t)||dt.

Overview

• Metrics and Riemannian Surfaces.

• Geodesic Computation - Iterative Scheme

• Geodesic Computation - Fast Marching

• Shape Recognition with Geodesic Statistics

•Geodesic Meshing34

Meshing Images, Shapes and Surfaces

35

Vertices V = {vi}Mi=1.

Faces F � {1, . . . ,M}3.Triangulation (V,F):

fM =M�

m=1

�m⇥m

� = argminµ

||f ��

m

µm⇥m||

Image approximation:

⇥m(vi) = �mi is a�ne on each face of F .

Meshing Images, Shapes and Surfaces

35

Vertices V = {vi}Mi=1.

Faces F � {1, . . . ,M}3.Triangulation (V,F):

fM =M�

m=1

�m⇥m

� = argminµ

||f ��

m

µm⇥m||

Image approximation:

||f � fM || � CfM�2

⇥m(vi) = �mi is a�ne on each face of F .

There exists (V,F) such thatOptimal (V,F): NP-hard.

Meshing Images, Shapes and Surfaces

35

Vertices V = {vi}Mi=1.

Faces F � {1, . . . ,M}3.Triangulation (V,F):

fM =M�

m=1

�m⇥m

� = argminµ

||f ��

m

µm⇥m||

Image approximation:

||f � fM || � CfM�2

⇥m(vi) = �mi is a�ne on each face of F .

There exists (V,F) such thatOptimal (V,F): NP-hard.

Domain meshing:

Conforming to complicated boundary.Capturing PDE solutions:Boundary layers, chocs . . .

Riemannian Sizing Field

36

Distance conforming:

Sampling {xi}i�I of a manifold.

Triangulation conforming:

⇤xi ⇥ xj , d(xi, xj) � �

� =( xi ⇤ xj ⇤ xk) ⇥�x \ ||x� x�||T (x�) � �

x

e1(x)e2(x)� �1(x)�

12

� �2(x)�12

�⇥Building triangulation

Ellipsoid packing

Global integration oflocal sizing field

�⇥

Geodesic Sampling

Metric Sampling

Sampling {xi}i�I of a manifold.

xk+1 = argmaxx

min0�i�k

d(xi, x)

Geodesic Sampling

Metric Sampling

Sampling {xi}i�I of a manifold.

Farthest point algorithm: [Peyre, Cohen, 2006]

xk+1 = argmaxx

min0�i�k

d(xi, x)

Geodesic Sampling

Metric

Voronoi

Sampling

Sampling {xi}i�I of a manifold.

Farthest point algorithm: [Peyre, Cohen, 2006]

Ci = {x \ ⇥ j �= i, d(xi, x) � d(xj , x)}Geodesic Voronoi:

xk+1 = argmaxx

min0�i�k

d(xi, x)

� distance conforming. � triangulation conforming if the metric is “gradded”.

� geodesic Delaunay refinement.

Geodesic Sampling

Metric

DelaunayVoronoi

Sampling

Sampling {xi}i�I of a manifold.

Farthest point algorithm: [Peyre, Cohen, 2006]

Geodesic Delaunay connectivity:

(xi � xj)⇥ (Ci ⇧ Cj ⇤= ⌅)

Ci = {x \ ⇥ j �= i, d(xi, x) � d(xj , x)}Geodesic Voronoi:

Adaptive Meshing

# samples

Texture Metric Uniform Adaptive

Adaptive Meshing

# samples

Minimize approximation error ||f � fM ||Lp .

Isotropic

Approximation Driven MeshingLinear approximation fM with M linear elements.

Minimize approximation error ||f � fM ||Lp .

Images: T (x) = |H(x)| (Hessian)Surfaces: T (x) = |C(x)| (curvature tensor)

Isotropic Anisotropic

Approximation Driven MeshingLinear approximation fM with M linear elements.

L� optimal metrics for smooth functions:

Minimize approximation error ||f � fM ||Lp .

Images: T (x) = |H(x)| (Hessian)Surfaces: T (x) = |C(x)| (curvature tensor)

Isotropic Anisotropic

Approximation Driven MeshingLinear approximation fM with M linear elements.

L� optimal metrics for smooth functions:

Anisotropic triangulation JPEG2000

For edges and textures: � use structure tensor.[Peyre et al, 2008]

Minimize approximation error ||f � fM ||Lp .

Images: T (x) = |H(x)| (Hessian)Surfaces: T (x) = |C(x)| (curvature tensor)

boundary approximation.

Isotropic Anisotropic

Approximation Driven MeshingLinear approximation fM with M linear elements.

L� optimal metrics for smooth functions:

Anisotropic triangulation JPEG2000

For edges and textures: � use structure tensor.

� extension to handle

[Peyre et al, 2008]

[Peyre et al, 2008]

40

ConclusionRiemannian tensors encode geometric features.� Size, orientation, anisotropy.

Computing geodesic distance:iterative vs. propagation.

40

ConclusionRiemannian tensors encode geometric features.� Size, orientation, anisotropy.

Using geodesic curves: image segmentation.

Using geodesic distance: image and surface meshing

Computing geodesic distance:iterative vs. propagation.