Automation Mike Marsh National Center for Macromolecular Imaging Baylor College of Medicine Single-Particle Reconstructions and Visualization EMAN Tutorial.

Slides:



Advertisements
Similar presentations
Spatial Filtering (Chapter 3)
Advertisements

Fourier Transform (Chapter 4)
Frequency Domain The frequency domain
Fourier Transform – Chapter 13. Image space Cameras (regardless of wave lengths) create images in the spatial domain Pixels represent features (intensity,
Chapter Four Image Enhancement in the Frequency Domain.
© by Yu Hen Hu 1 ECE533 Digital Image Processing Image Enhancement in Frequency Domain.
Chap 4 Image Enhancement in the Frequency Domain.
Image Processing Frequency Filtering Instructor: Juyong Zhang
Fourier Transform in Image Processing
Digital Image Processing
Digtial Image Processing, Spring ECES 682 Digital Image Processing Oleh Tretiak ECE Department Drexel University.
Reminder Fourier Basis: t  [0,1] nZnZ Fourier Series: Fourier Coefficient:
Chapter 4 Image Enhancement in the Frequency Domain.
Chap 4-2. Frequency domain processing Jen-Chang Liu, 2006.
Methods for Digital Image Processing
General Functions A non-periodic function can be represented as a sum of sin’s and cos’s of (possibly) all frequencies: F(  ) is the spectrum of the function.
Digital Image Processing Chapter 4: Image Enhancement in the Frequency Domain.
lecture 5, Sampling and the Nyquist Condition Sampling Outline  FT of comb function  Sampling Nyquist Condition  sinc interpolation Truncation.
Image Enhancement in the Frequency Domain Part I Image Enhancement in the Frequency Domain Part I Dr. Samir H. Abdul-Jauwad Electrical Engineering Department.
Image Enhancement in the Frequency Domain Part II Dr. Samir H. Abdul-Jauwad Electrical Engineering Department King Fahd University of Petroleum & Minerals.
Chapter 4 Image Enhancement in the Frequency Domain.
Transforms: Basis to Basis Normal Basis Hadamard Basis Basis functions Method to find coefficients (“Transform”) Inverse Transform.
Feb. 7, 2011 Plane EM Waves The Radiation Spectrum: Fourier Transforms.
Digital Image Processing, 2nd ed. © 2002 R. C. Gonzalez & R. E. Woods Chapter 4 Image Enhancement in the Frequency Domain Chapter.
G52IIP, School of Computer Science, University of Nottingham 1 Image Transforms Fourier Transform Basic idea.
Presentation Image Filters
Motivation Music as a combination of sounds at different frequencies
Introduction to Image Processing
CSC589 Introduction to Computer Vision Lecture 7 Thinking in Frequency Bei Xiao.
Digital Image Processing Chapter # 4 Image Enhancement in Frequency Domain Digital Image Processing Chapter # 4 Image Enhancement in Frequency Domain.
Image Processing © 2002 R. C. Gonzalez & R. E. Woods Lecture 4 Image Enhancement in the Frequency Domain Lecture 4 Image Enhancement.
Chapter 7: The Fourier Transform 7.1 Introduction
Part I: Image Transforms DIGITAL IMAGE PROCESSING.
09/19/2002 (C) University of Wisconsin 2002, CS 559 Last Time Color Quantization Dithering.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Digital Image Processing Chapter 4 Image Enhancement in the Frequency Domain Part I.
Digital Image Processing CSC331 Image Enhancement 1.
Lecture 7: Sampling Review of 2D Fourier Theory We view f(x,y) as a linear combination of complex exponentials that represent plane waves. F(u,v) describes.
ENG4BF3 Medical Image Processing Image Enhancement in Frequency Domain.
Spatial Frequencies Spatial Frequencies. Why are Spatial Frequencies important? Efficient data representation Provides a means for modeling and removing.
Digital Image Processing Chapter 4: Image Enhancement in the Frequency Domain 22 June 2005 Digital Image Processing Chapter 4: Image Enhancement in the.
1“Principles & Applications of SAR” Instructor: Franz Meyer © 2009, University of Alaska ALL RIGHTS RESERVED Dr. Franz J Meyer Earth & Planetary Remote.
7- 1 Chapter 7: Fourier Analysis Fourier analysis = Series + Transform ◎ Fourier Series -- A periodic (T) function f(x) can be written as the sum of sines.
Practical Image Processing1 Chap7 Image Transformation  Image and Transformed image Spatial  Transformed domain Transformation.
1 CMPB 345: IMAGE PROCESSING DISCRETE TRANSFORM 2.
Fourier Transform.
Computer Graphics & Image Processing Chapter # 4 Image Enhancement in Frequency Domain 2/26/20161.
2D Fourier Transform.
Frequency space, fourier transforms, and image analysis
The Frequency Domain Digital Image Processing – Chapter 8.
Frequency Domain Filtering. Frequency Domain Methods Spatial Domain Frequency Domain.
Fourier transform.
Digital Image Processing Lecture 8: Image Enhancement in Frequency Domain II Naveed Ejaz.
Fourier Transform (Chapter 4) CS474/674 – Prof. Bebis.
Digital Image Processing , 2008
Jean Baptiste Joseph Fourier
… Sampling … … Filtering … … Reconstruction …
Spatial & Frequency Domain
Image Enhancement in the
Fourier Transform.
All about convolution.
ENG4BF3 Medical Image Processing
Outline Linear Shift-invariant system Linear filters
2D Fourier transform is separable
Outline Linear Shift-invariant system Linear filters
4. Image Enhancement in Frequency Domain
Filtering in the Frequency Domain
Lecture 4 Image Enhancement in Frequency Domain
Presentation transcript:

Automation Mike Marsh National Center for Macromolecular Imaging Baylor College of Medicine Single-Particle Reconstructions and Visualization EMAN Tutorial and Workshop March 14, 2007 Fourier Transforms, Filtering and Convolution

Fourier Transform is an invertible operator ImageFourier Transform v2 will display image or its transform FT

Fourier Transform is an invertible operator Image f(x,y) F(k x,k y ) x y 0NxNx NyNy {F(k x,k y )} = f(x,y)} {f(x,y)} = F(k x,k y ) N x ⁄ 2 N y ⁄ 2 Fourier Transform

Continuous Fourier Transform f(x) = F(s) Euler’s Formula

Some Conventions Image Domain Forward Transform f(x,y,z) g(x) F Fourier Domain –Reciprocal space –Fourier Space –K-space –Frequency Space Reverse Transform, Inverse Transform F(k x,k y,k z ) G(s) F

Math Review - Periodic Functions If there is some a, for a function f(x), such that f(x) = f(x + na) then function is periodic with the period a 0 a2a3a

Math Review - Attributes of cosine wave Amplitude Phase f(x) = cos (x) f(x) = 5 cos (x) f(x) = 5 cos (x )

Math Review - Attributes of cosine wave Amplitude Phase Frequency f(x) = 5 cos (x) f(x) = 5 cos (x ) f(x) = 5 cos (3 x )

Math Review - Attributes of cosine wave f(x) = cos (x) Amplitude, Frequency, Phase f(x) = A cos (kx +  )

Math Review - Complex numbers Real numbers:  Complex numbers i – 6.7 i -5.2 ( i )

Math Review - Complex numbers Complex numbers i – 6.7 i -5.2 ( i ) General Form Z = a + b i Re(Z) = a Im(Z) = b Amplitude A = | Z | = √ (a 2 + b 2 ) Phase  =  Z = tan -1 (b/a)

Math Review – Complex Numbers Polar Coordinate Z = a + bi Amplitude A = √ (a 2 + b 2 ) Phase  = tan -1 (b/a) a b   A 

Math Review – Complex Numbers and Cosine Waves Cosine wave has three properties –Frequency –Amplitude –Phase Complex number has two properties –Amplitude –Wave Complex numbers to represent cosine waves at varying frequency –Frequency 1: Z 1 = 5 +2i –Frequency 2: Z 2 = i –Frequency 3: Z 3 = 1.3 – 1.6i

Fourier Analysis Decompose f(x) into a series of cosine waves that when summed reconstruct f(x)

Fourier Analysis in 1D. Audio signals (Hz) (Hz) Amplitude Only

Fourier Analysis in 1D. Audio signals (Hz) Your ear performs fourier analysis.

Fourier Analysis in 1D. Spectrum Analyzer. iTunes performs fourier analysis.

Fourier Synthesis Summing cosine waves reconstructs the original function

Fourier Synthesis of Boxcar Function Boxcar function Periodic Boxcar Can this function be reproduced with cosine waves?

k=1. One cycle per period A 1 ·cos(2  kx +  1 ) k=1 A k ·cos(2  kx +  k )  k=1 1

k=2. Two cycles per period A 2 ·cos(2  kx +  2 ) k=2 A k ·cos(2  kx +  k )  k=1 2

k=3. Three cycles per period A 3 ·cos(2  kx +  3 ) k=3 A k ·cos(2  kx +  k )  k=1 3

A k ·cos(2  kx +  k ) N Fourier Synthesis. N Cycles A 3 ·cos(2  kx +  3 ) k=3  k=1

Fourier Synthesis of a 2D Function An image is two dimensional data. Intensities as a function of x,y White pixels represent the highest intensities. Greyscale image of iris 128x128 pixels

Fourier Synthesis of a 2D Function F(2,3)

Fourier Filters Change the image by changing which frequencies of cosine waves go into the image Represented by 1D spectral profile 2D Profile is rotationally symmetrized 1D profile

Low frequency terms –Close to origin in Fourier Space –Changes with great spatial extent (like ice gradient), or particle size High frequency terms –Closer to edge in Fourier Space –Necessary to represent edges or high- resolution features

Frequency-based Filters Low-pass Filter (blurs) –Restricts data to low-frequency components High-pass Filter (sharpens) –Restricts data to high-frequency-componenets Band-pass Filter –Restrict data to a band of frequencies Band-stop Filter –Suppress a certain band of frequencies

Cutoff Low-pass Filter Image is blurred Sharp features are lost Ringing artifacts

Butterworth Low-pass Filter Flat in the pass-band Zero in the stop-band No ringing

Gaussian Low-pass Filter

Butterworth High-pass Filter Note the loss of solid densities

How the filter looks in 2D unprocessed lowpass highpass bandpass

Filtering with EMAN2 LowPass Filters filtered=image.process(‘filter.lowpass.guass’, {‘sigma’:0.10}) filtered=image.process(‘filter.lowpass.butterworth’, {‘low_cutoff_frequency’:0.10, ‘high_cutoff_frequency’:0.35}) filtered=image.process(‘filter.lowpass.tanh’, {‘cutoff_frequency’:0.10, ‘falloff’:0.2}) HighPass Filters filtered=image.process(‘filter.highpass.guass’, {‘sigma’:0.10}) filtered=image.process(‘filter.highpass.butterworth’, {‘low_cutoff_frequency’:0.10, ‘high_cutoff_frequency’:0.35}) filtered=image.process(‘filter.highpass.tanh’, {‘cutoff_frequency’:0.10, ‘falloff’:0.2}) BandPass Filters filtered=image.process(‘filter.bandpass.guass’, {‘center’:0.2,‘sigma’:0.10}) filtered=image.process(‘filter.bandpass.butterworth’, {‘low_cutoff_frequency’:0.10, ‘high_cutoff_frequency’:0.35}) filtered=image.process(‘filter.bandpass.tanh’, {‘cutoff_frequency’:0.10, ‘falloff’:0.2})

Convolution Convolution of some function f(x) with some kernel g(x) *= Continuous Discrete

xx Convolution in 2D x  xx = x  xx = xx xx xx xx

Microscope Point-Spread-Function is Convolution

Convolution Theorem f  g = {FG} f = FG G Convolution in image domain Is equivalent to multiplication in fourier domain

Contrast Theory observed image f(x) for true particle point-spread function envelope function noise obs(x) = f(x)  psf(x)  env(x) + n(x) Incoherant average of transform F 2 (s) CTF 2 (s) Env 2 (s) + N 2 (s) Power spectrum PS =

Lowpass Filtering by Convolution f  g = {FG} Camera shake Crystallographic B-factor

Review Fourier Transform is invertible operator Math Review Periodic functions Amplitude, Phase and Frequency Complex number Amplitude and Phase Fourier Analysis (Forward Transform) Decomposition of periodic signal into cosine waves Fourier Synthesis (Inverse Transform) Summation of cosine waves into multi-frequency waveform Fourier Transforms in 1D, 2D, 3D, ND Image Analysis Image (real-valued) Transform (complex-valued, amplitude plot) Fourier Filters Low-pass High-pass Band-pass Band-stop Convolution Theorem Deconvolute by Division in Fourier Space All Fourier Filters can be expressed as real-space Convolution Kernels Lens does Foureir transforms Diffraction Microscopy

Further Reading Wikipedia Mathworld The Fourier Transform and its Applications. Ronald Bracewell

Lens Performs Fourier Transform

Gibbs Ringing 5 waves 25 waves 125 waves