You are on page 1of 18

10/19/2006

ENGG 167

MEDICAL IMAGING
Lecture 10: Oct. 13 Image Processing II Frequency Domain & Transform Processing
References: Chapter 10, The Essential Physics of Medical Imaging, Bushberg Radiation Detection and Measurement, Knoll, 2nd ed. Intermediate Physics for Medicine and Biology, Hobbie, 3rd ed. Principles of Computerized Tomographic Imaging, Kak and Slaney. (http://rvl4.ecn.purdue.edu/~malcolm/pct/pct-toc.html)

Preparation Review Imaging Processing Toolbox Help Manual


(on your computer)

Download NIHImage (Mac) / ImageJ (Windows)


Create a Macro which will analyze images and save a processed version of the images (http://rsbweb.nih.gov/ij/developer/macro/macros.html)

Complete Image Processing Assignment

10/19/2006

The Fourier Theorum


All signals can be decomposed into pure sinusoidal signals

+ = +

Ref: Gonzalez et al, Text

The Fourier transform


All signals can be decomposed into pure sinusoidal signals
Spatial signal Corresponding Frequency-domain signal

This theorum is especially appropriate for periodic signals, but can be used for discrete signals if enough frequencies are used to capture the relevant information. Ref: Gonzalez et al, Text

10/19/2006

1) Basics 1-dimensional sinusoidal representation of signals

or:

Where magnitude and phase of the coefficients are given by:


Ref: Rizzoni
5

1) Basics complex numbers


Sinusoids are related to complex exponential expressions. A complex number is one which is of the form: z = a + ib, where I is the square root of -1, an imaginary number Recall that the magnitude and phase of z can be calculated by: magnitude => I = [a2 + b2] phase => = tan-1(b/a) So that another way to express z is : z = I ei Now, we can make use of a definition called Eulers formula: ei = cos() + i sin() And e-i = cos() - i sin() Or written for the sinusoid signals: cos() = [ei + e-i]/2 and sin() = [ei - e-i]/(2i)
6

10/19/2006

1) Basics complex numbers


So that equivalent expressions for a time domain signal are : x(t) = an cos(nt) + bn sin (nt) where an and bn are the magnitudes of the signal at each frequency n, and the summation is carried out over all values of n. x(t) = In exp(int+n) where In and n are the amplitude and phase at each frequency n.

1) Basics fourier transform of a signal


X() =
1 x(tn) exp(-itn) N

where the signal X() is now in the frequency domain (recall =2f = 2/T), whereas the original signal x(t) was a time resolved signal with N total data points. Summation is from n=1 to n=N. Alternatively a spatial data set can be transformed to spatial frequency data set by the same approach: F(k) =
1 f(xn) exp(-i 2kxn) N

where the signal F(k) is now in spatial frequency, k, and describes the exact discritized shape of the original signal f(xn).

10/19/2006

1) Basics 1-D Fourier Transforms f(x)


Input analytic function Fourier Transformed function

F(kx)

Ref: Rizzoni
9

Fourier Transform Summary

Ref: Gonzalez et al, Text

10

10/19/2006

Fourier Transform Summary

Ref: Gonzalez et al, Text

11

Fourier Transform Summary

Ref: Gonzalez et al, Text

12

10/19/2006

Fourier Transform Summary

Ref: Gonzalez et al, Text

13

2D Fourier Transforms

Where is the information in (u,v) space? Where are the low frequencies? Where are the high frequencies?
Ref: Gonzalez et al, Text

14

10/19/2006

The Fourier space image (k-space)


Highest positive ky frequency

Highest negative kx frequency

Highest positive kx frequency

Highest negative ky frequency Lowest frequency

Ref: Gonzalez et al, Text

15

Fourier space filtering

Spatial frequency changes in the Fourier domain are simply done with linear mathematics!
Ref: Gonzalez et al, Text
16

10/19/2006

Fourier space filtering

Spatial frequency changes in the Fourier domain are simply done with linear mathematics! Edge enhancement example (what is the shape of this filter)
Ref: Gonzalez et al, Text
17

Fourier space filtering

Ref: Gonzalez et al, Text

18

10/19/2006

Try the online DEMO

http://micro.magnet.fsu.edu/primer/java/digitalimaging/processing/fouriertransform/

19

Fourier space filtering

Ref: Gonzalez et al, Text

20

10

10/19/2006

Special filters Butterworth & Gaussian

Ref: Gonzalez et al, Text

21

Special filters Butterworth & Gaussian

Ref: Gonzalez et al, Text

22

11

10/19/2006

Special filters Butterworth & Gaussian

Ref: Gonzalez et al, Text

23

Noise

Ref: Gonzalez et al, Text

24

12

10/19/2006

Noise

Ref: Gonzalez et al, Text

25

Noise: simple linear filtering can help

Ref: Gonzalez et al, Text

26

13

10/19/2006

Noise: frequency domain filtering

Ref: Gonzalez et al, Text

27

Noise: frequency domain filtering

Ref: Gonzalez et al, Text

28

14

10/19/2006

Online resources for more info about image processing

http://micro.magnet.fsu.edu/primer/digitalimaging/imageprocessingintro.html

29

Geometric Linear Transformations


Affine transform

Ref: Gonzalez et al, Text

30

15

10/19/2006

Geometric Linear Transformations


Affine transform

Ref: Gonzalez et al, Text

31

Image compression : changing the binary


code used to reduce # of bits required

Use fewer bits to encode Information that occurs a lot and then use more bits to encode information that occurs little in the image p(r) is the probability of occurrence I2 is a more efficient coding of the bits than I1

Ref: Gonzalez et al, Text

32

16

10/19/2006

Lossy Image compression :


transforms to fewer bits across the entire image
8 bits 4 bits

2 bits

Ref: Gonzalez et al, Text

33

Minimum Lossy Image compression :


bit reduction at the local level, not globally!

Ref: Gonzalez et al, Text

34

17

10/19/2006

Minimum Lossy Image compression :


bit reduction at the local level, not globally!

Ref: Gonzalez et al, Text

35

Minimum Lossy Image compression :


bit reduction at the local level, 8x8 blocks -JPEG

compressed image

predicted error

close up view
Ref: Gonzalez et al, Text
36

18

You might also like