median filtering
Median filtering is a technique used in image processing to reduce noise while preserving edges. It works by replacing each pixel's value with the median value of its neighboring pixels within a defined window. This method is particularly effective for removing salt-and-pepper noise, which consists of random bright and dark pixels.
The process involves sliding a window over the image, calculating the median of the pixel values within that window, and then updating the central pixel with this median value. Median filtering is widely used in various applications, including medical imaging and computer vision, due to its ability to maintain important image features.