Noise Reduction and Estimation
Noise can degrade the visual quality of images, and certain processing operations (thresholding, high-pass filtering) will enhance noise in a non-acceptable way. Acquired images are always noisy (this is best observed on live images where the pixel values fluctuate around the true intensity). When acquired with 8 bits of accuracy, the noise level typically amounts to about 3 to 5 gray-level values. One distinguishes several forms of noise:
- additive: noise amplitude is not related to image contents
- multiplicative: noise amplitude is proportional to local intensity
- uniform: noise amplitude follows a smooth distribution centered around zero
- impulse: noise amplitude is infinite.
Impulse noise produces a "salt and pepper" effect, while uniform noise blends.
Reduces uniform and impulse noise but blurs edges.
Cannot distinguish noise from actual signal changes, so always spoils part of the signal.
Uses the correlation between neighboring pixel values to perform convolution or median filtering:
- Convolution replaces the value at each pixel by a combination of its neighbors, leading to a localized averaging. Linear filtering is recommended to reduce uniform noise. Beware that it tends to blur edges.
Uniform noise reduction by low-pass filtering
- Median filtering replaces each pixel by the median value in the pixel neighborhood (5-th largest value in a 3x3 neighborhood). This reduces impulse noise and keeps sharpness.
Temporal noise reduction is achieved by combining the successive values of individual pixels across time. EasyImage implements recursive averaging and moving averaging.
EasyImage provides three ways to minimize noise by means of several images:
- Temporal average: just accumulates N images and average them; using standard arithmetic operations, as illustrated below. Creates de-noised image after N acquisitions using average values. Noise varies from frame to frame while the signal remains unchanged, so if several images of the same (still) scene are available, noise can be separated from the signal.
The disadvantage of producing one de-noised image after N acquisitions only, is that fast display refresh is not possible.
Simple average
- Temporal moving average: accumulates the last N images and updates the de-noised image each time a new one is acquired, in such a way that the computation time does not depend on N. The whole process is handled by EMovingAverage. The disadvantage of this method is that it combines noisy images together.
Moving average
- Temporal recursive average: combines a noisy image with the previously de-noised image using EasyImage::.RecursiveAverage.
Recursive average
Recursive averaging
This is a well known process for noise reduction by temporal integration. The principle is to continuously update a noise-free image by blending it, using a linear combination, with the raw, noisy, live image stream. Algorithmically, this amounts to the following:
DSTN=a*Src+(1-a)*DstN-1
where a is a mixture coefficient. The value of this coefficient can be adjusted so that a prescribed noise reduction ratio is achieved.
This procedure is effective when applied to still images, but generates a trailing effect on moving objects. The larger the noise reduction ratio, the heavier the trailing effect is. To work around this, a non-linearity can be introduced in the blending process: small gray-level value variations between successive images are usually noise, while large variations correspond to changes in the image.
EasyImage::.RecursiveAverage uses this observation and applies stronger noise reduction to small variations and conversely. This reduces noise in still areas and trailing in moving areas.
For optimal performance, the non-linearity must be pre-computed once for all using function EasyImage::.SetRecursiveAverageLUT.
Before the first call to the EasyImage::.RecursiveAverage method, the 16-bit work image must be cleared (all pixel values set to zero).
To estimate the amount of noise, two or more successive images are required. In the simplest mode, two noisy images are compared. (Other modes are available: if a noise-free image is available, it is compared to a noisy one; a noise-free image can also be built by temporal averaging.) Calculates the root-mean-square amplitude and signal-to-noise ratio.
- EasyImage::.RmsNoise computes the root-mean-square amplitude of noise, by comparing a given image to a reference image. This function supports flexible mask and an input mask argument. BW8, BW16 and C24 source images are supported.
The reference image can be noiseless (obtained by suppressing the source of noise), or affected by a noise of the same distribution as the given image. - EasyImage::.SignalNoiseRatio computes the signal to noise ratio, in dB, by comparing a given image to a reference image. This function supports flexible mask and an input mask argument. BW8, BW16 and C24 source images are supported.
The reference image can be noiseless (obtained by suppressing the source of noise) or be affected by a noise of the same distribution as the given image.
Signal amplitude is the sum of the squared pixel gray-level values.
Noise amplitude is the sum of the squared difference between the pixel gray-level values of the given image and the reference.