资源简介
本基于MATLAB图像处理的疲劳驾驶检测提出了一种基于视觉信息和人工智能的驾驶员睡意自动检测模块。该系统的目的是对驾驶员的面部和眼睛进行定位、跟踪和分析,计算睡意指数,以防止事故的发生。人脸和眼睛的检测都是通过AdaBoost分类器来实现的。为了提高人脸跟踪的精度,提出了一种检测与目标跟踪相结合的方法。提出的人脸跟踪方法,还具有自校正能力。在找到眼睛区域后,利用局部二值模式(LBP)提取眼睛特征。利用这些特征,训练一个支持向量机分类器(SVM)进行眼睛状态分析。
代码片段和文件信息
clc; % clc clears all input and output from the Command Window display giving you a “clean screen.“
clear all; % removes all variables from the current workspace releasing them from system memory.
close all; % deletes the current figure or the specified figure(s). It optionally returns the status of the close operation.
%%
delete(imaqfind) % imaqfind: Find image acquisition objects
% returns an array containing all the video input objects that exist in memory.
% If only a single video input object exists in memory imaqfind displays a detailed summary of that object.
% Nest a call to the imaqfind function within the delete function to delete all these objects from memory.
vid=videoinput(‘winvideo‘1); % OS Generic Video Interface
% creates a video input object for a webcam image acquisition device.
% MATLAB files to use Windows Video Macintosh Video or Linux Video cameras with the toolbox.
% The correct OS files will be installed depending on your system.
% Kinect for Windows (kinect)
% Linux Video (linuxvideo)
triggerconfig(vid‘manual‘);
% Configure video input object trigger properties.
% configures the value of the TriggerType property of the video input object “vid“
% to the value specified by the text string type that here is “manual“.
% TriggerType Value are immediatemanualhardware.
% immediate: The trigger occurs automatically immediately after the start function is issued. This is the default trigger type.
% manual: The trigger occurs when you issue the trigger function. A manual trigger can provide more control over image acquisition.
% For example you can monitor the video stream being acquired using the preview function
% and manually execute the trigger when you observe a particular condition in the scene.
% hardware: Hardware triggers are external signals that are processed directly by the hardware.
set(vid‘framesPerTrigger‘1 ); % The default is 10 frames per trigger
set(vid‘TriggerRepeat‘ Inf);
% Specify number of additional times trigger executes
% If TriggerRepeat is set to its default value of zero then the trigger executes once.
% If TriggerRepeat is set to inf then the trigger executes continuously until a stop function is issued or an error occurs.
% start(vid);
% View the default color space used for the data ?The value of the ReturnedColorSpace property indicates the color space of the image data.
color_spec=vid.ReturnedColorSpace;
% specifies the color space you want the toolbox to use when it returns image data to the MATLAB workspace.
% grayscalergbYCbCr
% Modify the color space used for the data ?
% To change the color space of the returned image data set the value of the ReturnedColorSpace property.
if ~strcmp(color_spec‘rgb‘)
set(vid‘ReturnedColorSpace‘‘rgb‘);
end
start(vid) % to start the image acquisition object.
% Create a detector object
faceDetector = vision.CascadeobjectDetector;
faceDetectorLeye = vision.CascadeobjectDetector(‘EyePairBig‘);
faceDetectorM
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-05-01 15:26 Code\
文件 5241 2018-05-01 15:26 Code\create_Databa
目录 0 2018-05-01 15:26 Code\Databa
目录 0 2018-05-01 15:26 Code\Databa
目录 0 2018-05-01 15:26 Code\Databa
文件 2590 2018-05-01 15:26 Code\Databa
文件 2646 2018-05-01 15:26 Code\Databa
文件 2230 2018-05-01 15:26 Code\Databa
文件 2646 2018-05-01 15:26 Code\Databa
文件 2646 2018-05-01 15:26 Code\Databa
文件 2646 2018-05-01 15:26 Code\Databa
文件 13312 2018-05-01 15:26 Code\Databa
目录 0 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2878 2018-05-01 15:26 Code\Databa
文件 2878 2018-05-01 15:26 Code\Databa
文件 2878 2018-05-01 15:26 Code\Databa
文件 2878 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2878 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2878 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
文件 2818 2018-05-01 15:26 Code\Databa
............此处省略119个文件信息
- 上一篇:matlab包络分析程序
- 下一篇:基于Q=Dv的多种交通流模型Matlab绘图
相关资源
- Pattern Recognition and Machine Learning(高清
- MATLAB 编程 第二版 Stephen J. Chapman 著
- 均值滤波和FFT频谱分析Matlab代码
- 《MATLAB扩展编程》代码
- HDB3码、AMI码的MATLAB实现
- 3点GPS定位MATLAB仿真
- MATLAB数字信号处理85个实用案例精讲入
- matlab从入门到精通pdf94795
- 欧拉放大论文及matlab代码
- 跳一跳辅助_matlab版本
- 全面详解LTE MATLAB建模、仿真与实现
- MIMO-OFDM无线通信技术及MATLAB实现_孙锴
- MATLAB Programming for Engineers 4th - Chapman
- matlab 各种谱分析对比
- 分数阶chen混沌matlab程序
- 蚁群算法论文+源代码
- 基于粒子群算法的非合作博弈的matl
- MATLAB车流仿真 包括跟驰、延误
- matlab空间桁架计算程序
- 基于MATLAB的图像特征点匹配和筛选
- DMA-TVP-FAVAR
- GPS信号的码捕获matlab代码.7z
- 一维光子晶体MATLAB仿真代码吸收率折
- newmark法源程序
- 传统关联成像、计算鬼成像matlab
- pri传统分选算法
- 摆动滚子推杆盘形凸轮设计
- 高斯正反算批量计算
- 医学图像重建作业matlab源码
- Matlab实现混沌系统的控制
评论
共有 条评论