Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

08 frequency domain filtering DIP

5,427 views

Published on

Digital image Processing

Published in: Education, Technology, Business

08 frequency domain filtering DIP

  1. 1. Frequency Domain Filtering : 1 Frequency DomainFrequency Domain FilteringFiltering
  2. 2. Frequency Domain Filtering : 2 Blurring/Noise reductionBlurring/Noise reduction Noise characterized by sharp transitions in image intensity Such transitions contribute significantly to high frequency components of Fourier transform Intuitively, attenuating certain high frequency components result in blurring and reduction of image noise
  3. 3. Frequency Domain Filtering : 3 Ideal Low-pass FilterIdeal Low-pass Filter Cuts off all high-frequency components at a distance greater than a certain distance from origin (cutoff frequency) 0 0 1, if ( , ) ( , ) 0, if ( , ) D u v D H u v D u v D ≤ =  >
  4. 4. Frequency Domain Filtering : 4 VisualizationVisualization
  5. 5. Frequency Domain Filtering : 5 Effect of Different CutoffEffect of Different Cutoff FrequenciesFrequencies
  6. 6. Frequency Domain Filtering : 6 Effect of Different CutoffEffect of Different Cutoff FrequenciesFrequencies
  7. 7. Frequency Domain Filtering : 7 Effect of Different CutoffEffect of Different Cutoff FrequenciesFrequencies As cutoff frequency decreases Image becomes more blurred Noise becomes reduced Analogous to larger spatial filter sizes Noticeable ringing artifacts that increase as the amount of high frequency components removed is increased
  8. 8. Frequency Domain Filtering : 8 Why is there ringing?Why is there ringing? Ideal low-pass filter function is a rectangular function The inverse Fourier transform of a rectangular function is a sinc function
  9. 9. Frequency Domain Filtering : 9 RingingRinging
  10. 10. Frequency Domain Filtering : 10 Butterworth Low-pass FilterButterworth Low-pass Filter Transfer function does not have sharp discontinuity establishing cutoff between passed and filtered frequencies Cutoff frequency D0 defines point at which H(u,v)=0.5 [ ] 2 0 1 ( , ) 1 ( , ) / n H u v D u v D = +
  11. 11. Frequency Domain Filtering : 11 Butterworth Low-pass FilterButterworth Low-pass Filter
  12. 12. Frequency Domain Filtering : 12 Spatial RepresentationsSpatial Representations Tradeoff between amount of smoothing and ringing
  13. 13. Frequency Domain Filtering : 13 Butterworth Low-pass Filters of DifferentButterworth Low-pass Filters of Different FrequenciesFrequencies
  14. 14. Frequency Domain Filtering : 14 Gaussian Low-pass FilterGaussian Low-pass Filter Transfer function is smooth, like Butterworth filter Gaussian in frequency domain remains a Gaussian in spatial domain Advantage: No ringing artifacts 2 2 0( , )/2 ( , ) D u v D H u v e− =
  15. 15. Frequency Domain Filtering : 15 Gaussian Low-pass FilterGaussian Low-pass Filter
  16. 16. Frequency Domain Filtering : 16 Gaussian Low-pass FilterGaussian Low-pass Filter
  17. 17. Frequency Domain Filtering : 17 Low-pass Filtering: ExampleLow-pass Filtering: Example
  18. 18. Frequency Domain Filtering : 18 Low-pass Filtering: ExampleLow-pass Filtering: Example
  19. 19. Frequency Domain Filtering : 19 Periodic Noise ReductionPeriodic Noise Reduction Typically occurs from electrical or electromechanical interference during image acquisition Spatially dependent noise Example: spatial sinusoidal noise
  20. 20. Frequency Domain Filtering : 20 ExampleExample
  21. 21. Frequency Domain Filtering : 21 ObservationsObservations Symmetric pairs of bright spots appear in the Fourier spectra Why? Fourier transform of sine function is the sum of a pair of impulse functions Intuitively, sinusoidal noise can be reduced by attenuating these bright spots [ ]0 0 0 1 sin(2 ) ( ) ( ) 2 k x j k k k kπ δ δ⇔ + − −
  22. 22. Frequency Domain Filtering : 22 Bandreject FiltersBandreject Filters Removes or attenuates a band of frequencies about the origin of the Fourier transform Sinusoidal noise may be reduced by filtering the band of frequencies upon which the bright spots associated with period noise appear
  23. 23. Frequency Domain Filtering : 23 Example: Ideal Bandreject FiltersExample: Ideal Bandreject Filters 0 0 0 0 1, if ( , ) 2 ( , ) 0, if ( , ) 2 2 1, if ( , ) 2 W D u v D W W H u v D D u v D W D u v D  < −   = − ≤ < +   > + 
  24. 24. Frequency Domain Filtering : 24 ExampleExample
  25. 25. Frequency Domain Filtering : 25 Notchreject FiltersNotchreject Filters Idea: Sinusoidal noise appears as bright spots in Fourier spectra Reject frequencies in predefined neighborhoods about a center frequency In this case, center notchreject filters around frequencies coinciding with the bright spots
  26. 26. Frequency Domain Filtering : 26 Some Notchreject FiltersSome Notchreject Filters
  27. 27. Frequency Domain Filtering : 27 ExampleExample
  28. 28. Frequency Domain Filtering : 28 SharpeningSharpening Edges and fine detail characterized by sharp transitions in image intensity Such transitions contribute significantly to high frequency components of Fourier transform Intuitively, attenuating certain low frequency components and preserving high frequency components result in sharpening
  29. 29. Frequency Domain Filtering : 29 Sharpening Filter Transfer FunctionSharpening Filter Transfer Function Intended goal is to do the reverse operation of low-pass filters When low-pass filer attenuates frequencies, high-pass filter passes them When high-pass filter attenuates frequencies, low-pass filter passes them ( , ) 1 ( , )hp lpH u v H u v= −
  30. 30. Frequency Domain Filtering : 30 Some Sharpening FilterSome Sharpening Filter Transfer FunctionsTransfer Functions Ideal High-pass filter Butterworth High-pass filter Gaussian High-pass filter 0 0 0, if ( , ) ( , ) 1, if ( , ) D u v D H u v D u v D ≤ =  > [ ] 2 0 1 ( , ) 1 / ( , ) n H u v D D u v = + 2 2 0( , )/2 ( , ) 1 D u v D H u v e− = −
  31. 31. Frequency Domain Filtering : 31 Sharpening Filter Transfer FunctionsSharpening Filter Transfer Functions
  32. 32. Frequency Domain Filtering : 32 Spatial Representation ofSpatial Representation of Highpass FiltersHighpass Filters
  33. 33. Frequency Domain Filtering : 33 Filtered Results: IHPFFiltered Results: IHPF
  34. 34. Frequency Domain Filtering : 34 Filtered Results: BHPFFiltered Results: BHPF
  35. 35. Frequency Domain Filtering : 35 Filtered Results: GHPFFiltered Results: GHPF
  36. 36. Frequency Domain Filtering : 36 ObservationsObservations As with ideal low-pass filter, ideal high-pass filter shows significant ringing artifacts Second-order Butterworth high-pass filter shows sharp edges with minor ringing artifacts Gaussian high-pass filter shows good sharpness in edges with no ringing artifacts
  37. 37. Frequency Domain Filtering : 37 High-boost filteringHigh-boost filtering In frequency domain ( , ) ( , ) ( , )lpg x y Af x y f x y= − ( , ) ( 1) ( , ) ( , ) ( , )hpg x y A f x y f x y h x y= − + ∗ ( , ) ( 1) ( , ) ( , ) ( , )lpg x y A f x y f x y f x y= − + − ( , ) ( 1) ( , ) ( , )hpg x y A f x y f x y= − + ( , ) ( 1) ( , ) ( , ) ( , )G u v A F u v F u v H u v= − + ( , ) ( 1) ( , ) ( , )hp hb G u v A H u v F u v H  = − + 144424443
  38. 38. Frequency Domain Filtering : 38 High frequency emphasisHigh frequency emphasis Advantageous to accentuate enhancements made by high- frequency components of image in certain situations (e.g., image visualization) Solution: multiply high-pass filter by a constant and add offset so zero frequency term not eliminated Generalization of high-boost filtering ( , ) ( , )hfe hpH u v a bH u v= +
  39. 39. Frequency Domain Filtering : 39 ResultsResults
  40. 40. Frequency Domain Filtering : 40 Homomorphic FilteringHomomorphic Filtering Image can be modeled as a product of illumination (i) and reflectance (r) Can't operate on frequency components of illumination and reflectance separately ( , ) ( , ) ( , )f x y i x y y x y= [ ] [ ] [ ]( , ) ( , ) ( , )f x y i x y r x yℑ ≠ ℑ ℑ
  41. 41. Frequency Domain Filtering : 41 Homomorphic FilteringHomomorphic Filtering Idea: What if we take the logarithm of the image? Now the frequency components of i and r can be operated on separately ln ( , ) ln ( , ) ln ( , )f x y i x y r x y= + [ ] [ ] [ ]ln ( , ) ln ( , ) ln ( , )f x y i x y r x yℑ = ℑ + ℑ
  42. 42. Frequency Domain Filtering : 42 Homomorphic FilteringHomomorphic Filtering FrameworkFramework
  43. 43. Frequency Domain Filtering : 43 Homomorphic Filtering: ImageHomomorphic Filtering: Image EnhancementEnhancement Simultaneous dynamic range compression (reduce illumination variation) and contrast enhancement (increase reflectance variation) Illumination component characterized by slow spatial variations (low spatial frequencies) Reflectance component characterized by abrupt spatial variations (high spatial frequencies)
  44. 44. Frequency Domain Filtering : 44 Homomorphic Filtering: ImageHomomorphic Filtering: Image EnhancementEnhancement Can be accomplished using a high frequency emphasis filter in log space DC gain of 0.5 (reduce illumination variations) High frequency gain of 2 (increase reflectance variations) Output of homomorphic filter ( ) 2 ( , ) ( , ) ( , )g x y i x y r x y≈
  45. 45. Frequency Domain Filtering : 45 ExampleExample
  46. 46. Frequency Domain Filtering : 46 Homomorphic Filtering: Noise ReductionHomomorphic Filtering: Noise Reduction Multiplicative noise model Transforming into log space turns multiplicative noise to additive noise Low-pass filtering can now be applied to reduce noise ( , ) ( , ) ( , )f x y s x y n x y= ln ( , ) ln ( , ) ln ( , )f x y s x y n x y= +
  47. 47. Frequency Domain Filtering : 47 ExampleExample

×