[go: up one dir, main page]

CN111243236A - Fatigue driving early warning method and system based on deep learning - Google Patents

Fatigue driving early warning method and system based on deep learning Download PDF

Info

Publication number
CN111243236A
CN111243236A CN202010053964.8A CN202010053964A CN111243236A CN 111243236 A CN111243236 A CN 111243236A CN 202010053964 A CN202010053964 A CN 202010053964A CN 111243236 A CN111243236 A CN 111243236A
Authority
CN
China
Prior art keywords
module
categories
frame
deep learning
confidence
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010053964.8A
Other languages
Chinese (zh)
Inventor
庄文芹
谢世朋
李海波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nanjing University of Posts and Telecommunications
Original Assignee
Nanjing University of Posts and Telecommunications
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nanjing University of Posts and Telecommunications filed Critical Nanjing University of Posts and Telecommunications
Priority to CN202010053964.8A priority Critical patent/CN111243236A/en
Publication of CN111243236A publication Critical patent/CN111243236A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G08SIGNALLING
    • G08BSIGNALLING OR CALLING SYSTEMS; ORDER TELEGRAPHS; ALARM SYSTEMS
    • G08B21/00Alarms responsive to a single specified undesired or abnormal condition and not otherwise provided for
    • G08B21/02Alarms for ensuring the safety of persons
    • G08B21/06Alarms for ensuring the safety of persons indicating a condition of sleep, e.g. anti-dozing alarms
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/25Determination of region of interest [ROI] or a volume of interest [VOI]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/59Context or environment of the image inside of a vehicle, e.g. relating to seat occupancy, driver state or inner lighting conditions
    • G06V20/597Recognising the driver's state or behaviour, e.g. attention or drowsiness
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/18Eye characteristics, e.g. of the iris

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Multimedia (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Computing Systems (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Mathematical Physics (AREA)
  • Molecular Biology (AREA)
  • Evolutionary Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Ophthalmology & Optometry (AREA)
  • Human Computer Interaction (AREA)
  • Business, Economics & Management (AREA)
  • Emergency Management (AREA)
  • Image Analysis (AREA)

Abstract

本发明公开了一种基于深度学习的疲劳驾驶预警方法及系统,包括:参数解析模块,视频采集模块,图像处理模块,识别模块,画框模块,警报模块;所述参数解析模块用于当程序启动时读入程序的各种参数设定,所述视频采集模块采集视频,并将有效视频传输至所述图像处理模块,所述图像处理模块读入并记录图像的长度和宽度,并生成一个同样大小的零矩阵,将图像传输至所述识别模块,所述识别模块生成检测结果的框图坐标及检测结果的置信度,所述画框模块通过识别框图坐标和检测结果置信度,对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同,画出颜色不同的框体加以区别,所述警报模块发送警报信号。

Figure 202010053964

The invention discloses a deep learning-based fatigue driving early warning method and system, comprising: a parameter analysis module, a video acquisition module, an image processing module, an identification module, a picture frame module, and an alarm module; the parameter analysis module is used when a program Various parameter settings of the program are read during startup, the video acquisition module collects video, and transmits the valid video to the image processing module, the image processing module reads and records the length and width of the image, and generates a A zero matrix of the same size transmits the image to the recognition module. The recognition module generates the frame coordinates of the detection result and the confidence of the detection result. The frame module identifies the frame coordinates and the confidence of the detection result. Perform traversal, frame and label all categories with confidence greater than the threshold according to the coordinates of the frame, and draw frames with different colors to distinguish them according to different categories, and the alarm module sends an alarm signal.

Figure 202010053964

Description

一种基于深度学习的疲劳驾驶预警方法及系统A method and system for fatigue driving early warning based on deep learning

技术领域technical field

本发明涉及疲劳驾驶预警技术领域,更具体的说是涉及一种基于深度学习的疲劳驾驶预警系统。The invention relates to the technical field of fatigue driving early warning, and more particularly to a fatigue driving early warning system based on deep learning.

背景技术Background technique

目前,随着人们生活水平的不断提高,随着汽车工业和社会经济的不断发展,开车已经成为人们在日常生活中重要的一部分。然而,多发的交通事故威胁着人们的出行安全,轻则造成经济损失,重则危害人们的生命。At present, with the continuous improvement of people's living standards and the continuous development of the automobile industry and social economy, driving has become an important part of people's daily life. However, frequent traffic accidents threaten people's travel safety, causing economic losses in lightest cases, and endangering people's lives in heavy cases.

近年来,司机疲劳驾驶已经成为造成机动车事故的主要原因之一。疲劳驾驶,常发生于驾驶员持续驾驶车辆,或不能保证清醒状态时。此时驾驶员的生理和心理机能失衡,在客观上会导致驾驶技能下降。驾驶员的思维、注意力、感知能力、反应力、判断力、意志力和运动神经等方面会受疲劳驾驶的原因影响。长时间的疲劳驾驶,驾驶员会出现困倦疲惫,注意力难以集中,视野逐渐变窄,思维能力下降的情况。甚至会出现精神恍惚或短时间失忆,出现反应迟缓,操作失误或修正时间不及时等不安全因素,极易造成道路交通事故的发生概率。驾驶员疲劳驾驶时判断能力将会下降、反应迟缓,此时操作失误率将会增加。驾驶员面对轻微疲劳时,会导致操作变速箱不及时,不准确;驾驶员面对中度疲劳时,操作动作不连贯,忘记操作的现象也时有发生;驾驶员面对重度疲劳时,往往会机械化操作或出现中途打瞌睡现象,严重时车辆会失去控制。In recent years, driver fatigue driving has become one of the main causes of motor vehicle accidents. Fatigue driving, which often occurs when the driver continues to drive the vehicle, or cannot guarantee a awake state. At this time, the driver's physiological and psychological functions are out of balance, which will objectively lead to a decline in driving skills. The driver's thinking, attention, perception, responsiveness, judgment, willpower and motor nerves will be affected by the causes of fatigued driving. After long-term fatigue driving, the driver will appear drowsy and tired, it is difficult to concentrate, the vision gradually narrows, and the thinking ability declines. There may even be trance or short-term memory loss, slow response, operational errors or untimely corrections and other unsafe factors, which can easily lead to the probability of road traffic accidents. When the driver is fatigued, the judgment ability will be reduced and the response will be slow, and the operation error rate will increase at this time. When the driver faces slight fatigue, it will lead to untimely and inaccurate operation of the gearbox; when the driver faces moderate fatigue, the operation action is incoherent, and the phenomenon of forgetting to operate also occurs from time to time; when the driver faces severe fatigue, It is often mechanized or dozed off in the middle, and the vehicle will lose control in severe cases.

目前,已经有许多技术被用来检测驾驶员的疲劳状态,这些技术大致可以被分成三类:车辆的驾驶模式、司机的生理状态和计算机视觉技术。但是,基于车辆驾驶模式检测方法的主要缺点是它们的精度取决于车辆及其驾驶员的个人特征;基于生理特征的检测是目前所有疲劳检测方法中准确度最高的,但是,因为要在身体上附加许多的传感器来干扰驾驶员的侵入性,信号的采集可能会给驾驶员带来不适感;生物信号的非侵入性方法存在,但是准确度不高;基于视觉特征的方法通过使用诸如打哈欠,面部表情,头部运动和眼睛状态等非侵入性视觉信息来检测困倦。由于非接触性,基于视觉特征的方法已经成为困倦检测的有前途的研究领域。基于打哈欠和头部运动的方法不能可靠地检测到困倦的发作,因为这些方法并不直接表示困倦。At present, many technologies have been used to detect the fatigue state of drivers, and these technologies can be roughly divided into three categories: the driving pattern of the vehicle, the physiological state of the driver, and computer vision technology. However, the main disadvantage of vehicle driving pattern-based detection methods is that their accuracy depends on the personal characteristics of the vehicle and its driver; detection based on physiological characteristics is currently the most accurate of all fatigue detection methods, however, because of the physical Many sensors are attached to interfere with the invasiveness of the driver, and the acquisition of signals may cause discomfort to the driver; non-invasive methods of biosignaling exist, but the accuracy is not high; methods based on visual characteristics are used such as yawning. , non-invasive visual information such as facial expressions, head movements and eye states to detect drowsiness. Due to the non-contact nature, visual feature-based methods have become a promising research area for drowsiness detection. Methods based on yawning and head movement cannot reliably detect episodes of drowsiness because these methods do not directly represent drowsiness.

因此,提供一种通过眼睛闭合以及眨眼频率来判断驾驶员处于困倦等疲劳状态是本领域技术人员亟需解决的问题。Therefore, it is an urgent problem for those skilled in the art to provide a method for judging that the driver is in a fatigue state such as drowsiness through eye closure and blinking frequency.

发明内容SUMMARY OF THE INVENTION

有鉴于此,本发明提供了一种基于深度学习的疲劳驾驶预警方法及系统。In view of this, the present invention provides a deep learning-based fatigue driving warning method and system.

为了实现上述目的,本发明采用如下技术方案:In order to achieve the above object, the present invention adopts the following technical solutions:

一种基于深度学习的疲劳驾驶预警方法,包括步骤如下:A fatigue driving warning method based on deep learning includes the following steps:

S1、采集驾驶员眼部图像;S1. Collect the driver's eye image;

S2、建立Faster R-CNN人眼睁闭检测模型;S2. Establish a Faster R-CNN human eye opening and closing detection model;

S3、用Faster R-CNN对驾驶员眼部图像进行检测,获取框图坐标及检测结果的置信度;S3. Use Faster R-CNN to detect the driver's eye image, and obtain the frame coordinates and the confidence of the detection result;

S4、对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同,画出颜色不同的框体加以区别;S4, traverse all the categories, draw frames and mark the categories according to the frame coordinates of all categories whose confidence is greater than the threshold, and draw frames with different colors to distinguish them according to the categories;

S5、输出检测类别。S5. Output the detection category.

优选的,所述步骤S2的具体过程为:Preferably, the specific process of the step S2 is:

S21、选择RPN作为网络结构,通过CEW数据集进行模拟训练;S21. Select RPN as the network structure, and conduct simulation training through the CEW data set;

S22、为锚点打标签,与真实标签的Box有最高交并比重叠的锚点或交并比达到0.7的锚点为正标签,交并比低于0.3的锚点为负标签;S22. Label the anchor points. An anchor point with the highest overlap ratio with the box of the real label or an anchor point with an intersection ratio of 0.7 is a positive label, and an anchor point with an intersection ratio lower than 0.3 is a negative label;

S22、对共享卷积层进行训练,对特有层进行参数微调;S22, train the shared convolution layer, and fine-tune the parameters of the unique layer;

优选的,所述类别为睁眼或闭眼。Preferably, the category is eyes open or eyes closed.

优选的,所述步骤S3中检测的具体过程为:使用im_detect函数对驾驶员眼部图像进行检测。Preferably, the specific process of detection in the step S3 is: using the im_detect function to detect the driver's eye image.

一种使用基于深度学习的疲劳驾驶预警方法的系统,包括:参数解析模块,视频采集模块,图像处理模块,识别模块,画框模块,警报模块;A system using a deep learning-based fatigue driving warning method, comprising: a parameter analysis module, a video acquisition module, an image processing module, an identification module, a picture frame module, and an alarm module;

所述参数解析模块用于当程序启动时读入程序的各种参数设定,所述视频采集模块用于采集视频,并将有效视频传输至所述图像处理模块,所述图像处理模块用于读入并记录图像的长度和宽度,并生成一个同样大小的零矩阵,然后,将图像传输至所述识别模块,所述识别模块使用训练后的Fast R-CNN检测网络生成检测结果的框图坐标及检测结果的置信度,所述画框模块用于通过识别框图坐标和检测结果置信度,对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同,画出颜色不同的框体加以区别,所述警报模块用于发送警报信号。The parameter parsing module is used to read in various parameter settings of the program when the program is started, the video acquisition module is used to collect video, and transmit valid video to the image processing module, and the image processing module is used to Read in and record the length and width of the image, and generate a zero matrix of the same size, and then transmit the image to the recognition module, which uses the trained Fast R-CNN detection network to generate the block diagram coordinates of the detection result and the confidence of the detection result, the frame module is used to traverse all the categories by identifying the coordinates of the frame and the confidence of the detection result, and frame all the categories whose confidence is greater than the threshold according to the coordinates of the frame and mark the category, according to the category Different color boxes are drawn to distinguish them, and the alarm module is used to send an alarm signal.

优选的,所述类别为睁眼和闭眼。Preferably, the categories are eyes open and eyes closed.

优选的,所述警报模块连接有蜂鸣器,当所述警报模块输出高电平时蜂鸣器报警,当警报模块输出低电平时蜂鸣器停止报警。Preferably, the alarm module is connected with a buzzer, when the alarm module outputs a high level, the buzzer alarms, and when the alarm module outputs a low level, the buzzer stops the alarm.

经由上述的技术方案可知,与现有技术相比,本发明公开提供了一种通过视频采集模块采集驾驶员眼部图像信息,通过图像处理模块记录图像的长度和宽度,并生成一个同样大小的零矩阵,通过对Faster R-CNN网络的训练,使得识别模块生成检测结果的框图坐标和置信度更加精准,通过画框模块划分类别,当闭眼次数达到阈值是进行报警的基于深度学习的疲劳驾驶预警系统。It can be seen from the above technical solutions that, compared with the prior art, the present invention provides a method of collecting driver's eye image information through a video acquisition module, recording the length and width of the image through an image processing module, and generating an image of the same size. Zero matrix, through the training of the Faster R-CNN network, the frame coordinates and confidence of the detection results generated by the recognition module are more accurate, and the categories are divided by the frame module. When the number of closed eyes reaches the threshold, it will alarm based on deep learning fatigue Driving Warning System.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据提供的附图获得其他的附图。In order to explain the embodiments of the present invention or the technical solutions in the prior art more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only It is an embodiment of the present invention. For those of ordinary skill in the art, other drawings can also be obtained according to the provided drawings without creative work.

图1附图为本发明提供的流程示意图。The accompanying drawing of FIG. 1 is a schematic flow chart provided by the present invention.

图2附图为本发明提供的结构示意图。Figure 2 is a schematic diagram of the structure provided by the present invention.

具体实施方式Detailed ways

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, but not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

一种基于深度学习的疲劳驾驶预警方法,包括步骤如下:A fatigue driving warning method based on deep learning includes the following steps:

S1、采集驾驶员眼部图像;S1. Collect the driver's eye image;

S2、建立Faster R-CNN人眼睁闭检测模型;S2. Establish a Faster R-CNN human eye opening and closing detection model;

S3、用Faster R-CNN对驾驶员眼部图像进行检测,获取框图坐标及检测结果的置信度;S3. Use Faster R-CNN to detect the driver's eye image, and obtain the frame coordinates and the confidence of the detection result;

S4、对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同,画出颜色不同的框体加以区别;S4, traverse all the categories, draw frames and mark the categories according to the frame coordinates of all categories whose confidence is greater than the threshold, and draw frames with different colors to distinguish them according to the categories;

S5、输出检测类别。S5. Output the detection category.

为进一步优化上述技术方案,步骤S2的具体过程为:In order to further optimize the above-mentioned technical scheme, the specific process of step S2 is:

S21、选择RPN作为网络结构,通过CEW数据集进行模拟训练;S21. Select RPN as the network structure, and conduct simulation training through the CEW data set;

S22、为锚点打标签,与真实标签的Box有最高交并比重叠的锚点或交并比达到0.7的锚点为正标签,交并比低于0.3的锚点为负标签;S22. Label the anchor points. An anchor point with the highest overlap ratio with the box of the real label or an anchor point with an intersection ratio of 0.7 is a positive label, and an anchor point with an intersection ratio lower than 0.3 is a negative label;

S22、对共享卷积层进行训练,对特有层进行参数微调;S22, train the shared convolution layer, and fine-tune the parameters of the unique layer;

为进一步优化上述技术方案,类别为睁眼或闭眼。In order to further optimize the above technical solution, the categories are open eyes or closed eyes.

为进一步优化上述技术方案,步骤S3中检测的具体过程为:使用im_detect函数对驾驶员眼部图像进行检测。In order to further optimize the above technical solution, the specific process of detection in step S3 is: using the im_detect function to detect the driver's eye image.

一种深度学习的网络模型训练方法的疲劳驾驶预警系统,包括:参数解析模块1,视频采集模块2,图像处理模块3,识别模块4,画框模块5,警报模块6;A fatigue driving warning system based on a deep learning network model training method, comprising: a parameter analysis module 1, a video acquisition module 2, an image processing module 3, an identification module 4, a picture frame module 5, and an alarm module 6;

参数解析模块1负责在程序启动时读入程序的各种参数设定,例如是否使用RPN网络、代码所使用网络和模型的名称、是否使用CPU、GPU设备的编号等;视频采集模块2使用OpenCV的VideoCapture函数对视频进行捕捉,当摄像头开启时,就会自动读入一帧图像,若读入的图像有效,则将读入的图像传输至图像处理模块3;图像处理模块3在收到送来的这帧图像后,通过numpy包读入并记录图像的长度和宽度,并生成一个同样大小的零矩阵,为未来图像的输出做准备,然后,将图像传输至识别模块4;识别模块4调用了fast_rcnn自带的im_detect函数来进行检测,im_detect函数接收两个参数,分别为net对象和待识别的图像,返回两个参数:box和scores,box是用来存储检测结果的框图坐标,scores是检测结果的置信度;画框模块5通过识别模块4得到的框图坐标和检测结果置信度,首先对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同—睁眼和闭眼,画出颜色不同的框体加以区别;警报模块6用于发送警报信号。The parameter parsing module 1 is responsible for reading various parameter settings of the program when the program starts, such as whether to use the RPN network, the name of the network and model used by the code, whether to use the CPU, the number of the GPU device, etc.; the video capture module 2 uses OpenCV The VideoCapture function captures the video. When the camera is turned on, it will automatically read a frame of image. If the read-in image is valid, the read-in image will be transmitted to the image processing module 3; After this frame of image is received, the length and width of the image are read and recorded through the numpy package, and a zero matrix of the same size is generated to prepare for the output of future images, and then the image is transmitted to the recognition module 4; recognition module 4 The im_detect function that comes with fast_rcnn is called for detection. The im_detect function receives two parameters, namely the net object and the image to be recognized, and returns two parameters: box and scores. Box is the frame coordinates used to store the detection results, and scores is the confidence of the detection result; the frame-frame module 5 first traverses all the categories through the frame coordinates obtained by the recognition module 4 and the confidence of the detection result, and draws a frame and labels the categories according to the frame coordinates of all categories whose confidence is greater than the threshold. According to the different categories—open eyes and closed eyes, draw boxes with different colors to distinguish them; the alarm module 6 is used to send an alarm signal.

为进一步优化上述技术方案,警报模块6连接有蜂鸣器7,当警报模块6输出高电平时蜂鸣器7报警,当警报模块6输出低电平时蜂鸣器7停止报警。In order to further optimize the above technical solution, the alarm module 6 is connected with a buzzer 7. When the alarm module 6 outputs a high level, the buzzer 7 alarms, and when the alarm module 6 outputs a low level, the buzzer 7 stops alarming.

实施例Example

图一所示的为本发明的一个实施过程,系统开启后,参数解析模块1会读取所使用的网络模型和相关配置文件,完成模型的预加载,视频采集模块2开始监控,图像处理模块3记录图像的规格信息(长,宽),然后将其传输识别模块4。识别模块4会返回识别类别的置信度数组和框图坐标数组。经过一系列的处理:从置信度数组和框图坐标数组中获得置信度score和框图坐标(xmin,ymin,xmax,ymax),将它们按列堆叠,一起存入dets数组,对dets数组进行非极大值抑制,即去掉所有的较小区域后,得出识别结果,并调用画框模块5进行画框。每识别出一次闭眼,则闭眼次数统计量加1,每识别出一次睁眼,则闭眼次数统计量减1,当闭眼次数统计量为0时,则不进行减1操作;当闭眼次数统计量大于阈值时,警报模块6发送高电平给蜂鸣器7,蜂鸣器7开始报警,直至闭眼次数统计量为0后,警报模块6才会发送低电平给蜂鸣器7,蜂鸣器7停止警报。Figure 1 shows an implementation process of the present invention. After the system is turned on, the parameter analysis module 1 will read the used network model and related configuration files, complete the preloading of the model, the video acquisition module 2 starts monitoring, and the image processing module 3. Record the specification information (length, width) of the image, and then transmit it to the recognition module 4. The recognition module 4 will return the confidence level array and box frame coordinate array of the recognition category. After a series of processing: obtain the confidence score and box coordinates (x min , y min , x max , y max ) from the confidence score array and box frame coordinate array, stack them in columns, store them in the dets array together, and compare the dets The array is subjected to non-maximum suppression, that is, after removing all the smaller areas, the recognition result is obtained, and the frame module 5 is called to frame. Every time an eye closure is identified, the number of closed eyes is increased by 1, and every time an open eye is identified, the number of closed eyes is decreased by 1. When the statistics of closed eyes is 0, the operation of decrementing by 1 is not performed; when When the count of closed eyes is greater than the threshold, the alarm module 6 sends a high level to the buzzer 7, and the buzzer 7 starts to alarm, and the alarm module 6 will not send a low level to the buzzer until the count of closed eyes is 0. Buzzer 7, buzzer 7 stops the alarm.

本说明书中各个实施例采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似部分互相参见即可。对于实施例公开的装置而言,由于其与实施例公开的方法相对应,所以描述的比较简单,相关之处参见方法部分说明即可。The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same and similar parts between the various embodiments can be referred to each other. As for the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant part can be referred to the description of the method.

对所公开的实施例的上述说明,使本领域专业技术人员能够实现或使用本发明。对这些实施例的多种修改对本领域的专业技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本发明的精神或范围的情况下,在其它实施例中实现。因此,本发明将不会被限制于本文所示的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。The above description of the disclosed embodiments enables any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (7)

1.一种基于深度学习的疲劳驾驶预警方法,其特征在于,包括步骤如下:1. a fatigue driving warning method based on deep learning, is characterized in that, comprises the steps as follows: S1、采集驾驶员眼部图像;S1. Collect the driver's eye image; S2、建立Faster R-CNN人眼睁闭检测模型;S2. Establish a Faster R-CNN human eye opening and closing detection model; S3、用Faster R-CNN对驾驶员眼部图像进行检测,获取框图坐标及检测结果的置信度;S3. Use Faster R-CNN to detect the driver's eye image, and obtain the frame coordinates and the confidence of the detection result; S4、对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同,画出颜色不同的框体加以区别;S4, traverse all the categories, draw frames and mark the categories according to the frame coordinates of all categories whose confidence is greater than the threshold, and draw frames with different colors to distinguish them according to the categories; S5、输出检测类别。S5. Output the detection category. 2.一种基于深度学习的疲劳驾驶预警方法,其特征在于,所述步骤S2的具体过程为:2. a kind of fatigue driving warning method based on deep learning, is characterized in that, the concrete process of described step S2 is: S21、选择RPN作为网络结构,通过CEW数据集进行模拟训练;S21. Select RPN as the network structure, and conduct simulation training through the CEW data set; S22、为锚点打标签,与真实标签的Box有最高交并比重叠的锚点或交并比达到0.7的锚点为正标签,交并比低于0.3的锚点为负标签;S22. Label the anchor points. An anchor point with the highest overlap ratio with the box of the real label or an anchor point with an intersection ratio of 0.7 is a positive label, and an anchor point with an intersection ratio lower than 0.3 is a negative label; S22、对共享卷积层进行训练,对特有层进行参数微调。S22, train the shared convolutional layer, and fine-tune the parameters of the unique layer. 3.一种基于深度学习的疲劳驾驶预警方法,其特征在于,所述类别为睁眼或闭眼。3. A fatigue driving warning method based on deep learning, wherein the category is eyes open or eyes closed. 4.一种基于深度学习的疲劳驾驶预警方法,其特征在于,所述步骤S3中检测的具体过程为:使用im_detect函数对驾驶员眼部图像进行检测。4. A fatigue driving warning method based on deep learning, characterized in that the specific process of detection in the step S3 is: using the im_detect function to detect the driver's eye image. 5.一种使用权利要求1-4中任意一项所述的基于深度学习的疲劳驾驶预警方法的系统,其特征在于,包括:参数解析模块(1),视频采集模块(2),图像处理模块(3),识别模块(4),画框模块(5),警报模块(6);5. A system using the deep learning-based fatigue driving warning method according to any one of claims 1-4, characterized in that, comprising: a parameter analysis module (1), a video acquisition module (2), an image processing module module (3), identification module (4), picture frame module (5), alarm module (6); 所述参数解析模块(1)用于当程序启动时读入程序的各种参数设定,所述视频采集模块(2)用于采集视频,并将有效视频传输至所述图像处理模块(3),所述图像处理模块(3)用于读入并记录图像的长度和宽度,并生成一个同样大小的零矩阵,然后,将图像传输至所述识别模块(4),所述识别模块(4)使用训练后的Fast R-CNN检测网络生成检测结果的框图坐标及检测结果的置信度,所述画框模块(5)用于通过识别框图坐标和检测结果置信度,对所有类别进行遍历,将所有置信度大于阈值的类别根据框图坐标进行画框并标注类别,根据类别的不同,画出颜色不同的框体加以区别,所述警报模块(6)用于发送警报信号。The parameter analysis module (1) is used for reading in various parameter settings of the program when the program is started, and the video capture module (2) is used for capturing video and transmitting valid video to the image processing module (3). ), the image processing module (3) is used to read in and record the length and width of the image, and generate a zero matrix of the same size, then, the image is transmitted to the recognition module (4), the recognition module ( 4) Using the trained Fast R-CNN detection network to generate the frame coordinates of the detection results and the confidence of the detection results, the frame module (5) is used to traverse all the categories by identifying the frame coordinates and the confidence of the detection results , all the categories with confidence greater than the threshold are framed according to the coordinates of the frame and marked with the categories, according to the different categories, the frames with different colors are drawn to distinguish them, and the alarm module (6) is used for sending an alarm signal. 6.根据权利要求5所述的一种基于深度学习的疲劳驾驶预警系统,其特征在于,所述类别为睁眼和闭眼。6 . The fatigue driving warning system based on deep learning according to claim 5 , wherein the categories are eyes open and eyes closed. 7 . 7.根据权利要求5所述的一种基于深度学习的疲劳驾驶预警系统,其特征在于,所述警报模块(6)连接有蜂鸣器(7),当所述警报模块(6)输出高电平时所述蜂鸣器(7)报警,当所述警报模块(6)输出低电平时所述蜂鸣器(7)停止报警。7. The deep learning-based fatigue driving warning system according to claim 5, wherein the alarm module (6) is connected with a buzzer (7), and when the alarm module (6) outputs a high The buzzer (7) alarms when the level is at a low level, and the buzzer (7) stops the alarm when the alarm module (6) outputs a low level.
CN202010053964.8A 2020-01-17 2020-01-17 Fatigue driving early warning method and system based on deep learning Pending CN111243236A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010053964.8A CN111243236A (en) 2020-01-17 2020-01-17 Fatigue driving early warning method and system based on deep learning

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010053964.8A CN111243236A (en) 2020-01-17 2020-01-17 Fatigue driving early warning method and system based on deep learning

Publications (1)

Publication Number Publication Date
CN111243236A true CN111243236A (en) 2020-06-05

Family

ID=70879509

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010053964.8A Pending CN111243236A (en) 2020-01-17 2020-01-17 Fatigue driving early warning method and system based on deep learning

Country Status (1)

Country Link
CN (1) CN111243236A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114387435A (en) * 2021-12-14 2022-04-22 阿里巴巴达摩院(杭州)科技有限公司 Image processing method, storage medium, and computer terminal

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103198617A (en) * 2013-03-26 2013-07-10 无锡商业职业技术学院 Fatigue driving warning system
CN104257392A (en) * 2014-09-26 2015-01-07 马天驰 Fatigue driving detection prompt method and detection prompt device
JP2017505733A (en) * 2014-01-15 2017-02-23 国防科学技術大学 Method and apparatus for detecting safe driving state of driver
CN107657236A (en) * 2017-09-29 2018-02-02 厦门知晓物联技术服务有限公司 Vehicle security drive method for early warning and vehicle-mounted early warning system
CN107766835A (en) * 2017-11-06 2018-03-06 贵阳宏益房地产开发有限公司 traffic safety detection method and device
CN109523652A (en) * 2018-09-29 2019-03-26 百度在线网络技术(北京)有限公司 Processing method, device, equipment and the storage medium of insurance based on driving behavior
CN109886241A (en) * 2019-03-05 2019-06-14 天津工业大学 Driver fatigue detection based on long short-term memory network
CN110147738A (en) * 2019-04-29 2019-08-20 中国人民解放军海军特色医学中心 A kind of driver fatigue monitoring and pre-alarming method and system
TWI669664B (en) * 2018-09-14 2019-08-21 大陸商虹軟科技股份有限公司 Eye state detection system and method for operating an eye state detection system
CN110245574A (en) * 2019-05-21 2019-09-17 平安科技(深圳)有限公司 A kind of human fatigue state identification method, device and terminal device
CN110428908A (en) * 2019-07-31 2019-11-08 广西壮族自治区人民医院 A kind of eyelid movement functional assessment system based on artificial intelligence
CN209719572U (en) * 2019-03-22 2019-12-03 中国科学院重庆绿色智能技术研究院 A fatigue driving recognition control system
JP2019536673A (en) * 2017-08-10 2019-12-19 ペキン センスタイム テクノロジー ディベロップメント カンパニー リミテッド Driving state monitoring method and device, driver monitoring system, and vehicle

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103198617A (en) * 2013-03-26 2013-07-10 无锡商业职业技术学院 Fatigue driving warning system
JP2017505733A (en) * 2014-01-15 2017-02-23 国防科学技術大学 Method and apparatus for detecting safe driving state of driver
CN104257392A (en) * 2014-09-26 2015-01-07 马天驰 Fatigue driving detection prompt method and detection prompt device
JP2019536673A (en) * 2017-08-10 2019-12-19 ペキン センスタイム テクノロジー ディベロップメント カンパニー リミテッド Driving state monitoring method and device, driver monitoring system, and vehicle
CN107657236A (en) * 2017-09-29 2018-02-02 厦门知晓物联技术服务有限公司 Vehicle security drive method for early warning and vehicle-mounted early warning system
CN107766835A (en) * 2017-11-06 2018-03-06 贵阳宏益房地产开发有限公司 traffic safety detection method and device
TWI669664B (en) * 2018-09-14 2019-08-21 大陸商虹軟科技股份有限公司 Eye state detection system and method for operating an eye state detection system
CN109523652A (en) * 2018-09-29 2019-03-26 百度在线网络技术(北京)有限公司 Processing method, device, equipment and the storage medium of insurance based on driving behavior
CN109886241A (en) * 2019-03-05 2019-06-14 天津工业大学 Driver fatigue detection based on long short-term memory network
CN209719572U (en) * 2019-03-22 2019-12-03 中国科学院重庆绿色智能技术研究院 A fatigue driving recognition control system
CN110147738A (en) * 2019-04-29 2019-08-20 中国人民解放军海军特色医学中心 A kind of driver fatigue monitoring and pre-alarming method and system
CN110245574A (en) * 2019-05-21 2019-09-17 平安科技(深圳)有限公司 A kind of human fatigue state identification method, device and terminal device
CN110428908A (en) * 2019-07-31 2019-11-08 广西壮族自治区人民医院 A kind of eyelid movement functional assessment system based on artificial intelligence

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114387435A (en) * 2021-12-14 2022-04-22 阿里巴巴达摩院(杭州)科技有限公司 Image processing method, storage medium, and computer terminal

Similar Documents

Publication Publication Date Title
CN108791299B (en) Driving fatigue detection and early warning system and method based on vision
Gupta et al. Implementation of motorist weariness detection system using a conventional object recognition technique
WO2020078465A1 (en) Method and device for driving state analysis, driver monitoring system and vehicle
Hossain et al. IOT based real-time drowsy driving detection system for the prevention of road accidents
CN101593425B (en) Machine vision based fatigue driving monitoring method and system
CN105354985B (en) Fatigue driving monitoring apparatus and method
CN109902562A (en) A driver abnormal posture monitoring method based on reinforcement learning
CN101655907A (en) Trainman driving state monitoring intelligent alarm system
CN208126407U (en) Anti-fatigue-driving system based on software-hardware synergism image procossing
CN113887386A (en) Fatigue detection method based on deep learning and machine learning multi-feature fusion
CN113901866A (en) A fatigue driving warning method based on machine vision
CN118230298A (en) Driver fatigue driving state detection system and method
CN111243236A (en) Fatigue driving early warning method and system based on deep learning
CN114529887A (en) Driving behavior analysis method and device
Soman et al. Internet-of-things-assisted artificial intelligence-enabled drowsiness detection framework
Aboagye et al. Design and Development of Computer Vision-Based Driver Fatigue Detection and Alert System
GB2634152A (en) Method for assessing driver drowsiness based on view angle correction and improved vivit
CN114037979A (en) Lightweight driver fatigue state detection method
CN117115894A (en) Non-contact driver fatigue state analysis method, device and equipment
CN117475413A (en) Fatigue driving detection method and system based on image recognition and BP neural network
Gupta et al. Real time driver drowsiness detecion using transfer learning
CN117116467A (en) Intelligent diagnosis and treatment system based on facial recognition
Rajput et al. Accident prevention using drowsiness detection
CN114998874A (en) Driver abnormal behavior detection method based on deep learning
Mohan et al. Identification of driver drowsiness detection using a regularized extreme learning machine

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200605