is the PSNR parameter good to assess the effect of a filter?

6 ビュー (過去 30 日間)
Valeria Leto
Valeria Leto 2022 年 3 月 2 日
コメント済み: Valeria Leto 2022 年 3 月 5 日
Hi! I have filtered an image with 4 different filters, mean, median, gaussian and a low-pass filter in the freq domain. They are all low pass filters, and I would like to asses wich one has smootheed most. I computed the PSNR and I get :
  • 33.00 Mean
  • 33.37 Median
  • 41.50 Gaussian
  • 25.8 freq low pass
So I though the gaussian would be the best to apply edge detection methods but it was not. The best is the freq low pass. So, is the PSNR parameter not good to assess the effect of a filter? Thank you

採用された回答

Image Analyst
Image Analyst 2022 年 3 月 4 日
編集済み: Image Analyst 2022 年 3 月 4 日
You can use psnr(), immse(), or mad() to see how much the smoothed signal varies from the original signal. As the signal gets smoother and differs from the original more, those noise metrics which measure difference from the reference signal should increase, except for PSNR which will decrease. But keep in mind that if one filter has a higher value than another it does not mean it's a better filter. For example consider a median window with a short window width, and another that filters the signal so much that it's just a constant (the mean value). The one that filtered it way down to a constant would have the highest metric but not be the best filter because it obliterated the signal.
In general the best filter to use depends on the noise. Of those you used I would expect the median to be best since it's designed to remove spurious noise while maintaining true edges. The others are all about the same - they just blur/spread the signal. If you're doing experiments (like applying noise to a noise-free signal), I'd compare the mad value between the filtered signal and the original, noise-free signal.
  5 件のコメント
Image Analyst
Image Analyst 2022 年 3 月 4 日
Yes, exactly. But be cognizant of the fact that your reference signal is not the true, noise-free signal (which you do not know) but the bad, noisy signal.
Valeria Leto
Valeria Leto 2022 年 3 月 4 日
ok, so in my case high PSNR means that the filtered signal is similar to the one with noise wich is not good... lol I am supposed to comment in a proper way what I 've done but it's tricky...many thanks

サインインしてコメントする。

その他の回答 (2 件)

yanqi liu
yanqi liu 2022 年 3 月 3 日
yes,sir,may be consider more IQA method,such as PSNR、SSIM
  1 件のコメント
Valeria Leto
Valeria Leto 2022 年 3 月 4 日
but how is it possible that the PSNR decreases if I filter more? because the signal is too low?

サインインしてコメントする。


Image Analyst
Image Analyst 2022 年 3 月 4 日
You might try an image quality metric like brisque(), niqe() or piqe()
Image Quality Metrics
Image quality can degrade due to distortions during image acquisition and processing. Examples of distortion include noise, blurring, ringing, and compression artifacts.
Efforts have been made to create objective measures of quality. For many applications, a valuable quality metric correlates well with the subjective perception of quality by a human observer. Quality metrics can also track unperceived errors as they propagate through an image processing pipeline, and can be used to compare image processing algorithms.
If an image without distortion is available, you can use it as a reference to measure the quality of other images. For example, when evaluating the quality of compressed images, an uncompressed version of the image provides a useful reference. In these cases, you can use full-reference quality metrics to directly compare the target image and the reference image.
If a reference image without distortion is not available. you can use a no-reference image quality metric instead. These metrics compute quality scores based on expected image statistics.
Full-Reference Quality Metrics
Full-reference algorithms compare the input image against a pristine reference image with no distortion.
MetricDescription
immseMean-squared error (MSE). MSE measures the average squared difference between actual and ideal pixel values. This metric is simple to calculate but might not align well with the human perception of quality.
psnrPeak signal-to-noise ratio (pSNR). pSNR is derived from the mean square error, and indicates the ratio of the maximum pixel intensity to the power of the distortion. Like MSE, the pSNR metric is simple to calculate but might not align well with perceived quality.
Structural similarity (SSIM) index. The SSIM metric combines local image structure, luminance, and contrast into a single local quality score. In this metric, structures are patterns of pixel intensities, especially among neighboring pixels, after normalizing for luminance and contrast. Because the human visual system is good at perceiving structure, the SSIM quality metric agrees more closely with the subjective quality score.
Multi-scale structural similarity (MS-SSIM) index. The MS-SSIM metric expands on the SSIM index by combining luminance information at the highest resolution level with structure and contrast information at several downsampled resolutions, or scales. The multiple scales account for variability in the perception of image details caused by factors such as viewing distance from the image, distance from the scene to the sensor, and resolution of the image acquisition sensor.
Because structural similarity is computed locally, ssim, multissim, and multissim3 can generate a map of quality over the image.No-Reference Quality Metrics
No-reference algorithms use statistical features of the input image to evaluate the image quality.
MetricDescription
brisqueBlind/Referenceless Image Spatial Quality Evaluator (BRISQUE). A BRISQUE model is trained on a database of images with known distortions, and BRISQUE is limited to evaluating the quality of images with the same type of distortion. BRISQUE is opinion-aware, which means subjective quality scores accompany the training images.
niqeNatural Image Quality Evaluator (NIQE). Although a NIQE model is trained on a database of pristine images, NIQE can measure the quality of images with arbitrary distortion. NIQE is opinion-unaware, and does not use subjective quality scores. The tradeoff is that the NIQE score of an image might not correlate as well as the BRISQUE score with human perception of quality.
piqePerception based Image Quality Evaluator (PIQE). The PIQE algorithm is opinion-unaware and unsupervised, which means it does not require a trained model. PIQE can measure the quality of images with arbitrary distortion and in most cases performs similar to NIQE. PIQE estimates block-wise distortion and measures the local variance of perceptibly distorted blocks to compute the quality score.
The BRISQUE and the NIQE algorithms calculate the quality score of an image with computational efficiency after the model is trained. PIQE is less computationally efficient, but it provides local measures of quality in addition to a global quality score. All no-reference quality metrics usually outperform full-reference metrics in terms of agreement with a subjective human quality score.
Related Topics

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by