Module 4-1
Module 4-1
Frequency Domain
2 b ck to b ck h lf
periods meeting t
point M/2
x
Multiply f(x) by (−1)
−1
g(x, y) = [H(u, v)F(u, v)]
−1
Where is the IDFT
The ilter function H
F(u, v) is the DFT of input im ge f(x, y)
modi ies the tr nsform of
the input im ge resulting H(u, v) is ilter tr nsfer function
in processed output g
g(x, y) is the iltered output (im ge)
F, H nd g re m trix of size M x N
𝔉
𝔉
f
a
f
a
a
a
a
a
a
a
a
f
a
f
f
a
a
a
a
a
a
a
f
a
a
a
• One of the simplest ilters we c n construct is ilter H(u, v) th t is 0 t
the center of the tr nsform nd 1 elsewhere.
1. Given n input im ge f(x, y) of size M x N, obt in the p dding p r meters P nd Q. (Typic lly
P = 2M nd Q = 2N )
2. Form p dded im ge, fp(x, y) of size P x Q by ppending the necess ry number of zeros to f(x, y)
x+y
3. Multiply fp(x, y) by (−1) to center its tr nsform
−1 x+y
6. Obt in the processed im ge : gp(x, y) = {real[ [G(u, v)]]}(−1)
fi
Im ge smoothing using Frequency dom in ilters
1. Ide l
2. Butterworth
3. G ussi n
Where
a
a
a
a
a
a
a
If the DFT h s been centered, circle of r dius D0 with origin t the center
of the frequency rect ngle encloses α percent of the power, where
Summ tion is t ken over v lues of (u, v) th t lie inside the circle or on
its bound ry
a
a
a
a
a
a
a
a
a
a
Spectrum f lls o
r pidly, with 87 %
of the tot l power
being enclosed by
rel tively sm ll
circle of r dio 10
a
a
a
a
a
a
a
ff
2. Butterworth Lowp ss ilter
Where D(u, v) is the dist nce from center of the frequency rect ngle.
If σ = D0,
a
a
a
a
a
a
a
f
a
a
a
a
a
Im ge sh rpening using Frequency Dom in ilters
A highp ss ilter is obt ined from given lowp ss ilter using the equ tion
a
2. G ussi n Highp ss Filters
a
a
a
The L pl ci n in Frequency Dom in
The l pl ci n c n be implemented in frequency dom in using the ilter
a
a
a
f
The function f(x, y) is ch r cterised by two components:
f
Where Fi(u, v) nd Fr(u, v) re the Fourier tr nsform of ln i(x, y) nd
ln r(x, y), respectively
• Green objects re lect light with w velengths prim rily in the 500 to
570nm r nge while bsorbing most of the energy t other w velengths.
a
a
a
f
a
f
a
a
a
a
a
a
a
• Chrom tic light sp ns electrom gnetic spectrum from pproxim tely
400nm to 700nm.
1. R di nce
2. lumin nce
3. Brightness
a
a
a
a
a
a
a
a
a
a
a
a
a
a
1. R di nce is the tot l mount of energy th t lows from the light source.
— 2% re sensitive to blue
a
a
a
a
a
a
a
a
a
a
a
a
a
No single color m y be
c lled s red, green or blue.
Experiment l curves det iling the bsorption of light by red, green nd blue
cones in the eye.
a
a
a
a
a
a
a
W velength ssigned to prim ry colours
M gent (r+b)
cy n (g+b)
Yellow (r+g)
a
a
a
a
a
a
a
a
a
brightness, hue, nd s tur tion
S tur tion - rel tive purity or mount of white light mixed with hue.
• A color is then speci ied by its trichrom tic coe icients, de ines s
Also, x+y+z=1
a
f
a
a
a
a
a
a
ff
a
a
a
f
a
a
• Another ppro ch for specifying colours is to use CIE chrom ticity
di gr m (shows color composition s function of x (red) nd y (green)).
The term full-colour im ge is used often to denote 24-bit RGB color im ge.
8 3
The tot l number of colours in 24-bit RGB im ge is (2 ) = 16,777,216.
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
• The di erent colors in this model re points on or inside the cube
000000 = Black
FFFFFF = white
FF0000 = pure red and so on…
a
a
a
a
a
a
a
a
a
FFFFFF FFCCFF FF99FF FF66FF FF33FF FF00FF
• Sep r ting intensity from color inform tion (hue nd s tur tion) llows for
better m nipul tion of brightness nd color independently.
a
a
a
a
a
a
a
a
a
a
a
a
Magenta (r+b), cyan(g+b), Yellow (r+g)
Converting colors from RGB to HSI
Denomin tor is the norm liz tion f ctor, ensuring th t the ngle
we get from cos inverse is geometric lly v lid
a
a
a
a
a
a
a
a
Converting colors from HSI to RGB
Given v lues HSI in the interv l [0, 1], we now w nt to ind corresponding
RGB v lues in the s me r nge.
0 0
1. RG sector (0 ≤ H < 120 )
0 0
2. GB sector (120 ≤ H < 240 )
0 0
3.BR sector (240 ≤ H < 360 )
a
a
a
a
a
a
a
a
f
0 0
1. RG sector (0 ≤ H < 120 )
0 0
2. GB sector (120 ≤ H < 240 )
0 0
BR sector (240 ≤ H < 360 )
Pseudocolor Im ge Processing
1. Intensity slicing
th
Where ck is the color ssoci ted with the k intensity interv l Vk
de ined by the p rtitioning pl nes.
f
a
a
a
a
f
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
When more levels re used, the m pping function t kes on st irc se form
a
a
a
a
a
a
Intensity to Color Tr nsform tion
• The three results re th n fed sep r tely into the red, green, nd blue
ch nnels of color television monitor.
a
a
a
a
a
a
a
a
a
a
a
a
a
a
a
Coding which involves sever l monochrome im ges