基于Matlab 模拟停车位管理系统【源码 GUI】

系统对进入停车位的车辆进行车牌识别,将识别出来的车牌号显示出来;然后对车主进行人脸识别,框出车主照片的人脸部分作为车主信息的标记,记录在系统库中。车辆在库期间,系统使用者可以随意查看车辆与车主信息的获取过程及获取结果,当驾驶车辆离开停车场时,系统库将清空该车辆与车主的信息。

  • 源代码

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

% 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)

%清空

ax1=(handles.axes1);cla(ax1,'reset')

ax2=(handles.axes2);cla(ax2,'reset')

ax3=(handles.axes3);cla(ax3,'reset')

ax4=(handles.axes4);cla(ax4,'reset')

ax5=(handles.axes5);cla(ax5,'reset')

ax6=(handles.axes6);cla(ax6,'reset')

ax7=(handles.axes7);cla(ax7,'reset')

ax8=(handles.axes8);cla(ax8,'reset')

ax9=(handles.axes9);cla(ax9,'reset')

ax10=(handles.axes10);cla(ax10,'reset')

ax11=(handles.axes11);cla(ax11,'reset')

ax12=(handles.axes12);cla(ax12,'reset')

ax13=(handles.axes13);cla(ax13,'reset')

ax14=(handles.axes14);cla(ax14,'reset')

ax15=(handles.axes15);cla(ax15,'reset')

ax16=(handles.axes16);cla(ax16,'reset')

set(handles.text3,'string',' ');

%选择图片路径

[fname,pname,index] = uigetfile({'*.jpg';'*.bmp'},'选择图片');

str = [pname fname];

c = imread(str);

axes(handles.axes1); %获取句柄

imshow(c);

I = c;

title('测试图片');

handles.I=I;

guidata(hObject, 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)

% --- Executes on button press in pushbutton2.

function pushbutton2_Callback(hObject, eventdata, handles)

global I;

I=handles.I;

I1=rgb2gray(I);%转灰度图

axes(handles.axes2) %显示在axes2里

imshow(I1);

title('灰度图');

handles.I1=I1;

guidata(hObject, 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)

% --- Executes on button press in pushbutton3.

function pushbutton3_Callback(hObject, eventdata, handles)

I1=handles.I1;

I2=edge(I1,'roberts',0.18,'both');%边缘检测

axes(handles.axes3) ;%显示在axes3

imshow(I2);

title('边缘检测');

handles.I2=I2;

guidata(hObject, 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)

% --- Executes on button press in pushbutton4.

function pushbutton4_Callback(hObject, eventdata, handles)

I2=handles.I2;

se=[1;1;1]; %

I3=imerode(I2,se); %%腐蚀,相当于让线条更细,细到没有。

axes(handles.axes4);

imshow(I3);

title('腐蚀图');

handles.I3=I3;

guidata(hObject, 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)

% --- Executes on button press in pushbutton5.

function pushbutton5_Callback(hObject, eventdata, handles)

I3=handles.I3;

axes(handles.axes5);

imshow(I4);

title('开运算图')

handles.I4=I4;

guidata(hObject, handles);

% hObject    handle to pushbutton5 (see GCBO)

% eventdata  reserved - to be defined in a future version of MATLAB

% handles    structure with handles and user data (see GUIDATA)

% --- Executes on button press in pushbutton6.

function pushbutton6_Callback(hObject, eventdata, handles)

I4=handles.I4;

[n1, n2] = size(I4);

I4(1:round(n1/3), 1:n2) = 0;

imshow(I5);

title('去除小面积干扰')

handles.I5=I5;

guidata(hObject, handles);

% hObject    handle to pushbutton6 (see GCBO)

% eventdata  reserved - to be defined in a future version of MATLAB

% handles    structure with handles and user data (see GUIDATA)

% --- Executes on button press in pushbutton7.

function pushbutton7_Callback(hObject, eventdata, handles)

axes(handles.axes7);

imshow(dw);

title('车牌定位图');

handles.dw=dw;

guidata(hObject, handles);

% hObject    handle to pushbutton7 (see GCBO)

% eventdata  reserved - to be defined in a future version of MATLAB

% handles    structure with handles and user data (see GUIDATA)

% --- Executes on button press in pushbutton8.

function pushbutton8_Callback(hObject, eventdata, handles)

% hObject    handle to pushbutton8 (see GCBO)

% eventdata  reserved - to be defined in a future version of MATLAB

% handles    structure with handles and user data (see GUIDATA)

% --- Executes on button press in pushbutton9.

function pushbutton9_Callback(hObject, eventdata, handles)

k1=1;

k2=1;

s=sum(d);

j=1;

while j~=n

    while s(j)==0

        j=j+1;

    end

    k1=j;

    while s(j)~=0&&j<=n-1

        j=j+1;

    end

    k2=j-1;%

    if k2-k1>=round(n/6.5)%

        [val,num]=min(sum(d(:,[k1+5:k2-5])));%

        d(:,k1+num+5)=0;  %

    end

end

% 再切割

d=qiege(d);

y1=10;y2=0.25;

flag=0;

word1=[];

%拎出第一个字符

wide=round(1/8*N);

temp=(imcrop(d,[1 1 wide m]));

word1=temp;

d(:,[1:wide])=0;

d=qiege(d);%踢出掉第一个字符

return

word2=wordprocess(word2);

word3=wordprocess(word3);

word4=wordprocess(word4);

word5=wordprocess(word5);

word6=wordprocess(word6);

word7=wordprocess(word7);

axes(handles.axes10);

imshow(word1);

axes(handles.axes11);

imshow(word2);

axes(handles.axes12);

imshow(word3);

axes(handles.axes13);

imshow(word4);

axes(handles.axes14);

imshow(word5);

axes(handles.axes15);

imshow(word6);

axes(handles.axes16);

imshow(word7);

% hObject    handle to pushbutton9 (see GCBO)

% eventdata  reserved - to be defined in a future version of MATLAB

% handles    structure with handles and user data (see GUIDATA)

运行结果

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/diannao/59261.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

SpringBoot项目集成ONLYOFFICE

ONLYOFFICE 文档8.2版本已发布&#xff1a;PDF 协作编辑、改进界面、性能优化、表格中的 RTL 支持等更新 文章目录 前言ONLYOFFICE 产品简介功能与特点Spring Boot 项目中集成 OnlyOffice1. 环境准备2. 部署OnlyOffice Document Server3. 配置Spring Boot项目4. 实现文档编辑功…

SpringBoot开箱即用

点开SpringBoot项目POM文件中父依赖,按住Ctrl+鼠标左键,点进去 <parent><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-parent</artifactId><version>2.2.1.RELEASE</version><relativePath/&…

学习笔记:微服务技术栈(一)服务治理框架SpringCloud

教学视频链接&#xff1a; 【SpringCloudRabbitMQDockerRedis搜索分布式&#xff0c;系统详解springcloud微服务技术栈课程|黑马程序员Java微服务】 目录 前言一、认识微服务1.1 服务架构1.2 微服务架构1.3 SpringCloud 二、服务拆分及远程调用2.1 服务拆分细节2.2 服务间调用 …

Centos 下安装 jsoncpp 库、bundle 数据压缩库、httplib 库 -- 详细教程

一、安装 jsoncpp 库 sudo yum install epel-release sudo yum install jsoncpp-devel [xyllocalhost ~]$ ls /usr/include/jsoncpp/json/ assertions.h config.h forwards.h reader.h version.h autolink.h features.h json.h value.h writer.h 注意&#xff1a;Centos 版本不…

前端小练习——星辰宇宙(JS没有上限!!!)

前言&#xff1a;在刚开始学习前端的时候&#xff0c;我们会学习到前端三件套中的JavaScript&#xff0c;可能那时候读者没有觉得JavaScript这个语言有多么的牛逼&#xff0c;本篇文章将会使用一个炫酷的案例来刷新你对JavaScript这个语言的认知与理解。 ✨✨✨这里是秋刀鱼不做…

【网络】传输层协议TCP(下)

目录 四次挥手状态变化 流量控制 PSH标记位 URG标记位 滑动窗口 快重传 拥塞控制 延迟应答 mtu TCP异常情况 四次挥手状态变化 之前我们讲了四次挥手的具体过程以及为什么要进行四次挥手&#xff0c;下面是四次挥手的状态变化 那么我们下面可以来验证一下CLOSE_WAIT这…

实时金融股票数据API接口websocket接入方法

一、使用websocket的协议提升传输速度 实时金融股票数据对于投资者和交易员来说至关重要。通过使用WebSocket接入方法&#xff0c;可以轻松获取实时金融股票类数据并及时做出决策。WebSocket是一种高效的双向通信协议&#xff0c;它允许数据的实时推送&#xff0c;避免了不断的…

XingHan-Team团队官网系统源码 全开源

XingHan-Team 官网程序是一个现代化的企业官网管理系统&#xff0c;由星涵网络工作室开发。 本系统提供了完整的网站内容管理功能&#xff0c;包括用户管理、内容发布、成员查询、成员申请等功能。 源码下载&#xff1a;https://download.csdn.net/download/m0_66047725/8995…

vrrp和mstp,vrrp和byd

vrrp和mstp 思路 vrrp是用来虚拟网关&#xff0c;噢&#xff0c;是虚拟一条虚拟网关 优先级&#xff0c;priority越大越优先&#xff0c;优先级相同&#xff0c;哪个的路由器的vrrp先起来&#xff0c;谁就是主 mstp是快速生成树协议&#xff0c;防止环路用的 优先级越小越优…

鸿蒙生态认识

好的&#xff0c;让我们更深入地探讨鸿蒙生态的发展机遇、面临的挑战&#xff0c;以及未来的潜力。 对鸿蒙生态的认知与分析 鸿蒙系统作为一种新兴的操作系统&#xff0c;旨在打破设备之间的壁垒&#xff0c;打造一个更加连通的生态环境。以下是对其崛起的进一步分析&#xf…

图说复变函数论重大错误:将无穷多各异平面误为同一面

黄小宁 医学若将前所未知的“新冠”病毒误为已熟知的流感病毒&#xff0c;后果...&#xff1b;数学将前所未知的点集误为已熟知的集就会引出一连串的重大错误。 h定理&#xff1a;点集AB的必要条件是A≌B。 证&#xff1a;&#xff08;1&#xff09;任何图≌自己是几何学最起码…

SpringBoot技术:打造新闻稿件管理平台

2相关技术 2.1 MYSQL数据库 MySQL是一个真正的多用户、多线程SQL数据库服务器。 是基于SQL的客户/服务器模式的关系数据库管理系统&#xff0c;它的有点有有功能强大、使用简单、管理方便、安全可靠性高、运行速度快、多线程、跨平台性、完全网络化、稳定性等&#xff0c;非常…

深入理解DMA(直接存储器访问)

直接存储器访问(DMA,Direct Memory Access)是一种允许外设和内存之间直接传输数据的机制,旨在提高数据传输的效率,减少CPU的负担。在传统的数据传输中,CPU负责所有的数据移动和处理,这导致CPU资源被大量占用,影响系统的整体性能。而DMA的出现,正是为了优化这一过程,使…

【Wi-Fi】WiFi中QAM及16-QAM、64-QAM、512-QAM、1024-QAM、2048-QAM、4096-QAM整理

参考链接 什么是QAM&#xff1f;QAM是如何工作的&#xff1f; - 华为 不同阶QAM调制星座图中&#xff0c;符号能量的归一化计算原理 - 知乎 16 QAM modulation vs 64 QAM modulation vs 256 QAM modulation 512 QAM vs 1024 QAM vs 2048 QAM vs 4096 QAM modulation type…

EHOME视频平台EasyCVR萤石设备视频接入平台视频诊断技术可以识别哪些视频质量问题?

EasyCVR视频监控汇聚管理平台是一款针对大中型项目设计的跨区域网络化视频监控集中管理平台。萤石设备视频接入平台EasyCVR不仅具备视频资源管理、设备管理、用户管理、运维管理和安全管理等功能&#xff0c;还支持多种主流标准协议&#xff0c;如GB28181、GB35114、RTSP/Onvif…

42python数据分析numpy基础之trace计算对角线元素的和

python的numpy库的trace()函数&#xff0c;计算对角线元素的和。 用法 numpy.trace(a, offset0, axis10, axis21, dtypeNone, outNone)描述 numpy.trace(a)&#xff0c;返回数组a的对角线元素的和。 入参 a&#xff1a;必选&#xff0c;数组&#xff0c;列表&#xff0c;元…

arm64-v8a 和 armeabi-v7a 有啥区别?

ARM64-v8a 和 ARMEABI-v7a 是 Android 平台上两种不同的 ARM 架构&#xff0c;用于支持应用程序的运行。它们之间有几个关键的区别&#xff1a; 1. 架构类型 ARM64-v8a&#xff1a;代表的是 64 位的 ARM 架构&#xff08;ARMv8-A&#xff09;。它能够处理更大范围的地址空间和…

DCN网络进行新冠肺炎影像分类

项目源码获取方式见文章末尾! 600多个深度学习项目资料,快来加入社群一起学习吧。 《------往期经典推荐------》 项目名称 1.【BiLSTM模型实现电力数据预测】 2.【卫星图像道路检测DeepLabV3Plus模型】 3.【GAN模型实现二次元头像生成】 4.【CNN模型实现mnist手写数字识别】…

[代码随想录打卡Day6] 哈希表理论基础 242.有效的字母异位词 349. 两个数组的交集 349. 两个数组的交集 1. 两数之和

之后补充Python的 哈希表理论基础 首先什么是哈希表&#xff0c;哈希表&#xff08;英文名字为Hash table&#xff0c;国内也有一些算法书籍翻译为散列表&#xff0c;大家看到这两个名称知道都是指hash table就可以了&#xff09;。 哈希表是根据关键码的值而直接进行访问的数…

WPF+MVVM案例实战(二十三)- 阴影效果详解

文章目录 1、案例效果2、阴影属性参数说明3、阴影效果实现1、案例效果 2、阴影属性参数说明 WPF 中,控件的阴影效果是通过附加属性 Effect 来实现的。这里详细说明以下阴影效果的各个参数。 属性描述BlurRadius阴影模糊程度,值越大越模糊Color阴影颜色Opacity阴影透明度,默…