基於matlab的退化圖像復原(四)------Lucy-Richarson濾波復原


Lucy-Richarson濾波復原

 

 

I0=imread('src.png');
I=rgb2gray(I0);
subplot(341);
imshow(I);
title('src');


subplot(345);
imshow(I);
title('src');


subplot(349);
imshow(I);
title('src');

H=fspecial('motion',20,30); %運動卷積的偏移矩陣
MotionBlur=imfilter(I,H); %卷積
subplot(342);
imshow(MotionBlur);
title('MotionBlur')

G2=imnoise(MotionBlur,'gaussian',0,0.005);
subplot(346);
imshow(G2);
title('Motion+noise');

LR1=deconvlucy(G2,H,5)
subplot(3,4,10);
imshow(LR1);
title('Motion+noise復原');

H1=fspecial('disk',10); %圓盤狀偏移矩陣
disk=imfilter(I,H1); %卷積
subplot(343);
imshow(disk);
title('disk')

G3=imnoise(disk,'gaussian',0,0.001);
subplot(347);
imshow(G3);
title('disk+noise');

LR2=deconvlucy(G3,H1,10)
subplot(3,4,11);
imshow(LR2);
title('disk+noise復原');

H2=fspecial('unsharp'); %鈍化模糊的偏移矩陣
unsharp=imfilter(I,H2); %卷積
subplot(344);
imshow(unsharp);
title('unsharp')

G4=imnoise(unsharp,'gaussian',0,0.005);
subplot(348);
imshow(G4);
title('unsharp+noise');


LR3=deconvlucy(G4,H2,5)
subplot(3,4,12);
imshow(LR3);
title('unsharp+noise復原');

  

 

感覺只是對光學聚焦模糊有比較好的效果吧。。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM