SlideShare ist ein Scribd-Unternehmen logo
1 von 56
Downloaden Sie, um offline zu lesen
2
Fourier Analysis and
Image Processing
• History
• Periodic Signals
• Fourier Analysis
– Fourier Series
– Fourier Transform
– Discrete Fourier Transform (DFT)
– Fast Fourier Transform (FFT)
• 2D FFT and Image Processing
– Spatial Frequency in Images
– 2D Discrete Fourier Transform
– 2D FFT Examples
– Applications of FFTs in Image Processing
• Summary
3
History
Jean Baptiste Joseph Fourier
1768-1830
French Mathematician and Physicist
http://de.wikipedia.org/wiki/Kreiszahl
Outlined technique in memoir, On the Propagation of Heat in Solid Bodies, which was
read to Paris Institute on 21 Dec 1807. Controversial then: Laplace and Lagrange
objected to what is now Fourier series: “... his analysis ... leaves something to be desired on
the score of generality and even rigour...” (from report awarding Fourier math prize in 1811)
In La Theorie Analytique de la Chaleur (Analytic Theory of Heat) (1822) Fourier
• developed the theory of the series known by his name, and
• applied it to the solution of boundary-value problems in partial differential equations.
Sources:
www.me.utexas.edu/~me339/Bios/fourier.html and www-gap.dcs.st-and.ac.uk/~history/Biographies/Fourier.html
4
Periodic Signals
A continuous-time signal x(t) is periodic if:
x(t + T) = x(t)
Fundamental period, T0, of x(t) is smallest T satisfying
above equation.
Fundamental frequency: f0 = 1/T0
Fundamental angular frequency: ω0 = 2π/T0 = 2πf0
5
Periodic Signals
x(t + T) = x(t)
Harmonics: Integer multiples of frequency of wave
-1.0
0.0
1.0
t
sin
(
t
)
0 π 2 π 3π 2 2π 3π 4π
-1.0
0.0
1.0
t
sin
(
4t
)
0 π 2 π 3π 2 2π 3π 4π
T0
Fundamental
frequency:
f0 = 1/T0
6
Periodic Signals
Biological time series can be quite complex, and will contain noise.
x(t + T) = x(t)
-2
-1
0
1
2
t
x(t)
0 π 2 π 3π 2 2π 3π 4π
“Biological” Time Series
T0
8
Fourier Analysis
• Fourier Series
Expansion of continuous function into weighted sum of sines and
cosines, or weighted sum of complex exponentials.
• Fourier Transform
Maps one function to another: continuous-to-continuous mapping.
An integral transform.
• Discrete Fourier Transform (DFT)
Approximation to Fourier integral. Maps discrete vector to another
discrete vector. Can be viewed as a matrix operator.
• Fast Fourier Transform (FFT)
Special computational algorithm for DFT.
9
Fourier Series
www.science.org.au/nova/029/029img/wave1.gif
Trigonometric Fourier Series
Expansion of continuous function into weighted sum of sines and cosines.
[ ]
∑
∞
=
⋅
+
⋅
+
=
1
0
0
0
)
(
sin
)
(
cos
2
)
(
k
k
k t
k
t
k
t
x b
a
a ω
ω
∫ ⋅
=
T
dt
t
k
t
x
T
ak
0
)
cos(
)
(
2
0
0
ω
∫ ⋅
=
T
dt
t
k
t
x
T
bk
0
)
sin(
)
(
2
0
0
ω
f
T 0
0
0
2
2
π
π
ω =
=
If x(t) is even, i.e., x(-t) = x(t) like cosine, then bk = 0.
If x(t) is odd, i.e., x(-t) = -x(t) like sine, then ak = 0.
Source: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 211-213
10
Complex Math Review
Solutions to x2 = -1:
Complex Plane
Euler’s Formula:
Operators: +, -, *, /
u + v = (a + ib) + (c + id) = (a + c) + i(b + d)
u × v = (a + ib) (c + id) = (ac – bd) + i(ad + bc)
DeMoivre’s Theorem:
u* = a - ib
11
Fourier Series
f
T 0
0
0
2
2
π
π
ω =
=
Source Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 211-213
∑
∞
−∞
=
⋅
⋅
⋅
=
k
t
k
i
k e
c
t
x
ω0
)
(
∫
⋅
⋅
⋅
−
⋅
=
T
dt
t
x e
T
c
t
k
i
k
0
0
)
(
1
0
ω
Notes:
• If x(t) is real, c-k = ck
*.
• For k = 0, ck = average value of x(t) over one period.
• a0/2 = c0; ak = ck + c-k; bk = i · (ck - c-k)
Complex Exponential Fourier Series
Expansion of continuous function into weighted sum of complex exponentials.
12
Source: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 211-213
Fourier Series
Complex Exponential Fourier Series
Coefficients can be written as product:
e
c
c k
i
k
k
φ
⋅
=
• ck are known as the spectral coefficients of x(t)
• Plot of |ck| versus angular frequency ω is the amplitude spectrum.
• Plot of φkversus angular frequency is the phase spectrum.
• With discrete Fourier frequencies, k·ω0, both are discrete spectra.
13
Fourier Series
selected
Approximate any function as truncated Fourier series
Given: x(t) = t
Fourier Series:






−
+
−
= ...
3
3
sin
2
2
sin
sin
2
)
(
t
t
t
t
x






−
+
−
= ...
3
3
sin
2
2
sin
sin
2
)
(
t
t
t
t
x
0.0 0.2 0.4 0.6 0.8 1.0
0.0
0.2
0.4
0.6
0.8
1.0
t
x(t)
14
Fourier Series
selected
Approximate any function as truncated Fourier series
Given: x(t) = t Fourier Series:






−
+
−
= ...
3
3
sin
2
2
sin
sin
2
)
(
t
t
t
t
x






−
+
−
= ...
3
3
sin
2
2
sin
sin
2
)
(
t
t
t
t
x
-1.0
-0.5
0.0
0.5
1.0
1.5
2.0
Fourier Terms in Expansion of x(t) = t
t
Fourier
Terms
0 π 4 π 2 3π 4 π
1
2
3
4
5 6
Fourier Series Approximation
t
x(t)
First Six Series Terms
0 π 4 π 2 3π 4 π
0
1
2
3
15
Fourier Series
selected
Approximate any function as truncated Fourier series
Given: x(t) = t Fourier Series:






−
+
−
= ...
3
3
sin
2
2
sin
sin
2
)
(
t
t
t
t
x






−
+
−
= ...
3
3
sin
2
2
sin
sin
2
)
(
t
t
t
t
x
Fourier Series Approximation
t
x(t)
0 π 4 π 2 3π 4 π
0
1
2
3
100 terms
200 terms
16
Fourier Series
Periodogram
Decomposition
Time Series
Reconstruction
Filtered Series
Remove
High Frequency
Component
0
selected
“Remove” high frequency noise by zeroing a term in series expansion
Noise Removal
17
Fourier Transform
Maps one function to another: continuous-to-continuous mapping.
Fourier transform of x(t) is X(ω):
(converts from time space to frequency space)
∫
∞
∞
−
−
⋅
=
= dt
t
x
t
x
X e
t
iω
ω )
(
)}
(
{
)
( F
Fourier inverse transform of X(ω) recovers x(t):
(converts from frequency space to time space)
∫
∞
∞
−
⋅
=
= ω
ω
π
ω
ω
d
X
X
t
x e
t
i
)
(
2
1
)}
(
{
)
( F
1
-
The Fourier Transform is a special case of the Laplace Transform, s = i ·ω
x(t) and X(ω) form a Fourier transform pair: x(t) ↔ X(ω)
Source: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 214-218
Time Domain and Frequency
Domain
 Time Domain:
 Tells us how properties (air pressure in a sound function,
for example) change over time:
 Amplitude = 100
 Frequency = number of cycles in one second = 200 Hz
Time Domain and Frequency
Domain
 Frequency domain:
 Tells us how properties (amplitudes) change over
frequencies:
Frequency Spectra
18
Fourier Transform
Properties of the Fourier Transform
From http://en.wikipedia.org/wiki/Continuous_Fourier_transform
Also see Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 219-223
Extending FT in 2D
• Forward FT
• Inverse FT
Example: 2D rectangle function
• FT of 2D rectangle function
2D sinc()
top view
19
Discrete Time Signal
-1.0
-0.5
0.0
0.5
1.0
sinθ
θ
sinθ 0 π 2 π 3π 2 2π 3π 4π
A discrete-time signal x[n] is periodic if:
x[n + N] = x[n]
Fundamental period, N0, of x[n] is smallest integer N
satisfying above equation.
Fundamental angular frequency: Ω0 = 2π/N0
N0
20
Discrete Fourier Transform (DFT)
The Eight Eighth Roots of Unity
http://math.fullerton.edu/mathews/
c2003/ComplexAlgebraRevisitedMod.html
e
N
kn
i
N
n
n
x
n
x
k
X
)
/
2
(
1
0
]
[
]}
[
{
]
[
π
−
−
=
∑ ⋅
=
= DFT
Sources: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 305
and http://en.wikipedia.org/wiki/Fast_Fourier_transform
Given discrete time sequence, x[n], n = 0, 1, …, N-1
Discrete Fourier Transform (DFT)
k = 0, 1, …, N-1
Nth root of unity
Inverse Discrete Fourier Transform (IDFT)
e
N
kn
i
N
n
k
X
N
k
X
n
x
)
/
2
(
1
0
]
[
1
]}
[
{
]
[
π
∑
−
=
⋅
=
= IDFT
• One-to-one correspondence between x[n] and X[k]
• DFT closely related to discrete Fourier series and the Fourier Transform
• DFT is ideal for computer manipulation
• Share many of the same properties as Fourier Transform
• Multiplier (1/N) can be used in DFT or IDFT. Sometimes 1/SQRT(N) used in both.
21
For N = 4, the DFT becomes:
Discrete Fourier Transform (DFT)




























=














−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
⋅
−
x
x
x
x
e
e
e
e
e
e
e
e
e
e
e
e
e
e
e
e
X
X
X
X
i
i
i
i
i
i
i
i
i
i
i
i
i
i
i
i
3
2
1
0
2
/
9
2
/
6
2
/
3
2
/
0
2
/
6
2
/
4
2
/
2
2
/
0
2
/
3
2
/
2
2
/
1
2
/
0
2
/
0
2
/
0
2
/
0
2
/
0
3
2
1
0
π
π
π
π
π
π
π
π
π
π
π
π
π
π
π
π


























−
−
−
−
−
−
=














x
x
x
x
X
X
X
X
i
i
i
i
3
2
1
0
3
2
1
0
1
1
1
1
1
1
1
1
1
1
1
1
e
N
kn
i
N
n
n
x
n
x
k
X
)
/
2
(
1
0
]
[
]}
[
{
]
[
π
−
−
=
∑ ⋅
=
= DFT
n
k
k
k = 0, 1, …, N-1
22
For N = 4, the DFT is:
Discrete Fourier Transform (DFT)


























−
−
−
−
−
−
=














x
x
x
x
X
X
X
X
i
i
i
i
3
2
1
0
3
2
1
0
1
1
1
1
1
1
1
1
1
1
1
1
x = [1, 0, 1, 0] X = [2, 0, 2, 0]
x = [0, 3, 0, 3] X = [6, 0, -6, 0]
x = [1, 1, 1, 1] X = [4, 0, 0, 0]
x = [0, 0, 0, 0] X = [0, 0, 0, 0]
x = [0, 0, 1, 1] X = [2, -1+i, 0, -1-i]
x = [1, 1, 0, 0] X = [2, 1- i, 0, 1+i]
X[0]/N = mean
27
Fast Fourier Transform (FFT)
e
N
kn
i
N
n
n
x
n
x
k
X
)
/
2
(
1
0
]
[
]}
[
{
]
[
π
−
−
=
∑ ⋅
=
= DFT
Source: http://en.wikipedia.org/wiki/Fast_Fourier_transform
Discrete Fourier Transform (DFT)
k = 0, 1, …, N-1
• The FFT is a computationally efficient algorithm to compute the
Discrete Fourier Transform and its inverse.
• Evaluating the sum above directly would take O(N2) arithmetic
operations.
• The FFT algorithm reduces the computational burden to
O(N log N) arithmetic operations.
• FFT requires the number of data points to be a power of 2
(usually 0 padding is used to make this true)
• FFT requires evenly-spaced time series
29
Fast Fourier Transform (FFT)
Software
www.fftw.org
FFTW is a C subroutine library for computing the discrete Fourier transform
(DFT) in one or more dimensions, of arbitrary input size
IDL (see Signal Processing Demo for Fourier Filtering)
R
MatLab: Signal Processing/Image Processing Toolboxes
Mathematica: Perform symbolic or numerical Fourier analysis
30
Fast Fourier Transform (FFT)
1D FFT in IDL Software
IDL Run Demo, Data Analysis, Signal Processing, Filtering Demo
32
2D FFT and Image Processing
• Spatial Frequency in Images
• 2D Discrete Fourier Transform
• 2D FFT Examples
• Applications of FFT
– Noise Removal
– Pattern / Texture Recognition
– Filtering: Convolution and Deconvolution
Applications: Frequency
Domain In Images
 Spatial frequency of an image refers to the
rate at which the pixel intensities change
 In picture on right:
 High frequences:
 Near center
 Low frequences:
 Corners
34
2D Discrete Fourier Transform
Source: Seul et al, Practical Algorithms for Image Analysis, 2000, p. 249, 262.
2D FFT can be computed as two discrete Fourier transforms in 1 dimension
I[m,n] F[u,v]
Fourier
Transform
Spatial Domain Frequency Domain
(0,0)
(0,0)
(0,N/2)
(0,-N/2)
(-M/2,0) (M/2,0)
(M,N)
∑ ∑
−
=






+
−
−
=
⋅
=
1
0
2
1
0
]
,
[
1
]
,
[
M
m
N
vn
M
um
i
N
n
e
n
m
I
MN
v
u
F
π
M pixels
SM units
N
pixels
S
N
units
36
2D FFT Example
FFTs Using ImageJ
Spatial Domain Frequency Domain
ImageJ Steps: (1) File | Open, (2) Process | FFT | FFT
(0,0) Origin (0,0) Origin
37
2D FFT Example
FFTs Using ImageJ
Spatial Domain Frequency Domain
ImageJ Steps: Process | FFT | Swap Quadrants
(0,0) Origin
(0,0) Origin
Regularity in image manifests itself in the degree of order or randomness in FFT pattern.
Default display is to swap quadrants
38
2D FFT Example
FFTs Using ImageJ
Overland Park Arboretum and Botanical Gardens, June 2006
Spatial Domain Frequency Domain
ImageJ Steps: (1) File | Open, (2) Process | FFT | FFT
Regularity in image manifests itself in the degree of order or randomness in FFT pattern.
Why is FT Useful?
• Easier to remove undesirable frequencies in the
frequency domain.
• Faster to perform certain operations in the frequency
domain than in the spatial domain.
Example: Removing undesirable frequencies
remove high
frequencies
reconstructed
signal
frequencies
noisy signal
To remove certain
frequencies, set their
corresponding F(u)
coefficients to zero!
How do frequencies show up in an image?
• Low frequencies correspond to slowly varying pixel
intensities (e.g., continuous surface).
• High frequencies correspond to quickly varying pixel
intensities (e.g., edges)
Original Image Low-passed
Example of noise reduction using FT
Input image
Output image
Spectrum (frequency domain)
Band-reject
filter
Frequency Filtering: Main Steps
1. Take the FT of f(x):
2. Remove undesired frequencies:
3. Convert back to a signal:
We’ll talk more about these steps later .....
Filtering in Frequency Domain
 one reason for using Fourier transform in image processing is 
due to convolution theorem
 Spatial convolution can be performed by element‐wise 
multiplication of the Fourier transform by suitable “filter 
matrix”
Ideal Low Pass Filtering
 Low pass filter: Keep frequencies below a certain frequency
 Low pass filtering causes blurring
 After DFT, DC components and low frequency components 
are towards center
 May specify frequency cutoff as circle c 
Ideal Low Pass Filtering
 Multiply Image Fourier Transform F by some filter matrix m
Ideal Low Pass Filtering
 Low pass filtered image is inverse Fourier Transform of 
product of F and m
 Example: Consider the following image and its DFT
Image DFT
Ideal Low Pass Filtering
Applying
low pass filter
to DFT
Cutoff D = 15
Image after
inversion
low pass filter
Cutoff D = 5
low pass filter
Cutoff D = 30
Note: Sharp filter
Cutoff causes
ringing
Ideal High Pass Filtering
 Opposite of low pass filtering: eliminate center (low 
frequency values), keeping others
 High pass filtering causes image  sharpening
 If we use circle as cutoff again, size affects results
 Large cutoff = More information removed
DFT of Image after
high pass Filtering
Resulting image
after inverse DFT
Ideal High Pass Filtering: Effect of Cutoffs
Low cutoff
frequency removes
Only few lowest
frequencies
High pass filtering
of DFT with filter
Cutoff D = 5
High pass filtering
of DFT with filter
Cutoff D = 30
High cutoff
frequency removes
many frequencies,
leaving only edges
39
Application of FFT in Image Processing
Noise Removal
Source: www.mediacy.com/apps/fft.htm, Image Pro Plus FFT Example. Last seen online in 2004.
FFT Inverse
FFT
Edit FFT
Four Noise
Spikes Removed
Noise Pattern
Stands Out as
Four Spikes
40
Application of FFT
Pattern/Texture Recognition
Source: Lee and Chen, A New Method for Coarse Classification of Textures and Class Weight Estimation
for Texture Retrieval, Pattern Recognition and Image Analysis, Vol. 12, No. 4, 2002, pp. 400–410.
41
Application of FFT
Source: http://www.rpgroup.caltech.edu/courses/PBL/size.htm
Could FFT of Drosophila eye be used to identify/quantify subtle phenotypes?
The Drosophila eye is a great example a cellular crystal with
its hexagonally closed-packed structure. The absolute
value of the Fourier transform (right) shows its hexagonal
structure.
Pattern/Texture Recognition
42
Application of FFT
Filtering in the Frequency Domain: Convolution
Source: Gonzalez and Woods, Digital Image Processing (2nd ed), 2002, p. 159
I[m,n]
Raw Image
I’[m,n]
Enhanced Image
Fourier Transform
F[u,v]
Filter Function
H[u,v]
Inverse
Fourier Transform
Pre-
processing
Post-
processing
F[u,v] H[u,v] · F[u,v]
FFT{ I[u,v] } FFT-1{ H[u,v] · F[u,v] }
43
Application of FFT
Filtering: IDL Fourier Filter Demo
IDL Run Demo, Data Analysis, Image Processing, Image Processing Demo
44
Application of FFT
Filtering: IDL Fourier Filtering Demo
IDL Run Demo, Data Visualization, Images, Fourier Filtering
45
The Point Spread Function (PSF) is the Fourier transform of a filter.
(the PSP says how much blurring there will be in trying to image a point).
Source: http://www.reindeergraphics.com/index.php?option=com_content&task=view&id=179&Itemid=127
Hubble image and measured PSF
Dividing the Fourier transform of the PSF into
the transform of the blurred image, and
performing an inverse FFT, recovers the
unblurred image.
Application of FFT
Deblurring: Deconvolution
FFT(Unblurred Image) * FFT(Point Spread Function) = FFT(Blurred Image)
Unblurred Image = FFT-1[ FFT(Blurred Image) / FFT(Point Spread Function) ]
46
The Point Spread Function (PSF) is the Fourier transform of a filter.
(the PSP says how much blurring there will be in trying to image a point).
Source: http://www.reindeergraphics.com/index.php?option=com_content&task=view&id=179&Itemid=127
Hubble image and measured PSF
Deblurred image
Dividing the Fourier transform of the PSF into
the transform of the blurred image, and
performing an inverse FFT, recovers the
unblurred image.
Application of FFT
Deblurring: Deconvolution
School of Engineering
History of Computer Tomography
• Johan Radon (1917) showed how a reconstruction from
projections was possible.
•Cormack (1963,1964) introduced Fourier transforms into the
reconstruction algorithms.
•Hounsfield (1972) invented the X-ray Computer scanner for
medical work, (which Cormack and Hounsfield shared a Nobel
prize).
•EMI Ltd (1971) announced development of the EMI scanner
which combined X-ray measurements and sophisticated
algorithms solved by digital computers.
47
Summary
• Fourier Analysis is a powerful tool even when periodicity is not
directly a part of the problem being solved.
• Discrete Fourier Transforms (DFT) are well-suited for computation
by computer, especially when using Fast Fourier Transform (FFT)
algorithms.
• Fourier Analysis can be used to remove noise from a signal or
image.
• Interpretation of the complex Fourier Transform is not always
straightforward.
• Convolution and Deconvolution are “simple” in Fourier transform
space to restore or enhance images.
• There are many other image processing uses of Fourier Analysis,
such as image compression [JPGs use the Discrete Cosine
Transform (DCT), which is a special kind of DFT]

Weitere ähnliche Inhalte

Was ist angesagt?

Image segmentation ppt
Image segmentation pptImage segmentation ppt
Image segmentation ppt
Gichelle Amon
 
Image trnsformations
Image trnsformationsImage trnsformations
Image trnsformations
John Williams
 
Dilation and erosion
Dilation and erosionDilation and erosion
Dilation and erosion
Aswin Pv
 
Digital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdf
Digital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdfDigital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdf
Digital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdf
ssuserbe3944
 
4.intensity transformations
4.intensity transformations4.intensity transformations
4.intensity transformations
Yahya Alkhaldi
 
Bayseian decision theory
Bayseian decision theoryBayseian decision theory
Bayseian decision theory
sia16
 
Enhancement in frequency domain
Enhancement in frequency domainEnhancement in frequency domain
Enhancement in frequency domain
Ashish Kumar
 

Was ist angesagt? (20)

6.frequency domain image_processing
6.frequency domain image_processing6.frequency domain image_processing
6.frequency domain image_processing
 
Image Restoration (Digital Image Processing)
Image Restoration (Digital Image Processing)Image Restoration (Digital Image Processing)
Image Restoration (Digital Image Processing)
 
Image Filtering in the Frequency Domain
Image Filtering in the Frequency DomainImage Filtering in the Frequency Domain
Image Filtering in the Frequency Domain
 
Image segmentation ppt
Image segmentation pptImage segmentation ppt
Image segmentation ppt
 
Wiener Filter
Wiener FilterWiener Filter
Wiener Filter
 
Image trnsformations
Image trnsformationsImage trnsformations
Image trnsformations
 
Digital Image Processing: Image Enhancement in the Frequency Domain
Digital Image Processing: Image Enhancement in the Frequency DomainDigital Image Processing: Image Enhancement in the Frequency Domain
Digital Image Processing: Image Enhancement in the Frequency Domain
 
Dilation and erosion
Dilation and erosionDilation and erosion
Dilation and erosion
 
Digital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdf
Digital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdfDigital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdf
Digital Image Processing 3rd edition Rafael C. Gonzalez, Richard E. Woods.pdf
 
4.intensity transformations
4.intensity transformations4.intensity transformations
4.intensity transformations
 
Bayseian decision theory
Bayseian decision theoryBayseian decision theory
Bayseian decision theory
 
Gradient descent method
Gradient descent methodGradient descent method
Gradient descent method
 
Enhancement in frequency domain
Enhancement in frequency domainEnhancement in frequency domain
Enhancement in frequency domain
 
Optimization for Deep Learning
Optimization for Deep LearningOptimization for Deep Learning
Optimization for Deep Learning
 
Image Processing: Spatial filters
Image Processing: Spatial filtersImage Processing: Spatial filters
Image Processing: Spatial filters
 
Intensity Transformation and Spatial filtering
Intensity Transformation and Spatial filteringIntensity Transformation and Spatial filtering
Intensity Transformation and Spatial filtering
 
Image Segmentation (Digital Image Processing)
Image Segmentation (Digital Image Processing)Image Segmentation (Digital Image Processing)
Image Segmentation (Digital Image Processing)
 
Histogram Equalization
Histogram EqualizationHistogram Equalization
Histogram Equalization
 
03 digital image fundamentals DIP
03 digital image fundamentals DIP03 digital image fundamentals DIP
03 digital image fundamentals DIP
 
gaussian filter seminar ppt
gaussian filter seminar pptgaussian filter seminar ppt
gaussian filter seminar ppt
 

Ähnlich wie Fourier slide

FourierTransform detailed power point presentation
FourierTransform detailed power point presentationFourierTransform detailed power point presentation
FourierTransform detailed power point presentation
ssuseracb8ba
 
Optics Fourier Transform Ii
Optics Fourier Transform IiOptics Fourier Transform Ii
Optics Fourier Transform Ii
diarmseven
 

Ähnlich wie Fourier slide (20)

Eece 301 note set 14 fourier transform
Eece 301 note set 14 fourier transformEece 301 note set 14 fourier transform
Eece 301 note set 14 fourier transform
 
lecture_6_-_fourier_series_0.pdf
lecture_6_-_fourier_series_0.pdflecture_6_-_fourier_series_0.pdf
lecture_6_-_fourier_series_0.pdf
 
Lecture 9
Lecture 9Lecture 9
Lecture 9
 
Master Thesis on Rotating Cryostats and FFT, DRAFT VERSION
Master Thesis on Rotating Cryostats and FFT, DRAFT VERSIONMaster Thesis on Rotating Cryostats and FFT, DRAFT VERSION
Master Thesis on Rotating Cryostats and FFT, DRAFT VERSION
 
FourierTransform detailed power point presentation
FourierTransform detailed power point presentationFourierTransform detailed power point presentation
FourierTransform detailed power point presentation
 
Fourier series Introduction
Fourier series IntroductionFourier series Introduction
Fourier series Introduction
 
Ch15 transforms
Ch15 transformsCh15 transforms
Ch15 transforms
 
DIGITAL IMAGE PROCESSING - Day 4 Image Transform
DIGITAL IMAGE PROCESSING - Day 4 Image TransformDIGITAL IMAGE PROCESSING - Day 4 Image Transform
DIGITAL IMAGE PROCESSING - Day 4 Image Transform
 
Ft3 new
Ft3 newFt3 new
Ft3 new
 
160280102001 c1 aem
160280102001 c1 aem160280102001 c1 aem
160280102001 c1 aem
 
SP_SNS_C2.pptx
SP_SNS_C2.pptxSP_SNS_C2.pptx
SP_SNS_C2.pptx
 
Basics of edge detection and forier transform
Basics of edge detection and forier transformBasics of edge detection and forier transform
Basics of edge detection and forier transform
 
Wave diffraction
Wave diffractionWave diffraction
Wave diffraction
 
Presentation on fourier transformation
Presentation on fourier transformationPresentation on fourier transformation
Presentation on fourier transformation
 
IVR - Chapter 3 - Basics of filtering II: Spectral filters
IVR - Chapter 3 - Basics of filtering II: Spectral filtersIVR - Chapter 3 - Basics of filtering II: Spectral filters
IVR - Chapter 3 - Basics of filtering II: Spectral filters
 
Optics Fourier Transform Ii
Optics Fourier Transform IiOptics Fourier Transform Ii
Optics Fourier Transform Ii
 
Lecture7 Signal and Systems
Lecture7 Signal and SystemsLecture7 Signal and Systems
Lecture7 Signal and Systems
 
imagetransforms1-210417050321.pptx
imagetransforms1-210417050321.pptximagetransforms1-210417050321.pptx
imagetransforms1-210417050321.pptx
 
Fourier transform
Fourier transformFourier transform
Fourier transform
 
Image transforms
Image transformsImage transforms
Image transforms
 

Kürzlich hochgeladen

Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
ZurliaSoop
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
AnaAcapella
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
kauryashika82
 

Kürzlich hochgeladen (20)

SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentation
 
Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.ppt
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)
 
Magic bus Group work1and 2 (Team 3).pptx
Magic bus Group work1and 2 (Team 3).pptxMagic bus Group work1and 2 (Team 3).pptx
Magic bus Group work1and 2 (Team 3).pptx
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 
Third Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptxThird Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptx
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
psychiatric nursing HISTORY COLLECTION .docx
psychiatric  nursing HISTORY  COLLECTION  .docxpsychiatric  nursing HISTORY  COLLECTION  .docx
psychiatric nursing HISTORY COLLECTION .docx
 
Asian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptxAsian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptx
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POS
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
 

Fourier slide

  • 1. 2 Fourier Analysis and Image Processing • History • Periodic Signals • Fourier Analysis – Fourier Series – Fourier Transform – Discrete Fourier Transform (DFT) – Fast Fourier Transform (FFT) • 2D FFT and Image Processing – Spatial Frequency in Images – 2D Discrete Fourier Transform – 2D FFT Examples – Applications of FFTs in Image Processing • Summary
  • 2. 3 History Jean Baptiste Joseph Fourier 1768-1830 French Mathematician and Physicist http://de.wikipedia.org/wiki/Kreiszahl Outlined technique in memoir, On the Propagation of Heat in Solid Bodies, which was read to Paris Institute on 21 Dec 1807. Controversial then: Laplace and Lagrange objected to what is now Fourier series: “... his analysis ... leaves something to be desired on the score of generality and even rigour...” (from report awarding Fourier math prize in 1811) In La Theorie Analytique de la Chaleur (Analytic Theory of Heat) (1822) Fourier • developed the theory of the series known by his name, and • applied it to the solution of boundary-value problems in partial differential equations. Sources: www.me.utexas.edu/~me339/Bios/fourier.html and www-gap.dcs.st-and.ac.uk/~history/Biographies/Fourier.html
  • 3. 4 Periodic Signals A continuous-time signal x(t) is periodic if: x(t + T) = x(t) Fundamental period, T0, of x(t) is smallest T satisfying above equation. Fundamental frequency: f0 = 1/T0 Fundamental angular frequency: ω0 = 2π/T0 = 2πf0
  • 4. 5 Periodic Signals x(t + T) = x(t) Harmonics: Integer multiples of frequency of wave -1.0 0.0 1.0 t sin ( t ) 0 π 2 π 3π 2 2π 3π 4π -1.0 0.0 1.0 t sin ( 4t ) 0 π 2 π 3π 2 2π 3π 4π T0 Fundamental frequency: f0 = 1/T0
  • 5. 6 Periodic Signals Biological time series can be quite complex, and will contain noise. x(t + T) = x(t) -2 -1 0 1 2 t x(t) 0 π 2 π 3π 2 2π 3π 4π “Biological” Time Series T0
  • 6. 8 Fourier Analysis • Fourier Series Expansion of continuous function into weighted sum of sines and cosines, or weighted sum of complex exponentials. • Fourier Transform Maps one function to another: continuous-to-continuous mapping. An integral transform. • Discrete Fourier Transform (DFT) Approximation to Fourier integral. Maps discrete vector to another discrete vector. Can be viewed as a matrix operator. • Fast Fourier Transform (FFT) Special computational algorithm for DFT.
  • 7. 9 Fourier Series www.science.org.au/nova/029/029img/wave1.gif Trigonometric Fourier Series Expansion of continuous function into weighted sum of sines and cosines. [ ] ∑ ∞ = ⋅ + ⋅ + = 1 0 0 0 ) ( sin ) ( cos 2 ) ( k k k t k t k t x b a a ω ω ∫ ⋅ = T dt t k t x T ak 0 ) cos( ) ( 2 0 0 ω ∫ ⋅ = T dt t k t x T bk 0 ) sin( ) ( 2 0 0 ω f T 0 0 0 2 2 π π ω = = If x(t) is even, i.e., x(-t) = x(t) like cosine, then bk = 0. If x(t) is odd, i.e., x(-t) = -x(t) like sine, then ak = 0. Source: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 211-213
  • 8. 10 Complex Math Review Solutions to x2 = -1: Complex Plane Euler’s Formula: Operators: +, -, *, / u + v = (a + ib) + (c + id) = (a + c) + i(b + d) u × v = (a + ib) (c + id) = (ac – bd) + i(ad + bc) DeMoivre’s Theorem: u* = a - ib
  • 9. 11 Fourier Series f T 0 0 0 2 2 π π ω = = Source Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 211-213 ∑ ∞ −∞ = ⋅ ⋅ ⋅ = k t k i k e c t x ω0 ) ( ∫ ⋅ ⋅ ⋅ − ⋅ = T dt t x e T c t k i k 0 0 ) ( 1 0 ω Notes: • If x(t) is real, c-k = ck *. • For k = 0, ck = average value of x(t) over one period. • a0/2 = c0; ak = ck + c-k; bk = i · (ck - c-k) Complex Exponential Fourier Series Expansion of continuous function into weighted sum of complex exponentials.
  • 10. 12 Source: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 211-213 Fourier Series Complex Exponential Fourier Series Coefficients can be written as product: e c c k i k k φ ⋅ = • ck are known as the spectral coefficients of x(t) • Plot of |ck| versus angular frequency ω is the amplitude spectrum. • Plot of φkversus angular frequency is the phase spectrum. • With discrete Fourier frequencies, k·ω0, both are discrete spectra.
  • 11. 13 Fourier Series selected Approximate any function as truncated Fourier series Given: x(t) = t Fourier Series:       − + − = ... 3 3 sin 2 2 sin sin 2 ) ( t t t t x       − + − = ... 3 3 sin 2 2 sin sin 2 ) ( t t t t x 0.0 0.2 0.4 0.6 0.8 1.0 0.0 0.2 0.4 0.6 0.8 1.0 t x(t)
  • 12. 14 Fourier Series selected Approximate any function as truncated Fourier series Given: x(t) = t Fourier Series:       − + − = ... 3 3 sin 2 2 sin sin 2 ) ( t t t t x       − + − = ... 3 3 sin 2 2 sin sin 2 ) ( t t t t x -1.0 -0.5 0.0 0.5 1.0 1.5 2.0 Fourier Terms in Expansion of x(t) = t t Fourier Terms 0 π 4 π 2 3π 4 π 1 2 3 4 5 6 Fourier Series Approximation t x(t) First Six Series Terms 0 π 4 π 2 3π 4 π 0 1 2 3
  • 13. 15 Fourier Series selected Approximate any function as truncated Fourier series Given: x(t) = t Fourier Series:       − + − = ... 3 3 sin 2 2 sin sin 2 ) ( t t t t x       − + − = ... 3 3 sin 2 2 sin sin 2 ) ( t t t t x Fourier Series Approximation t x(t) 0 π 4 π 2 3π 4 π 0 1 2 3 100 terms 200 terms
  • 14. 16 Fourier Series Periodogram Decomposition Time Series Reconstruction Filtered Series Remove High Frequency Component 0 selected “Remove” high frequency noise by zeroing a term in series expansion Noise Removal
  • 15. 17 Fourier Transform Maps one function to another: continuous-to-continuous mapping. Fourier transform of x(t) is X(ω): (converts from time space to frequency space) ∫ ∞ ∞ − − ⋅ = = dt t x t x X e t iω ω ) ( )} ( { ) ( F Fourier inverse transform of X(ω) recovers x(t): (converts from frequency space to time space) ∫ ∞ ∞ − ⋅ = = ω ω π ω ω d X X t x e t i ) ( 2 1 )} ( { ) ( F 1 - The Fourier Transform is a special case of the Laplace Transform, s = i ·ω x(t) and X(ω) form a Fourier transform pair: x(t) ↔ X(ω) Source: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 214-218
  • 16. Time Domain and Frequency Domain  Time Domain:  Tells us how properties (air pressure in a sound function, for example) change over time:  Amplitude = 100  Frequency = number of cycles in one second = 200 Hz
  • 17. Time Domain and Frequency Domain  Frequency domain:  Tells us how properties (amplitudes) change over frequencies:
  • 19. 18 Fourier Transform Properties of the Fourier Transform From http://en.wikipedia.org/wiki/Continuous_Fourier_transform Also see Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 219-223
  • 20. Extending FT in 2D • Forward FT • Inverse FT
  • 21. Example: 2D rectangle function • FT of 2D rectangle function 2D sinc() top view
  • 22. 19 Discrete Time Signal -1.0 -0.5 0.0 0.5 1.0 sinθ θ sinθ 0 π 2 π 3π 2 2π 3π 4π A discrete-time signal x[n] is periodic if: x[n + N] = x[n] Fundamental period, N0, of x[n] is smallest integer N satisfying above equation. Fundamental angular frequency: Ω0 = 2π/N0 N0
  • 23. 20 Discrete Fourier Transform (DFT) The Eight Eighth Roots of Unity http://math.fullerton.edu/mathews/ c2003/ComplexAlgebraRevisitedMod.html e N kn i N n n x n x k X ) / 2 ( 1 0 ] [ ]} [ { ] [ π − − = ∑ ⋅ = = DFT Sources: Schaum’s Theory and Problems: Signals and Systems, Hwei P. Hsu, 1995, pp. 305 and http://en.wikipedia.org/wiki/Fast_Fourier_transform Given discrete time sequence, x[n], n = 0, 1, …, N-1 Discrete Fourier Transform (DFT) k = 0, 1, …, N-1 Nth root of unity Inverse Discrete Fourier Transform (IDFT) e N kn i N n k X N k X n x ) / 2 ( 1 0 ] [ 1 ]} [ { ] [ π ∑ − = ⋅ = = IDFT • One-to-one correspondence between x[n] and X[k] • DFT closely related to discrete Fourier series and the Fourier Transform • DFT is ideal for computer manipulation • Share many of the same properties as Fourier Transform • Multiplier (1/N) can be used in DFT or IDFT. Sometimes 1/SQRT(N) used in both.
  • 24. 21 For N = 4, the DFT becomes: Discrete Fourier Transform (DFT)                             =               − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − ⋅ − x x x x e e e e e e e e e e e e e e e e X X X X i i i i i i i i i i i i i i i i 3 2 1 0 2 / 9 2 / 6 2 / 3 2 / 0 2 / 6 2 / 4 2 / 2 2 / 0 2 / 3 2 / 2 2 / 1 2 / 0 2 / 0 2 / 0 2 / 0 2 / 0 3 2 1 0 π π π π π π π π π π π π π π π π                           − − − − − − =               x x x x X X X X i i i i 3 2 1 0 3 2 1 0 1 1 1 1 1 1 1 1 1 1 1 1 e N kn i N n n x n x k X ) / 2 ( 1 0 ] [ ]} [ { ] [ π − − = ∑ ⋅ = = DFT n k k k = 0, 1, …, N-1
  • 25. 22 For N = 4, the DFT is: Discrete Fourier Transform (DFT)                           − − − − − − =               x x x x X X X X i i i i 3 2 1 0 3 2 1 0 1 1 1 1 1 1 1 1 1 1 1 1 x = [1, 0, 1, 0] X = [2, 0, 2, 0] x = [0, 3, 0, 3] X = [6, 0, -6, 0] x = [1, 1, 1, 1] X = [4, 0, 0, 0] x = [0, 0, 0, 0] X = [0, 0, 0, 0] x = [0, 0, 1, 1] X = [2, -1+i, 0, -1-i] x = [1, 1, 0, 0] X = [2, 1- i, 0, 1+i] X[0]/N = mean
  • 26. 27 Fast Fourier Transform (FFT) e N kn i N n n x n x k X ) / 2 ( 1 0 ] [ ]} [ { ] [ π − − = ∑ ⋅ = = DFT Source: http://en.wikipedia.org/wiki/Fast_Fourier_transform Discrete Fourier Transform (DFT) k = 0, 1, …, N-1 • The FFT is a computationally efficient algorithm to compute the Discrete Fourier Transform and its inverse. • Evaluating the sum above directly would take O(N2) arithmetic operations. • The FFT algorithm reduces the computational burden to O(N log N) arithmetic operations. • FFT requires the number of data points to be a power of 2 (usually 0 padding is used to make this true) • FFT requires evenly-spaced time series
  • 27. 29 Fast Fourier Transform (FFT) Software www.fftw.org FFTW is a C subroutine library for computing the discrete Fourier transform (DFT) in one or more dimensions, of arbitrary input size IDL (see Signal Processing Demo for Fourier Filtering) R MatLab: Signal Processing/Image Processing Toolboxes Mathematica: Perform symbolic or numerical Fourier analysis
  • 28. 30 Fast Fourier Transform (FFT) 1D FFT in IDL Software IDL Run Demo, Data Analysis, Signal Processing, Filtering Demo
  • 29. 32 2D FFT and Image Processing • Spatial Frequency in Images • 2D Discrete Fourier Transform • 2D FFT Examples • Applications of FFT – Noise Removal – Pattern / Texture Recognition – Filtering: Convolution and Deconvolution
  • 30. Applications: Frequency Domain In Images  Spatial frequency of an image refers to the rate at which the pixel intensities change  In picture on right:  High frequences:  Near center  Low frequences:  Corners
  • 31. 34 2D Discrete Fourier Transform Source: Seul et al, Practical Algorithms for Image Analysis, 2000, p. 249, 262. 2D FFT can be computed as two discrete Fourier transforms in 1 dimension I[m,n] F[u,v] Fourier Transform Spatial Domain Frequency Domain (0,0) (0,0) (0,N/2) (0,-N/2) (-M/2,0) (M/2,0) (M,N) ∑ ∑ − =       + − − = ⋅ = 1 0 2 1 0 ] , [ 1 ] , [ M m N vn M um i N n e n m I MN v u F π M pixels SM units N pixels S N units
  • 32. 36 2D FFT Example FFTs Using ImageJ Spatial Domain Frequency Domain ImageJ Steps: (1) File | Open, (2) Process | FFT | FFT (0,0) Origin (0,0) Origin
  • 33. 37 2D FFT Example FFTs Using ImageJ Spatial Domain Frequency Domain ImageJ Steps: Process | FFT | Swap Quadrants (0,0) Origin (0,0) Origin Regularity in image manifests itself in the degree of order or randomness in FFT pattern. Default display is to swap quadrants
  • 34. 38 2D FFT Example FFTs Using ImageJ Overland Park Arboretum and Botanical Gardens, June 2006 Spatial Domain Frequency Domain ImageJ Steps: (1) File | Open, (2) Process | FFT | FFT Regularity in image manifests itself in the degree of order or randomness in FFT pattern.
  • 35. Why is FT Useful? • Easier to remove undesirable frequencies in the frequency domain. • Faster to perform certain operations in the frequency domain than in the spatial domain.
  • 36. Example: Removing undesirable frequencies remove high frequencies reconstructed signal frequencies noisy signal To remove certain frequencies, set their corresponding F(u) coefficients to zero!
  • 37. How do frequencies show up in an image? • Low frequencies correspond to slowly varying pixel intensities (e.g., continuous surface). • High frequencies correspond to quickly varying pixel intensities (e.g., edges) Original Image Low-passed
  • 38. Example of noise reduction using FT Input image Output image Spectrum (frequency domain) Band-reject filter
  • 39. Frequency Filtering: Main Steps 1. Take the FT of f(x): 2. Remove undesired frequencies: 3. Convert back to a signal: We’ll talk more about these steps later .....
  • 41. Ideal Low Pass Filtering  Low pass filter: Keep frequencies below a certain frequency  Low pass filtering causes blurring  After DFT, DC components and low frequency components  are towards center  May specify frequency cutoff as circle c 
  • 44. Ideal Low Pass Filtering Applying low pass filter to DFT Cutoff D = 15 Image after inversion low pass filter Cutoff D = 5 low pass filter Cutoff D = 30 Note: Sharp filter Cutoff causes ringing
  • 45. Ideal High Pass Filtering  Opposite of low pass filtering: eliminate center (low  frequency values), keeping others  High pass filtering causes image  sharpening  If we use circle as cutoff again, size affects results  Large cutoff = More information removed DFT of Image after high pass Filtering Resulting image after inverse DFT
  • 46. Ideal High Pass Filtering: Effect of Cutoffs Low cutoff frequency removes Only few lowest frequencies High pass filtering of DFT with filter Cutoff D = 5 High pass filtering of DFT with filter Cutoff D = 30 High cutoff frequency removes many frequencies, leaving only edges
  • 47. 39 Application of FFT in Image Processing Noise Removal Source: www.mediacy.com/apps/fft.htm, Image Pro Plus FFT Example. Last seen online in 2004. FFT Inverse FFT Edit FFT Four Noise Spikes Removed Noise Pattern Stands Out as Four Spikes
  • 48. 40 Application of FFT Pattern/Texture Recognition Source: Lee and Chen, A New Method for Coarse Classification of Textures and Class Weight Estimation for Texture Retrieval, Pattern Recognition and Image Analysis, Vol. 12, No. 4, 2002, pp. 400–410.
  • 49. 41 Application of FFT Source: http://www.rpgroup.caltech.edu/courses/PBL/size.htm Could FFT of Drosophila eye be used to identify/quantify subtle phenotypes? The Drosophila eye is a great example a cellular crystal with its hexagonally closed-packed structure. The absolute value of the Fourier transform (right) shows its hexagonal structure. Pattern/Texture Recognition
  • 50. 42 Application of FFT Filtering in the Frequency Domain: Convolution Source: Gonzalez and Woods, Digital Image Processing (2nd ed), 2002, p. 159 I[m,n] Raw Image I’[m,n] Enhanced Image Fourier Transform F[u,v] Filter Function H[u,v] Inverse Fourier Transform Pre- processing Post- processing F[u,v] H[u,v] · F[u,v] FFT{ I[u,v] } FFT-1{ H[u,v] · F[u,v] }
  • 51. 43 Application of FFT Filtering: IDL Fourier Filter Demo IDL Run Demo, Data Analysis, Image Processing, Image Processing Demo
  • 52. 44 Application of FFT Filtering: IDL Fourier Filtering Demo IDL Run Demo, Data Visualization, Images, Fourier Filtering
  • 53. 45 The Point Spread Function (PSF) is the Fourier transform of a filter. (the PSP says how much blurring there will be in trying to image a point). Source: http://www.reindeergraphics.com/index.php?option=com_content&task=view&id=179&Itemid=127 Hubble image and measured PSF Dividing the Fourier transform of the PSF into the transform of the blurred image, and performing an inverse FFT, recovers the unblurred image. Application of FFT Deblurring: Deconvolution FFT(Unblurred Image) * FFT(Point Spread Function) = FFT(Blurred Image) Unblurred Image = FFT-1[ FFT(Blurred Image) / FFT(Point Spread Function) ]
  • 54. 46 The Point Spread Function (PSF) is the Fourier transform of a filter. (the PSP says how much blurring there will be in trying to image a point). Source: http://www.reindeergraphics.com/index.php?option=com_content&task=view&id=179&Itemid=127 Hubble image and measured PSF Deblurred image Dividing the Fourier transform of the PSF into the transform of the blurred image, and performing an inverse FFT, recovers the unblurred image. Application of FFT Deblurring: Deconvolution
  • 55. School of Engineering History of Computer Tomography • Johan Radon (1917) showed how a reconstruction from projections was possible. •Cormack (1963,1964) introduced Fourier transforms into the reconstruction algorithms. •Hounsfield (1972) invented the X-ray Computer scanner for medical work, (which Cormack and Hounsfield shared a Nobel prize). •EMI Ltd (1971) announced development of the EMI scanner which combined X-ray measurements and sophisticated algorithms solved by digital computers.
  • 56. 47 Summary • Fourier Analysis is a powerful tool even when periodicity is not directly a part of the problem being solved. • Discrete Fourier Transforms (DFT) are well-suited for computation by computer, especially when using Fast Fourier Transform (FFT) algorithms. • Fourier Analysis can be used to remove noise from a signal or image. • Interpretation of the complex Fourier Transform is not always straightforward. • Convolution and Deconvolution are “simple” in Fourier transform space to restore or enhance images. • There are many other image processing uses of Fourier Analysis, such as image compression [JPGs use the Discrete Cosine Transform (DCT), which is a special kind of DFT]