image matting with the matting laplacian

41
Image Matting with the Matting Laplacian Chen-Yu Tseng 曾曾曾 Advisor: Sheng-Jyh Wang

Upload: marina

Post on 22-Feb-2016

181 views

Category:

Documents


2 download

DESCRIPTION

Image Matting with the Matting Laplacian. Chen-Yu Tseng 曾禎宇 Advisor: Sheng- Jyh Wang. Image Matting with the Matting Laplacian. Matting Laplacian - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Image Matting with  the Matting  Laplacian

Image Matting with the Matting LaplacianChen-Yu Tseng 曾禎宇Advisor: Sheng-Jyh Wang

Page 2: Image Matting with  the Matting  Laplacian

Image Matting with the Matting Laplacian• Matting Laplacian• A. Levin, D. Lischinski, Y. Weiss. A Closed Form Solution to Natural

Image Matting. IEEE T. PAMI, vol. 30, no. 2, pp. 228-242, Feb. 2008.

• Spectral Matting• A. Levin, A. Rav-Acha, D. Lischinski. Spectral Matting. IEEE T. PAMI,

vol. 30, no. 10, pp. 1699-1712, Oct. 2008.• Matting for Multiple Image Layers• D. Singaraju, R. Vidal. Estimation of Alpha Mattes for Multiple

Image Layers. IEEE T. PAMI, vol. 33, no. 7, pp. 1295-1309, July 2011.

Center for Imaging Science, Department of Biomedical Engineering,The Johns Hopkins University

Page 3: Image Matting with  the Matting  Laplacian

Image Matting

• Extracting a foreground object from an image along with an opacity estimate for each pixel covered by the object

Input Image Conventional Segmentation

Result

Spectral Matting Result

Page 4: Image Matting with  the Matting  Laplacian

Image Compositing Equation

Alpha Mattes Image Layers

x

x

x

=

+

+

Input Image

L1

L2

L3

α1

α2

α3

Ki

Kiii LLLI

iii ...2211

Page 5: Image Matting with  the Matting  Laplacian

Methodology• Supervised Matting

• Unsupervised Matting• Spectral Matting

Input Image Trimap (user’s constraint) Alpha Matte

Matting ComponentsInput Image

Page 6: Image Matting with  the Matting  Laplacian

Local Models for Alpha Mattes

= x x+ 1 2L1L

𝐼 𝑖=𝛼𝑖𝐹 𝑖+(1−𝛼 𝑖)𝐵𝑖

𝛼 𝑖=𝐼 𝑖−𝐵𝑖

𝐹 𝑖−𝐵𝑖≈𝑎 𝐼𝑖+𝑏 ,∀ 𝑖∈𝑤 Assume a and b are constant

in a small window

LJ T )(

, , and are unknown ill-posed problem

Page 7: Image Matting with  the Matting  Laplacian

Color Line Assumption

Color Distributions

Input

Omer and M. Werman. Color Lines: Image Specific Color Representation. CVPR, 2004.

Page 8: Image Matting with  the Matting  Laplacian

Local Models for Alpha Mattes for Multiple Layers

Local Models1. Two color lines2. A color point and a color point3. Two color points and a single color line4. Four color points

R

G

B

Page 9: Image Matting with  the Matting  Laplacian

Local Models1. Two color lines2. A color plane and a color point3. Two color points and a single color line4. Four color points

Color point

Color plane

Unknown color point

𝐼 𝑖=𝛼𝑖𝐹 𝑖+(1−𝛼 𝑖)𝐵𝑖

𝐹 𝑖

𝐵𝑖

𝐼 𝑖

Page 10: Image Matting with  the Matting  Laplacian

Local Models1. Two color lines2. A color plane and a color point3. Two color points and a single color line4. Four color points

𝐼 𝑗=𝛼 𝑗1𝐹 𝑗

1+𝛼 𝑗2𝐹 𝑗

2 Color point

Color plane

𝐹 𝑗1

𝐹 𝑗2

𝐼 𝑖=

=++

Page 11: Image Matting with  the Matting  Laplacian
Page 12: Image Matting with  the Matting  Laplacian

Local Models for Alpha Mattes for Multiple Layers

Local Models1. Two color lines2. A color point and a color point3. Two color points and a single color line4. Four color points

R

G

B

Page 13: Image Matting with  the Matting  Laplacian

The Matting Laplacian

LJ T )(

.11),(),|(

1

3

kwjikkj

kk

Tki

kij ww

ji IUIL

Page 14: Image Matting with  the Matting  Laplacian

Overview of Spectral MattingInput Data

Matting Laplacian Construction

Spectral GraphAnalysis

Data ComponentGeneration

Output Components Laplacian Matrix

Input Image Local Adjacency

Components

Page 15: Image Matting with  the Matting  Laplacian

Spectral Clustering

Scatter plot of a 2D data set

K-means Clustering Spectral Clustering

U. von Luxburg. A tutorial on spectral clustering. Technical report, Max Planck Institute for Biological Cybernetics, Germany, 2006.

Page 16: Image Matting with  the Matting  Laplacian

Graph Construction

njiijwW ,...,1,)(

),( EVG

},...,,{ 21 nvvvV Vertex Set

Similarity Graph

Weighted Adjacency Matrix

Connected Groups

Similarity Graph

Similarity Graph• ε-neighborhood Graph• k-nearest neighbor Graphs• Fully connected graph

Page 17: Image Matting with  the Matting  Laplacian

Graph Laplacian

njiijwW ,...,1,)( W: adjacency matrix

D: degree matrix

n

jiji wd

1

L: Laplacian matrix

WDL

𝒇 𝑇 𝐿 𝒇 =12 ∑𝑖 , 𝑗=1

𝑛

𝑤 𝑖𝑗 ( 𝑓 𝑖− 𝑓 𝑗 )2

For every vector

Page 18: Image Matting with  the Matting  Laplacian

Example

2

3

1

4

0 1 1 0 0

1 0 1 0 0

1 1 0 0 0

0 0 0 0 1

0 0 0 1 0

W: adjacency matrix

5

L: Laplacian matrix

Similarity Graph

2 -1 -1 0 0

-1 2 -1 0 0

-1 -1 2 0 0

0 0 0 1 -1

0 0 0 -1 1

𝒇 𝑇 𝐿 𝒇 =12 ∑𝑖 , 𝑗=1

𝑛

𝑤 𝑖𝑗 ( 𝑓 𝑖− 𝑓 𝑗 )2

1

1

1

0

0

Cost Function

𝒇1

1

0

1

0

*2

3

1

4

5

2

3

1

4

5

Good Assignment Poor Assignment

Page 19: Image Matting with  the Matting  Laplacian

Laplacian Eigenvectors

s.t. =1 𝐿 𝒇 =λ 𝒇1. L is symmetric and positive semi-definite.2. The smallest eigenvalue of L is 0, the corresponding

eigenvector is the constant one vector 1.3. L has n non-negative, real-valued eigenvalues 0= λ 1 ≦ λ 2 . . . ≦ ≦ λ n.

: Eigenvector: Eigenvalue

Smallest eigenvectors

Input Image

Page 20: Image Matting with  the Matting  Laplacian

From Eigenvectors to Matting Components

Smallest eigenvectors Projection into eigs space kCTk mEE

....

K-means

..

kCmle

Page 21: Image Matting with  the Matting  Laplacian

Overview of Spectral MattingInput Data

GraphConstruction

Spectral GraphAnalysis

Data ComponentGeneration

Output Components Laplacian Matrix

Input Image Local Adjacency

Components

Page 22: Image Matting with  the Matting  Laplacian

Matting Laplacian

iiiii BFI )1(

LJ T )(

= x+1-α Bα Fx

Page 23: Image Matting with  the Matting  Laplacian

Matting Laplacian

Color Distribution

𝐼 𝑖

𝐼 𝑗 𝜇𝑘

Page 24: Image Matting with  the Matting  Laplacian

Matting LaplacianTypical affinity function Matting affinity function

24

Page 25: Image Matting with  the Matting  Laplacian

Brief Summary

Input Image

Laplacian Matrix

Smallest Eigenvectors Matting Components

K-means Clustering

&Linear

Transformation

Page 26: Image Matting with  the Matting  Laplacian

Supervised Matting

LJ T )(

)()( )( TTLE

otherwise0

011),( iiii

5.001

i

i

i

TrimapInput

Foreground

Background

Unknown

Cost function with user-specified constraint:

Page 27: Image Matting with  the Matting  Laplacian

Supervised Matting

𝜶𝑇 𝐿𝜶=12 ∑𝑖 , 𝑗=1

𝑛

𝑤𝑖𝑗 (𝛼 𝑖−𝛼 𝑗 )2

LJ T )(

)()( )( TTLE

Page 28: Image Matting with  the Matting  Laplacian

Estimation Alpha Matte for Two Layers

Page 29: Image Matting with  the Matting  Laplacian

Estimation Alpha Matte for Multi-Layers

Karusch-Kuhn-Tucker (KKT) condition

Page 30: Image Matting with  the Matting  Laplacian

Assumption Construction

The vector of 1s lies in the null space of L,

the solution automatically satisfies the constraint

Page 31: Image Matting with  the Matting  Laplacian

Constrained Alpha Matte Estimation

Image matting for n≥2 image layers with positivity + summation constraints

Page 32: Image Matting with  the Matting  Laplacian

Karusch-Kuhn-Tucker (KKT) conditions

For 0 < < 1(i,i)=0 and (i,i)=0

Conventional Approaches Directly Clipping

Refinement is neglected in conventional approaches

Equivalent toIntroducing Lagrange Multipliers

Page 33: Image Matting with  the Matting  Laplacian

Experiments

Page 34: Image Matting with  the Matting  Laplacian
Page 35: Image Matting with  the Matting  Laplacian

(a) Algorithm 1. (b) Algorithm 2. (c) Spectral Matting. (d) SM-enhance.

Page 36: Image Matting with  the Matting  Laplacian

(a) Algorithm 1. (b) Algorithm 2. (c) Spectral Matting. (d) SM-enhance.

Page 37: Image Matting with  the Matting  Laplacian
Page 38: Image Matting with  the Matting  Laplacian

Summary

• Image Matting with the Matting Laplacian• Construction of the Matting Laplacian• Image Compositing Model• Local-Color Affine Model

• Supervised Closed-form Matting• Two-layer• Multiple-layer

• Spectral Matting• Extended Applications

Page 39: Image Matting with  the Matting  Laplacian

Depth Estimation

)()( )( TTLEInput Image

Estimated Depth

Refined Result

Compositing ImageLikelihood Prior

L

Confidence Map

Prior

MAP

Page 40: Image Matting with  the Matting  Laplacian

)()( )( TTLE

Input Image Transmission Prior

Refined TransmissionOutput Image

Page 41: Image Matting with  the Matting  Laplacian

Graph Laplacian and Non-linear Filters

GlobalOptima

LocalOptima

Global Optima Local Optima

Gaussian-based Bilateral Filter

Matting-Laplacian-based Guided Filter (K. He, ECCV 2010)