| 3 | 1/1 | 返回列表 |
| 查看: 482 | 回復(fù): 2 | ||
yyhmbb銀蟲(chóng) (初入文壇)
|
[求助]
matlab程序求助 已有1人參與
|
| 本人現(xiàn)有一組ct掃描圖片,想把它變成三維數(shù)值圖,區(qū)分里面的不同物質(zhì)。急求。 |
|
你這個(gè)問(wèn)題解決了沒(méi)有。我知道有些方法可以幫到你,首先我推薦你使用專(zhuān)業(yè)軟件來(lái)處理這些數(shù)據(jù),比如Avizo和mimics。另外,如果非得用matlab處理,我看了下是tif文件(不是dicom的),可以參照下面這個(gè)帖子。http://au.mathworks.com/help/images/examples/exploring-slices-from-a-3-dimensional-mri-data-set.html 另外,找了個(gè)mri的代碼,你自己研究下吧 %% mriplot.m % Click on any the three MRI images and press "ENTER" to change slices at new [x,y,z] positions. % Press "ESC" and press "ENTER" to exit. % by Binlin Wu -- CCNY % bwu@sci.ccny.cuny.edu % 09/14/2010 load mri.mat; D1=double(squeeze(D)); DIM = size(D1); [X,Y,Z]=meshgrid(1:DIM(2),1:DIM(1),1:DIM(3)); h1=subplot(2,2,1);imagesc(D1(:,:,round(DIM(3)/2)),[min(D1(:)) max(D1(:))]);colormap(gray);title('axial');colorbar; xlabel('x');ylabel('y') h2=subplot(2,2,2);imagesc(squeeze(D1(:,round(DIM(2)/2),:)),[min(D(:)) max(D(:))]);colormap(gray);title('sagittal');colorbar; xlabel('z');ylabel('y') h3=subplot(2,2,3);imagesc(squeeze(D1(round(DIM(1)/2),:,:)),[min(D(:)) max(D(:))]);colormap(gray);title('coronal');colorbar; xlabel('z');ylabel('x') subplot(2,2,4);slice(X,Y,Z,D1,64,64,14);colormap(gray);shading flat;title('3D Slices') xlabel('x');ylabel('y');zlabel('z'); x=round(DIM(2)/2);y=round(DIM(1)/2);z=round(DIM(3)/2); button = 0; while(1) try [A,B,button]=ginput catch return end if length(A)==0 A=14;B=64;button=0; end A=A(end); B=B(end); button=button(end); A=ceil(A-0.5); B=ceil(B-0.5); if button==27 break; end if gca==h1 x=A; y=B; if x<=0 || x>DIM(2) || y<=0 || y>DIM(1) continue end axes(h2);imagesc(squeeze(D1(:,x,:)),[min(D(:)) max(D1(:))]);colormap(gray);title('sagittal');colorbar; xlabel('z');ylabel('y') axes(h3);imagesc(squeeze(D1(y,:,:)),[min(D(:)) max(D1(:))]);colormap(gray);title('coronal');colorbar; xlabel('z');ylabel('x') subplot(2,2,4);slice(X,Y,Z,D1,x,y,z);colormap(gray);shading flat;title('3D Slices') xlabel('x');ylabel('y');zlabel('z'); elseif gca==h2 z=A; y=B; if z<=0 || z>DIM(3) || y<=0 || y>DIM(1) continue end axes(h1);imagesc(D1(:,:,z),[min(D1(:)) max(D1(:))]);colormap(gray);title('axial');colorbar; xlabel('x');ylabel('y') axes(h3);imagesc(squeeze(D1(y,:,:)),[min(D1(:)) max(D1(:))]);colormap(gray);title('coronal');colorbar; xlabel('z');ylabel('x') subplot(2,2,4);slice(X,Y,Z,D1,x,y,z);colormap(gray);shading flat;title('3D Slices') xlabel('x');ylabel('y');zlabel('z'); elseif gca==h3 z=A; x=B; if x<=0 || x>DIM(2) || z<=0 || z>DIM(3) continue end axes(h1);imagesc(D1(:,:,z),[min(D1(:)) max(D1(:))]);colormap(gray);title('axial');colorbar; xlabel('x');ylabel('y') axes(h2);imagesc(squeeze(D1(:,x,:)),[min(D1(:)) max(D1(:))]);colormap(gray);title('sagittal');colorbar; xlabel('z');ylabel('y') subplot(2,2,4);slice(X,Y,Z,D1,x,y,z);colormap(gray);shading flat;title('3D Slices') xlabel('x');ylabel('y');zlabel('z'); end end |

金蟲(chóng) (小有名氣)

| 3 | 1/1 | 返回列表 |
| 最具人氣熱帖推薦 [查看全部] | 作者 | 回/看 | 最后發(fā)表 | |
|---|---|---|---|---|
|
[考研] 333求調(diào)劑 +5 | 87639 2026-03-21 | 5/250 |
|
|---|---|---|---|---|
|
[考研] 299求調(diào)劑 +5 | shxchem 2026-03-20 | 7/350 |
|
|
[考研] 303求調(diào)劑 +5 | 睿08 2026-03-17 | 7/350 |
|
|
[考研] 332求調(diào)劑 +4 | ydfyh 2026-03-17 | 4/200 |
|
|
[考研]
|
.6lL 2026-03-18 | 8/400 |
|
|
[考研] 一志愿華南師大 070300(化學(xué))304分求調(diào)劑 +3 | 0703武芊慧雪304 2026-03-18 | 3/150 |
|
|
[考研] 一志愿西南交大,求調(diào)劑 +5 | 材化逐夢(mèng)人 2026-03-18 | 5/250 |
|
|
[考研] 22408 344分 求調(diào)劑 一志愿 華電計(jì)算機(jī)技術(shù) +4 | solanXXX 2026-03-20 | 4/200 |
|
|
[考研] 295求調(diào)劑 +4 | 一志愿京區(qū)211 2026-03-18 | 6/300 |
|
|
[考研] 290求調(diào)劑 +7 | ^O^乜 2026-03-19 | 7/350 |
|
|
[考研] 一志愿武理材料工程348求調(diào)劑 +3 |  ̄^ ̄゜汗 2026-03-19 | 4/200 |
|
|
[考研] 261求B區(qū)調(diào)劑,科研經(jīng)歷豐富 +3 | 牛奶很忙 2026-03-20 | 4/200 |
|
|
[考研] 工科材料085601 279求調(diào)劑 +7 | 困于星晨 2026-03-17 | 9/450 |
|
|
[考研] 材料與化工求調(diào)劑 +7 | 為學(xué)666 2026-03-16 | 7/350 |
|
|
[考研] 286求調(diào)劑 +6 | lemonzzn 2026-03-16 | 10/500 |
|
|
[考研] 0703化學(xué)調(diào)劑 +5 | pupcoco 2026-03-17 | 8/400 |
|
|
[考研] 328求調(diào)劑,英語(yǔ)六級(jí)551,有科研經(jīng)歷 +4 | 生物工程調(diào)劑 2026-03-16 | 12/600 |
|
|
[考研] 311求調(diào)劑 +11 | 冬十三 2026-03-15 | 12/600 |
|
|
[考研] 321求調(diào)劑 +5 | 大米飯! 2026-03-15 | 5/250 |
|
|
[考研] 0703化學(xué)調(diào)劑 290分有科研經(jīng)歷,論文在投 +7 | 膩膩gk 2026-03-14 | 7/350 |
|