Dr' Claude C' Chibelushi - PowerPoint PPT Presentation

1 / 29
About This Presentation
Title:

Dr' Claude C' Chibelushi

Description:

Rate of intensity change gives information such as object boundary, presence of noise, ... e.g. Canny edge detector. Increasing degree of blurring. 9/26/09. 35 ... – PowerPoint PPT presentation

Number of Views:94
Avg rating:3.0/5.0
Slides: 30
Provided by: claudecch
Category:

less

Transcript and Presenter's Notes

Title: Dr' Claude C' Chibelushi


1
Fac. of Comp., Eng. Tech. Staffordshire
University
Image Processing, Computer Vision, and Pattern
Recognition
Spatial Domain Filters
Dr. Claude C. Chibelushi
2
Outline
  • Introduction
  • Filter pass band
  • Spatial domain filters
  • Convolution-based filters
  • Mode and median filters
  • Combination of convolution-based filters
  • Summary

3
Introduction
Rate of intensity change gives information such
as object boundary, presence of noise, ...
4
Introduction
  • Filter transforms image such that
  • certain type of information is retained /
    emphasized while others are rejected / attenuated
  • based on rate of change of pixel values

5
Introduction
6
Filter Pass Band
  • Filters let through or attenuate specific ranges
    of image details
  • e.g. slow/gradual or fast changes in pixel value
  • Hence the classification of filters into
  • low-pass filters
  • high-pass filters
  • and other types of filters
  • band-pass filters, band-reject filters,

7
Filter Pass Band
  • Low-pass filter
  • Attenuates fast changes in pixel value but lets
    through slow / gradual changes
  • Typical application noise removal
  • Tends to blur image

8
Filter Pass Band
  • High-pass filter
  • Attenuates slow / gradual changes in pixel value
    but lets through fast changes
  • Typical application edge enhancement
  • Tends to be sensitive to noise
  • Output values may be outside numerical range of
    pixel value
  • scaling may be required

9
Spatial-Domain Filters
  • Spatial-domain filters are based on moving
    window techniques e.g.
  • convolution operation (e.g. Laplacian filter)
  • sorting operation (e.g. median filter)
  • pixel-counting operation (e.g. mode filter)

10
Spatial-Domain Filters
  • Moving window
  • window repeatedly shifted over image
  • calculations performed for each shift
  • only pixels within window are considered

11
Spatial-Domain Filters
  • Convolution
  • Many spatial-domain filters are based on
    convolution
  • Convolution uses a moving window
  • shift-multiply-add operation

12
Spatial-Domain Filters
32
Output value
(-1x9)
(-1x30)
(0x29)
(0x33)
(0x39)
(1x9)
(1x2)
32
window
  • Convolution (example)

13
Spatial-Domain Filters
  • Convolution
  • Shift-multiply-add operation
  • weighted sum of pixel values in neighbourhood
  • weights specified in mask (kernel, template, ...)
  • sum entered in output image at pixel location
    corresponding to mask anchor
  • mask shifted by one pixel
  • Note shift by more than 1 pixel is sometimes
    used (gives smaller output image)

14
Spatial-Domain Filters
  • Convolution
  • Mathematical notation

Output at image row i, column j
for each mask row
for each mask column
15
Spatial-Domain Filters
  • Convolution pseudo code
  • / at each image pixel /
  • for each image row // downward window shifts
  • for each image column // rightward window
    shifts
  • / in image window covered by mask /
  • for each mask row
  • for each mask column
  • update local cumulative weighted sum
  • Note use output buffer

16
Spatial-Domain Filters
  • Convolution
  • Warning
  • Example given earlier shows common implementation
    of convolution
  • but it actually uses formula for cross-correlation

17
Spatial-Domain Filters
  • Convolution-based filters
  • Low-pass filter masks

18
Spatial-Domain Filters
  • Convolution-based filters
  • High-pass filter masks

For general use combine outputs of vertical and
horizontal edge filters
19
Spatial-Domain Filters
High-pass filtering (Sobel masks) note
directional sensitivity
20
Spatial-Domain Filters
  • Convolution-based filters
  • High-pass filter masks

21
Spatial-Domain Filters
  • Convolution-based filters
  • High-pass filter masks

22
Spatial-Domain Filters
  • Convolution-based filters
  • High-pass filter masks

Single mask detects vertical and horizontal edges
23
Spatial-Domain Filters
  • Mode and median filters
  • Some low-pass filters not based on convolution,
    e.g.
  • mode filter
  • output pixel value (at anchor) most common
    value in neighbourhood requires local histogram
  • median filter
  • output pixel value (at anchor) median value
    in neighbourhood requires sorting

24
Spatial-Domain Filters
  • Mode filter pseudo code
  • / at each image pixel /
  • for each image row // downward window shifts
  • for each image column // rightward window
    shifts
  • / in current image window /
  • for each window row
  • for each window column
  • update local histogram
  • put local mode in output buffer

25
Spatial-Domain Filters
  • Median filter pseudo code
  • / at each image pixel /
  • for each image row // downward window shifts
  • for each image column // rightward window
    shifts
  • / in current image window /
  • for each window row
  • for each window column
  • update local sort
  • put local median in output buffer

26
Spatial-Domain Filters
  • Mode and median filters
  • Less blurring of edges (compared to averaging
    filters)
  • Computational requirements may be high sorting
    in the median filter

27
Spatial-Domain Filters
28
Spatial-Domain Filters
  • Combination of convolution-based filters
  • Several filtering passes may be applied to image
  • passes may be parallel or sequential
  • combined effect can be obtained by (one of
    following)
  • combining results of individual passes
  • combining masks into one single-pass mask

29
Spatial-Domain Filters
  • Combination of convolution-based filters
  • Parallel passes
  • e.g. combination of output of directional edge
    detectors (e.g. Sobel edge detector)
  • each edge pixel considered as vector (with
    magnitude and direction)

30
Spatial-Domain Filters
  • Combination of convolution-based filters
  • Parallel passes
  • e.g. addition of output images

Single-pass equivalent add mask coefficients
31
Spatial-Domain Filters
  • Combination of convolution-based filters
  • Parallel passes
  • addition of output images (ctd.)
  • relevant property of convolution
  • distributivity with addition

32
Spatial-Domain Filters
  • Combination of convolution-based filters
  • Sequential passes

Single-pass equivalent convolve masks
33
Spatial-Domain Filters
  • Combination of convolution-based filters
  • Sequential passes (ctd.)
  • relevant property of convolution
  • associativity

34
Spatial-Domain Filters
  • Sometimes beneficial to blur image prior to edge
    detection
  • e.g. Canny edge detector

Increasing degree of blurring
35
Summary
  • Filters retain / reject image details based on
    rate of change of pixel values
  • classes low-pass filter, high-pass filter, ...
  • based on neighbourhood (window) operations
  • e.g. convolution, sorting, counting operations,
  • convolution-based filters use mask

36
Summary
  • Combination of convolution-based filters
  • parallel e.g. for addition of filtered images
  • add mask coefficients
  • sequential convolve masks
Write a Comment
User Comments (0)
About PowerShow.com