Frequency domain filtering fundamentals



Similar documents
Lectures 6&7: Image Enhancement

Linear Filtering Part II

Color image processing: pseudocolor processing

Lecture 14. Point Spread Function (PSF)

Convolution, Correlation, & Fourier Transforms. James R. Graham 10/25/2005

Aliasing, Image Sampling and Reconstruction

EECS 556 Image Processing W 09. Interpolation. Interpolation techniques B splines

FFT Algorithms. Chapter 6. Contents 6.1

How To Understand The Nyquist Sampling Theorem

Computational Foundations of Cognitive Science

SIGNAL PROCESSING & SIMULATION NEWSLETTER

Sharpening through spatial filtering

Correlation and Convolution Class Notes for CMSC 426, Fall 2005 David Jacobs

Design of FIR Filters

Admin stuff. 4 Image Pyramids. Spatial Domain. Projects. Fourier domain 2/26/2008. Fourier as a change of basis

Introduction to Digital Filters

Digital Imaging and Multimedia. Filters. Ahmed Elgammal Dept. of Computer Science Rutgers University

Specular reflection. Dielectrics and Distribution in Ray Tracing. Snell s Law. Ray tracing dielectrics

Applications of the DFT

The Fourier Analysis Tool in Microsoft Excel

Function Guide for the Fourier Transformation Package SPIRE-UOL-DOC

Convolution. 1D Formula: 2D Formula: Example on the web:

Procedure for Graphing Polynomial Functions

Chapter 4 Image Enhancement in the Frequency Domain. Chapter 4 Image Enhancement in the Frequency Domain

L9: Cepstral analysis

The continuous and discrete Fourier transforms

Computational Optical Imaging - Optique Numerique. -- Deconvolution --

Determine If An Equation Represents a Function

Canny Edge Detection

Chapter 7 - Roots, Radicals, and Complex Numbers

Lecture 9. Poles, Zeros & Filters (Lathi 4.10) Effects of Poles & Zeros on Frequency Response (1) Effects of Poles & Zeros on Frequency Response (3)

Loop Bandwidth and Clock Data Recovery (CDR) in Oscilloscope Measurements. Application Note

Section 9.1 Vectors in Two Dimensions

Figure 1.1 Vector A and Vector F

Supplemental Worksheet Problems To Accompany: The Pre-Algebra Tutor: Volume 1 Section 9 Order of Operations

Lecture 18: The Time-Bandwidth Product

Palmprint Recognition. By Sree Rama Murthy kora Praveen Verma Yashwant Kashyap

Practice with Proofs

Understand the effects of clock jitter and phase noise on sampled systems A s higher resolution data converters that can

SIMPLIFYING ALGEBRAIC FRACTIONS

Filter Design in Thirty Seconds

Frequency Response of Filters

Introduction to the Smith Chart for the MSA Sam Wetterlin 10/12/09 Z +

AM Receiver. Prelab. baseband

Geometric Transformations

Impedance Matching. Using transformers Using matching networks

Algebra Practice Problems for Precalculus and Calculus

Lecture 6: Classification & Localization. boris. ginzburg@intel.com

Bildverarbeitung und Mustererkennung Image Processing and Pattern Recognition

In mathematics, there are four attainment targets: using and applying mathematics; number and algebra; shape, space and measures, and handling data.

Frequency Response of FIR Filters

Frequency response: Resonance, Bandwidth, Q factor

ELECTRIC FIELD LINES AND EQUIPOTENTIAL SURFACES

Lecture 8 : Coordinate Geometry. The coordinate plane The points on a line can be referenced if we choose an origin and a unit of 20

Introduction to IQ-demodulation of RF-data

Zeros of a Polynomial Function

Chapter 3.8 & 6 Solutions

Tutorial. Phase, polarity and the interpreter s wavelet. tutorial. Rob Simm 1 & Roy White 2

Linear Programming. March 14, 2014

4 Sums of Random Variables

ECE 3510 Final given: Spring 11

Lecture 2. Binary and Hexadecimal Numbers

Time series analysis Matlab tutorial. Joachim Gross

Graphing - Parallel and Perpendicular Lines

SOFTWARE FOR GENERATION OF SPECTRUM COMPATIBLE TIME HISTORY

Homework # 3 Solutions

CHAPTER 24 GAUSS S LAW

SGN-1158 Introduction to Signal Processing Test. Solutions

3.1. RATIONAL EXPRESSIONS

88 CHAPTER 2. VECTOR FUNCTIONS. . First, we need to compute T (s). a By definition, r (s) T (s) = 1 a sin s a. sin s a, cos s a

Factoring Polynomials and Solving Quadratic Equations

Designing Gain and Offset in Thirty Seconds

Number Sense and Operations

The Algorithms of Speech Recognition, Programming and Simulating in MATLAB

Convolution. The Delta Function and Impulse Response

Chapter 6. Work and Energy

Nonlinear Algebraic Equations. Lectures INF2320 p. 1/88

Simplifying Algebraic Fractions

Trigonometric Functions: The Unit Circle

Notes on Orthogonal and Symmetric Matrices MENU, Winter 2013

Logo Symmetry Learning Task. Unit 5

Lab 1. The Fourier Transform

MAC Learning Objectives. Module 10. Polar Form of Complex Numbers. There are two major topics in this module:

RANDOM VIBRATION AN OVERVIEW by Barry Controls, Hopkinton, MA

Problem Set V Solutions

MATH 10550, EXAM 2 SOLUTIONS. x 2 + 2xy y 2 + x = 2

Lesson 6: Measuring Trees

8.2. Solution by Inverse Matrix Method. Introduction. Prerequisites. Learning Outcomes

POLYNOMIAL FUNCTIONS

2.2 Creaseness operator

Galaxy Morphological Classification

Optimizing Masimo SET SpO2 Alarm Settings on Select GE Monitors

Useful Number Systems

3. Evaluate the objective function at each vertex. Put the vertices into a table: Vertex P=3x+2y (0, 0) 0 min (0, 5) 10 (15, 0) 45 (12, 2) 40 Max

Sachin Patel HOD I.T Department PCST, Indore, India. Parth Bhatt I.T Department, PCST, Indore, India. Ankit Shah CSE Department, KITE, Jaipur, India

To give it a definition, an implicit function of x and y is simply any relationship that takes the form:

Agilent Time Domain Analysis Using a Network Analyzer

Implementation of Canny Edge Detector of color images on CELL/B.E. Architecture.

Positive Feedback and Oscillators

Transcription:

Frequency domain filtering fundamentals by Gleb V. Tcheslavski: gleb@ee.lamar.edu http://ee.lamar.edu/gleb/dip/index.htm Spring 2008 ELEN 4304/5365 DIP 1 Preliminaries For a digital image f(x,y) the basic filtering equation is 1 { HuvFuv } gxy (, ) = I (, ) (, ) Where H(u,v) and F(u,v) are DFTs of the image and of the filter. Their product is defined by array (element-by-element) multiplication. Specifications of H(u,v) are simplified considerably when using functions symmetric about their centers. This requires that F(u,v) is also centered, which is accomplished by multiplying the input image by (-1) x+y before computing its transform. Spring 2008 ELEN 4304/5365 DIP 2 1

Simple filters Considering the following image with centered (and scaled) DFT Spring 2008 ELEN 4304/5365 DIP 3 Simple filters One of the simplest filters would be H(u,v) having 0 at the center and 1 elsewhere. Such filter will reject the DC (constant) term and leave everything else unchanged. Since the DC term represents an average intensity, setting it to zero results in reduction of average intensity to zero. Therefore, the resulting image appears darker. Actually, aero average implies negative intensities. Spring 2008 ELEN 4304/5365 DIP 4 2

Simple filters Low frequencies in the transform are related to slowly varying intensity components of image. High frequencies are caused by sharp transitions in intensity (edges, noise). Therefore, LPF will blur an image reducing details (and noise). HPF will enhance sharp details but cause reduction in contrast since it eliminates DC component. Adding a small constant to a HPF does not affect sharpening properties but prevents elimination i of DC term and, thus, preserves contrast. Spring 2008 ELEN 4304/5365 DIP 5 Simple filters a=0.85 Spring 2008 ELEN 4304/5365 DIP 6 3

Zero padding Periodicity implied by DFT leads to a wraparound error: data from adjacent periods aliases leading to incorrect results of convolution. To avoid wraparounds, convolved functions must be zero padded. Spring Correct 2008 result ELEN 4304/5365 DIP 7 More on zero padding Sample image Blurred without padding Blurred with padding Blurred images are not uniform: top white edges are blurred but side edges are not (without zero padding). The zero padding leads to an expected result. Spring 2008 ELEN 4304/5365 DIP 8 4

More on zero padding Image Image No padding With padding Due to periodicity implicit while using DFT, a spatial filter passing through the top edge of the image encompasses a part of the image and also a part of the bottom of the periodic image right above it. Padding helps to avoid this Spring 2008 ELEN 4304/5365 DIP 9 Zero padding and ringing Considering an ideal LPF and its spatial representation obtained via multiplication by (-1) u and IDFT, we notice that zero-padding will lead to discontinuities. If we compete DFT of zeropadded filter (to obtain its frequency characteristic), ti ringing (Gibbs?) will occur. Ideal infinite sinc truncation ringing! Spring 2008 ELEN 4304/5365 DIP 10 5

Appearance of ringing Results of filtering with ILPF Notice ringing appearance. We cannot use ideal filters AND zero-padding at the same time! One approach would be to zero-pad images and then create filters (of the same zero-padded size) in frequency domain. However, this will produce (insignificant though) wraparounds since the filter won t be zero-padded. Spring 2008 ELEN 4304/5365 DIP 11 On phase angle Since DFT of an image is a complex array, say The filtered image would be Fuv (, ) = Ruv (, ) + jiuv (, ) gxy (, ) =I HuvRuv (, ) (, ) + jhuviuv (, ) (, ) We are interested in filters affecting the real and imaginary a parts equally zero-phase-shift filters. Even small changes in the phase angle may have drastic effect! 1 { } Phase multiplied by 0.5 Phase multiplied by 0.25 Spring 2008 ELEN 4304/5365 DIP 12 6

Summary of steps 1. For the input image f(x,y) of size MxN, form the zero-padded image f p (x,y) of size PxQ (typically P = 2M, Q = 2N), where P 2 M 1; Q 2 N 1 2. Obtain f c (x,y) multiplying f p (x,y) by (-1) x+y to center its transform; 3. Compute the DFT of the f c (x,y); 4. Generate a real, symmetric filter function H(u,v) of size PxQ with center at coordinates (P/2, Q/2); 5. Form the product G(u,v) = H(u,v) F(u,v) via array multiplication; 6Ob 6. Obtain the processed dimage 1 (, ) ( { (, )} )( 1) x + g y p x y = real I G u v 7. Finally, extract g(x,y) the MxN region from the top left quadrant of g p (x,y). Spring 2008 ELEN 4304/5365 DIP 13 The original image zero-padded scaled by (-1) x+y DFT DFT of LPF DFT of filtering result IDFT extracted filtered image. Summary of steps Spring 2008 ELEN 4304/5365 DIP 14 7

Spatial vs. Frequency domains The link between filtering in spatial and in frequency domains is the convolution theorem... h ( xy, ) H ( uv, ) However, DFT implements a circular convolution. Considering next the image and its spectrum (magnitude of its DFT) of size 600 x 600 Spring 2008 ELEN 4304/5365 DIP 15 Spatial vs. Frequency domains We attempt to use a 3x3 Sobel mask Therefore, we need to zero-pad both the image and the mask to size of 602 x 602 (keeping the mask at the center to preserve symmetry) to avoid wraparounds. The filter I n frequency domain Results of frequencydomain filtering and spatial filtering are same. Spring 2008 ELEN 4304/5365 DIP 16 8