五月天青色头像情侣网名,国产亚洲av片在线观看18女人,黑人巨茎大战俄罗斯美女,扒下她的小内裤打屁股

歡迎光臨散文網(wǎng) 會員登陸 & 注冊

【圖像分割】基于計算機(jī)視覺實現(xiàn)醫(yī)學(xué)影像分割含GUI界面

2022-09-13 23:50 作者:Matlab工程師  | 我要投稿

1 簡介

圖像分割是圖像處理和計算機(jī)視覺中的關(guān)鍵技術(shù)之一.它有助于提高基于圖像內(nèi)容的特定目標(biāo)定位的準(zhǔn)確性,在圖像的編輯摳圖等技術(shù)中離不開正確的分割.圖像分割的方法浩如煙海,但要實現(xiàn)一個具有通用性的分割技術(shù)還面臨著很大困難.隨著計算機(jī)視覺,現(xiàn)代生理學(xué),神經(jīng)心理學(xué),物體識別,圖像處理等學(xué)科的綜合發(fā)展,基于視覺注意的圖像分割技術(shù)日益引起了人們的普遍關(guān)注.它屬于國際前沿課題,其理論成果對智能研究和發(fā)展具有重要的貢獻(xiàn).在遙感氣象服務(wù),醫(yī)學(xué)影像分析,機(jī)械制造,產(chǎn)品檢測,軍事研究,交通圖像分析等領(lǐng)域有著廣泛的應(yīng)用前景.本文基于計算機(jī)視覺實現(xiàn)醫(yī)學(xué)影像分割。

2 部分代碼

function varargout = brain_ysw(varargin)% BRAIN_YSW MATLAB code for brain_ysw.fig% ? ? ?BRAIN_YSW, by itself, creates a new BRAIN_YSW or raises the existing% ? ? ?singleton*.%% ? ? ?H = BRAIN_YSW returns the handle to a new BRAIN_YSW or the handle to% ? ? ?the existing singleton*.%% ? ? ?BRAIN_YSW('CALLBACK',hObject,eventData,handles,...) calls the local% ? ? ?function named CALLBACK in BRAIN_YSW.M with the given input arguments.%% ? ? ?BRAIN_YSW('Property','Value',...) creates a new BRAIN_YSW or raises the% ? ? ?existing singleton*. ?Starting from the left, property value pairs are% ? ? ?applied to the GUI before brain_ysw_OpeningFcn gets called. ?An% ? ? ?unrecognized property name or invalid value makes property application% ? ? ?stop. ?All inputs are passed to brain_ysw_OpeningFcn via varargin.%% ? ? ?*See GUI Options on GUIDE's Tools menu. ?Choose "GUI allows only one% ? ? ?instance to run (singleton)".%% See also: GUIDE, GUIDATA, GUIHANDLES% Edit the above text to modify the response to help brain_ysw% Last Modified by GUIDE v2.5 10-Jun-2015 13:34:14% Begin initialization code - DO NOT EDITgui_Singleton = 1;gui_State = struct('gui_Name', ? ? ? mfilename, ... ? ? ? ? ? ? ? ? ? 'gui_Singleton', ?gui_Singleton, ... ? ? ? ? ? ? ? ? ? 'gui_OpeningFcn', @brain_ysw_OpeningFcn, ... ? ? ? ? ? ? ? ? ? 'gui_OutputFcn', ?@brain_ysw_OutputFcn, ... ? ? ? ? ? ? ? ? ? 'gui_LayoutFcn', ?[] , ... ? ? ? ? ? ? ? ? ? 'gui_Callback', ? []);if nargin && ischar(varargin{1}) ? ?gui_State.gui_Callback = str2func(varargin{1});endif nargout ? ?[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});else ? ?gui_mainfcn(gui_State, varargin{:});end% End initialization code - DO NOT EDIT% --- Executes just before brain_ysw is made visible.function brain_ysw_OpeningFcn(hObject, eventdata, handles, varargin)% This function has no output args, see OutputFcn.% hObject ? ?handle to figure% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)% varargin ? command line arguments to brain_ysw (see VARARGIN)% Choose default command line output for brain_yswhandles.output = hObject;% Update handles structureguidata(hObject, handles);% UIWAIT makes brain_ysw wait for user response (see UIRESUME)% uiwait(handles.figure1);% --- Outputs from this function are returned to the command line.function varargout = brain_ysw_OutputFcn(hObject, eventdata, handles) % varargout ?cell array for returning output args (see VARARGOUT);% hObject ? ?handle to figure% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)% Get default command line output from handles structurevarargout{1} = handles.output;% --- Executes on button press in pushbutton1.function pushbutton1_Callback(hObject, eventdata, handles)% hObject ? ?handle to pushbutton1 (see GCBO)% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)warning offglobal im_org dataload('data.mat'); ? ? ? % 加載MRI圖像數(shù)據(jù),整個頭顱圖像num = str2num(get(handles.edit1,'string'));% 從13 - 31 ? (32-44取反)if num <13 || num>31 ? ?msgbox('num數(shù)字不對!num在13-31之間?。?!');endim_org = data(:,:,num); ?% 第 i 幀圖像axes(handles.axes1)imshow(im_org);title('原始圖像'); ?% 顯示原圖像% --- Executes on button press in pushbutton2.function pushbutton2_Callback(hObject, eventdata, handles)% hObject ? ?handle to pushbutton2 (see GCBO)% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)warning offglobal im_org data bwmax_level = double(max(data(:))); if size(im_org,3)==1 ? ?im = im_org;else ? ?im = rgb2gray(im_org);endim = permute(im,[3 2 1]); % 重置矩陣的維數(shù)for i=1:3 ? ?im = flipdim(im,i);endim(im<=40/255) = 0; ? ? ? % 剔除灰度值低的部分(腦袋和背景)im(im>=100/255) = 0; ? ? ?% 剔除灰度值高的部分(顱骨和其他的組織)im(:,:,1) = 0; ? ? ? ? ? ?% 剔除大腦灰白質(zhì)下面的部分灰度部分blk = ones([1 7 7]); ? ? ?% 塊操作% im = imerode(im,blk); ? % 腐蝕% 分離大腦腦組織lev = graythresh(double(im)/max_level) * max_level; ?% 閾值bw = (im>=lev); ? ? ? ? ? ? ? ?% 二值化bw = imrotate(squeeze(bw),90); % 變異復(fù)原axes(handles.axes2)imshow(bw);title('二值化圖像');% --- Executes on button press in pushbutton3.function pushbutton3_Callback(hObject, eventdata, handles)% hObject ? ?handle to pushbutton3 (see GCBO)% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)axes(handles.axes2)imshow(L);title('灰白質(zhì)分割圖')% --- Executes on button press in pushbutton4.function pushbutton4_Callback(hObject, eventdata, handles)% hObject ? ?handle to pushbutton4 (see GCBO)% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)clc,clear,close allfunction edit1_Callback(hObject, eventdata, handles)% hObject ? ?handle to edit1 (see GCBO)% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?structure with handles and user data (see GUIDATA)% Hints: get(hObject,'String') returns contents of edit1 as text% ? ? ? ?str2double(get(hObject,'String')) returns contents of edit1 as a double% --- Executes during object creation, after setting all properties.function edit1_CreateFcn(hObject, eventdata, handles)% hObject ? ?handle to edit1 (see GCBO)% eventdata ?reserved - to be defined in a future version of MATLAB% handles ? ?empty - handles not created until after all CreateFcns called% Hint: edit controls usually have a white background on Windows.% ? ? ? See ISPC and COMPUTER.if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor')) ? ?set(hObject,'BackgroundColor','white');end

3 仿真結(jié)果


4 參考文獻(xiàn)

[1]李燦飛. 計算機(jī)視覺中圖像分割技術(shù)的研究[D]. 湖南大學(xué), 2005.

博主簡介:擅長智能優(yōu)化算法、神經(jīng)網(wǎng)絡(luò)預(yù)測、信號處理、元胞自動機(jī)、圖像處理、路徑規(guī)劃、無人機(jī)等多種領(lǐng)域的Matlab仿真,相關(guān)matlab代碼問題可私信交流。

部分理論引用網(wǎng)絡(luò)文獻(xiàn),若有侵權(quán)聯(lián)系博主刪除。



【圖像分割】基于計算機(jī)視覺實現(xiàn)醫(yī)學(xué)影像分割含GUI界面的評論 (共 條)

分享到微博請遵守國家法律
曲麻莱县| 赞皇县| 涡阳县| 鄂尔多斯市| 利津县| 江孜县| 罗山县| 顺昌县| 永康市| 南京市| 浦东新区| 泸州市| 陈巴尔虎旗| 马公市| 黔南| 巢湖市| 开远市| 永济市| 绥棱县| 平舆县| 贺州市| 合山市| 安庆市| 澄迈县| 贡嘎县| 都匀市| 白朗县| 呈贡县| 镇坪县| 河东区| 大庆市| 洱源县| 正定县| 辰溪县| 尖扎县| 乐山市| 云南省| 湄潭县| 星座| 中阳县| 大厂|