Why median filter is considered as good for removal of salt and pepper noise? What are the other filters used for the same?
Median filter is considered good because unlike averaging filter which ruins the edges of an image by blurring it to remove the noise, median filter removes only the noise without disturbing the edges.
Well, median filter is the best and only filter to remove salt and pepper noise.
Hope this helps:)
Let us look at a $3\times 3$ patch of pixels:
And assume that you have for instance $2$ salt and $3$ pepper pixels, which is pretty harsh. Then you have four valid pixels, let us call them, in magnitude order $p_a$, $p_b$, $p_c$, $p_d$. Then ordering all the values, you get:
$$p \le p \le p_a \le p_b \le p_c \le p_d \le s \le s \le s$$
The median will thus be $p_c$, one of the valid pixel values. As you see, the output is not dependent on the $b=$ or $w=255$ values. Since it is based on ordering, it may tolerate up to $4$ black or white, still outputing one of the valid pixel value. Whether that value is a meaningful candidate for the patch is another story. A complete two-pass scheme is detailed in Salt-and-Pepper Noise Removal by Median-Type Noise Detectors and detail-Preserving Regularization, 2005
This paper proposes a two-phase scheme for removing salt-and-pepper impulse noise. In the first phase, an adaptive median filter is used to identify pixels which are likely to be contaminated by noise (noise candidates). In the second phase, the image is restored using a specialized regularization method that applies only to those selected noise candidates. In terms of edge preservation and noise suppression, our restored images show a significant improvement compared to those restored by using just nonlinear filters or regularization methods only. Our scheme can remove salt-and-pepper-noise with a noise level as high as 90%.