脑血管检测项目matlab源码程序 - matlab图像处理 - 谷速源码
下载频道> 资源分类> matlab源码> 图像处理> 脑血管检测项目matlab源码程序

标题:脑血管检测项目matlab源码程序
分享到:

所属分类: 图像处理 资源类型:程序源码 文件大小: 1.95 KB 上传时间: 2019-07-17 20:04:10 下载次数: 4 资源积分:1分 提 供 者: jiqiren 脑血管检测项目matlab源码程序
内容:
info = dicominfo('8006000186A0_0035_0001.dcm');
I = dicomread(info);
I = double(I(153:360,98:430));
maxI = max(max(I))
I = I/maxI;
figure(1), imshow(I, []) ,title('原图');
 
%img = NLmeansfilter(img,5,2,10);
%figure(2), imshow(img, []), title('滤波');
 
level = graythresh(I)
BW = im2bw(I,level);
%figure(4), imshow(img, []) ,title('二值化');
 
%BW = edge(BW,'canny');
%figure(3), imshow(BW, []), title('Canny');
 
% I=imdilate(I,strel('disk',8));
% I=imerode(I,strel('disk',8));
% BW=bwmorph(I,'thin',20);
 
[H,T,R] = hough(BW);
 
% imshow(H,[],'XData',T,'YData',R,...
% 'InitialMagnification','fit');
% xlabel('\theta'), ylabel('\rho');
% axis on, axis normal, hold on;
% P = houghpeaks(H,10,'threshold',ceil(0.3*max(H(:))));
% x = T(P(:,2)); y = R(P(:,1));
% plot(x,y,'s','color','white');
 
lines = houghlines(BW,T,R,P,'FillGap',10,'MinLength',20);
figure,imshow(BW), hold on
 
max_len = 0;
for k = 1:length(lines)
    xy = [lines(k).point1; lines(k).point2];
    plot(xy(:,1),xy(:,2),'LineWidth',2,'Color','green');
 
    % Plot beginnings and ends of lines
    %plot(xy(1,1),xy(1,2),'x','LineWidth',2,'Color','yellow');
    %plot(xy(2,1),xy(2,2),'x','LineWidth',2,'Color','red');
 
    % Determine the endpoints of the longest line segment
    len = norm(lines(k).point1 - lines(k).point2);
    Len(k)=len
    if ( len > max_len)
        max_len = len;
        xy_long = xy;
    end
end
 
% highlight the longest line segment
%plot(xy_long(:,1),xy_long(:,2),'LineWidth',2,'Color','blue');

文件列表(点击上边下载按钮,如果是垃圾文件请在下面评价差评或者投诉):

关键词: 脑血管 检测 项目 matlab 源码程序

Top_arrow
回到顶部
联系方式| 版权声明| 招聘信息| 广告服务| 银行汇款| 法律顾问| 兼职技术| 付款方式| 关于我们|
网站客服网站客服 程序员兼职招聘 程序员兼职招聘
沪ICP备19040327号-3
公安备案号:沪公网安备 31011802003874号
库纳格流体控制系统(上海)有限公司 版权所有
Copyright © 1999-2014, GUSUCODE.COM, All Rights Reserved