First taken a fresh image then added salt & pepper noise and finally using median filter removed the noise as it works best in case of this type of noise because it takes the median of the region around the noise while gaussian filter takes the mean of the region section-wise which doesn't remove the noise at all.
First taken a fresh image then added salt & pepper noise and finally using median filter removed the noise as it works best in case of this type of noise because it takes the median of the region around the noise while gaussian filter takes the mean of the region section-wise which doesn't remove the noise at all.