SlideShare a Scribd company logo
1 of 61
Digital Image Processing:
Color Image Processing
Spectrum of White Light
(Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
1666 Sir Isaac Newton, 24 year old, discovered white light spectrum.
Electromagnetic Spectrum
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Visible light wavelength: from around 400 to 700 nm
1. For an achromatic (monochrome) light source,
there is only 1 attribute to describe the quality: intensity
2.For a chromatic light source, there are 3 attributes to describe
the quality:
Radiance = total amount of energy flow from a light source (Watts)
Luminance = amount of energy received by an observer (lumens)
Brightness = intensity
The Eye
Source: Gonzalez/ Woods DIPbook website
(Chapter 2)
Cross section illustration
Two Types of Photoreceptors at Retina
– Mesopic vision
• provided at intermediate illumination by both rod and cones
• Rods
– Long and thin
– Large quantity (~ 100 million)
– Provide scotopic vision (i.e., dim light vision or at low illumination)
– Only extract luminance information and provide a general overall picture
• Cones
– Short and thick, densely packed in fovea (center of retina)
– Much fewer (~ 6.5 million) and less sensitive to light than rods
– Provide photopic vision (i.e., bright light vision or at high illumination)
– Help resolve fine details as each cone is connected to its own nerve end
– Responsible for color vision
our interest
(well-lighted display)
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Sensitivity of Cones in the Human Eye
7millions cones
in a human eye
- 65% sensitive to Red light
- 33% sensitive to Green light
- 2 % sensitive to Blue light
Primary colors:
Defined CIE in 1931
Red = 700 nm
Green = 546.1nm
Blue = 435.8 nm
CIE = Commission Internationale de l’Eclairage
(The International Commission on Illumination)
Luminance vs. Brightness
• Luminance (or intensity)
– Independent of the luminance of surroundings
I(x,y,) -- spatial light distribution
V() -- relative luminous efficiency func. of visual system ~ bell shape
(different for scotopic vs. photopic vision;
highest for green wavelength, second for red, and least for blue )
• Brightness
– Perceived luminance
– Depends on surrounding luminance
Same lum.
Different
brightness
Different lum.
Similar
brightness
Luminance vs. Brightness (cont’d)
• Example: visible digital watermark
– How to make the watermark
appears the same graylevel
all over the image?
Source:from IBM Watson web page “Vatican Digital Library”
Mach Bands
• Visual system tends to undershoot or overshoot around the boundary of regions of different intensities
Demonstrates the perceived brightness is not a function of light intensity
Color of Light
• Perceived color depends on spectral content(wavelength
composition)
– e.g., 700nm ~ red.
– “spectral color”
• A light with very narrow bandwidth
• A light with equal energy in all visible bands appears
white
“Spectrum” from http://www.physics.sfasu.edu/astro/color.html
Primary and Secondary Colors
Primary
color
Primary
color
Primary
color
Secondary
colors
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Primary and Secondary Colors (cont.)
Additive primary colors: RGB
use in the case of light sources
such as color monitors
RGB add together to get white
Subtractive primary colors: CMY
use in the case of pigments in
printing devices
White subtracted by CMY to get
Black
Example: Seeing Yellow Without Yellow
mix green and red light to obtain perception of
yellow, without shining a single yellow photon
520nm 630nm
570nm
=
Hue: dominant color corresponding to a dominant
wavelength of mixture light wave
Relative purity or amount of white light mixed
with a hue (inversely proportional to amount of white
light added)
Intensity
Saturation:
Brightness:
Color Characterization
Hue
Saturation
Chromaticity
amount of red (X), green (Y) and blue (Z) to form any particular
color is called tristimulus.
Perceptual Attributes of Color
• Value of Brightness
(perceived luminance)
• Chrominance
– Hue
• specify color tone (redness, greenness, etc.)
• depend on peak wavelength
– Saturation
• describe how pure the color is
• depend on the spread (bandwidth) of light
spectrum
• reflect how much white light is added
• RGB  HSV Conversion~ nonlinear
HSV circular cone is from online
documentation of Matlab image
processing toolbox
http://www.mathworks.com/access
/helpdesk/help/toolbox/images/col
or10.shtml
(Images from Rafael C. Gonzalez and Richard E.
CIE Chromaticity Diagram
Trichromatic coefficients:
X
X  Y  Z
x 
Y
X  Y  Z
y 
Z
X  Y  Z
Wood, Digital Image Processing, 2nd Edition.
z 
x  y  z 1
x
y
Points on the boundary are
fully saturated colors
CIE Color Coordinates (cont’d)
• CIE XYZ system
– hypothetical primary sources to yield all-positive spectral
tristimulus values
– Y ~ luminance
• Color gamut of 3 primaries
– Colors on line C1 and C2 can be
produced by linear mixture of the two
– Colors inside the triangle gamut
can be reproduced by three primaries
From http://www.cs.rit.edu/~ncs/color/t_chroma.html
RGB Color Model
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Purpose of color models: to facilitate the specification of colors in
some standard
RGB color models:
- based on cartesian
coordinate system
RGB Color Cube
R = 8 bits
G = 8 bits
B = 8 bits
Color depth 24 bits
= 16777216 colors
Hidden faces
of the cube
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
RGB Color Model (cont.)
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Red fixed at 127
Safe RGB Colors
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Safe RGB colors: a subset of RGB colors.
There are 216 colors common in most operating systems.
RGB Safe-color Cube
The RGB Cube is divided into
6 intervals on each axis to achieve
the total 63 = 216 common colors.
However, for 8 bit color
representation, there are the total
256 colors. Therefore, the remaining
40 colors are left to OS.
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
CMY and CMYK Color Models
C = Cyan
M = Magenta
Y = Yellow
K = Black
• Primary colors for pigment
– Defined as one that subtracts/absorbs a
primary color of light & reflects the
other two
• CMY – Cyan, Magenta,Yellow
– Complementary to RGB
– Proper mix of them produces black
Y 
     
1 B
 C  1 R
M   1 G
HSI Color Model
RGB, CMY models are not good for human interpreting
HSI Color model:
Hue: Dominant color
Saturation: Relative purity (inversely proportional
to amount of white light added)
Intensity: Brightness
Color carrying
information
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Intensity
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Example: HSI Components of RGB Cube
Hue Saturation
RGB Cube
Example: HSI Components of RGB Colors
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Hue
Saturation Intensity
RGB
Image
Example: Manipulating HSI Components
Hue
Saturation Intensity
RGB
Image Hue
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Saturation
Intensity RGB
Image
Examples
HSV
YUV
RGB
Examples
RGB
HSV
YIQ
Summary
• Monochrome human vision
– visual properties: luminance vs. brightness, etc.
– image fidelity criteria
• Color
– Color representations and three primarycolors
– Color coordinates
Color Image Processing
There are 2 types of color image processes
1. Pseudocolor image process: Assigning colors to gray
values based on a specific criterion. Gray scale images to be processed
may be a single image or multiple images such as multispectral images
2. Full color image process: The process to manipulate real
color images such as color photographs.
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Pseudocolor Image Processing
Pseudo color = false color : In some case there is no “color” concept
for a gray scale image but we can assign “false” colors to an image.
Why we need to assign colors to gray scale image?
Answer: Human can distinguish different colors better than different
shades of gray.
Intensity Slicing or Density Slicing

C if f (x, y)  T
if f (x, y)  T
g(x, y) 
C2
1
Formula:
C1 = Color No.1
C2 = Color No.2
T
Color
C1
C2
T
Intensity
0 L-1
A gray scale image viewed as a 3D surface.
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Intensity Slicing Example
An X-ray image of a weld with cracks
After assigning a yellow color to pixels with
value 255 and a blue color to all other pixels.
Multi Level Intensity Slicing Example
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
g(x, y)  Ck for lk1  f (x, y)  lk
Ck = Color No.k
lk = Threshold level k
An X-ray image of the Picker
Thyroid Phantom.
After density slicing into 8 colors
Color Coding Example
Color coded image South America region
Gray
Scale
Color
map
Gray-scale image of average
monthly rainfall.
0
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
10
>20
Gray Level to Color Transformation
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Assigning colors to gray levels based on specific mapping functions
Red component
Green component
Blue component
Gray scale image
(Images from Rafael C.
Gonzalez and Richard
E. Wood, Digital Image
Processing, 2nd Edition.
Gray Level to Color Transformation Example
An X-ray image of a
garment bag with a
simulated explosive
device
An X-ray image
of a garment bag
Color
coded
images
Transformations
(Images from Rafael C.
Gonzalez and Richard
E. Wood, Digital Image
Processing, 2nd Edition.
Gray Level to Color Transformation Example
An X-ray image of a
garment bag with a
simulated explosive
device
An X-ray image
of a garment bag
Color
coded
images
Transformations
Pseudocolor Coding Example
Psuedocolor rendition
of Jupiter moon Io
Yellow areas = older sulfur deposits.
Aclose-up
Red areas = material ejected from
active volcanoes.
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Example: Full-Color Image and Various Color Space Components
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Color image
CMYK components
RGB components
HSI components
Color Complements
Color complement replaces each color with its opposite color in the
color circle of the Hue component. This operation is analogous to
image negative in a gray scale image.
Color circle
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Color Complement Transformation Example
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Color Slicing Transformation Example
Original image
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
After color slicing
Tonal Correction Examples
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
In these examples, only
brightness and contrast are
adjusted while keeping color
unchanged.
This can be done by
using the same transformation
for all RGB components.
Contrast enhancement
Power law transformations
Color Balancing Correction Examples
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Color imbalance: primary color components in white area
are not balance. We can measure these components by
using a color spectrometer.
Color balancing can be
performed by adjusting
color components separately
as seen in this slide.
Histogram Equalization of a Full-Color Image
Histogram equalization of a color image can be performed by
adjusting color intensity uniformly while leaving color unchanged.
The HSI model is suitable for histogram equalization where only
Intensity (I) component is equalized.
 
k
k
nj
sk  T(rk )   pr (rj )
j0
j0 N
where r and s are intensity components of input and output color image.
(Images from Rafael C.
Gonzalez and RichardE.
Wood, Digital Image
Processing, 2nd Edition.
Histogram Equalization of a Full-Color Image
Original image
After histogram
equalization
After increasing
saturation component
Color Image Smoothing Example (cont.)
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Color image Red
Green Blue
Color Image Smoothing Example (cont.)
Hue Saturation Intensity
Color image
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
HSI Components
Color Image Smoothing Example (cont.)
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Smooth all RGB components Smooth only I component of HSI
(faster)
Color Image Smoothing Example (cont.)
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Difference between
smoothed results from 2
methods in the previous
slide.
Color Image Sharpening
We can do in the same manner as color image smoothing:
1. Per-color-plane method for RGB,CMY images
2. Sharpening only I component of a HSI image
Sharpening all RGB components Sharpening only I component of HSI
Color Image Sharpening Example (cont.)
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Difference between
sharpened results from 2
methods in the previous
slide.
Gradient of a Color Image
Since gradient is define only for a scalar image, there is no concept
of gradient for a color image. We can’t compute gradient of each
color component and combine the results to get the gradient of a color
image.
Red Green Blue
Edges
We see
4 objects.
We see
2 objects.
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Obtained using
the formula
in the previous
slide
Sum of
gradients of
each color
component
Original
image
2
3
Difference
between
22and 33
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Gradient of a Color Image Example
Gradients of each color component
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Red Green Blue
Gradient of a Color Image Example
Noise in Color Images
Noise can corrupt each color component independently.
(Images from Rafael C.
Gonzalez and RichardE.
Wood, Digital Image
Processing, 2nd Edition.
Noise is less
noticeable
in a color
image
AWGN  =800
2
AWGN  =800
2
AWGN  =800
2
Noise in Color Images
(Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
Hue Saturation Intensity
Color Image Compression
JPEG2000 File
Original image
After lossy compression with ratio 230:1 (Images from Rafael C. Gonzalez and Richard E.
Wood, Digital Image Processing, 2nd Edition.
REFERENCES
Gonzalez, Rafael C. “Digital Image Processing 3rd
Edition”. 2018. Pearson International Edition. pp
416-478

More Related Content

What's hot

Histogram equalization
Histogram equalizationHistogram equalization
Histogram equalization11mr11mahesh
 
Machine learning in image processing
Machine learning in image processingMachine learning in image processing
Machine learning in image processingData Science Thailand
 
Fourier descriptors & moments
Fourier descriptors & momentsFourier descriptors & moments
Fourier descriptors & momentsrajisri2
 
Digital image processing2.pptx
Digital image processing2.pptxDigital image processing2.pptx
Digital image processing2.pptxDivyanshAgarwal78
 
An Introduction to Image Processing and Artificial Intelligence
An Introduction to Image Processing and Artificial IntelligenceAn Introduction to Image Processing and Artificial Intelligence
An Introduction to Image Processing and Artificial IntelligenceWasif Altaf
 
Image enhancement techniques
Image enhancement techniquesImage enhancement techniques
Image enhancement techniquesSaideep
 
Image Processing with OpenCV
Image Processing with OpenCVImage Processing with OpenCV
Image Processing with OpenCVdebayanin
 
Fundamentals and image compression models
Fundamentals and image compression modelsFundamentals and image compression models
Fundamentals and image compression modelslavanya marichamy
 
Image pre processing
Image pre processingImage pre processing
Image pre processingAshish Kumar
 
Image proccessing and its application
Image proccessing and its applicationImage proccessing and its application
Image proccessing and its applicationAshwini Awatare
 

What's hot (20)

Histogram equalization
Histogram equalizationHistogram equalization
Histogram equalization
 
Spatial filtering
Spatial filteringSpatial filtering
Spatial filtering
 
Machine learning in image processing
Machine learning in image processingMachine learning in image processing
Machine learning in image processing
 
Fourier descriptors & moments
Fourier descriptors & momentsFourier descriptors & moments
Fourier descriptors & moments
 
Digital image processing2.pptx
Digital image processing2.pptxDigital image processing2.pptx
Digital image processing2.pptx
 
An Introduction to Image Processing and Artificial Intelligence
An Introduction to Image Processing and Artificial IntelligenceAn Introduction to Image Processing and Artificial Intelligence
An Introduction to Image Processing and Artificial Intelligence
 
Line Detection
Line DetectionLine Detection
Line Detection
 
Image enhancement techniques
Image enhancement techniquesImage enhancement techniques
Image enhancement techniques
 
Image Processing with OpenCV
Image Processing with OpenCVImage Processing with OpenCV
Image Processing with OpenCV
 
Fundamentals and image compression models
Fundamentals and image compression modelsFundamentals and image compression models
Fundamentals and image compression models
 
Image pre processing
Image pre processingImage pre processing
Image pre processing
 
Image enhancement
Image enhancementImage enhancement
Image enhancement
 
Histogram Equalization
Histogram EqualizationHistogram Equalization
Histogram Equalization
 
IMAGE SEGMENTATION.
IMAGE SEGMENTATION.IMAGE SEGMENTATION.
IMAGE SEGMENTATION.
 
DIGITAL IMAGE PROCESSING
DIGITAL IMAGE PROCESSINGDIGITAL IMAGE PROCESSING
DIGITAL IMAGE PROCESSING
 
Image segmentation
Image segmentationImage segmentation
Image segmentation
 
DIP - Image Restoration
DIP - Image RestorationDIP - Image Restoration
DIP - Image Restoration
 
image compression ppt
image compression pptimage compression ppt
image compression ppt
 
Image proccessing and its application
Image proccessing and its applicationImage proccessing and its application
Image proccessing and its application
 
Lect 06
Lect 06 Lect 06
Lect 06
 

Similar to Color-in-Digital-Image-Processing.pptx

06 color image processing
06 color image processing06 color image processing
06 color image processingJaiverdhan .
 
Important features of color image processing
Important features of color image processingImportant features of color image processing
Important features of color image processingdhananjeyanrece
 
Color image processing Presentation
Color image processing PresentationColor image processing Presentation
Color image processing PresentationRevanth Chimmani
 
10 color image processing
10 color image processing10 color image processing
10 color image processingbabak danyal
 
Colour models
Colour modelsColour models
Colour modelsBCET
 
Color image processing
Color image processingColor image processing
Color image processingrmsurya
 
Color image processing.ppt
Color image processing.pptColor image processing.ppt
Color image processing.pptPapajuvvanapudi
 
Color fundamentals and color models - Digital Image Processing
Color fundamentals and color models - Digital Image ProcessingColor fundamentals and color models - Digital Image Processing
Color fundamentals and color models - Digital Image ProcessingAmna
 
Color Image Processing: Basics
Color Image Processing: BasicsColor Image Processing: Basics
Color Image Processing: BasicsA B Shinde
 
Introduction to Color Science for display engineer
Introduction to Color Science for display engineerIntroduction to Color Science for display engineer
Introduction to Color Science for display engineerBrian Kim, PhD
 
Project report_DTRL_subrat
Project report_DTRL_subratProject report_DTRL_subrat
Project report_DTRL_subratSubrat Prasad
 

Similar to Color-in-Digital-Image-Processing.pptx (20)

06 color image processing
06 color image processing06 color image processing
06 color image processing
 
Important features of color image processing
Important features of color image processingImportant features of color image processing
Important features of color image processing
 
Color image processing Presentation
Color image processing PresentationColor image processing Presentation
Color image processing Presentation
 
ch1ip.ppt
ch1ip.pptch1ip.ppt
ch1ip.ppt
 
10 color image processing
10 color image processing10 color image processing
10 color image processing
 
Colormodels
ColormodelsColormodels
Colormodels
 
Colour models
Colour modelsColour models
Colour models
 
Image processing report
Image processing reportImage processing report
Image processing report
 
Chapter02.ppt
Chapter02.pptChapter02.ppt
Chapter02.ppt
 
Color image processing
Color image processingColor image processing
Color image processing
 
Image processing tatorial
Image processing tatorialImage processing tatorial
Image processing tatorial
 
Color image processing.ppt
Color image processing.pptColor image processing.ppt
Color image processing.ppt
 
Color_Spaces.pptx
Color_Spaces.pptxColor_Spaces.pptx
Color_Spaces.pptx
 
Color fundamentals and color models - Digital Image Processing
Color fundamentals and color models - Digital Image ProcessingColor fundamentals and color models - Digital Image Processing
Color fundamentals and color models - Digital Image Processing
 
image-pro.ppt
image-pro.pptimage-pro.ppt
image-pro.ppt
 
Color Image Processing: Basics
Color Image Processing: BasicsColor Image Processing: Basics
Color Image Processing: Basics
 
Chapter01 (2)
Chapter01 (2)Chapter01 (2)
Chapter01 (2)
 
Displays and color system in computer graphics(Computer graphics tutorials)
Displays and color system in computer graphics(Computer graphics tutorials)Displays and color system in computer graphics(Computer graphics tutorials)
Displays and color system in computer graphics(Computer graphics tutorials)
 
Introduction to Color Science for display engineer
Introduction to Color Science for display engineerIntroduction to Color Science for display engineer
Introduction to Color Science for display engineer
 
Project report_DTRL_subrat
Project report_DTRL_subratProject report_DTRL_subrat
Project report_DTRL_subrat
 

Recently uploaded

18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.arsicmarija21
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceSamikshaHamane
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaVirag Sontakke
 
MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxabhijeetpadhi001
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...jaredbarbolino94
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentInMediaRes1
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfUjwalaBharambe
 

Recently uploaded (20)

18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in Pharmacovigilance
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of India
 
MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptx
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media Component
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
 

Color-in-Digital-Image-Processing.pptx

  • 2. Spectrum of White Light (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. 1666 Sir Isaac Newton, 24 year old, discovered white light spectrum.
  • 3. Electromagnetic Spectrum (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Visible light wavelength: from around 400 to 700 nm 1. For an achromatic (monochrome) light source, there is only 1 attribute to describe the quality: intensity 2.For a chromatic light source, there are 3 attributes to describe the quality: Radiance = total amount of energy flow from a light source (Watts) Luminance = amount of energy received by an observer (lumens) Brightness = intensity
  • 4. The Eye Source: Gonzalez/ Woods DIPbook website (Chapter 2) Cross section illustration
  • 5. Two Types of Photoreceptors at Retina – Mesopic vision • provided at intermediate illumination by both rod and cones • Rods – Long and thin – Large quantity (~ 100 million) – Provide scotopic vision (i.e., dim light vision or at low illumination) – Only extract luminance information and provide a general overall picture • Cones – Short and thick, densely packed in fovea (center of retina) – Much fewer (~ 6.5 million) and less sensitive to light than rods – Provide photopic vision (i.e., bright light vision or at high illumination) – Help resolve fine details as each cone is connected to its own nerve end – Responsible for color vision our interest (well-lighted display)
  • 6. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Sensitivity of Cones in the Human Eye 7millions cones in a human eye - 65% sensitive to Red light - 33% sensitive to Green light - 2 % sensitive to Blue light Primary colors: Defined CIE in 1931 Red = 700 nm Green = 546.1nm Blue = 435.8 nm CIE = Commission Internationale de l’Eclairage (The International Commission on Illumination)
  • 7. Luminance vs. Brightness • Luminance (or intensity) – Independent of the luminance of surroundings I(x,y,) -- spatial light distribution V() -- relative luminous efficiency func. of visual system ~ bell shape (different for scotopic vs. photopic vision; highest for green wavelength, second for red, and least for blue ) • Brightness – Perceived luminance – Depends on surrounding luminance Same lum. Different brightness Different lum. Similar brightness
  • 8. Luminance vs. Brightness (cont’d) • Example: visible digital watermark – How to make the watermark appears the same graylevel all over the image? Source:from IBM Watson web page “Vatican Digital Library”
  • 9. Mach Bands • Visual system tends to undershoot or overshoot around the boundary of regions of different intensities Demonstrates the perceived brightness is not a function of light intensity
  • 10. Color of Light • Perceived color depends on spectral content(wavelength composition) – e.g., 700nm ~ red. – “spectral color” • A light with very narrow bandwidth • A light with equal energy in all visible bands appears white “Spectrum” from http://www.physics.sfasu.edu/astro/color.html
  • 11. Primary and Secondary Colors Primary color Primary color Primary color Secondary colors
  • 12. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Primary and Secondary Colors (cont.) Additive primary colors: RGB use in the case of light sources such as color monitors RGB add together to get white Subtractive primary colors: CMY use in the case of pigments in printing devices White subtracted by CMY to get Black
  • 13. Example: Seeing Yellow Without Yellow mix green and red light to obtain perception of yellow, without shining a single yellow photon 520nm 630nm 570nm =
  • 14. Hue: dominant color corresponding to a dominant wavelength of mixture light wave Relative purity or amount of white light mixed with a hue (inversely proportional to amount of white light added) Intensity Saturation: Brightness: Color Characterization Hue Saturation Chromaticity amount of red (X), green (Y) and blue (Z) to form any particular color is called tristimulus.
  • 15. Perceptual Attributes of Color • Value of Brightness (perceived luminance) • Chrominance – Hue • specify color tone (redness, greenness, etc.) • depend on peak wavelength – Saturation • describe how pure the color is • depend on the spread (bandwidth) of light spectrum • reflect how much white light is added • RGB  HSV Conversion~ nonlinear HSV circular cone is from online documentation of Matlab image processing toolbox http://www.mathworks.com/access /helpdesk/help/toolbox/images/col or10.shtml
  • 16. (Images from Rafael C. Gonzalez and Richard E. CIE Chromaticity Diagram Trichromatic coefficients: X X  Y  Z x  Y X  Y  Z y  Z X  Y  Z Wood, Digital Image Processing, 2nd Edition. z  x  y  z 1 x y Points on the boundary are fully saturated colors
  • 17. CIE Color Coordinates (cont’d) • CIE XYZ system – hypothetical primary sources to yield all-positive spectral tristimulus values – Y ~ luminance • Color gamut of 3 primaries – Colors on line C1 and C2 can be produced by linear mixture of the two – Colors inside the triangle gamut can be reproduced by three primaries From http://www.cs.rit.edu/~ncs/color/t_chroma.html
  • 18. RGB Color Model (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Purpose of color models: to facilitate the specification of colors in some standard RGB color models: - based on cartesian coordinate system
  • 19. RGB Color Cube R = 8 bits G = 8 bits B = 8 bits Color depth 24 bits = 16777216 colors Hidden faces of the cube (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 20. RGB Color Model (cont.) (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Red fixed at 127
  • 21. Safe RGB Colors (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Safe RGB colors: a subset of RGB colors. There are 216 colors common in most operating systems.
  • 22. RGB Safe-color Cube The RGB Cube is divided into 6 intervals on each axis to achieve the total 63 = 216 common colors. However, for 8 bit color representation, there are the total 256 colors. Therefore, the remaining 40 colors are left to OS. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 23. CMY and CMYK Color Models C = Cyan M = Magenta Y = Yellow K = Black • Primary colors for pigment – Defined as one that subtracts/absorbs a primary color of light & reflects the other two • CMY – Cyan, Magenta,Yellow – Complementary to RGB – Proper mix of them produces black Y        1 B  C  1 R M   1 G
  • 24. HSI Color Model RGB, CMY models are not good for human interpreting HSI Color model: Hue: Dominant color Saturation: Relative purity (inversely proportional to amount of white light added) Intensity: Brightness Color carrying information (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 25. Intensity (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Example: HSI Components of RGB Cube Hue Saturation RGB Cube
  • 26. Example: HSI Components of RGB Colors (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Hue Saturation Intensity RGB Image
  • 27. Example: Manipulating HSI Components Hue Saturation Intensity RGB Image Hue (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Saturation Intensity RGB Image
  • 30. Summary • Monochrome human vision – visual properties: luminance vs. brightness, etc. – image fidelity criteria • Color – Color representations and three primarycolors – Color coordinates
  • 31. Color Image Processing There are 2 types of color image processes 1. Pseudocolor image process: Assigning colors to gray values based on a specific criterion. Gray scale images to be processed may be a single image or multiple images such as multispectral images 2. Full color image process: The process to manipulate real color images such as color photographs.
  • 32. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Pseudocolor Image Processing Pseudo color = false color : In some case there is no “color” concept for a gray scale image but we can assign “false” colors to an image. Why we need to assign colors to gray scale image? Answer: Human can distinguish different colors better than different shades of gray.
  • 33. Intensity Slicing or Density Slicing  C if f (x, y)  T if f (x, y)  T g(x, y)  C2 1 Formula: C1 = Color No.1 C2 = Color No.2 T Color C1 C2 T Intensity 0 L-1 A gray scale image viewed as a 3D surface.
  • 34. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Intensity Slicing Example An X-ray image of a weld with cracks After assigning a yellow color to pixels with value 255 and a blue color to all other pixels.
  • 35. Multi Level Intensity Slicing Example (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. g(x, y)  Ck for lk1  f (x, y)  lk Ck = Color No.k lk = Threshold level k An X-ray image of the Picker Thyroid Phantom. After density slicing into 8 colors
  • 36. Color Coding Example Color coded image South America region Gray Scale Color map Gray-scale image of average monthly rainfall. 0 (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. 10 >20
  • 37. Gray Level to Color Transformation (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Assigning colors to gray levels based on specific mapping functions Red component Green component Blue component Gray scale image
  • 38. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Gray Level to Color Transformation Example An X-ray image of a garment bag with a simulated explosive device An X-ray image of a garment bag Color coded images Transformations
  • 39. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Gray Level to Color Transformation Example An X-ray image of a garment bag with a simulated explosive device An X-ray image of a garment bag Color coded images Transformations
  • 40. Pseudocolor Coding Example Psuedocolor rendition of Jupiter moon Io Yellow areas = older sulfur deposits. Aclose-up Red areas = material ejected from active volcanoes. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 41. Example: Full-Color Image and Various Color Space Components (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Color image CMYK components RGB components HSI components
  • 42. Color Complements Color complement replaces each color with its opposite color in the color circle of the Hue component. This operation is analogous to image negative in a gray scale image. Color circle (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 43. Color Complement Transformation Example (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 44. Color Slicing Transformation Example Original image (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. After color slicing
  • 45. Tonal Correction Examples (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. In these examples, only brightness and contrast are adjusted while keeping color unchanged. This can be done by using the same transformation for all RGB components. Contrast enhancement Power law transformations
  • 46. Color Balancing Correction Examples (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Color imbalance: primary color components in white area are not balance. We can measure these components by using a color spectrometer. Color balancing can be performed by adjusting color components separately as seen in this slide.
  • 47. Histogram Equalization of a Full-Color Image Histogram equalization of a color image can be performed by adjusting color intensity uniformly while leaving color unchanged. The HSI model is suitable for histogram equalization where only Intensity (I) component is equalized.   k k nj sk  T(rk )   pr (rj ) j0 j0 N where r and s are intensity components of input and output color image.
  • 48. (Images from Rafael C. Gonzalez and RichardE. Wood, Digital Image Processing, 2nd Edition. Histogram Equalization of a Full-Color Image Original image After histogram equalization After increasing saturation component
  • 49. Color Image Smoothing Example (cont.) (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Color image Red Green Blue
  • 50. Color Image Smoothing Example (cont.) Hue Saturation Intensity Color image (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. HSI Components
  • 51. Color Image Smoothing Example (cont.) (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Smooth all RGB components Smooth only I component of HSI (faster)
  • 52. Color Image Smoothing Example (cont.) (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Difference between smoothed results from 2 methods in the previous slide.
  • 53. Color Image Sharpening We can do in the same manner as color image smoothing: 1. Per-color-plane method for RGB,CMY images 2. Sharpening only I component of a HSI image Sharpening all RGB components Sharpening only I component of HSI
  • 54. Color Image Sharpening Example (cont.) (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Difference between sharpened results from 2 methods in the previous slide.
  • 55. Gradient of a Color Image Since gradient is define only for a scalar image, there is no concept of gradient for a color image. We can’t compute gradient of each color component and combine the results to get the gradient of a color image. Red Green Blue Edges We see 4 objects. We see 2 objects. (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 56. Obtained using the formula in the previous slide Sum of gradients of each color component Original image 2 3 Difference between 22and 33 (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Gradient of a Color Image Example
  • 57. Gradients of each color component (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Red Green Blue Gradient of a Color Image Example
  • 58. Noise in Color Images Noise can corrupt each color component independently. (Images from Rafael C. Gonzalez and RichardE. Wood, Digital Image Processing, 2nd Edition. Noise is less noticeable in a color image AWGN  =800 2 AWGN  =800 2 AWGN  =800 2
  • 59. Noise in Color Images (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition. Hue Saturation Intensity
  • 60. Color Image Compression JPEG2000 File Original image After lossy compression with ratio 230:1 (Images from Rafael C. Gonzalez and Richard E. Wood, Digital Image Processing, 2nd Edition.
  • 61. REFERENCES Gonzalez, Rafael C. “Digital Image Processing 3rd Edition”. 2018. Pearson International Edition. pp 416-478