denoising images containing salt and pepper noise

1 view (last 30 days)
ANyone please tell the coding for this algorithm as im not able to get the required output.
step1) A two dimensional square filtering window of size 3 x 3 is slid over a highly contaminated image.
Step2) The pixels inside the window are sorted out in ascending order.
Step 3) Minimum, maximum and median of the pixel values in the processing window are determined.
Step 4) If the central pixel lies between minimum and maximum values, then it is detected as an uncorrupted pixel and the pixel is left undisturbed. Otherwise, it is considered a corrupted pixel value.
Step 5) The corrupted central pixel is replaced by the median of the filtering window, if the median value is not an impulse. If the median value itself is an impulse then the central pixel is replaced by the already processed immediate top neighbouring pixel.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!