Topic: Conservative smoothing is a very simple noise reduction method that trades noise suppression power with the ability to preserve image details. It is effective in dealing with salt and pepper noise, because it ensures that each pixel’s intensity value is bounded withing the intensity range of its neighbors, but it is extremely weak when dealing with additive noise.


Exercise: Create a Python script file and perform the following tasks:

  • Import OpenCV and NumPy libraries.
  • Create a function that takes as input an image and the size of the conservative filter and applies conservative smoothing to the image. Then, it returns the filtered image. The algorithm should use 0-padding in order to avoid the creation of black borders in the image. You can add any extra parameters you desire.
  • Read an image.
  • Corrupt the image with any type of noise you desire.
  • Apply conservative smoothing to the noise image.
  • Finally, display the noise image alongside the filtered one.

Instructions and Material for solution: Click Noise_Functions & Image to download the exercise material.

Help (if needed): Click Pdf to download the exercise help.

Lecture for better understanding:  https://icarus.csd.auth.gr/image-filtering-lecture/

This exercise was developed by C. Georgiadis.

————————————————————————————————————–

For the solutions to the exercises, please contact koroniioanna@csd.auth.gr