85
Contrast Preserving Decolorization Cewu Lu, Li Xu, Jiaya Jia, The Chinese University of Hong Kong

Contrast Preserving Decolorization

  • Upload
    dean

  • View
    54

  • Download
    0

Embed Size (px)

DESCRIPTION

Contrast Preserving Decolorization. Cewu Lu, Li Xu , Jiaya Jia , The Chinese University of Hong Kong . Mono printers are still the majority. Fast Economic Environmental friendly. Documents generally have color figures. The printing problem. The printing problem. - PowerPoint PPT Presentation

Citation preview

Page 1: Contrast Preserving  Decolorization

Contrast Preserving Decolorization

Cewu Lu, Li Xu, Jiaya Jia, The Chinese University of Hong Kong

Page 2: Contrast Preserving  Decolorization

Mono printers are still the majority

• Fast• Economic• Environmental friendly

Page 3: Contrast Preserving  Decolorization

Documents generally have color figures

Page 4: Contrast Preserving  Decolorization

The printing problem

Page 5: Contrast Preserving  Decolorization

The printing problem

Page 6: Contrast Preserving  Decolorization

The printing problem

Page 7: Contrast Preserving  Decolorization

The printing problem

Page 8: Contrast Preserving  Decolorization

HP printer

The printing problem

Page 9: Contrast Preserving  Decolorization

Our Result

The printing problem

Page 10: Contrast Preserving  Decolorization

Decolorization

Mapping

Single Channel

Page 11: Contrast Preserving  Decolorization

Applications

Color Blindness

Page 12: Contrast Preserving  Decolorization

Applications

Color Blindness

Page 13: Contrast Preserving  Decolorization

Decolorization could lose contrast Mapping( )

Mapping( ) =

=

Page 14: Contrast Preserving  Decolorization

Mapping

Decolorization could lose contrast

Page 15: Contrast Preserving  Decolorization

• Bala and Eschbach 2004

• Neumann et al. 2007

• Smith et al. 2008

Pervious Work (Local methods)

Page 16: Contrast Preserving  Decolorization

Pervious Work (Local methods)

Naive Mapping

Color Contrast

Result

Page 17: Contrast Preserving  Decolorization

• Gooch et al. 2004

• Rasche et al. 2005

• Kim et al. 2009

Pervious Work (Global methods)

Page 18: Contrast Preserving  Decolorization

Pervious Work (Global methods)

Color feature preserving optimization mapping function

( )g f c

Page 19: Contrast Preserving  Decolorization

Pervious Work (Global methods)

In most global methods, color order is strictly satisfied

( )g f c

Page 20: Contrast Preserving  Decolorization

Color order could be ambiguous

Can you tell the order?

Page 21: Contrast Preserving  Decolorization

brightness( ) < brightness ( ) YUV space

Lightness( ) > Lightness ( ) LAB space

Color order could be ambiguous

Page 22: Contrast Preserving  Decolorization

People with different culture and language background have different senses of brightness with respect to color.

E. Ozgen et al., Current Directions in Psychological Science, 2004

K. Zhou et al., National Academy of Sciences, 2010

The order of different colors cannot be defined uniquely by people

B. Wong et al., Nature Methods, 2010

Color order could be ambiguous

Page 23: Contrast Preserving  Decolorization

If we enforce the color order constraint, contrast loss could happen

Input Ours[Rasche et al. 2005] [Kim et al. 2009]

Color order could be ambiguous

Page 24: Contrast Preserving  Decolorization

Our Contribution

Weak Color Order

Bimodal Contrast-PreservingRelax the color order constraint

Unambiguous color pairs

Global Mapping Polynomial Mapping

Page 25: Contrast Preserving  Decolorization

The Framework

• Objective Function Bimodal Contrast-Preserving Weak Color Order

• Finite Multivariate Polynomial Mapping Function

• Numerical Solution

Page 26: Contrast Preserving  Decolorization

Bimodal Contrast-Preserving

• Color pixel , grayscale contrast , color contrast (CIELab distance) • follows a Gaussian distribution with mean

{ , }x y xy x yg g g

xyg xy

xy

2

22, exp

2xy xy

xy

gG

Page 27: Contrast Preserving  Decolorization

Bimodal Contrast-Preserving

• Color pixel , grayscale contrast , color contrast (CIELab distance) • follows a Gaussian distribution with mean .

{ , }x y xy x yg g g

xyg xy

xy

2

22, exp

2xy xy

xy

gG

xy xyg

Page 28: Contrast Preserving  Decolorization

Bimodal Contrast-Preserving

• Tradition methods (order preserving):

2

( , )

max sign( , ) ,xyg x y N

G x y

N : neighborhood pixel set

• Our bimodal contrast-preserving for ambiguous color pairs:

2 2

( , )

max , ,xy xyg x y N

G G

Page 29: Contrast Preserving  Decolorization

Bimodal Contrast-Preserving

2

( , )

max sign( , ) ,xyg x y N

G x y

2 2

( , )

max , ,xy xyg x y N

G G

xyxy

xy xyg

xyg

sign(x,y) 1=

Page 30: Contrast Preserving  Decolorization

Bimodal Contrast-Preserving

2

( , )

max sign( , ) ,xyg x y N

G x y

2 2

( , )

max , ,xy xyg x y N

G G

xyxy

xyg

xyg

xy

sign(x,y) 1=

Page 31: Contrast Preserving  Decolorization

Our Work

• Objective Function Bimodal Contrast-Preserving Weak Color Order

• Finite Multivariate Polynomial Mapping Function

• Numerical Solution

Page 32: Contrast Preserving  Decolorization

Weak Color Order

• Unambiguous color pairs: or & &x y x y x yr r g g b b & &x y x y x yr r g g b b

Page 33: Contrast Preserving  Decolorization

Weak Color Order

• Unambiguous color pairs: or & &x y x y x yr r g g b b & &x y x y x yr r g g b b

,

1.0 unambiguous color pair

0.5 ambiguous color pairx y

• Our model thus becomes

2 2, ,

( , )

max , 1 ,x y xy x y xyg x y N

G G

Page 34: Contrast Preserving  Decolorization

Our Work

• Objective Function Bimodal Contrast-Preserving Weak Color Order

• Finite Multivariate Polynomial Mapping Function

• Numerical Solution

Page 35: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

2 2, ,

( , )

max , 1 ,x y xy x y xyg x y N

G G

Solve for grayscale image: g

Variables (pixels): 400x250 = 100,000

ExampleToo many (easily produce unnatural structures)

Page 36: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

2 2, ,

( , )

max , 1 ,x y xy x y xyg x y N

G G

• Parametric global color-to-grayscale mapping

grayscale value (color vector, )f

Small Scale

Page 37: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

31 21 2 3span{ : =0, 1, 2, ... n}dd d

n ir g b d d d d

• Parametric color-to-grayscale( , ) i i

i

f c m n

When n = 2, a grayscale is a linear combination of elements

imthiis the monomial basis of , .

2 2 2{ , , , , , , , , }r g b rg gb rb r g b

{ , , }c r g b

Page 38: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

Page 39: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

gbrbrg

bgr

Page 40: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

gbrbrg

bg

Page 41: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

gbrbrg

b

Page 42: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

gbrbrg

Page 43: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

gbrb

Page 44: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

gb

Page 45: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g2r

Page 46: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b2g

Page 47: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

2b

Page 48: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

Page 49: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

0.1550 0.8835 0.3693

0.1817 0.4977 -1.7275

-0.4479 0.6417 0.6234

Page 50: Contrast Preserving  Decolorization

Multivariate Polynomial Mapping Function

• Parametric color-to-grayscale( , ) i i

i

f c m

0.1550 0.8835 0.3693

0.1817 0.4977 -1.7275

-0.4479 0.6417 0.6234

Page 51: Contrast Preserving  Decolorization

Our Model

, ,xy x y x y i ix iyi

g g g f c f c m m

• Objective function:

2 2, ,

( , )

max , 1 ,x y xy x y xyx y N

G G

Page 52: Contrast Preserving  Decolorization

Numerical Solution

2 2, ,

( , )

max , 1 ,x y xy x y xyx y N

G G

2 2, ,

( , )

min In , 1 ,x y xy x y xyx y N

G G

2 2, ,

( , )

In , 1 ,x y xy x y xyx y N

E G G

Define:

Page 53: Contrast Preserving  Decolorization

Numerical Solution

0

E

2, ,

, 2 2, , , ,

,

, 1 ,x y x y

x yx y x y x y x y

G

G G

min E

, ,( , )

1 2 0i xi yi xj yj x y xj yj x yx y N ij

Em m m m m m

Page 54: Contrast Preserving  Decolorization

Numerical Solution

, ,( , )

2 1i xi yi xj yj x y xj yj x yx y N i

m m m m m m

Initialize :

Page 55: Contrast Preserving  Decolorization

Numerical Solution

2, ,

, 2 2, , , ,

,

, 1 ,x y x y

x yx y x y x y x y

G

G G

, ,( , )

2 1i xi yi xj yj x y xj yj x yx y N i

m m m m m m

obtain

Page 56: Contrast Preserving  Decolorization

Numerical Solution

2, ,

, 2 2, , , ,

,

, 1 ,x y x y

x yx y x y x y x y

G

G G

, ,( , )

2 1i xi yi xj yj x y xj yj x yx y N i

m m m m m m

obtainobtain ,x y

Page 57: Contrast Preserving  Decolorization

Numerical Solution

2, ,

, 2 2, , , ,

,

, 1 ,x y x y

x yx y x y x y x y

G

G G

, ,( , )

2 1i xi yi xj yj x y xj yj x yx y N i

m m m m m m

obtainobtain ,x y

Page 58: Contrast Preserving  Decolorization

Numerical Solution

2, ,

, 2 2, , , ,

,

, 1 ,x y x y

x yx y x y x y x y

G

G G

, ,( , )

2 1i xi yi xj yj x y xj yj x yx y N i

m m m m m m

obtainobtain ,x y

Page 59: Contrast Preserving  Decolorization

Numerical Solution

2, ,

, 2 2, , , ,

,

, 1 ,x y x y

x yx y x y x y x y

G

G G

, ,( , )

2 1i xi yi xj yj x y xj yj x yx y N i

m m m m m m

obtainobtain ,x y

Page 60: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 1

0.33 0.33 0.33 0.00 0.00 0.00 0.00 0.00 0.00

Page 61: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 2

0.97 0.91 0.38 -3.71 2.46 -4.01 -4.02 4.00 0.79

Page 62: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 3

1.14 -0.25 1.22 -1.55 -1.53 -3.51 -1.18 3.32 0.69

Page 63: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 4

1.33 -1.61 2.10 1.35 -0.36 -1.61 -1.69 1.70 0.29

Page 64: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 5

1.52 -2.25 2.46 2.69 -1.38 -0.30 -1.95 0.79 -0.02

Page 65: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 13

1.98 -3.29 3.02 5.94 -3.38 2.81 -2.91 -1.56 -0.96

Page 66: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 14

1.99 -3.31 3.03 6.03 -3.42 2.89 -2.95 -1.62 -0.98

Page 67: Contrast Preserving  Decolorization

Numerical Solution (Example)

2 2 2                                r g b rg rb gb r g bIter 15

2.00 -3.32 3.04 6.10 -3.45 2.94 -2.98 -1.67 -1.00

Page 68: Contrast Preserving  Decolorization

Results

Input Ours [Rasche et al. 2005] [Kim et al. 2009]

Page 69: Contrast Preserving  Decolorization

Results

Input Ours [Rasche et al. 2005] [Kim et al. 2009]

Page 70: Contrast Preserving  Decolorization

Results

Input Ours [Rasche et al. 2005] [Kim et al. 2009]

Page 71: Contrast Preserving  Decolorization

Results

Input Ours [Rasche et al. 2005] [Kim et al. 2009]

Page 72: Contrast Preserving  Decolorization

Results (Quantitative Evaluation)

• color contrast preserving ratio (CCPR)

# ( , ) | ( , ) ,| |CCPR=

| |x yx y x y g g

the set containing all neighboring pixel pairs with the original color difference .

,x y

Page 73: Contrast Preserving  Decolorization

Results (Quantitative Evaluation)

10

Page 74: Contrast Preserving  Decolorization

Our Results (Quantitative Evaluation)

10

,x y

Page 75: Contrast Preserving  Decolorization

Results (Quantitative Evaluation)

10

,x y , ,&x y x yg

Page 76: Contrast Preserving  Decolorization

Results (Quantitative Evaluation)

10

,x y , ,&x y x yg

Number: 38740 Number: 24853

Page 77: Contrast Preserving  Decolorization

Results (Quantitative Evaluation)

Number: 38740 Number: 24853

24853CCPR= 64.2%38740

Page 78: Contrast Preserving  Decolorization

Results (Quantitative Evaluation)

Page 79: Contrast Preserving  Decolorization

Results (contrast boosting)

substituting our grayscale image for the L channel in the Lab space

Page 80: Contrast Preserving  Decolorization

Results (contrast boosting)

substituting our grayscale image for the L channel in the Lab space

Page 81: Contrast Preserving  Decolorization

Conclusion

• A new color-to-grayscale method that can well maintain the color contrast.

• Weak color constraint.

• Polynomial Mapping Function for global mapping.

Page 82: Contrast Preserving  Decolorization

The End

Page 83: Contrast Preserving  Decolorization

Limitations

• Color2gray is very subjective visual experience. Contrast enhancement may not be acceptable for everyone.

• Compared to the naive color2grayscale mapping, our method is less efficient due to the extra operations.

Page 84: Contrast Preserving  Decolorization

An arguable result

Page 85: Contrast Preserving  Decolorization

Running Time

• For a 600 × 600 color input, our Matlab implementation takes 0.8s

• A C-language implementation can be 10 times faster at least.