Download presentation
Presentation is loading. Please wait.
Published byTracy Sutton Modified over 9 years ago
1
CS 376b Introduction to Computer Vision 03 / 17 / 2008 Instructor: Michael Eckmann
2
Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Today’s Topics Comments/Questions Enhancing images (Chap. 5) –review of basis –Fourier transform
3
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Review Standard and Frei-Chen basis matrices for 3x3 images
4
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Sinusoids as a Basis reminders of the terms –frequency –wavelength –amplitude –phase There exists a basis of sinusoidal (sine and cosine) functions. A weighted sum of these basis functions is the Fourier series. The weights are called coefficients. The process of representing a function by its Fourier series is called a Fourier transform. There are Fourier transforms for continuous and discrete functions of 1, 2, etc. dimensions. Since we're dealing with images, we are interested in the discrete Fourier transform in two dimensions.
5
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Sinusoids as a Basis Real images can be represented by Fourier series. This allows us to say what spatial frequencies are in our image. On the board –reminder of Euler's forumla –DFT (discrete Fourier transform) –the inverse DFT u and v are the spatial frequencies compute F(u,v) for all u and v from 0 to N-1 F(u,v) represents the amount of contribution of the pair (sine and cosine) of basis images to the original image. It is a complex number. This complex number is the coefficient (weight) of those pair of functions. The image, f(x,y), can be completely recreated without any loss of data from its transform F(u.v).
6
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Sinusoids as a Basis The complex coefficients are more useful to us in terms of the magnitude and phase. equations on the board for magnitude, phase and power The magnitudes correspond to the amplitudes of the basis functions The amplitude spectrum is the magnitudes collectively. The phase spectrum is the phases collectively. The power spectrum is the square of the amplitude spectrum. –there is an error in our text book on page 177 in equation 5.32 the power spectrum should not have the square root in there These spectrums are often displayed as images. “Frequency domain” vs. “Spatial domain”
7
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Sinusoids as a Basis After transforming an image to its DFT, we can process the image in the frequency domain and the do an inverse DFT to get an altered image. Useful in –enhancing images to remove certain frequencies (e.g. high frequency noise) –extracting texture features --- the coefficients of certain frequencies can be used describe certain textures –image compression can keep only some coefficients e.g. Jpeg uses DCT which has similarities to a DFT as part of its compression scheme
8
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Sinusoids as a Basis Typically the center pixel is u=0, v=0 of a power spectrum. Let's look at some images and their power spectrums. Notice that Magnitude of F(u,v) = Magnitude of F(-u, -v)
9
Michael Eckmann - Skidmore College - CS 376 - Spring 2008 Sinusoids as a Basis The cost of computing the DFT as described is expensive. The Fast Fourier Transform exploits the separability of the fourier transform and performs a 1d transform along each row and a 1d transform along each column. It also exploits another property of the Fourier transform to speed up it's computation. DFT is O(N 4 ) and FFT is O(N 2 logN) for an NxN image.
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.