- 1
- 0
- 约1.75千字
- 约 8页
- 2020-08-30 发布于浙江
- 举报
Combining Spatial Enhancement Methods
Successful image enhancement is typically not achieved using a single operation
Rather we combine a range of techniques in order to achieve a final result
This example will focus on enhancing the bone scan to the right
源代码及实验截图
Laplacian filter of bone scan (a)
I=imread(a.jpg);
subplot(2,4,1);
imshow(I);
I1=im2double(I); %把图像unit格式转换成double格式
I2=reshape(I1,[679 1278]); %把图像的尺寸由679*426*3转换为679*1278
M1=[0,-1,0; %设置拉普拉斯的卷积核为M1
-1,2,-1;
0,-1,0];
I3=imfilter(I2,M1); %I3为拉普拉斯变换后的图片
subplot(2,4,2);
imshow(I3);
Sharpened version of bone scan achieved by subtracting (a) and (b)
I4=I3+I2; %原图和经过拉普拉斯变换后的图像相加得到锐化图像
subplot(2,4,3);
imshow(I4);
Sobel filter of bone scan (a)
对原图像用Sobel梯度操作,设分量为
gx为[-1,-2,-1;0,0,0;1,2,1],
gy为[-1,0,1;-2,0,2;-1,0,1]的模板。
subplot(2,4,4);
hx=[-1,-2,-1;0,0,0;1,2,1]; %生产sobel垂直梯度模板
hy=[-1,0,1;-2,0,2;-1,0,1]; %生产sobel水平梯度模板
gradx=filter2(hx,I,same);
gradx=abs(gradx); %计算图像的sobel垂直梯度
grady=filter2(hy,I,same);
grady=abs(grady); %计算图像的sobel水平梯度
I5=gradx+grady; %得到图像的sobel梯度
imshow(I5,[]);
Image (d) smoothed with a 5*5 averaging filte
subplot(2,4,5);
h1 = fspecial(average,5) ;
I6 = imfilter(I5,h1);
imshow(I6);
The product of (c) and (e) which will be used as a mask
subplot(2,4,6);
I7=I4.*I6;
imshow(I7);
Sharpened image which is sum of (a) and (f)
subplot(2,4,7);
I8=I+I7;
imshow(I8);
Result of applying a power-law trans. to (g)
对图g进行幂率变换处理
subplot(2,4,8);
gamma=0.5;
c=1;
I9=c.*I8.^gamma;
imshow(I9);
利用拉普拉斯变换突出图像细节,利用梯度法突出其边缘,利用平滑过的梯度图像掩蔽拉普拉斯图像等方法处理图像,通过对比原始图像和混合图像增强方法后的图像,可以发现改善了原始图像的清晰度,增强其对比度,突出谷歌的细节及边缘等等。总的来说,比单一的图像增强方法,如直方图,效果更好。
您可能关注的文档
最近下载
- 《自然教育》课件——自然记录.pptx VIP
- 2022年湖北省荆州市中考英语试题(含答案解析).docx VIP
- 《弟子规》与职业素养教育 课件全套 第1--8部分 总叙---余力学文.pptx
- 摩托车骑行安全培训课件.pptx VIP
- 国际压力性损伤-溃疡预防和治疗临床指南(2025年版)解读PPT课件.pptx VIP
- pcs-9651_080948技术和使用说明书.pdf VIP
- 医学课讲课技巧与方法.pptx VIP
- 《我的个性名片》综合实践课件(后附完整教学设计).pptx VIP
- 《电磁场与电磁波基础教程》读书笔记.pptx VIP
- 第5课 《认识情绪 管理情绪》课件 - 中职高教版心理健康与职业生涯.ppt
原创力文档

文档评论(0)