Algorithm used for reducing/removing salt & pepper noise from an image