Driver dangerous driving behavior detection method based on deep learning algorithm

By detecting the driver's face video frames through a deep learning algorithm, combined with aspect ratio and head posture judgment, it solves the problem of high false alarm and misrecognition rates in the existing technology, and achieves more accurate detection of driver's dangerous driving behavior.

CN118570774APending Publication Date: 2024-08-30SHANGHAI MISSION INFORMATION TECH CORP LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410334530.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-03-22
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

Existing driver dangerous driving behavior detection methods have problems with false alarms, high misrecognition rates, and errors, including the inability of traditional image processing to judge dynamic behaviors, misrecognition of small eyes by methods based on human eye recognition, and methods based on key points due to human factors. Errors caused by fluctuations in relative ratios due to face differentiation.

Method used

Using a method based on deep learning algorithms, the driver's face video frames are collected in real time, face areas and key points are detected through MTCNN, head posture is estimated using the SixDRepNet model, the aspect ratio of the eyes and mouth is calculated, and the video frame queue is maintained to determine continuity. and relevance, setting thresholds to judge off-duty, eye-closing, yawning and gaze aversion behaviors.

Benefits of technology

It improves the accuracy and persuasiveness of detection and reduces false alarms. The key point features extracted through deep learning algorithms are more representative and can more accurately judge the driver's dangerous driving behavior.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570774A
    Figure CN118570774A
Patent Text Reader

Abstract

The invention relates to a driver dangerous driving behavior detection method based on a deep learning algorithm, and the method comprises the steps: collecting continuous video frames of the face of a driver in real time, and maintaining a video frame queue of fixed-length frames; detecting a face region and key points in each frame of image; calculating the frame number of the face area which is not detected in the video frame queue, judging whether the driver leaves the post or not, if so, judging that the driver leaves the post, and if not, executing the next step; based on the detected video frame of the face area, calculating the aspect ratio of key points of the eyes and the mouth, estimating the head posture information of the driver by adopting a SixDRepNet model, judging whether the driver has an eye closing behavior or a yawning behavior or a sight line deviation behavior or not, further judging whether the driver has a dangerous driving behavior or not, and completing the detection process. Compared with the prior art, the method has the advantages of improving the detection accuracy and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm. Background Art

[0002] The main task of the driver's dangerous driving behavior detection method is to detect whether the driver has dangerous driving behavior, including leaving the post, driving while fatigued and sight deviation; if so, an alarm signal is output to the monitoring system.

[0003] At present, there are several detection methods for driver fatigue driving, a dangerous driving behavior: based on traditional image processing, based on human eye recognition, and based on single key point recognition. The following will analyze the problems existing in the current methods from these categories of methods. Among the methods based on traditional image processing, patent application CN113255558A discloses a low-cost identification method for driver fatigue driving based on a single image. This method has two defects: 1) Using a static single image cannot determine the driver's dynamics, and the driver's blinking will cause false alarms; 2) This method extracts SIFT features as the representation result of the image. Compared with the rich semantic information extracted by the deep learning algorithm, the SIFT feature is relatively simple and cannot cover all the information of the image. Among the methods based on human eye recognition, patent application CN108805085A discloses an intelligent sleep detection method based on human eye recognition. This method directly divides the eye state into: closed eyes and open eyes, and trains neural network models for the two eye states. The defect of this method is that when the driver's eyes are small, or the driver squints but does not close his eyes, it will affect the recognition accuracy of the model. In the method based on key point recognition, patent application CN108363968A discloses a driver fatigue driving monitoring based on key point extraction. This method calculates the ratio of the height difference of the mouth or eyes to the height of the entire face as the degree of opening of the mouth or eyes, thereby judging whether the driver is yawning or closing his eyes. The defect of this method is that when the driver's eyes are small and the face height is large, the ratio of the height difference of the eyes to the face height will be small. When the ratio is less than a predetermined threshold, it will lead to an erroneous judgment.

[0004] In summary, the current methods for detecting dangerous driving behaviors of drivers have the following problems: First, the traditional image processing method only uses a single image for judgment, and cannot judge the dynamics of the driver. Actions such as blinking will cause false alarms, and the SIFT features extracted by this method lack richer semantic information compared to the features extracted by the deep learning algorithm; secondly, the method based on human eye recognition will mistakenly identify small eyes as closed eyes, affecting the recognition accuracy; finally, in the recognition method based on key points, the ratio of the height difference of the eyes to the height of the face represents the degree of openness of the eyes, but due to the differences in human faces, the relative ratio will fluctuate widely, and using the same threshold for judgment will cause large errors. Summary of the invention

[0005] The purpose of the present invention is to provide a method for detecting dangerous driving behavior of drivers based on a deep learning algorithm with improved detection accuracy.

[0006] The purpose of the present invention can be achieved by the following technical solutions:

[0007] A method for detecting dangerous driving behavior of a driver based on a deep learning algorithm comprises the following steps:

[0008] Collect continuous video frames of the driver's face in real time and maintain a fixed-length video frame queue;

[0009] Using a deep learning algorithm to detect the face area and key points in each frame of the video frame queue, the key points include key points of the eyes and mouth;

[0010] Count the number of frames in the video frame queue where no face area is detected, and determine whether the driver is off duty. If so, determine that there is dangerous driving behavior. If not, proceed to the next step.

[0011] Based on the video frames with detected face areas, the aspect ratios of the key points of the eyes and mouth are calculated, and the SixDRepNet model is used to estimate the driver's head posture information. This determines whether the driver has closed his eyes, yawned, or strayed from his line of sight, and further determines whether the driver has engaged in dangerous driving behavior, thus completing the detection process.

[0012] Furthermore, the deep learning algorithm is a MTCNN algorithm.

[0013] Furthermore, the step of determining whether the driver is off duty includes:

[0014] Calculate the ratio of the number of frames in which no face area is detected to the number of frames in the video frame queue, and record it as C1;

[0015] Set the off-duty threshold τ. If C1 is greater than or equal to τ, it means the driver is off-duty; otherwise, it means the driver is not off-duty.

[0016] Furthermore, the key points of the eye area include the key points of the left eye area and the key points of the right eye area, and the key points of the left eye area include the left eye corner point P l1 (le x1 ,le y1 ), the right corner point P of the left eye l2 (le x2 ,le y2 ), left eye upper contour key point P l3 (le x3 ,le y3 ) and P l4 (le x4 ,le y4 ), left eye lower contour key point P l5 (le x5 ,le y5 ) and p l6 (le x6 ,le y6 ), the key points of the right eye area include the left eye corner point P of the right eye r1 (re x1 ,re y1 ), the right eye corner point P r2 (re x2 ,re y2 ), the key point P of the upper contour of the right eye r3 (re x3 ,re y3 ) and P r4 (re x4 ,re y4 ), right eye lower contour key point P r5 (re x5 ,re y5 ) and P r6 (re x6 ,re y6 ).

[0017] Furthermore, the steps of determining whether the driver has closed his eyes and further determining whether the driver has engaged in dangerous driving behavior include:

[0018] Calculate the left eye corner point P of the left eye l1 (le x1 ,le y1 ) and the right eye corner point P of the left eye l2 (le x2 ,le y2 ) is the Euclidean distance, denoted as: d hl ;

[0019] Calculate the left eye corner point P of the right eye r1 (rex1 ,re y1 ) and the right eye corner point P r2 (re x2 ,re y2 ), denoted as: d hr ;

[0020] Calculate the two sets of contour key points P of the left eye l3 (le x3 ,le y3 ) and P l5 (le x5 ,le y5 ), P l4 (le x4 ,le y4 ) and P l6 (le x6 ,le y6 ), respectively denoted as d v1 and d v2 , and calculate d v1 and d v2 The mean value of

[0021] Calculate the two sets of contour key points P of the right eye r3 (re x3 ,re y3 ) and P r5 (re x5 ,re y5 ), P r4 (re x4 ,re y4 ) and P r6 (re x6 ,re y6 ), respectively denoted as d v1′ and d v2′ , and calculate d v1′ and d v2′ The mean value of

[0022] calculate With d hl The ratio is denoted as: R el ;

[0023] calculate With d hr The ratio is denoted as: R er ;

[0024] Calculate R el and R er The mean value is denoted as: R e ;

[0025] Set the threshold α to determine R e Is it less than or equal to α? If yes, it means that the driver has closed eyes in the current video frame image; if no, it means that the driver has not closed eyes in the current video frame image;

[0026] Calculate the number of video frames in which the driver has closed eyes in the video frame queue, recorded as T, and calculate the ratio of T to the number of frames in the video frame queue, recorded as C2;

[0027] Set the threshold τ e , determine whether C2 is greater than or equal to τ e If yes, it means the driver has dangerous driving behavior, if no, it means the driver has no dangerous driving behavior.

[0028] Furthermore, the key points of the mouth include the left corner point P of the mouth m1 (ml x ,ml y ), right corner of mouth point P m2 (mr x ,mr y ), upper lip key points and lower lip key points, the upper lip key points and lower lip key points are 3, used for the position of the upper lip and lower lip, the upper lip key points are P u1 (mu x1 ,mu y1 ), P u2 (mu x2 ,mu y2 ), P u3 (mu x3 ,mu y3 ), the key points of the lower lip are P d1 (md x1 ,md y1 ), P d2 (md x2 ,md y2 ), P d3 (md x3 ,md y3 ).

[0029] Furthermore, the steps of determining whether the driver yawns and further determining whether the driver has dangerous driving behavior include:

[0030] Calculate the left corner point P of the mouth m1 (ml x ,ml y ) and the right corner of the mouth point P m2 (mr x ,mr y ), denoted as d mh ;

[0031] Calculate three sets of lip key points P respectively u1 (mu x1 ,mu y1 ) and P d1 (md x1 ,md y1 ), P u2 (mu x2 ,mu y2 ) and P d2 (md x2 ,md y2 ), P u3 (mu x3 ,mu y3 ) and P d3 (md x3 ,md y3 ) and find the mean of the three sets of Euclidean distances, denoted as: d ml ;

[0032] Calculate d ml and d mh The ratio is denoted as: R m ;

[0033] Set the threshold β and judge R m Is it greater than or equal to β? If so, it means that the driver in the current video frame image has yawning behavior; if not, it means that the driver in the current video frame image does not have yawning behavior;

[0034] Calculate the number of video frames in the video frame queue in which the driver yawns, recorded as V, and calculate the ratio of V to the number of frames in the video frame queue, recorded as C3;

[0035] Set the threshold τ m , determine whether C3 is greater than or equal to τ m If yes, it means the driver has dangerous driving behavior, if no, it means the driver has no dangerous driving behavior.

[0036] Furthermore, the driver's head posture information includes a pitch angle, a yaw angle, and a roll angle, which respectively correspond to the driver's head movements of raising his head, shaking his head, and turning his head.

[0037] Furthermore, the step of determining whether the driver has a visual deviation behavior and further determining whether the driver has a dangerous driving behavior includes:

[0038] Set the thresholds τ of the pitch angle, yaw angle and roll angle respectively p ,τ y and τ r , determine whether the pitch angle is greater than or equal to τ p , or whether the yaw angle is greater than or equal to τy , or whether the roll angle is greater than or equal to τ r , if yes, it means that the driver has a visual deviation behavior in the current video frame image, if no, it means that the driver has no visual deviation behavior in the current video frame image;

[0039] Calculate the number of video frames in the video frame queue in which the driver has a line of sight deviation behavior, recorded as S, and calculate the ratio of S to the number of frames in the video frame queue, recorded as C4;

[0040] Set the threshold τ h , determine whether C4 is greater than or equal to τ h If yes, it means the driver has dangerous driving behavior, if no, it means the driver has no dangerous driving behavior.

[0041] Furthermore, it also includes: outputting a dangerous driving signal according to the detected dangerous driving behavior.

[0042] Compared with the prior art, the present invention has the following beneficial effects:

[0043] (1) The present invention maintains a video frame queue and judges all image information in a video frame as a whole, fully considering the continuity and correlation of dangerous driving behaviors and improving the accuracy of detection.

[0044] (2) Compared with the traditional image processing method to extract SIFT features, the key point features of the eyes and mouth extracted by the deep learning algorithm MTCNN in the present invention are more representative.

[0045] (3) The present invention determines the closed state of the eyes and mouth by calculating the aspect ratio of the key points of the eyes and mouth. It will not cause a large fluctuation range of the relative ratio due to the differences in human faces, and will reduce false alarms.

[0046] (4) The present invention determines the driver's dangerous driving behavior by detecting driver fatigue driving, driver vision deviation and driver leaving the post in three dimensions, and the detection result is more convincing. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 It is a schematic diagram of the method flow of the present invention;

[0048] Figure 2 A schematic diagram of the layout of the driver's cab monitoring camera according to an embodiment of the present invention;

[0049] Figure 3 A schematic diagram of the driver's face region and key points of the eyes and mouth according to an embodiment of the present invention;

[0050] Figure 4 A schematic diagram of a driver closing his eyes according to an embodiment of the present invention;

[0051] Figure 5 A schematic diagram of a driver yawning according to an embodiment of the present invention;

[0052] Figure 6 Schematic diagram of driver's sight deviation according to an embodiment of the present invention. DETAILED DESCRIPTION

[0053] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. This embodiment is implemented based on the technical solution of the present invention, and provides a detailed implementation method and specific operation process, but the protection scope of the present invention is not limited to the following embodiments.

[0054] The collection, updating, analysis, and processing of all personal portraits involved in this embodiment comply with the law, do not violate public order and good morals, and all portraits involved have been authorized for use by the person bearing the portrait. This embodiment provides a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm. Figure 1 As shown, the method comprises the following steps:

[0055] S1. Install a surveillance camera above the driver's cab, with the camera facing the driver.

[0056] like Figure 2 As shown, in this embodiment, the camera is facing the driver's face and is about sixty centimeters away from the driver's face.

[0057] S2. Collect continuous video in real time and maintain a video queue with a fixed length of K frames.

[0058] The surveillance camera collects continuous video in real time. The length of the video frame queue Q is K. The queue length is fixed and is used to store continuous video frames. The queue Q = {I1, I2, ..., I i}, I i is the i-th frame image in the queue, i=1,2,...,k;

[0059] Whenever a new video frame is read in, the image frame at the head of the queue is removed from the queue, and the new video frame is added to the tail of the queue.

[0060] S3. Use deep learning algorithms to detect the face area and key points of the eyes and mouth in the K-frame video sequence to determine whether the driver is off duty.

[0061] In this embodiment, the deep learning algorithm MTCNN is used to detect the key points of the face area and the eyes and mouth in each frame image in the queue Q, such as Figure 3 As shown, the key points include:

[0062] S31: 6 key points of the left eye:

[0063] ① Left eye corner point P l1 , the specific coordinates are: (le x1 ,le y1 );

[0064] ②The left and right corner points P l2 , the specific coordinates are: (le x2 ,le y2 );

[0065] ③Left eye upper contour key point P l3 and P l4 , the specific coordinates are: (le x3 ,le y3 ), (le x4 ,le y4 );

[0066] ④Left eye lower contour key point P l5 and P l6 , the specific coordinates are: (le x5 ,le y5 ), (le x6 ,le y6 );

[0067] S32: 6 key points of the right eye:

[0068] ① Right eye left eye corner point P r1 , the specific coordinates are: (re x1 ,re y1 );

[0069] ② Right eye corner point P r2 , the specific coordinates are: (re x2 ,re y2 );

[0070] ③The key point P of the upper contour of the right eye r3 and P r4 , the specific coordinates are: (re x3 ,re y3 ), (re x4 ,re y4 );

[0071] ④Key point P of the lower right eye contour r5 and P r6 , the specific coordinates are: (re x5 ,re y5 ), (re x6 ,re y6 );

[0072] S33: 8 key points of the mouth:

[0073] ① Point P at the left corner of the mouth m1 , the specific coordinates are: (ml x ,ml y );

[0074] ②Point P at the right corner of the mouth m2 , the specific coordinates are: (mr x ,mr y );

[0075] ③ Upper lip feature points: three key points located above the upper lip, used to mark the position of the upper lip, namely: P u1 :(mu x1 ,mu y1 ), P u2 :(mu x2 ,mu y2 ), P u3 :(mu x3 ,mu y3 );

[0076] ④Lower lip feature points: Three key points located below the lower lip, used to mark the position of the lower lip, namely: P d1 :(md x1 ,md y1 ), P d2 :(md x2 ,md y2 ), P d3 :(md x3 ,md y3 ).

[0077] The steps to determine whether a driver is off duty include:

[0078] S34: Calculate the number of frames in Q where no face area is detected, denoted as N;

[0079] S35: Calculate the ratio of N to K, recorded as C1;

[0080] S36: Set an off-duty threshold τ. If C1 is greater than or equal to τ, it means that the driver is off-duty, and a dangerous driving signal of the driver is output to the monitoring system.

[0081] S4. If the driver has not left his post, calculate the aspect ratio of the key points of the eyes and mouth in the K-frame video sequence to determine whether the driver has closed his eyes or yawned.

[0082] The steps to determine whether the driver has closed his eyes include:

[0083] S41: Calculate the left eye corner key point p l1 and P l2 The Euclidean distance is denoted as: d hl ; Calculate the feature point P of the right eye cornerr1 and p r2 The Euclidean distance is denoted as: d hr ;

[0084] S42: Calculate the left eye contour key point P l3 and P l5 The Euclidean distance is denoted as: d v1 ; Calculate the left eye contour feature point P l4 and P l6 The Euclidean distance is denoted as: d v2 , and calculate d v1 and d v2 The mean value of

[0085] S43: Calculate the right eye contour key point P r3 and P r5 The Euclidean distance is denoted as: d v1′ ; Calculate the right eye contour feature point P r4 and p r6 The Euclidean distance is denoted as: d v2′ , and calculate d v1′ and d v2′ The mean value of

[0086] S44: Calculation With d hl The ratio is denoted as: R el ;calculate With d hr The ratio is denoted as: R er ; Calculate R el and R er The mean value is denoted as: R e ;

[0087] S45: Set threshold α, if R e If it is less than or equal to α, it means that the driver has closed his eyes in the current video frame image;

[0088] S46: Calculate the number of video frames in the video frame queue Q in which the driver has closed eyes, recorded as T, and calculate the ratio of T to the video frame length K, recorded as C2;

[0089] S47: Setting threshold τ e , if C2 is greater than or equal to τ e , then the driver's dangerous driving signal is output to the monitoring system.

[0090] The driver's eyes closed results obtained in this example are as follows Figure 4 shown.

[0091] The steps to determine whether the driver is yawning include:

[0092] S48: Calculate the mouth corner key points P m1 and P m2 The Euclidean distance of mh ;

[0093] S49: Calculate three groups of mouth and lip key points P respectively u1 and P d1 , P u2 and P d2 , P u3 and P d3 The Euclidean distance of the three groups is calculated, and the mean of the three groups of Euclidean distances is recorded as: d ml ;

[0094] S410: Calculate d ml and d mh The ratio is denoted as: R m ;

[0095] S411: Set threshold β, if R m If it is greater than or equal to β, it means that the driver is yawning in the current video frame image;

[0096] S412: Calculate the number of video frames in the video frame queue Q in which the driver yawns, recorded as V, and calculate the ratio of V to the video frame length K, recorded as C3;

[0097] S413: Setting threshold τ m , if C3 is greater than or equal to τ m , then the driver's dangerous driving signal is output to the monitoring system.

[0098] The driver yawning results detected in this example are as follows Figure 5 shown.

[0099] S5. If the driver has not left his post, use the deep learning algorithm to predict the driver's head posture and determine whether the driver's line of sight is deviated.

[0100] S51: using the deep learning algorithm model SixDRepNet to predict the Euler angle information of the driver's head, the Euler angle includes: pitch angle P, yaw angle Y and roll angle R, corresponding to the driver's head movements represented by raising head, shaking head and turning head respectively;

[0101] S52: Set three thresholds τ respectively p ,τ y and τ r , if P is greater than or equal to τ p , or Y is greater than or equal to τ y , or R is greater than or equal to τ r , indicating that the driver has deviated his sight in the current video frame image;

[0102] S53: Calculate the number of video frames in which the driver's line of sight is deviated in the video frame queue Q, recorded as S, and calculate the ratio of S to the video frame length K, recorded as C4;

[0103] S54: Setting threshold τ h , if C4 is greater than or equal to τ h , then the driver's dangerous driving signal is output to the monitoring system. The driver's line of sight deviation results detected in this example are as follows Figure 6 shown.

[0104] If the above functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc., which can store program code.

[0105] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes. The schemes in the embodiments of the present invention may be implemented in various computer languages, for example, object-oriented programming language Java and literal scripting language JavaScript, etc.

[0106] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0107] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0108] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0109] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.

[0110] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A method for detecting dangerous driving behavior of drivers based on deep learning algorithm, It is characterized in that The following steps are involved: Collect continuous video frames of the driver's face in real time and maintain a fixed-length video frame queue; Using a deep learning algorithm to detect the face area and key points in each frame of the video frame queue, the key points include key points of the eyes and mouth; Count the number of frames in the video frame queue where no face area is detected, and determine whether the driver is off duty. If so, determine that there is dangerous driving behavior. If not, proceed to the next step. Based on the video frames with detected face areas, the aspect ratios of the key points of the eyes and mouth are calculated, and the SixDRepNet model is used to estimate the driver's head posture information. This determines whether the driver has closed his eyes, yawned, or strayed from his line of sight, and further determines whether the driver has engaged in dangerous driving behavior, thus completing the detection process.

2. According to claim 1, a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm, It is characterized in that The deep learning algorithm is the MTCNN algorithm.

3. According to claim 1, a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm, It is characterized in that The step of determining whether the driver is off duty comprises: Calculate the ratio of the number of frames in which no face area is detected to the number of frames in the video frame queue, and record it as C1; Set the off-duty threshold τ. If C1 is greater than or equal to τ, it means the driver is off-duty; otherwise, it means the driver is not off-duty.

4. According to claim 1, a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm, It is characterized in that The key points of the eye part include the key points of the left eye part and the key points of the right eye part. The key points of the left eye part include the left eye corner point P l1 (le x1 ,le y1 ), the right corner point P of the left eye l2 (le x2 ,le y2 ), left eye upper contour key point P l3 (le x3 ,le y3 ) and P l4 (le x4 ,le y4 ), left eye lower contour key point P l5 (le x5 ,le y5 ) and P l6 (le x6 ,le y6 ), the key points of the right eye area include the left eye corner point P of the right eye r1 (re x1 ,re y1 ), the right eye corner point P r2 (re x2 ,re y2 ), the key point P of the upper contour of the right eye r3 (re x3 ,re y3 ) and P r4 (re x4 ,re y4 ), right eye lower contour key point P r5 (re x5 , r ey5 ) and P r6 (re x6 ,re y6 ).

5. According to claim 4, a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm, It is characterized in that The steps of determining whether the driver has closed his eyes and further determining whether the driver has dangerous driving behavior include: Calculate the left eye corner point P of the left eye l1 (le x1 ,le y1 ) and the right eye corner point P of the left eye l2 (le x2 ,le y2 ) is the Euclidean distance, denoted as: d hl ; Calculate the left eye corner point P of the right eye r1 (re x1 ,re y1 ) and the right eye corner point P r2 (re x2 ,re y2 ), denoted as: d hr ; Calculate the two sets of contour key points P of the left eye l3 (le x3 ,le y3 ) and P l5 (le x5 ,le y5 ), P l4 (le x4 ,le y4 ) and P l6 (l ex6 ,le y6 ), respectively denoted as d v1 and d v2 , and calculate d v1 and d v2 The mean value of Calculate the two sets of contour key points P of the right eye r3 (re x3 ,re y3 ) and P r5 (re x5 ,re y5 ), P r4 (re x4 ,re y4 ) and P r6 (re x6 ,re y6 ), respectively denoted as d v1′ and d v2′ , and calculate d v1′ and d v2′ The mean value of calculate With d hl The ratio is denoted as: R el ; calculate With d hr The ratio is denoted as: R er ; Calculate R el and R er The mean value is denoted as: R e ; Set the threshold α to determine R e Is it less than or equal to α? If yes, it means that the driver has closed eyes in the current video frame image; if no, it means that the driver has not closed eyes in the current video frame image; Calculate the number of video frames in which the driver has closed eyes in the video frame queue, recorded as T, and calculate the ratio of T to the number of frames in the video frame queue, recorded as C2; Set the threshold τ e , determine whether C2 is greater than or equal to τ e If yes, it means the driver has dangerous driving behavior, if no, it means the driver has no dangerous driving behavior.

6. A method for detecting dangerous driving behavior of a driver based on a deep learning algorithm according to claim 1, It is characterized in that The key points of the mouth include the left corner point P of the mouth m1 (ml x , ml y ), right corner of mouth point P m2 (mr x , mr y ), upper lip key points and lower lip key points, the upper lip key points and lower lip key points are 3, used for the position of the upper lip and lower lip, the upper lip key points are P u1 (mu x1 ,mu y1 ), P u2 (mu x2 , mu y2 ), P u3 (mu x3 , mu y3 ), the key points of the lower lip are P d1 (md x1 ,md y1 ), P d2 (md x2 ,md y2 ), P d3 (md x3 ,md y3 ).

7. A method for detecting dangerous driving behavior of a driver based on a deep learning algorithm according to claim 6, It is characterized in that The steps of determining whether the driver yawns and further determining whether the driver has dangerous driving behavior include: Calculate the left corner point P of the mouth m1 (ml x , ml y ) and the right corner of the mouth point P m2 (mr x , mr y ), denoted as d mh ; Calculate three groups of lip key points P respectively u1 (mu x1 , mu y1 ) and P d1 (md x1 ,md y1 ), P u2 (mu x2 , mu y2 ) and P d2 (md x2 ,md y2 ), P u3 (mu x3 , mu y3 ) and P d3 (md x3 ,md y3 ) and find the mean of the three sets of Euclidean distances, denoted as: d ml ; Calculate d ml and d mh The ratio is denoted as: R m ; Set the threshold β to determine R m Is it greater than or equal to β? If so, it means that the driver in the current video frame image has yawning behavior; if not, it means that the driver in the current video frame image does not have yawning behavior; Calculate the number of video frames in the video frame queue in which the driver yawns, recorded as V, and calculate the ratio of V to the number of frames in the video frame queue, recorded as C3; Set the threshold τ m , determine whether C3 is greater than or equal to τ m If yes, it means the driver has dangerous driving behavior, if no, it means the driver has no dangerous driving behavior.

8. According to claim 1, a method for detecting dangerous driving behavior of a driver based on a deep learning algorithm, It is characterized in that The driver's head posture information includes a pitch angle, a yaw angle, and a roll angle, which respectively correspond to the driver's head movements of raising his head, shaking his head, and turning his head.

9. A method for detecting dangerous driving behavior of a driver based on a deep learning algorithm according to claim 8, It is characterized in that The steps of determining whether the driver has sight deviation behavior and further determining whether the driver has dangerous driving behavior include: Set the thresholds τ of the pitch angle, yaw angle and roll angle respectively p , τ y and τ r , determine whether the pitch angle is greater than or equal to τ p , or whether the yaw angle is greater than or equal to τ y , or whether the roll angle is greater than or equal to τ r , if yes, it means that the driver has a visual deviation behavior in the current video frame image, if no, it means that the driver has no visual deviation behavior in the current video frame image; Calculate the number of video frames in the video frame queue in which the driver has a line of sight deviation behavior, recorded as S, and calculate the ratio of S to the number of frames in the video frame queue, recorded as C4; Set the threshold τ h , determine whether C4 is greater than or equal to τ h If yes, it means the driver has dangerous driving behavior, if no, it means the driver has no dangerous driving behavior.

10. A method for detecting dangerous driving behavior of a driver based on a deep learning algorithm according to claim 1, It is characterized in that Also includes: Based on the detected dangerous driving behavior, a dangerous driving signal is output.

Citation Information

Cited By

  • User state monitoring method and device

    CN121963095A