Presentation is loading. Please wait.

Presentation is loading. Please wait.

ELE 488 F06 ELE 488 Fall 2006 Image Processing and Transmission 10-3-06 Image Restoration distortion noise Inverse Filtering Wiener Filtering Ref: Jain,

Similar presentations


Presentation on theme: "ELE 488 F06 ELE 488 Fall 2006 Image Processing and Transmission 10-3-06 Image Restoration distortion noise Inverse Filtering Wiener Filtering Ref: Jain,"— Presentation transcript:

1 ELE 488 F06 ELE 488 Fall 2006 Image Processing and Transmission 10-3-06 Image Restoration distortion noise Inverse Filtering Wiener Filtering Ref: Jain, Sec 8.1 – 8.3. Gonzalez–Woods, Sec 5.5 – 5.8 10/3/06

2 ELE 488 F06 From Matlab ImageToolbox Documentation pp12-4 UMCP ENEE631 Slides (created by M.Wu © 2001) Image Restoration

3 ELE 488 F06 Imperfection in Image Capturing Imaging system –point spread function (impulse response): h(m,n) ≠  (m,n). –out of focus blur caused by local averaging in a circular neighborhood –camera motion: blur caused by local averaging along motion direction –Atomspheric turbulence blur, etc. UMCP ENEE631 Slides (created by M.Wu © 2001) h, H original image u (object) available image v noise η g, G restored image w

4 ELE 488 F06 Undo Linear Spatial-Invariant Distortion Choose G to correct distortion from H Consider special case –no noise, known distortion –Often used to correct blur Consider 1D case first, then take up 2D v = u * h, w = v * g = u * (h * g) want w = u, so h * g = δ. Easy to solve in frequency domain: G(ω) = 1 / H(ω). What if H(ω) = 0? h, H uv  g, G w UMCP ENEE631 Slides (created by M.Wu © 2001) restoration distortion

5 ELE 488 F06 Example Distortion h(n):.25.5.25 non causal H(w) =.5 (cos(w/2) 2, G(w)=1 / H(w), g(n)=? n=5; dw=pi/n; m=-n+1:1:n-1; w=m*dw; mm=-n:1:n; Hw=(cos(w/2)).^2; Gw=1./Hw; gg=fftshift(ifft(ifftshift(Gw))); gh=conv(gg,[.25.5.25]); 3 pt inverse: -0.3333 1.6667 -0.3333 5 pt inverse: 0.2630 -0.9296 2.3333 -0.9296 0.2630 9 pt inverse: 0.2228 -0.7019 1.2958 -2.1501 3.6667 -2.1501 1.2958 -0.7019 0.2228

6 ELE 488 F06.25.5.25 3 sample inverse 9 sample inverse 5 sample inverse

7 ELE 488 F06 3 sample averager: 1 1 1

8 ELE 488 F06

9

10

11

12

13

14

15 Problems With Inverse Filtering Under Noise Zeros in H(  ) –Interpretation: distortion by H removes all info. in those freq. –Inverse filter tries to “compensate” by assigning infinite gains –Amplifies noise: W (ω) = (V+N) / H  N/H for small V Solutions ~ Pseudo-inverse Filtering –Assign zero to G at spectrum nulls of H G(ω) = 1 / H(ω), if | H(ω) | > ε G(ω) = 0, if | H(ω) | < ε –Interpretation: not possible to restore lost information UMCP ENEE631 Slides (created by M.Wu © 2001)

16 ELE 488 F06 Handling Spectrum Nulls Via High-Freq Cut-off Limit restoration to lower frequency components to avoid amplifying noise at high frequencies and at nulls UMCP ENEE631 Slides (created by M.Wu © 2004) Gonzalez/ Woods (Chapter 5)

17 ELE 488 F06 Examples of Inverse & Pseudo-inverse Filtering From Jain Fig.8.10 UMCP ENEE631 Slides (created by M.Wu © 2001)

18 ELE 488 F06 Handling Noise in Deconvolution Inverse filtering is sensitive to noise –Does not explicitly handle noise To balance between deblurring vs. noise suppression: –Minimize MSE between the original u and restored w: e = E{ [ u – w ] 2 }, given v –Best estimate is conditional mean: E { u | v} –usually difficult to solve needs info not usually available, non-linear problem –To find the best linear estimate instead  Wiener filtering –Consider the (desired) image and noise as random fields –Produce linear estimate from observed image v to minimize MSE UMCP ENEE631 Slides (created by M.Wu © 2001/2004) h, H uv  g, G w

19 ELE 488 F06 Wiener Filtering Best linear estimate (minimum MSE) – assume: –spatial-invariant filter w = v * g –wide-sense stationarity for original signal and noise –noise zero-mean and uncorrelated with original signal Solution –from orthogonal condition E{ [ u(n) – w(n) ] v(m) }=0 –Represent in correlation functions: R uv (k) = g(k) * R vv (k) –Take DFT to get representation in power spectrum density –G(ω) = H*(ω) Φ uu (ω) / { |H| 2 (ω) Φ uu (ω) + Φ nn (ω) } = 1 / { H + Φ nn / ( H* Φ uu ) } UMCP ENEE631 Slides (created by M.Wu © 2001)

20 ELE 488 F06 Wiener Filtering (cont) To deblur noisy image, need to balance between: –HPF filter for de-blurring (undo H distortion) –LPF for suppressing noise Noiseless case ~ Φ nn = 0 (inverse filter) –Wiener filter becomes pseudo-inverse filter for Φ nn  0 –G(ω) = 1 / { H + Φ nn / ( H* Φ uu ) } G(ω)  1 / H(ω), if H(ω) ≠ 0 G(ω)  0, if H(ω) = 0 No blur, H = 1 (smoothing Filter) –Attenuate noise according to SNR at each freq. –G(ω) = Φ uu / {Φ uu + Φ nn } = (Φ uu / Φ nn )/ { 1 + Φ uu / Φ nn } UMCP ENEE631 Slides (created by M.Wu © 2001)


Download ppt "ELE 488 F06 ELE 488 Fall 2006 Image Processing and Transmission 10-3-06 Image Restoration distortion noise Inverse Filtering Wiener Filtering Ref: Jain,"

Similar presentations


Ads by Google