Our project focuses on implementing various denoising techniques to fix the quality of images destroyed by noise. Our data revolves around 100 clean images obtained from BSD300. Due to these images being clean, we implemented a code that gave them noise such as Gaussian, Salt and Pepper, and Speckle. Our main objective was to clean the images using Bilateral filtering and wavelet-based denoising. Furthermore, we tested our results by verifying with Peak signal to noise ratio and also Structural Similarity Index.
Using Python, we applied various types of noise—salt and pepper, speckle, and Gaussian—to four images to explore denoising techniques. Initially, we employed classical methods such as wavelet denoising and bilateral filtering, implemented through Python libraries, and manually processed and saved the results.
The two types of denoising we focused on were wavelet denoising and bilateral filtering.
Bilateral filtering:
Applies a weighted average of nearby pixels based on proximity and intensity of color, but preserves edges where the intensity varies sharply.
Smoothes areas with similar intensities while preserving sharp edges.
Works well for images where edge preservation is important but detail preservation is not
Struggles with images with precise features, such as tree bark, or preserving fine details on a face.
Wavelet denoising:
Image is decomposed into wavelet coefficients.
Large features in the image are captured as low frequency (approximation coefficients). Small details are captured as high frequency (detail coefficients). Noise generally affects the high frequency components of an image.
Uses thresholding to remove the noise from the high frequency. For example, if a detail is below a certain threshold, it is removed.
We expect wavelet denoising to remove more noise than Bilateral Filtering
Bilaterally denoised images
Wavelet denoised images
As you can see from the images above, both bilaterally denoised images and wavelet denoised images have their flaws and strengths. The bilaterally denoised images have a lot of noise leftover and lose their color, but the edges are crisp. The wavelet denoised images have a bit less noise, but are blurrier than the bilaterally denoised images.
We found these techniques insufficient for significant noise reduction. As a result, we turned to MPRNet, a pre-trained model that leverages diffusion processes and neural networks to identify and enhance the underlying features of images, resulting in superior denoising performance. This model excels at reducing noise even in heavily corrupted images and can effectively handle images with multiple types of noise.
Despite the improved noise reduction, a notable issue is the distortion of color in the output images. This color distortion occurs because the neural network's training process might not fully preserve the color information while focusing on denoising, leading to a compromise between noise removal and color fidelity. Additionally, the model's emphasis on structural features can sometimes result in altered color tones in the reconstructed images.
Encoder-decoder architectures, combines them into a branch that supervises local information.
Reweighs local features based on areas of the image.
Relies on three weighted attention modules
The pre-trained model leverages diffusion processes and neural networks to effectively identify underlying features in images, addressing challenges in noise reduction. The architecture integrates an encoder-decoder framework, which is then refined through a branch specifically designed to supervise local information. This branch employs reweighting mechanisms to prioritize local features based on specific areas of the image, ensuring a more context-aware output. Additionally, the model incorporates three weighted attention modules that strategically analyze and enhance these local features, resulting in improved image quality. Hyperparameter tuning was conducted to achieve optimal performance, and the model demonstrated its efficacy through tests on multiple noisy images, showcasing its capability to reconstruct images with reduced noise and improved feature retention.
Salt & Pepper Noise
Gaussian Noise
Speckle Noise
Based on the results above, we can see how successful our denoising algorithms were when applied to these three filters. For Gaussian, we see that there is no noise remaining and the images are nearly perfect from the original. For speckle, we once again have no noise remaining but there images are a bit sharper, and a little harder to tell what the original photo is such as the third image. Finally, Salt and Pepper model performed worse than the three noises that we applied. We can see that the images are significantly harder to identify. In all, we are proud of the results that we have yielded but do want to improve on the algorithm and also try to identify why the color of the images changes.
A major advantage of this architecture is its ability to denoise images subjected to multiple types of noise, making it versatile for diverse applications.
Unlike traditional models that may struggle with overlapping or compounded noise patterns, this architecture excels due to its sophisticated integration of diffusion processes, encoder-decoder structures, and weighted attention modules.
Bilateral filtering has high PSNR and SSIM values; this suggests that this filter serves to balance noise reduction and preserving structural details. This would be the best option to have both noise removal as well as image quality.
Wavelet filtering has low PSNR and SSIM values; this method is the worst when considering its ability to preserve details. However, for speckle noise it performed better than the other methods.
Interestingly, the pre-trained model achieves the highest average PSNR but only slightly. However, its SSIM is slightly lower than bilateral filtering - it does a little worse at detail preservation. Based on these metrics, the model may not seem to outperform the others significantly, but visually, the model performs much better, producing much cleaner and appealing images.
Denoising real-world noisy images
Since our data came from having clean images to which we had to manually add the noise to it, we would like to find a dataset that already has noise to the images and see how it compares to our algorithm to ensure we get better results in real-world situations.
Different noises and expansion
There are many different types of noises that an image can have. Because of this, the noise that we used led to a lot of limitations on what images we could use. If we were able to apply different noises, we would be able to branch out to a lot more datasets and images which would make it much more beneficial and applicable.
Test on a larger set of images