function varargout = gui(varargin)
% GUI MATLAB code for gui.fig
% GUI, by itself, creates a new GUI or raises the existing
% singleton*.
%
% H = GUI returns the handle to a new GUI or the handle to
% the existing singleton*.
%
% GUI('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in GUI.M with the given input arguments.
%
% GUI('Property','Value',...) creates a new GUI or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before gui_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to gui_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 gui
% Last Modified by GUIDE v2.5 25-Dec-2018 12:05:12
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @gui_OpeningFcn, ...
'gui_OutputFcn', @gui_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if 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 gui is made visible.
function gui_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 gui (see VARARGIN)
% Choose default command line output for gui
handles.output = hObject;
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes gui wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = gui_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 structure
varargout{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[
[imgfilename imgpathname]=uigetfile('*.jpg','选一张图');
if imgfilename
strPath=strcat(imgpathname,imgfilename);
imgdata=imread(strPath);
form=maketform('affine',[0 1 0;1 0 0;0 0 1]);%创建空间转换结构
showImage=imtransform(imgdata,form,'nearest');%对图像应用二维空间变换,由form定义的2-D空间变换来转换图像img,nearest为指定要使用的插值的形式
image(handles.axes1,showImage);
null=imread('null.jpg');
image(handles.axes2,null);
set(handles.edit2,'string','快点击识别把');
handles.imgfilename=imgfilename;
handles.imgdata=imgdata;
end
guidata(hObject,handles);
% --- 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)
[ansImg,ans]=Identification(handles.imgdata);
image(handles.axes2,ansImg);
set(handles.edit2,'string',ans);
guidata(hObject,handles);
function edit2_Callback(hObject, eventdata, handles)
% hObject handle to edit2 (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 edit2 as text
% str2double(get(hObject,'String')) returns contents of edit2 as a double
% --- Executes during object creation, after setting all properties.
function edit2_CreateFcn(hObject, eventdata, handles)
% hObject handle to edit2 (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
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
期末课设基于matlab+BP神经网络的人脸识别源码+数据.zip期末课设基于matlab+BP神经网络的人脸识别源码+数据.zip期末课设基于matlab+BP神经网络的人脸识别源码+数据.zip期末课设基于matlab+BP神经网络的人脸识别源码+数据.zip期末课设基于matlab+BP神经网络的人脸识别源码+数据.zip 【资源介绍】 该项目是个人毕设项目,答辩评审分达到95分,代码都经过调试测试,确保可以运行!欢迎下载使用,可用于小白学习、进阶。 该资源主要针对计算机、通信、人工智能、自动化等相关专业的学生、老师或从业者下载使用,亦可作为期末课程设计、课程大作业、毕业设计等。 项目整体具有较高的学习借鉴价值!基础能力强的可以在此基础上修改调整,以实现不同的功能。
资源推荐
资源详情
资源评论
























收起资源包目录










































































共 68 条
- 1
资源评论


manylinux
- 粉丝: 4987
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助


最新资源
- 企业信息化项目资金申请报告编制大纲.docx
- 企业云原生之微服务全面解析.docx
- 使用开源软件监控至强处理器概述.pptx
- 信息安全的网络隔离技术探析.docx
- 信息传输、软件和信息技术服务行业营销方案.pptx
- 信息系统集成和物联网技术服务行业营销方案.pptx
- 公共广播系统集成方案.docx
- 光通信器件行业深度解析.docx
- 借鉴Oracle深入修改MySQL与PostgreSQL内核.pdf
- 内蒙古高校教育信息化满意度调查分析.docx
- 农业大数据平台化服务及解决方案.docx
- 农业物联网技术发展程度的实证分析.docx
- 倾角传感器在智慧城市中的应用.docx
- 全面详解云计算.docx
- 全球超级计算机100强榜单.docx
- 全球工业互联网行业产品竞争格局及发展前景预测.docx
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



安全验证
文档复制为VIP权益,开通VIP直接复制
