Chapter 5 Image Restoration
Preview Goal: improve an image in some predefined sense. Image enhancement: subjective process Image restoration: objective process Restoration attempts to reconstruct an image that has been degraded by using a priori knowledge of the degradation process. Modeling the degradation and applying the inverse process to recover the original image. When degradation model is unknown blind deconvolution (ICA)
A Model of Degradation or Given g(x,y), some knowledge about H, and some knowledge about the noise term, obtain an estimate of the original image.
Noise Models Gaussian noise: electronic circuit sensor noise Rayleigh noise: range imaging Erlang (Gamma noise): laser imaging Exponential noise: laser imaging Uniform noise Impulse (salt-and-pepper noise): faulty switching Periodic noise
Gaussian Noise The PDF of a Gaussian random variable, z, is given by:
Rayleigh Noise The PDF of Rayleigh noise is given by: Mean and variance are given by: Useful for approximating skewed histograms.
Erlang (Gamma) Noise The PDF of Erlang noise is given by: Mean and variance:
Exponential Noise The PDF of exponential noise is given by: where a >0 Mean and variance:
Uniform Noise The PDF of uniform noise is given by: Mean and variance:
Impulse (Salt-and-Pepper) Noise The PDF of (bipolar) impulse noise is given by:
Periodic Noise Arises typically from electrical or electromechanical interference during image acquisition. The only type of spatially dependent noise considered in this chapter.
Illustration (I)
Illustration (II)
Estimation of Noise Parameters Periodic noises: from Fourier spectrum Others: try to compute the mean and variance of a subimage S (containing only constant gray levels).
Restoration in the Presence of Noise Only – Spatial Filtering Mean filters: Arithmetic mean filters Geometric mean filter Harmonic mean filter: Contraharmonic mean filter: Q: the order of the filter. Q>0 eliminates pepper noise, Q <0 eliminates salt noise.
Illustration (I)
Illustration (II)
Illustration (III)
Order-Statistics Filters Median filters Max and min filters Midpoint filter: Alpha-trimmed mean filter: delete the d/2 lowest and d/2 highest gray-level values of g(s,t) in the neighborhood of Sxy , the average
Illustration (I)
Illustration (II)
Illustration (III)
Adaptive Filters Filter’s behavior changes based on statistical characteristics of the image inside the filter region defined by the mxn window. Adaptive, local noise reduction filter Adaptive median filter
Adaptive, local noise reduction filter (a) g(x,y): the value of the noisy image at (x,y) (b) The variance of the noise (c) The mean of the pixels in Sxy (d) Local variance of the pixels in Sxy If (b) is zero, return g(x,y) If (d) is high relative to (b), the filter should return a value close to g(x,y) If the two variances are equal, return the arithmetic mean of the pixels in Sxy
Illustration
Adaptive Median Filter Notation: zmin: minimum gray level value in Sxy zmax: maximum gray level value in Sxy zmed: median of gray levels in Sxy zxy: gray level value at (x,y) Smax: maximum allowed size of Sxy Level A: A1= zmed – zmin, A2= zmed – zmax if A1> 0 and A2 <0, go to level B Else increase the window size If window size <= Smax repeat level A else output zxy Level B: B1= zxy – zmin, B2= zxy – zmax if B1> 0 and B2 <0, output zxy Else output zmed
Illustration
Periodic Noise Reduction By Fourier domain filtering: Bandreject filters Bandpass filters Notch filters
Illustration
Ideal Notch Reject Filter where
Butterworth Notch Reject Filter
Gaussian Notch Reject Filter
Notch Filters
Linear, Position-Invariant Degradations Estimating the degradation function By image observation By experimentation By modeling
Estimation by Image Observation In the strong signal area, using sample gray levels of the object and background to construct an unblurred image Then, Use Hs(u,v) to estimate H(u,v)
Estimation by Experimentation Simulate an impulse by a (very) bright dot of light, the response G(u,v) is related to H(u,v) by:
Figure 5.24
Estimation by Modeling Modeling atmospheric turbulence
Atmospheric Turbulence
Estimation by Modeling (cont’d) Modeling effect of planar motion x0(t),y0(t): If T is the duration of the exposure, then It can be shown that:
Motion Blur If x0(t)=at/T and y0(t)=0, then
Motion Blur Example
Deconvolution Inverse filtering Minimum mean square error (Wiener) filtering Constrained least squares filtering Geometric mean filter
Results (Inverse Filter)
Results (Inverse and Wiener)
Results (Motion Blurs)
Results (Constrained LS Filter)
Recent Developments Blind deconvolution http://cs.unc.edu/~lazebnik/research/fall08/lec05_deblurring.pdf Removing camera shake from a single photograph http://cs.nyu.edu/~fergus/research/deblur.html