smoothing filters in spatial domain
TRANSCRIPT
![Page 1: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/1.jpg)
1
SMOOTHING FILTERS IN SPATIAL DOMAIN
Submitted by,M.Madhu BalaP.MalathiR.Mathu SiniV.Praseetha
Submitted to,G. Murugeswari M.E,Assistant Professor,MS University,Triunelveli.
![Page 2: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/2.jpg)
2
ContentsWhat is Spatial filterMechanism of spatial filterSmoothing filters in spatial
Linear filterNon-linear filter
conclusion
![Page 3: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/3.jpg)
3
Spatial FilterA spatial filter is an image operation where
each pixel value I(u, v) is changed by a
function of the intensities of pixels in a
neighborhood of (u, v).
Spatial filtering term is the filtering
operations that are performed directly on the
pixels of an image.
![Page 4: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/4.jpg)
4
Mechanism of Spatial Filtering
The process consists simply of moving the
filter mask from point to point in an image.
At each point (x,y) the response of the filter
at that point is calculated using a predefined
relationship.
![Page 5: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/5.jpg)
5
Smoothing Spatial FilterSmoothing filters are used for
blurring noise reduction.
Blurring is used in preprocessing steps to removal of small details from an image prior to object extraction and bridging of small gaps in lines or curvesNoise reduction can be accomplished by blurring
![Page 6: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/6.jpg)
6
Types of Smoothing FilterThere are 2 way of smoothing spatial filters
Linear Filters – operations performed on
image pixel
Order-Statistics (non-linear) Filters - based
on ranking the pixels
![Page 7: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/7.jpg)
7
Linear Filter
Linear spatial filter is simply the average of
the pixels contained in the neighborhood of
the filter mask.
The idea is replacing the value of every pixel
in an image by the average of the gray
levels in the neighborhood defined by the
filter mask.
![Page 8: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/8.jpg)
8
Linear Filter (cont..)This process result in an image reduce the
sharp transitions in intensities.
Two mask
Averaging filter
Weighted averaging filter
![Page 9: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/9.jpg)
9
Averaging FilterA major use of averaging filters is in the reduction of irrelevant detail in image.mxn mask would have a normalizing constant equal to 1/mn.Its also known as low pass filter.A spatial averaging filter in which all coefficients are equal is called a box filter.
![Page 10: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/10.jpg)
10
Averaging Filter - Example
1 1 1
1 1 1
1 1 1
91
![Page 11: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/11.jpg)
11
Weighted Averaging FilterPixels are multiplied by different coefficients, thus giving more weight to some pixel at the expanses of others.The center pixel is multiplied by a higher value than any other, thus giving the pixel more importance in the calculation of average.The other pixels are inversely weighted as a function of their distance from center of mask
![Page 12: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/12.jpg)
12
Weighted Averaging FilterThe general implementation for filtering an MxN image with a weighted averaging filter of size m x n is given by the expression
For complete filtered image apply x = 0,1,2,3……..m-1 and y=0,1,2,3,……..n-1 in the above equation.
a
as
b
bt
a
as
b
bt
tsw
tysxftswyxg
),(
),(),(),(
![Page 13: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/13.jpg)
13
Weighted Average Filter - Example
1 2 1
2 4 2
1 2 1
161
![Page 14: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/14.jpg)
14
Order-Statistics FilterOrder-statistics filters are nonlinear spatial
filters.
It is based on ordering (ranking) the pixels
contained in the image area encompassed by
the filter,
It replacing the value of the center pixel with the
value determined by the ranking result.
![Page 15: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/15.jpg)
15
Order- statics filterThe filter selects a sample from the window, does not average
Edges are better preserved than with liner filters
Best suited for “salt and pepper” noise
![Page 16: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/16.jpg)
16
Types of order-statics filterDifferent types of order-statics filters are
Minimum filter
Maximum filter
Median filter
![Page 17: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/17.jpg)
17
Minimum FilterThe 0th percentile filter is the min filter.
Minimum filter selects the smallest value in the
window and replace the center by the smallest
value
Using comparison the minimum value can be obtained fast.(not necessary to sort)
It enhances the dark areas of image
![Page 18: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/18.jpg)
18
Minimum Filter - Example.
( mask size =3 x 3) ( mask size =7 x 7)
![Page 19: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/19.jpg)
19
Maximum FilterThe maximum filter selects the largest value within of pixel values, and replace the center by the largest value.
Using comparison the maximum value can be obtained fast.(not necessary to sort)Using the 100th percentile results in the so-called max filter
it enhances bright areas of image
![Page 20: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/20.jpg)
20
Maximum Filter
mask (3 x 3) mask (7 x 7)
![Page 21: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/21.jpg)
21
Median FilterThree steps to be followed to run a median filter:1. Consider each pixel in the image2. Sort the neighboring pixels into order based upon their intensities3. Replace the original value of the pixel with the median value from the list.
![Page 22: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/22.jpg)
22
Median Filter - Process
![Page 23: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/23.jpg)
23
Median Filter - Example
Median Filter size =7 x 7
Median Filter size =3 x 3
![Page 24: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/24.jpg)
24
conclusionA linear filter cannot totally eliminate impulse noise, as a single pixel which acts as an intensity spike can contribute significantly to the weighted average of the filter.
Non-linear filters can be robust to this type of noise because single outlier pixel intensities can be eliminated entirely.
![Page 25: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/25.jpg)
25
Original image
Median filter
Original imageMean filter
![Page 26: Smoothing Filters in Spatial Domain](https://reader035.vdocuments.site/reader035/viewer/2022081512/5871f8c61a28ab5c348b7127/html5/thumbnails/26.jpg)
26