Professional Documents
Culture Documents
Outline
Motivation and Color Fundamentals
Standard Color Models (RGB/CMYK/HSI)
Demosaicing and Color Filtering
Pseudo-color and Full-color Image Processing
Color Transformation
Tone and Color Corrections
Color Image Smoothing, Sharpening, Segmentation,
Edge detection, and Denoising
Assignments
Dr. S. M. Mahbubur Rahman
Motivation
Color is a powerful descriptors that simplifies feature extraction
and object identification from a scene
HVS is sensitive to thousands of color shades or intensities
instead of two dozens of shades of gray
Basics
Color spectrum of visible light has six broad regions, viz.,
Violet, Blue, Green, Yellow, Orange, and Red (ViBGYOR)
Achromatic light is void of color. Chromatic light spans
electromagnetic spectrum from 400 nm to 700 nm.
Radiance is the amount of light energy radiates from light
source in Watts. Luminance is the energy perceives by viewer in
Lumen. Infrared spectrum may have significant radiance but zero
luminance
Brightness is a subjective measure, depends on the
reflectance or absorption characteristics of the observed body
Dr. S. M. Mahbubur Rahman
Color Spectrum
Absorption Characteristics
65% cones
are sensitive to
Red
33% cones
are for Green
2% cones
are for Blue,
but very
sensitive!
Absorption characteristics experimented in 1965.
Dr. S. M. Mahbubur Rahman
Characteristics of Color
Brightness Achromatic notion of intensity.
Hue Dominant wavelength in the mixture of light waves, i.e.,
dominant color perceived by observer, say, Red
Saturation Relative purity or the amount of white light mixed
with a hue. For example, pink (red+white) and lavendar
(violet+white) are saturated. Degree of saturation is inversely
proportional to the amount of white light.
Chromaticity Hue and saturation together is the chromaticity.
Any color is specified a combination of tristimulus values
denotes as X (Red), Y (Green), and Z (Blue)
Dr. S. M. Mahbubur Rahman
Characteristics of Color
A color is thus specified by trichromatic coefficients
X
Y
z
; y=
; z=
x=
X +Y + Z
X +Y + Z
X +Y + Z
x + y + z =1
CIE chromaticity diagram For a given value of x (red) and y
(green), a corresponding value of z=1-(x+y), i.e., blue is obtained
A color is thus specified by trichromatic coefficients
Any triangle inside chromaticity diagram shows all possible
colors which may be obtained mixing only three distinct
wavelength primary electromagnetic waves.
Dr. S. M. Mahbubur Rahman
Chromaticity Diagram
Color Gamuts
CRT Display
Printing
Coordinate
C
M
Y
Dr. S. M. Mahbubur Rahman
1 R
= 1 G
1 B
Conceptual
model in HSI
space
= cos 1
[(R
if
B G
if
B > G
[(R
2
G)
1
2
G ) + (R B
+ (R B
3
Saturation S = 1
(R + G + B
Intensity
Dr. S. M. Mahbubur Rahman
1
(R + G + B
I =
3
)
)
)(G
)]
)] 2
1
[min {R , G , B }]
S cos H
B = I (1 S ); R = I 1 +
; G = 3 I- (R + B
0
cos 60 H
GB Sector
(120
H < 240
H = H 120
S cos H
R = I (1 S ); G = I 1 +
; B = 3 I- (R + G
0
cos 60 H
BR Sector
G =
I (1
S );
(240
H 360
H = H 240
S cos H
B = I 1 +
; R = 3 I- (R + B
0
cos 60 H
(a) (b)
(c) (d)
Image Demosaicing
Demosaicing is a process of obtaining a full color image from
incomplete color samples
A single image sensor associated with the color filter array
(CFA) performs the demosaicing
A digital camera may store the raw data so that user-defined
software for CFA may be chosen instead of built-in firmware.
Problems of image demosaicing includes chromatic aliases,
zippering (abrupt change in intensity), and purple fringing.
Most commonly used CFA for demosaicing is the Bayer
Filter.
Dr. S. M. Mahbubur Rahman
Bayer Filter
Bayer Filter has alternating Red
(R) and Green (G) filters in odd rows
and alternating Blue (B) and Green
(G) filters in the even rows.
Green filters are twice since HVS is
widely sensitive to Green color!
Optical anti-aliasing filter is used
between sensor and lens.
Image
due to
CFA
Original
Dr. S. M. Mahbubur Rahman
Reconstructed
(Adobe)
Functional diagram
Geometric interpretation
Intensity Slicing
Monochrome is
color coded
Two colors
Eight colors
Dr. S. M. Mahbubur Rahman
Intensity Slicing
Monochrome is color coded for SAR images
Pseudo-color Processing
Pseudo-color enhancement by gray level to color transformation
Explosive
detection
Pseudo-color Processing
Two gray level transformation
functions for detection of
explosives in a luggage in a
typical airport
Functional diagram
Pseudo-color Processing
Pseudo-color enhancement
of multispectral images
Pseudo-color Processing
Pseudo-color enhancement
in terms of material deposition,
e.g., sulfur content shown in
yellow for Jupiter moon Io
Full-color Processing
Full-color processing uses independent mask processing of
individual RGB components
Full-color Processing
Color Transformation
General transformation
For RGB or CMY or HSI
For CMYK
Color mapping
HSI
s 3 = kr 3
RGB
s i = kr i
CMY
s i = T i (r1 , r 2 , L , r n
n = 3
n = 4
(0 < k
(0 < k
s i = kr i + (1 k )
< 1 ) s 1 = r1 s 2 = r 2
< 1 ) i = 1, 2 ,3
(0
< k < 1 ) i = 1, 2 ,3
Color Transformation
Intensity
reduction by
33% in three
different color
spaces using
full-color
processing
Color Complements
Hues directly
opposite to color
circle are called
color complements
Complements
are used to
generate color film
negatives
Color Complements
(a) Original image
(b) Transformation
functions for
generating
complements (c)
Resultant image for
RGB space (d)
Resultant image for
HSI space
(a) (b)
(c) (d)
Color Slicing
Selection of a color using a hypercube in a color space
L * a *b *
CIELAB Model
The L * a * b * color components are
Y
16
L * = 116 h
YW
X
h
a * = 500 h
XW
Y
h
b* = 200 h
YW
where
Y
YW
Z
ZW
3 q
h (q ) =
16
7 . 787 q +
116
q > 0 . 008856
q 0 . 008856
CIELAB Model
The X W , YW , ZW
L * a *b *
color space
CIELAB Model
Other features of
L * a *b *
color space
a * for
Tonal Transformation
Tonal or contrast
correction and
corresponding
transformation function in
RGB color space
MiddleKey
HighKey
LowKey
Color Transformation
Color balancing
correction and
corresponding
transformation function in
CMYK color space
Histogram Processing
Histogram equalization
followed by saturation
adjustment in HSI color
space
HSI Components
(a)
(b)
2
g xx g yy
R
G
B
+
g xx =
+
x
x
x
2
R
G
B
g yy =
+
+
y
y
y
R R G G B B
g xy =
+
+
x y x y x y
Individual
gradients of RGB
components
Dr. S. M. Mahbubur Rahman
(a) (b)
(c) (d)
(a) (b)
(c) (d)
(a) (b)
(c) (d)
Assignments
Problem #1
Problem #2
Assignments
Problem #3
Derive the CMY intensity mapping function from its RGB counterpart.
Problem #4