0 Bewertungen0% fanden dieses Dokument nützlich (0 Abstimmungen)
16 Ansichten5 Seiten
The adaptive median filter aims to remove impulse noise while preserving edges. It starts with a 3x3 window and checks if the median value equals the minimum or maximum, indicating potential impulse noise. If so, it increases the window size and rechecks until reaching the maximum size. Otherwise, it checks if the center pixel equals an endpoint, indicating impulse noise. If so, it replaces with the median; otherwise, it keeps the original value. This helps preserve small details better than a standard median filter.
Originalbeschreibung:
Image Restoration Noise based on Gonzalez and woods
The adaptive median filter aims to remove impulse noise while preserving edges. It starts with a 3x3 window and checks if the median value equals the minimum or maximum, indicating potential impulse noise. If so, it increases the window size and rechecks until reaching the maximum size. Otherwise, it checks if the center pixel equals an endpoint, indicating impulse noise. If so, it replaces with the median; otherwise, it keeps the original value. This helps preserve small details better than a standard median filter.
The adaptive median filter aims to remove impulse noise while preserving edges. It starts with a 3x3 window and checks if the median value equals the minimum or maximum, indicating potential impulse noise. If so, it increases the window size and rechecks until reaching the maximum size. Otherwise, it checks if the center pixel equals an endpoint, indicating impulse noise. If so, it replaces with the median; otherwise, it keeps the original value. This helps preserve small details better than a standard median filter.
Purpose: want to remove impulse noise while preserving edges
Algorithm: Level A: A1= zmedian – zmin A2= zmedian – zmax If A1 > 0 and A2 < 0, goto level B Else increase window size If window size <= Smax repeat level A Else return zxy Level B: B1= zxy – zmin B2= zxy – zmax If B1 > 0 and B2 < 0, return zxy where zmin = minimum Else gray return zmedianin Sxy level value zmax = maximum gray level value in Sxy zmedian = median of gray levels in Sxy zxy = gray level value at pixel (x,y) Adaptive Median Filter: How it works
• We start by considering only the immediate neighbors of the
current pixel, a window size of 3×3.
• The purpose of Level A is to determine if the standard median
filter output is impulse noise for this initial window. • If it equals the MAX or MIN, it might be impulse noise, so we increase the window size and try again.
• If it is not, we go to Level B and test to see if the current pixel is
impulse noise. • If it is, we output the median value, if not, we output the current value. • This will tend to preserve edges. Adaptive Median Filter: How it works Level A: A1= zmedian – zmin Determine A2= zmedian – zmax whether zmedian If A1 > 0 and A2 < 0, goto level B is an impulse or not
Else Window is not big enough
increase window size If window size <= Smax repeat level A Level B: Else return zxy Determine zmedian is not an impulse whether zxy is an impulse or not B1= zxy – zmin B2= zxy – zmax If B1 > 0 and B2 < 0, zxy is not an impulse return zxy to preserve original details Adaptive Median Filter: Example
Image corrupted Image obtained Image obtained
by salt-and-pepper using a 7x7 using an adaptive noise with median filter median filter with pa=pb= 0.25 Smax = 7