WO2022142614A1 - Dangerous driving early warning method and apparatus, computer device and storage medium - Google Patents

Dangerous driving early warning method and apparatus, computer device and storage medium Download PDF

Info

Publication number
WO2022142614A1
WO2022142614A1 PCT/CN2021/125225 CN2021125225W WO2022142614A1 WO 2022142614 A1 WO2022142614 A1 WO 2022142614A1 CN 2021125225 W CN2021125225 W CN 2021125225W WO 2022142614 A1 WO2022142614 A1 WO 2022142614A1
Authority
WO
WIPO (PCT)
Prior art keywords
expression
face image
feature
facial
micro
Prior art date
Application number
PCT/CN2021/125225
Other languages
French (fr)
Chinese (zh)
Inventor
熊玮
Original Assignee
深圳壹账通智能科技有限公司
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 深圳壹账通智能科技有限公司 filed Critical 深圳壹账通智能科技有限公司
Publication of WO2022142614A1 publication Critical patent/WO2022142614A1/en

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
    • 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/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/161Detection; Localisation; Normalisation
    • 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/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/168Feature extraction; Face representation
    • 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/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/174Facial expression recognition
    • GPHYSICS
    • G08SIGNALLING
    • G08BSIGNALLING OR CALLING SYSTEMS; ORDER TELEGRAPHS; ALARM SYSTEMS
    • G08B3/00Audible signalling systems; Audible personal calling systems
    • G08B3/10Audible signalling systems; Audible personal calling systems using electric transmission; using electromagnetic transmission
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/48Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 specially adapted for particular use
    • G10L25/51Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 specially adapted for particular use for comparison or discrimination

Definitions

  • the present application relates to the technical field of micro-expression recognition, and in particular, to a dangerous driving early warning method, device, computer equipment and storage medium.
  • the inventor realized that the existing dangerous driving warning system detects the driver's driving behavior through hardware devices installed on the car, and issues a warning to the driver when a driving violation occurs, for example, by detecting the speed of the car to make a judgment.
  • this method has the problem that the accuracy of dangerous driving warning is low, and the sudden alarm is more likely to cause panic of the driver, resulting in an increased possibility of an accident.
  • Embodiments of the present application provide a dangerous driving warning method, device, computer equipment and storage medium to solve the problem of low accuracy of dangerous driving warning.
  • a dangerous driving warning method comprising:
  • the target expression features Refers to the facial expression feature with the largest difference from the first facial image among all the second facial images;
  • the first facial image refers to the first facial image of the first micro-expression type before the micro-expression changes;
  • the second facial image Refers to the face image in the back-end sequence segment that is continuous with the first face image in the sequence of facial images, and all the second face images in the back-end sequence segment are of the second micro-expression type;
  • the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
  • a dangerous driving voice prompt is triggered according to the voiceprint feature and the sample expression.
  • a dangerous driving warning device comprising:
  • a face image sequence recording module configured to acquire the driver's face image in real time during the driving process of the vehicle, and record the acquired face image as a face image sequence according to the acquisition sequence;
  • the expression feature acquisition module is used to detect whether the facial image in the sequence of facial images has a micro-expression change, and when detecting the micro-expression change of the facial image, obtain the target expression of the facial image after the micro-expression change feature;
  • an expression category determination module configured to input the target expression feature into a preset expression encoding system, and determine the target expression category corresponding to the target expression characteristic
  • a dialogue information acquisition module configured to conduct dialogue with the driver through a multi-round dialogue device if the target expression category belongs to the preset dangerous expression category, and acquire dialogue information of the driver;
  • a voiceprint feature matching module configured to extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver has fatigued driving according to the voiceprint feature and a preset fatigue scale;
  • the voice prompt module is used to trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued driving.
  • a computer device comprising a memory, a processor, and computer-readable instructions stored in the memory and executable on the processor, the processor implementing the following steps when executing the computer-readable instructions:
  • the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
  • a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  • One or more readable storage media storing computer-readable instructions that, when executed by one or more processors, cause the one or more processors to perform the following steps:
  • the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
  • a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  • the above-mentioned dangerous driving warning method, device, computer equipment and storage medium obtains the face image of the driver in real time during the driving process of the vehicle, and records the obtained face image as a face image sequence according to the acquisition sequence; Whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, obtain the target expression features of the face images after the micro-expression changes; the target expression features are Refers to the facial expression feature with the largest difference from the first facial image among all the second facial images; the first facial image refers to the first facial image of the first micro-expression type before the micro-expression changes; the second facial image is Refers to the face images in the back-end sequence segment that is continuous with the first face image in the sequence of facial images, and all the second face images in the back-end sequence segment are of the second micro-expression type;
  • the target facial expression feature is input into the preset facial expression coding system, and the target facial expression category corresponding to the target facial expression feature is determined; if the target facial expression category
  • a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  • FIG. 1 is a schematic diagram of an application environment of a dangerous driving warning method in an embodiment of the present application
  • FIG. 3 is a flowchart of step S10 in the dangerous driving warning method in an embodiment of the present application.
  • step S20 is a flowchart of step S20 in the dangerous driving warning method in an embodiment of the present application.
  • step S20 is another flowchart of step S20 in the dangerous driving warning method in an embodiment of the present application.
  • step S30 is a flowchart of step S30 in the dangerous driving warning method in an embodiment of the present application.
  • FIG. 7 is a schematic block diagram of a dangerous driving warning device in an embodiment of the present application.
  • FIG. 8 is a schematic block diagram of a face image sequence recording module in a dangerous driving warning device according to an embodiment of the present application
  • FIG. 9 is a schematic block diagram of an expression feature acquisition module in a dangerous driving warning device according to an embodiment of the present application.
  • FIG. 10 is another principle block diagram of the facial expression feature acquisition module in the dangerous driving warning device according to an embodiment of the present application.
  • FIG. 11 is a schematic block diagram of an expression category determination module in a dangerous driving warning device according to an embodiment of the present application.
  • FIG. 12 is a schematic diagram of a computer device in an embodiment of the present application.
  • the dangerous driving early warning method provided by the embodiment of the present application can be applied in the application environment shown in FIG. 1 .
  • the dangerous driving early warning method is applied in a dangerous driving early warning system.
  • the dangerous driving early warning system includes a client and a server as shown in FIG. 1 , and the client and the server communicate through the network, which is used to compare the accuracy of the dangerous driving early warning. low problem.
  • the client also known as the client, refers to the program corresponding to the server and providing local services for the client.
  • Clients can be installed on, but not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices.
  • the server can be implemented as an independent server or a server cluster composed of multiple servers.
  • a dangerous driving warning method is provided, and the method is applied to the server in FIG. 1 as an example for description, including the following steps:
  • S10 Acquire a face image of the driver in real time during the driving of the vehicle, and record the acquired face image as a sequence of face images in an associated order according to the acquisition sequence;
  • a face image sequence refers to a collection of face images acquired within a period of time, and the sorting of the face images is associated with the acquisition time sequence, thereby forming a multi-frame face image sequence arranged in the acquisition time sequence.
  • step S10 includes:
  • S101 During the driving process of the vehicle, use a preset shooting device to shoot an image within a preset range;
  • the driver's face image can be obtained by photographing a photographing device installed in the vehicle.
  • the photographing device can be a camera, a mobile phone, or other device with a photographing and storage function.
  • the preset range can be adjusted according to the driver's seat of different vehicles, the preset range is used to limit the driver's seat range, that is, the driver's face image is detected within the preset range, indicating that the driver is driving. During the process, there were no actions such as bending over, turning head, etc.
  • S103 Trigger a dangerous driving prompt when the preset photographing device does not photograph a face image of the driver within a preset range, and stop the dangerous driving prompt when a face image including the driver is re-shot.
  • the preset photographing device does not photograph a face image including the driver, it indicates that the driver may not be driving normally at present. For example, for example, the driver is bent over to pick up something, and the photograph is taken within the preset range at this time. If the driver's face image is not available, or the driver's face image cannot be captured when the driver is looking down and playing with the mobile phone, the dangerous driving prompt will be triggered immediately, or when the vehicle has an automatic driving mode, it will automatically switch to Automatic driving mode, and stop the dangerous driving prompt when the driver's face image is re-captured. At this time, the previously captured face image of the driver can be deleted, so that the driver will not experience other conditions such as fatigue driving temporarily; the previously captured face image of the driver can also be retained to match the subsequent captured face image. Images are compared.
  • S20 Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, obtain the target expression features of the facial images after the micro-expression changes;
  • the target facial expression feature refers to the facial expression feature with the greatest difference from the first facial image among all the second face images; it is understandable that the process of micro-expression changes is determined by frame-by-frame image, while In order to more accurately determine the expression category of the micro-expression, it is necessary to obtain the expression feature with the greatest difference from the first face image.
  • the first face image is a calm expression, which may be caused by the driver during driving. Fatigue driving causes the corresponding face image to change to a fatigued expression, and when the difference in expression is the largest, the expression features of the second face image can include drooping eyebrows (the eyebrows may be flush in a calm expression), tight eyes.
  • the first face image refers to the first face image of the first micro-expression type before the micro-expression changes;
  • the second face image refers to the back-end sequence segment that is continuous with the first face image in the face image sequence face images in the back-end sequence segment, all second face images in the back-end sequence segment are of the second micro-expression type;
  • the back-end sequence segment refers to a sequence in the face image sequence, in which the micro-expression type has not changed temporarily, that is, all the second face images in the back-end sequence segment. Both are the second micro-expression type.
  • step S20 that is, the detecting whether the facial images in the sequence of facial images have micro-expression changes, including:
  • S201 Record the first frame of face image in the face image sequence as an initial face image, and perform pixel labeling on the initial face image to obtain an initial feature label corresponding to the initial face image;
  • S202 Record the next frame of face image corresponding to the initial face image in the face image sequence as a comparison face image, and perform pixel labeling on the comparison face image, and obtain a comparison with the comparison face image.
  • the face images corresponding to each micro-expression are different, such as the position of the eyebrows (such as the eyebrows are flush or the eyebrows are raised), etc.
  • the first frame of face image in the face image sequence is recorded as the initial face image, and the initial face image is marked with pixels, that is, The position information of each part (such as eyebrows, eyes, mouth, etc.) in the face image is annotated to determine the first feature annotation corresponding to the initial face image.
  • the next frame of face image corresponding to the initial face image in the face image sequence is recorded as a contrasting face image, and the contrasting face image is recorded.
  • the face image is labeled with pixels, and the contrast feature label corresponding to the contrast face image is obtained.
  • S203 Perform pixel feature comparison between the initial feature label and the comparison feature label, and determine a label difference value between the initial feature label and the comparison feature label;
  • an initial feature label corresponding to the initial face image is obtained, and pixel labeling is performed on the comparison face image, and the comparison face image is obtained with the comparison face image.
  • compare the pixel features between the initial feature label and the contrast feature label such as the position between the eyebrows, the degree of eye opening, etc., for example, compare the position of the eyebrows in the initial feature label with the contrast.
  • Compare the position of the eyebrows in the feature annotation to determine the difference between the eyebrow positions.
  • the degree of eye opening in the initial feature annotation (such as recording the distance between the upper eyelid and the lower eyelid) is compared with the eye opening in the feature annotation.
  • the difference between the degrees of eye opening is determined, and then the label difference value between the initial feature label and the comparison feature label is determined according to the feature difference value of each part information above.
  • S205 When the marked difference value is greater than or equal to a preset difference threshold, prompt the facial images in the sequence of facial images to undergo micro-expression changes, and record the initial facial image as the first facial image image, and record the comparison face image and the face image after the comparison face image as the second face image.
  • the preset difference threshold can be determined according to actual needs. For example, when the driver is an older person, considering that his response is not so fast, the preset difference threshold can be set to a smaller value, such as 20%, 30% %Wait.
  • the micro-expressions in the comparison face image are characterized and compared with the micro-expressions in the initial face image. A major change occurs, and at this time, it is necessary to pay attention to situations where dangerous driving may occur. It is understandable that the driver's micro-expression is relatively calm and in a state of concentration during the initial driving. In the case of excessive driving time, the driver's micro-expression may change. Therefore, in this embodiment, the initial When the marked difference value between the face image and the comparison face image is greater than or equal to the preset difference threshold, the driver may have a change in the micro-expression, and the micro-expression may be one of the fatigue micro-expression types.
  • the marked difference value After comparing the marked difference value with the preset difference threshold, if the marked difference value is smaller than the preset difference threshold, it means that there is no large difference between the microexpressions in the comparison face image and the microexpressions in the initial face image Then, you can continue to compare other face images in the face image sequence, such as comparing the face image in the next frame of the comparison face image with the comparison face image.
  • step S20 the target expression feature of the face image after the micro-expression change is obtained, including:
  • S206 Perform pixel labeling on the first face image to obtain a first feature label corresponding to the first face image
  • the first micro-expression type of the first micro-expression before the micro-expression changes Pixel labeling is performed on a face image, that is, the position information of each part (such as eyebrows, eyes, mouth, etc.) in the first face image is obtained, and a first feature label corresponding to the first face image is obtained.
  • S207 carry out pixel labeling to all the second human face images, and obtain the second feature labeling corresponding to each of the second human face images;
  • the second face image of the second micro-expression type that is, the position information of each part (such as eyebrows, eyes, mouth, etc.) in the second face image
  • the second feature annotation of the second face image also has corresponding marked parts, so that the second feature annotation corresponding to each second face image is obtained.
  • S208 Compare the first feature label with each of the second feature labels, and determine a label difference value between the first feature label and each of the second feature labels;
  • S209 Record the second feature label corresponding to the largest label difference value as the target expression feature.
  • the first feature annotation is compared with each second feature annotation to determine the annotation difference value between the first feature annotation and each second feature annotation, and the maximum value of the annotation difference is determined.
  • the second feature label corresponding to the label difference value is recorded as the target expression feature.
  • the second feature label corresponding to the largest label difference value is recorded as the target expression feature because the second feature label before this may not be able to more accurately judge the current state of the driver, and then After the second feature label corresponding to the largest label difference value is recorded as the target expression feature, the accuracy of the dangerous driving warning can be improved.
  • S30 Input the target facial expression feature into a preset facial expression coding system, and determine the target facial expression category corresponding to the target facial expression feature;
  • the encoding system of specific expressions under various micro-expressions is stored in the preset expression encoding system.
  • the target expression features are input into the preset expression encoding system, so as to determine the target expression category corresponding to the target expression characteristics in the preset expression encoding system.
  • step S30 it further includes:
  • S01 obtain a plurality of muscle movement units obtained after the preset face image is divided into regions, and one described muscle movement unit is associated with an expression code;
  • the preset face image may be an expressionless face image.
  • the eyebrows, the mouth or the eyes are in a flush state, that is, the eyebrows are not raised and the eyes are not raised. closed etc.
  • the area division of the preset face image refers to dividing according to the parts that may have obvious changes in the face image to obtain a plurality of muscle movement units.
  • the muscle movement units may be mouth, eye , forehead muscles, etc.
  • a muscle motor unit consists of one muscle or multiple muscles in the human face.
  • the expression code is used to characterize the classification of the muscle movement units.
  • the mouth muscle movement unit is associated with an expression code as A
  • the eye muscle movement unit is associated with an expression code as B, and so on.
  • S02 Obtain a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
  • the micro-expression sample images in the preset expression image set are selected as many images as possible in the driving scene, so as to better reflect the corresponding micro-expressions in the driving scene. image features.
  • the expression label indicates the meaning of the specific micro-expression in the micro-expression sample image.
  • the micro-expression in the micro-expression sample image is unhappy, and the corresponding expression label may be a sad expression label.
  • the expression movement unit refers to the existence of different muscle movement units between the micro-expression sample image and the preset face image. It is understandable that the micro-expression sample image is associated with an expression label, and the muscle movement unit between each micro-expression There are differences in the specific information (such as the position of the eyebrows, the radian of the mouth, etc.), so after the micro-expression sample image is pixel-labeled to obtain the sample image features corresponding to the micro-expression sample image, the sample image features are compared with the sample image.
  • the preset image features corresponding to the preset face image are compared, and the muscles corresponding to the different features between the sample image features and the preset image features are compared.
  • Motor units were recorded as expression motor units.
  • S04 Categorize each of the expression movement units into the corresponding muscle movement units, and set an expression sub-code for each expression movement unit according to the expression code associated with its matching muscle movement unit, and assign the an emoticon code is associated with the emoticon code;
  • the expression movement unit is the raising of the eyebrows
  • the expression movement unit is classified into the eyebrow muscle movement unit.
  • an expression code is set for each expression movement unit according to the expression code associated with the matching muscle movement unit, and the expression movement unit is assigned an expression code.
  • the code is associated with the expression code; exemplarily, assuming that the expression code of the eyebrow muscle motor unit is A, the expression code of the raised eyebrow may be A1.
  • S05 record the expression label, the expression sub-code and the expression code association corresponding to the same micro-expression sample image as the code combination of the micro-expression sample image;
  • S06 Construct a preset expression encoding system according to the encoding combinations of the micro-expression sample images.
  • each expression movement unit into the matching muscle movement unit, and setting an expression sub-code for each expression movement unit according to the expression code associated with its matching muscle movement unit, and set the expression sub-code for each expression movement unit.
  • the expression code is associated with the expression code
  • the expression label corresponding to the same micro-expression sample image, the expression code and the expression code are associated and recorded as the code combination of the micro-expression sample image, exemplarily, can be
  • the expression label, the expression sub-code and the expression code association are recorded as expression triples, and then a code combination of micro-expression sample images is formed, so as to construct a preset expression encoding system according to the code combination of each of the micro-expression sample images.
  • step S30 that is, inputting the target facial expression feature into the preset facial expression coding system to determine the target facial expression category corresponding to the target facial expression feature, including:
  • S301 Obtain each first motion unit corresponding to the first feature annotation, and each second motion unit corresponding to the target expression feature; the first feature annotation is obtained by performing pixel annotation on the first face image ;
  • first motion unit is related to the part marked on the first face image in the first feature annotation
  • second motion unit is related to the part marked on the second face image in the target expression feature
  • the first feature label includes the eyebrow motion unit and the mouth motion unit; for the same reason, the target has been pointed out in the above description.
  • the second feature label corresponding to the expression feature has the same label position as the first feature label, so the target expression feature also includes the eyebrow motion unit and the mouth motion unit.
  • the eyebrow motion unit marked by the first feature may be the eyebrow flush
  • the eyebrow motion unit of the target expression feature may be the eyebrow raised. Therefore, the eyebrow motion unit in the first motion unit is the eyebrow flush motion unit, and the second motion unit is the eyebrow flush motion unit.
  • the middle eyebrow motor unit is the eyebrow raising motor unit.
  • the second motion unit different from the first motion unit is The unit is recorded as the motion unit to be matched, that is, the eyebrow motion unit in the first motion unit is the eyebrow flush motion unit in the above description, and the eyebrow motion unit in the second motion unit is the eyebrow raising motion unit, then the first motion unit is the eyebrow raising motion unit.
  • the motion unit different from the second motion unit is the eyebrow motion unit.
  • S303 determine the muscle movement unit matched with the to-be-matched movement unit, and obtain the expression code corresponding to the muscle movement unit matched with it from the preset expression encoding system;
  • the muscle motion unit that matches the motion unit to be matched After recording the second motion unit different from the first motion unit as the motion unit to be matched, determine the muscle motion unit that matches the motion unit to be matched, and acquire the expression corresponding to the muscle motion unit coding.
  • the motion unit to be matched is an eyebrow motion unit
  • the expression code corresponding to the eyebrow motion unit is obtained from a preset expression encoding system.
  • the expression sub-code corresponding to the to-be-matched movement unit is determined.
  • S305 Determine a target expression category corresponding to the target expression feature according to the determined expression code and the expression sub-code.
  • the expression sub-coding and the expression encoding corresponding to the same micro-expression sample image are stored in the preset expression encoding system, It is recorded as the code combination of the micro-expression sample images, and then the target expression category corresponding to the target expression feature is determined according to the expression code and the expression sub-code.
  • a micro-expression may be composed of a plurality of different expression sub-codes, and then the target expression category can be determined according to the expression code and the expression sub-code corresponding to each muscle motion unit to be matched.
  • the corresponding expression encoding is the expression encoding corresponding to the eyebrow motion unit, and the expression encoding corresponding to the eye motion unit
  • the corresponding expression sub-coding includes the expression sub-coding corresponding to drooping eyebrows, and the expression sub-coding corresponding to closed eyes, and then according to the above-mentioned expression encoding and the expression sub-coding, it is determined that the target expression category corresponding to the target expression feature is the fatigue expression category.
  • the preset dangerous expression category may be a fatigue expression category.
  • the multi-round dialogue device can be set in the intelligent voice system on the vehicle, and the multi-round dialogue device can communicate with the driver through the TTS broadcast technology, so as to improve the driver's spirit.
  • the target facial expression category is a preset dangerous facial expression category, so as to determine whether the target facial expression category is a preset dangerous facial expression category.
  • start the multi-round dialogue device and ask the driver's current status through the multi-round dialogue device, or broadcast some interesting messages to the driver, and then have a dialogue with the driver and obtain the driver's dialogue information.
  • S50 Extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver is fatigued according to the voiceprint feature and a preset fatigue scale;
  • the preset fatigue scale is generated according to the characteristics of the voice in the dialogue after learning the driver's voice in various states in advance through the multi-round dialogue device. Tests, such as extracting the voiceprint features of the driver during normal driving, encoding the voiceprint features and labeling the normal driving voiceprint, or extracting the voiceprint features of the driver when they are initially fatigued, and encoding the voiceprint features Code and label the initial fatigue voiceprint, and then construct a preset fatigue scale according to the voiceprint features and corresponding labels in different driving periods.
  • the voiceprint features are matched, such as level adjustment and alignment of the voiceprint features and the sample voiceprint features, and the frequency characteristics of the voiceprint features and the sample voiceprint features are simulated by IRS filtering, so as to compare the voiceprint features and the sample voiceprint features.
  • the similarity between the voiceprint feature and the sample voiceprint feature is determined by the asymmetric processing algorithm, and then the sample voiceprint feature with the highest similarity is selected as the basis for judging the voiceprint feature, so as to automatically
  • the fatigue level corresponding to the voiceprint feature of the sample with the highest similarity is determined in the preset fatigue measurement table, so as to determine the current fatigue level of the driver, so as to determine whether the driver has a fatigue driving phenomenon.
  • S60 Trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued.
  • the current driver's fatigue level (such as mild fatigue, severe fatigue, etc.) can be determined according to the voiceprint feature or the target expression category, for example, according to the voiceprint feature and preset fatigue.
  • the current fatigue level of the driver can be determined according to the fatigue level corresponding to the voiceprint feature, or when the target expression category is determined according to the target expression feature, due to the micro-expressions corresponding to different fatigue levels.
  • the expression characteristics of the two are also different, and then the specific fatigue level expressions can be obtained when determining the target expression category (for example, different fatigue levels are defined according to the distance range between the upper eyelid and the lower eyelid), and then the driver is determined to be fatigued.
  • a dangerous driving voice prompt can be triggered according to the voiceprint feature and the target expression category. It can conduct continuous voice chat with the driver, or broadcast voice prompts for dangerous driving such as light-hearted talk shows; if it is heavily fatigued, it can broadcast through a louder voice prompt and switch when the driver is driving an autonomous car to automatic driving.
  • the fatigue reminder strategy can be adjusted according to the fatigue frequency of the driver every time (such as frequent fatigue, general fatigue), usually in a certain period of time (for example, 10:00 to 12:00 in the evening). For example, drivers who are often tired can Reminder in advance, automatically give voice reminders when the driver is not fatigued (the frequency of reminders for frequent fatigue is higher than that of general fatigue); or play reminder information or music at the time when the driver is prone to fatigue (10 o'clock in the evening), and then you can By constantly interacting with the driver, the driver can be prevented from falling into a deep sleep, reducing the accident rate.
  • the use of intelligent expression technology and voice analysis can more sensitively and accurately capture the driver's fatigue state. Once the situation is found, multiple rounds of dialogue technology are used to remind, which improves the accuracy of dangerous driving warning, and in When it is found that there is fatigue driving in the face image, it is not prompted immediately, which alleviates the suddenness caused by the immediate triggering of the warning prompt.
  • a dangerous driving early warning device is provided, and the dangerous driving early warning device is in one-to-one correspondence with the dangerous driving early warning method in the above-mentioned embodiment.
  • the dangerous driving warning device includes a face image sequence recording module 10 , an expression feature acquisition module 20 , an expression category determination module 30 , a dialogue information acquisition module 40 , a voiceprint feature matching module 50 and a voice prompt module 60 .
  • the detailed description of each functional module is as follows:
  • the face image sequence recording module 10 is used to acquire the driver's face image in real time during the driving process of the vehicle, and record the acquired face image as a face image sequence according to the acquisition sequence;
  • the facial expression feature acquisition module 20 is used to detect whether the facial image in the sequence of facial images has a micro-expression change, and when detecting that the facial image has a micro-expression change, obtain the target of the facial image after the micro-expression change facial features;
  • An expression category determination module 30 configured to input the target expression feature into a preset expression encoding system, and determine the target expression category corresponding to the target expression characteristic;
  • Dialogue information acquisition module 40 configured to conduct dialogue with the driver through a multi-round dialogue device and acquire dialogue information of the driver if the target expression category belongs to the preset dangerous expression category;
  • a voiceprint feature matching module 50 configured to extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver has fatigued driving according to the voiceprint feature and a preset fatigue scale;
  • the voice prompt module 60 is configured to trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued driving.
  • the face image sequence recording module 10 includes the following units:
  • the image capturing unit 101 is used for capturing images within a preset range through a preset capturing device during the driving of the vehicle;
  • the face image sequence recording unit 102 is configured to associate and record the obtained face images as a face image sequence according to the acquisition order when the preset photographing device captures the driver's face images;
  • the danger prompting unit 103 is used for triggering a dangerous driving prompt when the preset photographing device fails to photograph the driver's face image within a preset range, and stops when the driver's face image is re-photographed Dangerous driving tips.
  • the expression feature acquisition module 20 includes:
  • the first pixel labeling unit 201 is configured to record the first frame of the face image in the sequence of face images as an initial face image, and perform pixel labeling on the initial face image to obtain the same value as the initial face image.
  • the second pixel labeling unit 202 is configured to record the next frame of face image corresponding to the initial face image in the sequence of face images as a comparison face image, and perform pixel labeling on the comparison face image , obtain the contrast feature annotation corresponding to the contrast face image;
  • Annotation difference value determination unit 203 configured to perform pixel feature comparison between the initial feature label and the comparison feature label, and determine the label difference value between the initial feature label and the comparison feature label;
  • a difference comparison unit 204 configured to compare the marked difference value with a preset difference threshold
  • the second face image recording unit 205 is configured to, when the marked difference value is greater than or equal to a preset difference threshold, prompt the face images in the face image sequence to have micro-expression changes, and record the initial face image The image is recorded as the first face image, and the comparison face image and the face images ranked after the comparison face image are associated and recorded as the second face image.
  • the expression feature acquisition module 20 further includes:
  • a third pixel labeling unit 206 configured to perform pixel labeling on the first face image to obtain a first feature label corresponding to the first face image
  • a fourth pixel labeling unit 207 configured to perform pixel labeling on all the second face images to obtain second feature labels corresponding to each of the second face images
  • a feature label comparison unit 208 configured to compare the first feature label with each of the second feature labels, and determine a label difference value between the first feature label and each of the second feature labels;
  • the target facial expression feature determining unit 209 is configured to record the second feature label corresponding to the largest label difference value as the target facial expression feature.
  • the dangerous driving warning device further includes:
  • the muscle movement unit acquisition module 01 is used to obtain a plurality of muscle movement units obtained after the preset face image is divided into regions, and one of the muscle movement units is associated with an expression code;
  • An expression image set obtaining module 02 configured to obtain a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
  • Expression motion unit determination module 03 used to perform pixel labeling on the micro-expression sample image to obtain sample image features corresponding to the micro-expression sample image, and determine all the expression motion units corresponding to the sample image features;
  • Expression sub-coding setting module 04 for classifying each described expression movement unit into the described muscle movement unit matched with it, and set an expression for each expression movement unit according to the expression code associated with its matching muscle movement unit subcoding, and associate the expression subcoding with the expression encoding;
  • the coding combination recording module 05 is used to associate and record the expression label, the expression sub-coding and the expression coding associated with the same micro-expression sample image as the coding combination of the micro-expression sample image;
  • Expression coding system building module 06 for constructing a preset expression coding system according to the coding combination of each described micro-expression sample image.
  • the expression category determination module 30 includes:
  • the motion unit acquisition unit 301 is configured to acquire each first motion unit corresponding to the first feature label, and each second motion unit corresponding to the target expression feature; the first feature label is obtained by identifying the first person The face image is obtained by pixel labeling;
  • a motion unit recording unit 302 to be matched configured to record the second motion unit different from the first motion unit as the motion unit to be matched;
  • the expression code obtaining unit 303 is used to determine the muscle movement unit matched with the described movement unit to be matched, and obtain the expression code of the muscle movement unit matched with it from the preset expression code system;
  • An expression code obtaining unit 304 configured to determine the expression code corresponding to the motion unit to be matched from the expression encoding
  • the target expression category determination unit 305 is configured to determine a target expression category corresponding to the target expression feature according to the determined expression code and the expression sub-code.
  • Each module in the above-mentioned dangerous driving warning device can be implemented in whole or in part by software, hardware and combinations thereof.
  • the above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
  • a computer device is provided, and the computer device may be a server, and its internal structure diagram may be as shown in FIG. 12 .
  • the computer device includes a processor, memory, a network interface, and a database connected by a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities.
  • the memory of the computer device includes a readable storage medium, an internal memory.
  • the readable storage medium stores an operating system, computer readable instructions and a database.
  • the internal memory provides an environment for the execution of the operating system and computer-readable instructions in the readable storage medium.
  • the database of the computer device is used to store the data used in the dangerous driving warning method in the above embodiment.
  • the network interface of the computer device is used to communicate with an external terminal through a network connection.
  • the computer readable instructions when executed by a processor, implement a dangerous driving warning method.
  • a computer apparatus comprising a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, the processor executing the computer readable instructions Implement the following steps when instructing:
  • the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
  • a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  • one or more readable storage media are provided that store computer-readable instructions that, when executed by one or more processors, cause the one or more processors to execute follows the steps below:
  • the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
  • a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  • Nonvolatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory.
  • Volatile memory may include random access memory (RAM) or external cache memory.
  • RAM is available in various forms such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous chain Road (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

Abstract

The present application relates to the technical field of micro-expression recognition, and discloses a dangerous driving early warning method and apparatus, a computer device, and a storage medium. The method comprises: associating and recording face images acquired in real time during a vehicle driving process as a face image sequence according to an acquisition order; detecting whether there are changes in micro-expressions in a face image in the face image sequence, and when it is detected that there are changes in micro-expressions in a face image, acquiring target expression features of the face image after the micro-expressions have changed; inputting the target expression features into a preset expression encoding system to determine a target expression category; if the target expression category belongs to a preset dangerous expression category, acquiring dialogue information of a driver by means of a multi-round dialogue device; according to voiceprint features in the dialogue information and a preset fatigue measurement table, determining whether the driver is driving while fatigued; and when it is determined that the driver is driving while fatigued, triggering a dangerous driving voice prompt according to the voiceprint features and the target expression category. The present application improves the accuracy of dangerous driving early warning.

Description

危险驾驶预警方法、装置、计算机设备及存储介质Dangerous driving warning method, device, computer equipment and storage medium
本申请要求于2020年12月28日提交中国专利局、申请号为202011584251.0,发明名称为“危险驾驶预警方法、装置、计算机设备及存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application with the application number 202011584251.0 and the invention titled "Dangerous Driving Warning Method, Device, Computer Equipment and Storage Medium", which was filed with the China Patent Office on December 28, 2020, the entire contents of which are by reference Incorporated in this application.
技术领域technical field
本申请涉及微表情识别技术领域,尤其涉及一种危险驾驶预警方法、装置、计算机设备及存储介质。The present application relates to the technical field of micro-expression recognition, and in particular, to a dangerous driving early warning method, device, computer equipment and storage medium.
背景技术Background technique
目前,随着人们生活水平的提高,道路上的车流量年年攀升,交通事故的数量也随之增加。其中,危险驾驶行为是导致交通事故的主要原因之一,因此对危险驾驶行为进行提前预警是非常重要的。At present, with the improvement of people's living standards, the traffic flow on the road increases year by year, and the number of traffic accidents also increases. Among them, dangerous driving behavior is one of the main causes of traffic accidents, so early warning of dangerous driving behavior is very important.
发明人意识到,现有的危险驾驶预警系统,通过安装在汽车上的硬件设备来检测驾驶员的驾驶行为,并在出现驾驶违规操作时对驾驶员发出告警,例如通过检测汽车速度进行判断。但是该方法存在危险驾驶预警准确率较低的问题,并且突然发出警报更容易造成驾驶员的慌乱,导致事故发生的可能性增加。The inventor realized that the existing dangerous driving warning system detects the driver's driving behavior through hardware devices installed on the car, and issues a warning to the driver when a driving violation occurs, for example, by detecting the speed of the car to make a judgment. However, this method has the problem that the accuracy of dangerous driving warning is low, and the sudden alarm is more likely to cause panic of the driver, resulting in an increased possibility of an accident.
申请内容Application content
本申请实施例提供一危险驾驶预警方法、装置、计算机设备及存储介质以解决危险驾驶预警准确率较低的问题。Embodiments of the present application provide a dangerous driving warning method, device, computer equipment and storage medium to solve the problem of low accuracy of dangerous driving warning.
一种危险驾驶预警方法,包括:A dangerous driving warning method, comprising:
在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;所述目标表情特征是指所有第二人脸图像中与第一人脸图像差异最大的表情特征;第一人脸图像是指微表情变化之前的首个第一微表情类型的人脸图像;第二人脸图像是指所述人脸图像序列中与第一人脸图像连续的后端序列段中的人脸图像,所述后端序列段中的所有第二人脸图像均为第二微表情类型;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the face images after the micro-expression changes; the target expression features Refers to the facial expression feature with the largest difference from the first facial image among all the second facial images; the first facial image refers to the first facial image of the first micro-expression type before the micro-expression changes; the second facial image Refers to the face image in the back-end sequence segment that is continuous with the first face image in the sequence of facial images, and all the second face images in the back-end sequence segment are of the second micro-expression type;
将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述样本表情触发危险驾驶语音提示。When it is determined that the driver is fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the sample expression.
一种危险驾驶预警装置,包括:A dangerous driving warning device, comprising:
人脸图像序列记录模块,用于在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;A face image sequence recording module, configured to acquire the driver's face image in real time during the driving process of the vehicle, and record the acquired face image as a face image sequence according to the acquisition sequence;
表情特征获取模块,用于检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特 征;The expression feature acquisition module is used to detect whether the facial image in the sequence of facial images has a micro-expression change, and when detecting the micro-expression change of the facial image, obtain the target expression of the facial image after the micro-expression change feature;
表情类别确定模块,用于将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;an expression category determination module, configured to input the target expression feature into a preset expression encoding system, and determine the target expression category corresponding to the target expression characteristic;
对话信息获取模块,用于若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取所述驾驶员的对话信息;a dialogue information acquisition module, configured to conduct dialogue with the driver through a multi-round dialogue device if the target expression category belongs to the preset dangerous expression category, and acquire dialogue information of the driver;
声纹特征匹配模块,用于提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;A voiceprint feature matching module, configured to extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver has fatigued driving according to the voiceprint feature and a preset fatigue scale;
语音提示模块,用于在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。The voice prompt module is used to trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued driving.
一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,所述处理器执行所述计算机可读指令时实现如下步骤:A computer device, comprising a memory, a processor, and computer-readable instructions stored in the memory and executable on the processor, the processor implementing the following steps when executing the computer-readable instructions:
在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is driving fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
一个或多个存储有计算机可读指令的可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:One or more readable storage media storing computer-readable instructions that, when executed by one or more processors, cause the one or more processors to perform the following steps:
在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is driving fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
上述危险驾驶预警方法、装置、计算机设备及存储介质,该方法通过在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;所述目标表情特征是指所有第二人脸图像中与第一人脸图像差异最大的表情特征;第一人脸图像是指微表情变化之前的首个第一微表情类型的人脸图像;第二人脸图像是指所述人脸图像序列中与第一人脸图像连续的后端序列段中的人脸图像,所述后端序列段中的所有第二人脸图像均为第二微表情类型;将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情 特征对应的目标表情类别;若所述目标表情类别属于预设危险表情类别,则启动多轮对话装置,与所述驾驶员进行对话,并获取驾驶员的对话信息;提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。The above-mentioned dangerous driving warning method, device, computer equipment and storage medium, the method obtains the face image of the driver in real time during the driving process of the vehicle, and records the obtained face image as a face image sequence according to the acquisition sequence; Whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, obtain the target expression features of the face images after the micro-expression changes; the target expression features are Refers to the facial expression feature with the largest difference from the first facial image among all the second facial images; the first facial image refers to the first facial image of the first micro-expression type before the micro-expression changes; the second facial image is Refers to the face images in the back-end sequence segment that is continuous with the first face image in the sequence of facial images, and all the second face images in the back-end sequence segment are of the second micro-expression type; The target facial expression feature is input into the preset facial expression coding system, and the target facial expression category corresponding to the target facial expression feature is determined; if the target facial expression category belongs to the preset dangerous facial expression category, the multi-round dialogue device is activated to communicate with the driver. dialogue with the driver, and obtain the dialogue information of the driver; extract the voiceprint characteristics of the driver in the dialogue information, and determine whether the driver has fatigue driving according to the voiceprint characteristics and the preset fatigue scale; When it is determined that the driver is fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
本申请的一个或多个实施例的细节在下面的附图和描述中提出,本申请的其他特征和优点将从说明书、附图以及权利要求变得明显。The details of one or more embodiments of the application are set forth in the accompanying drawings and the description below, and other features and advantages of the application will become apparent from the description, drawings, and claims.
附图说明Description of drawings
为了更清楚地说明本申请实施例的技术方案,下面将对本申请实施例的描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions of the embodiments of the present application more clearly, the following briefly introduces the drawings that are used in the description of the embodiments of the present application. Obviously, the drawings in the following description are only some embodiments of the present application. , for those of ordinary skill in the art, other drawings can also be obtained from these drawings without creative labor.
图1是本申请一实施例中危险驾驶预警方法的一应用环境示意图;1 is a schematic diagram of an application environment of a dangerous driving warning method in an embodiment of the present application;
图2是本申请一实施例中危险驾驶预警方法的一流程图;2 is a flowchart of a dangerous driving warning method in an embodiment of the present application;
图3是本申请一实施例中危险驾驶预警方法中步骤S10的一流程图;FIG. 3 is a flowchart of step S10 in the dangerous driving warning method in an embodiment of the present application;
图4是本申请一实施例中危险驾驶预警方法中步骤S20的一流程图;4 is a flowchart of step S20 in the dangerous driving warning method in an embodiment of the present application;
图5是本申请一实施例中危险驾驶预警方法中步骤S20的另一流程图;5 is another flowchart of step S20 in the dangerous driving warning method in an embodiment of the present application;
图6是本申请一实施例中危险驾驶预警方法中步骤S30的一流程图;6 is a flowchart of step S30 in the dangerous driving warning method in an embodiment of the present application;
图7是本申请一实施例中危险驾驶预警装置的一原理框图;7 is a schematic block diagram of a dangerous driving warning device in an embodiment of the present application;
图8是本申请一实施例中危险驾驶预警装置中人脸图像序列记录模块的一原理框图;8 is a schematic block diagram of a face image sequence recording module in a dangerous driving warning device according to an embodiment of the present application;
图9是本申请一实施例中危险驾驶预警装置中表情特征获取模块的一原理框图;9 is a schematic block diagram of an expression feature acquisition module in a dangerous driving warning device according to an embodiment of the present application;
图10是本申请一实施例中危险驾驶预警装置中表情特征获取模块的另一原理框图;10 is another principle block diagram of the facial expression feature acquisition module in the dangerous driving warning device according to an embodiment of the present application;
图11是本申请一实施例中危险驾驶预警装置中表情类别确定模块的一原理框图;11 is a schematic block diagram of an expression category determination module in a dangerous driving warning device according to an embodiment of the present application;
图12是本申请一实施例中计算机设备的一示意图。FIG. 12 is a schematic diagram of a computer device in an embodiment of the present application.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the protection scope of the present application.
本申请实施例提供的危险驾驶预警方法,该危险驾驶预警方法可应用如图1所示的应用环境中。具体地,该危险驾驶预警方法应用在危险驾驶预警系统中,该危险驾驶预警系统包括如图1所示的客户端和服务器,客户端与服务器通过网络进行通信,用于危险驾驶预警准确率较低的问题。其中,客户端又称为用户端,是指与服务器相对应,为客户提供本地服务的程序。客户端可安装在但不限于各种个人计算机、笔记本电脑、智能手机、平板电脑和便携式可穿戴设备上。服务器可以用独立的服务器或者是多个服务器组成的服务器集群来实现。The dangerous driving early warning method provided by the embodiment of the present application can be applied in the application environment shown in FIG. 1 . Specifically, the dangerous driving early warning method is applied in a dangerous driving early warning system. The dangerous driving early warning system includes a client and a server as shown in FIG. 1 , and the client and the server communicate through the network, which is used to compare the accuracy of the dangerous driving early warning. low problem. Among them, the client, also known as the client, refers to the program corresponding to the server and providing local services for the client. Clients can be installed on, but not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server can be implemented as an independent server or a server cluster composed of multiple servers.
在一实施例中,如图2所示,提供一种危险驾驶预警方法,以该方法应用在图1中的服务器为例进行说明,包括如下步骤:In one embodiment, as shown in FIG. 2, a dangerous driving warning method is provided, and the method is applied to the server in FIG. 1 as an example for description, including the following steps:
S10:在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;S10: Acquire a face image of the driver in real time during the driving of the vehicle, and record the acquired face image as a sequence of face images in an associated order according to the acquisition sequence;
可以理解地,人脸图像序列指的是在一段时间内获取到的人脸图像的集合,且人脸图像的排序与获取时间顺序关联,进而形成按照获取时间顺序排列的多帧人脸图像序列。Understandably, a face image sequence refers to a collection of face images acquired within a period of time, and the sorting of the face images is associated with the acquisition time sequence, thereby forming a multi-frame face image sequence arranged in the acquisition time sequence. .
在一实施例中,如图3所示,步骤S10中,包括:In one embodiment, as shown in FIG. 3 , step S10 includes:
S101:在车辆行驶过程中,通过预设拍摄设备拍摄预设范围内的图像;S101: During the driving process of the vehicle, use a preset shooting device to shoot an image within a preset range;
可以理解地,在车辆行驶过程中,可以通过安装在车辆的拍摄设备进行拍摄获取驾驶员的人脸图像,示例性地,该拍摄设备可以为摄像机、手机等具有拍摄存储功能的设备。预设范围可以根据不同的车辆的驾驶员座位进行调整,该预设范围用于限定驾驶员的座位范围,也即在该预设范围内检测到驾驶员的人脸图像,表征驾驶员在驾驶过程中没有进行如弯腰,转头等动作。It can be understood that, during the driving of the vehicle, the driver's face image can be obtained by photographing a photographing device installed in the vehicle. Exemplarily, the photographing device can be a camera, a mobile phone, or other device with a photographing and storage function. The preset range can be adjusted according to the driver's seat of different vehicles, the preset range is used to limit the driver's seat range, that is, the driver's face image is detected within the preset range, indicating that the driver is driving. During the process, there were no actions such as bending over, turning head, etc.
S102:在所述预设拍摄设备拍摄到驾驶员的人脸图像时,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;S102: When the preset photographing device captures the face image of the driver, record the obtained face image as a sequence of face images in an associated sequence according to the acquisition sequence;
可以理解地,在通过预设拍摄设备拍摄到包含驾驶员的人脸图像时,表征驾驶员正在正常驾驶,此时不用触发危险驾驶提示,进而可以根据获取的人脸图像按照获取顺序关联记录为人脸图像序列。It is understandable that when a face image including the driver is captured by the preset shooting device, it indicates that the driver is driving normally. At this time, there is no need to trigger a dangerous driving prompt, and then the obtained face image can be associated and recorded as a human in the order of acquisition. face image sequence.
S103:在所述预设拍摄设备在预设范围内未拍摄到驾驶员的人脸图像时,触发危险驾驶提示,并在重新拍摄到包含驾驶员的人脸图像时,停止危险驾驶提示。S103: Trigger a dangerous driving prompt when the preset photographing device does not photograph a face image of the driver within a preset range, and stop the dangerous driving prompt when a face image including the driver is re-shot.
可以理解地,在预设拍摄设备未拍摄到包含驾驶员的人脸图像时,表征驾驶员当前可能不在正常驾驶,示例性地,如驾驶员弯腰捡东西,此时在预设范围内拍摄不到驾驶员的人脸图像,亦或者驾驶员低头玩手机时,也不能拍摄到驾驶员的人脸图像,则立刻触发危险驾驶提示,亦或者在车辆具有自动驾驶模式时,会自动切换至自动驾驶模式,并在重新拍摄到驾驶员的人脸图像时,停止危险驾驶提示。此时,可以将之前拍摄到驾驶员的人脸图像删除,因此暂时驾驶员不会发生其它如疲劳驾驶的情况;也可以保留之前拍摄到驾驶员的人脸图像,以与后续拍摄的人脸图像进行比对。Understandably, when the preset photographing device does not photograph a face image including the driver, it indicates that the driver may not be driving normally at present. For example, for example, the driver is bent over to pick up something, and the photograph is taken within the preset range at this time. If the driver's face image is not available, or the driver's face image cannot be captured when the driver is looking down and playing with the mobile phone, the dangerous driving prompt will be triggered immediately, or when the vehicle has an automatic driving mode, it will automatically switch to Automatic driving mode, and stop the dangerous driving prompt when the driver's face image is re-captured. At this time, the previously captured face image of the driver can be deleted, so that the driver will not experience other conditions such as fatigue driving temporarily; the previously captured face image of the driver can also be retained to match the subsequent captured face image. Images are compared.
S20:检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;S20: Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, obtain the target expression features of the facial images after the micro-expression changes;
其中,所述目标表情特征是指所有第二人脸图像中与第一人脸图像差异最大的表情特征;可以理解地,发生微表情变化的过程是通过一帧一帧图像进行判别的,而为了更准确地确定微表情的表情类别,则需要获取与第一人脸图像具有最大差异的表情特征,示例性地,假设第一人脸图像是平静的表情,在驾驶员驾驶过程中可能由于疲劳驾驶导致其对应的人脸图像向疲劳表情变化,进而在表情变化差异最大的时候,该第二人脸图像的表情特征可以包含眉毛下垂(平静表情时眉毛可能为齐平状态)、双眼紧闭(该双眼闭合程度可以通过上眼皮与下眼皮之间的距离进行确定,平静表情时双眼中上眼皮与下眼皮之间的距离较大),进而眉毛下垂以及双眼紧闭即为微表情变化之后的人脸图像的目标表情特征。第一人脸图像是指微表情变化之前的首个第一微表情类型的人脸图像;第二人脸图像是指所述人脸图像序列中与第一人脸图像连续的后端序列段中的人脸图像,所述后端序列段中的所有第二人脸图像均为第二微表情类型;Wherein, the target facial expression feature refers to the facial expression feature with the greatest difference from the first facial image among all the second face images; it is understandable that the process of micro-expression changes is determined by frame-by-frame image, while In order to more accurately determine the expression category of the micro-expression, it is necessary to obtain the expression feature with the greatest difference from the first face image. Exemplarily, it is assumed that the first face image is a calm expression, which may be caused by the driver during driving. Fatigue driving causes the corresponding face image to change to a fatigued expression, and when the difference in expression is the largest, the expression features of the second face image can include drooping eyebrows (the eyebrows may be flush in a calm expression), tight eyes. closed (the degree of closure of the eyes can be determined by the distance between the upper eyelid and the lower eyelid, the distance between the upper eyelid and the lower eyelid in the eyes is larger when the expression is calm), and the drooping eyebrows and the closed eyes are the micro-expression changes The target expression features of the face image afterward. The first face image refers to the first face image of the first micro-expression type before the micro-expression changes; the second face image refers to the back-end sequence segment that is continuous with the first face image in the face image sequence face images in the back-end sequence segment, all second face images in the back-end sequence segment are of the second micro-expression type;
可以理解地,为了通过人脸图像对危险驾驶行为进行判断,因此需要针对相邻两帧人脸图像之间是否发生微表情变化进行判定,在相邻两帧人脸图像之间微表情发生变化,表征此时驾驶员的情绪或者状态发生变化,进而可以获取微表情变化之后的人脸图像的目标表情特征。Understandably, in order to judge dangerous driving behaviors through face images, it is necessary to judge whether there is a micro-expression change between two adjacent frames of face images, and the micro-expression changes between two adjacent frames of face images. , indicating that the driver's mood or state changes at this time, and then the target expression features of the face image after the micro-expression change can be obtained.
可以理解地,所述后端序列段指的是人脸图像序列中的一段序列,在该段序列中微表情类型暂未发生改变,也即在后端序列段中的所有第二人脸图像均为第二微表情类型。Understandably, the back-end sequence segment refers to a sequence in the face image sequence, in which the micro-expression type has not changed temporarily, that is, all the second face images in the back-end sequence segment. Both are the second micro-expression type.
在一实施例中,如图4所示,步骤S20中,也即所述检测所述人脸图像序列中的人脸图像是否发生微表情变化,包括:In one embodiment, as shown in FIG. 4 , in step S20, that is, the detecting whether the facial images in the sequence of facial images have micro-expression changes, including:
S201:将所述人脸图像序列中第一帧人脸图像记录为初始人脸图像,并对所述初始人脸图像进行像素标注,得到与所述初始人脸图像对应的初始特征标注;S201: Record the first frame of face image in the face image sequence as an initial face image, and perform pixel labeling on the initial face image to obtain an initial feature label corresponding to the initial face image;
S202:将所述人脸图像序列中与所述初始人脸图像对应的下一帧人脸图像记录为对比人脸图像,并对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特 征标注;S202: Record the next frame of face image corresponding to the initial face image in the face image sequence as a comparison face image, and perform pixel labeling on the comparison face image, and obtain a comparison with the comparison face image. The contrast feature annotation corresponding to the face image;
可以理解地,对于一个人脸图像而言,每一种微表情对应的人脸图像是不一样的,如眉毛的位置不同(如眉毛齐平或者眉毛上挑)等,因此在将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列之后,将所述人脸图像序列中第一帧人脸图像记录为初始人脸图像,并对所述初始人脸图像进行像素标注,也即标注人脸图像中各个部位(如眉毛,眼睛,嘴巴等)的位置信息,以确定与所述初始人脸图像对应的第一特征标注。Understandably, for a face image, the face images corresponding to each micro-expression are different, such as the position of the eyebrows (such as the eyebrows are flush or the eyebrows are raised), etc. After the face image is associated and recorded as a face image sequence according to the acquisition sequence, the first frame of face image in the face image sequence is recorded as the initial face image, and the initial face image is marked with pixels, that is, The position information of each part (such as eyebrows, eyes, mouth, etc.) in the face image is annotated to determine the first feature annotation corresponding to the initial face image.
同理,对初始人脸图像进行像素标注完成之后,将所述人脸图像序列中与所述初始人脸图像对应的下一帧人脸图像记录为对比人脸图像,并对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特征标注。Similarly, after the initial face image is marked with pixels, the next frame of face image corresponding to the initial face image in the face image sequence is recorded as a contrasting face image, and the contrasting face image is recorded. The face image is labeled with pixels, and the contrast feature label corresponding to the contrast face image is obtained.
S203:将所述初始特征标注与所述对比特征标注进行像素特征比较,确定所述初始特征标注与所述对比特征标注之间的标注差异值;S203: Perform pixel feature comparison between the initial feature label and the comparison feature label, and determine a label difference value between the initial feature label and the comparison feature label;
可以理解地,在对所述初始人脸图像进行像素标注,得到与所述初始人脸图像对应的初始特征标注,以及对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特征标注之后,将所述初始特征标注与所述对比特征标注进行像素特征比较,如眉毛之间的位置,眼睛睁开的程度等进行比较,比如将初始特征标注中眉毛位置与对比特征标注中眉毛位置进行比较,确定眉毛位置差值,又比如将初始特征标注中眼睛睁开的程度(如记录上眼皮与下眼皮之间的距离),与比对特征标注中眼睛睁开的程度进行比较,确定眼睛睁开程度差值,进而根据上述各个部位信息的特征差值确定所述初始特征标注与所述对比特征标注之间的标注差异值。It can be understood that, after performing pixel labeling on the initial face image, an initial feature label corresponding to the initial face image is obtained, and pixel labeling is performed on the comparison face image, and the comparison face image is obtained with the comparison face image. After the corresponding contrast feature is marked, compare the pixel features between the initial feature label and the contrast feature label, such as the position between the eyebrows, the degree of eye opening, etc., for example, compare the position of the eyebrows in the initial feature label with the contrast. Compare the position of the eyebrows in the feature annotation to determine the difference between the eyebrow positions. For example, the degree of eye opening in the initial feature annotation (such as recording the distance between the upper eyelid and the lower eyelid) is compared with the eye opening in the feature annotation. The difference between the degrees of eye opening is determined, and then the label difference value between the initial feature label and the comparison feature label is determined according to the feature difference value of each part information above.
S204:将所述标注差异值与预设差异阈值进行比较;S204: Compare the marked difference value with a preset difference threshold;
S205:在所述标注差异值大于或等于预设差异阈值时,提示所述人脸图像序列中的人脸图像发生微表情变化,并将所述初始人脸图像记录为所述第一人脸图像,将所述对比人脸图像以及排序在对比人脸图像之后的人脸图像关联记录为所述第二人脸图像。S205: When the marked difference value is greater than or equal to a preset difference threshold, prompt the facial images in the sequence of facial images to undergo micro-expression changes, and record the initial facial image as the first facial image image, and record the comparison face image and the face image after the comparison face image as the second face image.
其中,预设差异阈值可以根据实际需求进行判定,例如,在驾驶员是年龄比较大的人员时,考虑到其反应没有那么快,则该预设差异阈值可以设置小一点,如20%、30%等。The preset difference threshold can be determined according to actual needs. For example, when the driver is an older person, considering that his response is not so fast, the preset difference threshold can be set to a smaller value, such as 20%, 30% %Wait.
可以理解地,将所述标注差异值与预设差异阈值进行比较之后,在标注差异值大于或等于预设差异阈值时,表征对比人脸图像中的微表情与初始人脸图像中的微表情发生较大的改变,此时需要注意可能发生危险驾驶的情况。可以理解地,驾驶员在初期驾驶时,微表情较为平静且处于一种精神集中的状态,在驾驶时间过长的情况下,驾驶员的微表情可能会发生变化,因此本实施例中,初始人脸图像与对比人脸图像之间的标注差异值大于或等于预设差异阈值时,可能驾驶员出现了微表情的变化,且该微表情可能是疲劳微表情类型中的一种。It can be understood that after comparing the marked difference value with the preset difference threshold, when the marked difference value is greater than or equal to the preset difference threshold, the micro-expressions in the comparison face image are characterized and compared with the micro-expressions in the initial face image. A major change occurs, and at this time, it is necessary to pay attention to situations where dangerous driving may occur. It is understandable that the driver's micro-expression is relatively calm and in a state of concentration during the initial driving. In the case of excessive driving time, the driver's micro-expression may change. Therefore, in this embodiment, the initial When the marked difference value between the face image and the comparison face image is greater than or equal to the preset difference threshold, the driver may have a change in the micro-expression, and the micro-expression may be one of the fatigue micro-expression types.
在将所述标注差异值与预设差异阈值进行比较之后,若标注差异值小于预设差异阈值,则表征对比人脸图像中的微表情与初始人脸图像中的微表情之间没有较大的改变,进而可以继续比较人脸图像序列中其它人脸图像,如将对比人脸图像的后一帧的人脸图像与对比人脸图像进行比对。After comparing the marked difference value with the preset difference threshold, if the marked difference value is smaller than the preset difference threshold, it means that there is no large difference between the microexpressions in the comparison face image and the microexpressions in the initial face image Then, you can continue to compare other face images in the face image sequence, such as comparing the face image in the next frame of the comparison face image with the comparison face image.
进一步地,如图5所示,步骤S20中,也即获取微表情变化之后的人脸图像的目标表情特征,包括:Further, as shown in FIG. 5 , in step S20, the target expression feature of the face image after the micro-expression change is obtained, including:
S206:对所述第一人脸图像进行像素标注,得到与所述第一人脸图像对应的第一特征标注;S206: Perform pixel labeling on the first face image to obtain a first feature label corresponding to the first face image;
具体地,在检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化之后,对微表情变化之前的首个第一微表情类型的第一人脸图像进行像素标注,也即对第一人脸图像中各个部位(如眉毛,眼睛,嘴巴等)的位置信息,进而得到与第一人脸图像对应的第一特征标注。Specifically, after detecting whether the facial images in the sequence of facial images have micro-expression changes, and after detecting that the facial images have micro-expression changes, the first micro-expression type of the first micro-expression before the micro-expression changes Pixel labeling is performed on a face image, that is, the position information of each part (such as eyebrows, eyes, mouth, etc.) in the first face image is obtained, and a first feature label corresponding to the first face image is obtained.
S207:对所有所述第二人脸图像进行像素标注,得到与各所述第二人脸图像对应的第 二特征标注;S207: carry out pixel labeling to all the second human face images, and obtain the second feature labeling corresponding to each of the second human face images;
具体地,在检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化之后,对第二微表情类型的第二人脸图像进行像素标注,也即对第二人脸图像中各个部位(如眉毛,眼睛,嘴巴等)的位置信息,可以理解地,为了更好地区分第一人脸图像与第二人脸图像之间的区别,因此第一人脸图像的第一特征标注中具有的标注部位,第二人脸图像的第二特征标注也具有相应标注部位,进而得到与各第二人脸图像对应的第二特征标注。Specifically, after detecting whether a micro-expression change occurs in the face image in the sequence of face images, and after detecting the micro-expression change in the face image, pixel labeling is performed on the second face image of the second micro-expression type , that is, the position information of each part (such as eyebrows, eyes, mouth, etc.) in the second face image, understandably, in order to better distinguish the difference between the first face image and the second face image, Therefore, for the marked parts included in the first feature annotation of the first face image, the second feature annotation of the second face image also has corresponding marked parts, so that the second feature annotation corresponding to each second face image is obtained.
S208:将所述第一特征标注与各所述第二特征标注进行比对,确定所述第一特征标注与各所述第二特征标注之间的标注差异值;S208: Compare the first feature label with each of the second feature labels, and determine a label difference value between the first feature label and each of the second feature labels;
S209:将最大的所述标注差异值对应第二特征标注记录为所述目标表情特征。S209: Record the second feature label corresponding to the largest label difference value as the target expression feature.
具体地,在对所述第一人脸图像进行像素标注,得到与所述第一人脸图像对应的第一特征标注,以及对所有所述第二人脸图像进行像素标注,得到与各所述第二人脸图像对应的第二特征标注之后,将第一特征标注与各第二特征标注进行比对,确定第一特征标注与各第二特征标注之间的标注差异值,并将最大的标注差异值对应的第二特征标注记录为目标表情特征。可以理解地,在本实施例中,将最大的标注差异值对应的第二特征标注记录为目标表情特征是因为,可能在此之前的第二特征标注无法更准确判断驾驶员当前状态,进而在将最大的所述标注差异值对应第二特征标注记录为所述目标表情特征之后,可以提高危险驾驶预警的准确率。Specifically, performing pixel labeling on the first face image to obtain a first feature label corresponding to the first face image, and performing pixel labeling on all the second face images to obtain corresponding After the second feature annotation corresponding to the second face image is described, the first feature annotation is compared with each second feature annotation to determine the annotation difference value between the first feature annotation and each second feature annotation, and the maximum value of the annotation difference is determined. The second feature label corresponding to the label difference value is recorded as the target expression feature. Understandably, in this embodiment, the second feature label corresponding to the largest label difference value is recorded as the target expression feature because the second feature label before this may not be able to more accurately judge the current state of the driver, and then After the second feature label corresponding to the largest label difference value is recorded as the target expression feature, the accuracy of the dangerous driving warning can be improved.
S30:将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;S30: Input the target facial expression feature into a preset facial expression coding system, and determine the target facial expression category corresponding to the target facial expression feature;
其中,预设表情编码系统中存储与各类微表情下的具体表情的编码系统。Among them, the encoding system of specific expressions under various micro-expressions is stored in the preset expression encoding system.
具体地,在检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征之后,将目标表情特征输入至预设表情编码系统中,以在预设表情编码系统中确定与目标表情特征对应的目标表情类别。Specifically, after detecting whether a micro-expression change occurs in the facial image in the sequence of facial images, and when detecting a micro-expression change in the facial image, after acquiring the target expression feature of the facial image after the micro-expression change, The target expression features are input into the preset expression encoding system, so as to determine the target expression category corresponding to the target expression characteristics in the preset expression encoding system.
在一实施例中,步骤S30之前,还包括:In one embodiment, before step S30, it further includes:
S01:获取对预设人脸图像进行区域划分之后得到的多个肌肉运动单元,一个所述肌肉运动单元关联一个表情编码;S01: obtain a plurality of muscle movement units obtained after the preset face image is divided into regions, and one described muscle movement unit is associated with an expression code;
可以理解地,预设人脸图像可以为面无表情的人脸图像,示例性地,该预设人脸图像中,眉毛、嘴巴或者眼睛均处于齐平状态,也即眉毛未上扬,眼睛未闭合等。进一步地,对预设人脸图像进行区域划分指的是根据人脸图像中各可能存在明显变化的部位进行划分,得到多个肌肉运动单元,示例性地,该肌肉运动单元可以为嘴巴、眼睛、额头肌肉等,一个肌肉运动单元由人脸中一块肌肉或者多块肌肉组成。表情编码用于表征肌肉运动单元的分类,示例性地,嘴巴肌肉运动单元关联一个表情编码为A;眼睛肌肉运动单元关联一个表情编码为B等。Understandably, the preset face image may be an expressionless face image. For example, in the preset face image, the eyebrows, the mouth or the eyes are in a flush state, that is, the eyebrows are not raised and the eyes are not raised. closed etc. Further, the area division of the preset face image refers to dividing according to the parts that may have obvious changes in the face image to obtain a plurality of muscle movement units. Exemplarily, the muscle movement units may be mouth, eye , forehead muscles, etc. A muscle motor unit consists of one muscle or multiple muscles in the human face. The expression code is used to characterize the classification of the muscle movement units. For example, the mouth muscle movement unit is associated with an expression code as A; the eye muscle movement unit is associated with an expression code as B, and so on.
S02:获取预设表情图像集;所述预设表情图像集中包含至少一张微表情样本图像;一个微表情样本图像关联一个表情标签;S02: Obtain a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
其中,为了提高预设表情编码系统中数据的准确性,预设表情图像集中的微表情样本图像尽量多的选取驾驶场景下的图像,以更好的反应驾驶场景下的各种微表情对应的图像特征。表情标签指示微表情样本图像中的具体微表情含义,示例性地,微表情样本图像中的微表情为不开心,对应的表情标签可以为伤心表情标签,可以理解地,一个微表情类别下存在多种不同的微表情,也即同一种微表情类别,其对应的微表情的肌肉运动单元运动方式可能是不同的。Among them, in order to improve the accuracy of the data in the preset expression coding system, the micro-expression sample images in the preset expression image set are selected as many images as possible in the driving scene, so as to better reflect the corresponding micro-expressions in the driving scene. image features. The expression label indicates the meaning of the specific micro-expression in the micro-expression sample image. Exemplarily, the micro-expression in the micro-expression sample image is unhappy, and the corresponding expression label may be a sad expression label. Understandably, there is a micro-expression category in the A variety of different micro-expressions, that is, the same micro-expression category, may have different movement modes of the muscle motor units corresponding to the micro-expressions.
S03:对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,确定与所述样本图像特征对应的所有表情运动单元;S03: After performing pixel labeling on the micro-expression sample image to obtain the sample image features corresponding to the micro-expression sample image, determine all expression movement units corresponding to the sample image features;
其中,表情运动单元指的是微表情样本图像与预设人脸图像之间存在不同的肌肉运动单元,可以理解地,微表情样本图像关联一个表情标签,每一个微表情之间的肌肉运动单元的具体信息均存在不同(如眉毛的位置不同,嘴巴的弧度不同等),因此对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,对样本图像特征与预设人脸图像对应的预设图像特征(该预设图像特征可以对预设人脸图像进行像素标注之后得到)进行比较,将样本图像特征与预设图像特征之间不同的特征对应的肌肉运动单元记录为表情运动单元。Among them, the expression movement unit refers to the existence of different muscle movement units between the micro-expression sample image and the preset face image. It is understandable that the micro-expression sample image is associated with an expression label, and the muscle movement unit between each micro-expression There are differences in the specific information (such as the position of the eyebrows, the radian of the mouth, etc.), so after the micro-expression sample image is pixel-labeled to obtain the sample image features corresponding to the micro-expression sample image, the sample image features are compared with the sample image. The preset image features corresponding to the preset face image (the preset image features can be obtained after pixel labeling of the preset face image) are compared, and the muscles corresponding to the different features between the sample image features and the preset image features are compared. Motor units were recorded as expression motor units.
S04:将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,并根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联;S04: Categorize each of the expression movement units into the corresponding muscle movement units, and set an expression sub-code for each expression movement unit according to the expression code associated with its matching muscle movement unit, and assign the an emoticon code is associated with the emoticon code;
具体地,对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,确定与所述样本图像特征对应的所有表情运动单元;将各表情运动单元归类至与其匹配的肌肉运动单元中,示例性地,表情运动单元为眉毛上扬,则将该表情运动单元归类至眉毛肌肉运动单元。在将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联;示例性地,假设眉毛肌肉运动单元表情编码为A,则眉毛上扬表情子编码可以为A1。Specifically, after performing pixel labeling on the micro-expression sample image to obtain sample image features corresponding to the micro-expression sample image, all expression motion units corresponding to the sample image features are determined; Among the matched muscle movement units, for example, the expression movement unit is the raising of the eyebrows, and the expression movement unit is classified into the eyebrow muscle movement unit. In classifying each expression movement unit to the corresponding muscle movement unit, an expression code is set for each expression movement unit according to the expression code associated with the matching muscle movement unit, and the expression movement unit is assigned an expression code. The code is associated with the expression code; exemplarily, assuming that the expression code of the eyebrow muscle motor unit is A, the expression code of the raised eyebrow may be A1.
S05:将与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合;S05: record the expression label, the expression sub-code and the expression code association corresponding to the same micro-expression sample image as the code combination of the micro-expression sample image;
S06:根据各所述微表情样本图像的编码组合构建预设表情编码系统。S06: Construct a preset expression encoding system according to the encoding combinations of the micro-expression sample images.
具体地,在将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,并根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联之后,将与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合,示例性地,可以将表情标签、表情子编码以及表情编码关联记录为表情三元组,进而形成微表情样本图像的编码组合,以根据各所述微表情样本图像的编码组合构建预设表情编码系统。Specifically, classifying each expression movement unit into the matching muscle movement unit, and setting an expression sub-code for each expression movement unit according to the expression code associated with its matching muscle movement unit, and set the expression sub-code for each expression movement unit. After the expression code is associated with the expression code, the expression label corresponding to the same micro-expression sample image, the expression code and the expression code are associated and recorded as the code combination of the micro-expression sample image, exemplarily, can be The expression label, the expression sub-code and the expression code association are recorded as expression triples, and then a code combination of micro-expression sample images is formed, so as to construct a preset expression encoding system according to the code combination of each of the micro-expression sample images.
在一实施例中,如图6所示,步骤S30中,也即所述将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别,包括:In one embodiment, as shown in FIG. 6 , in step S30, that is, inputting the target facial expression feature into the preset facial expression coding system to determine the target facial expression category corresponding to the target facial expression feature, including:
S301:获取第一特征标注对应的各第一运动单元,以及与所述目标表情特征对应的各第二运动单元;所述第一特征标注是通过对所述第一人脸图像进行像素标注得到;S301: Obtain each first motion unit corresponding to the first feature annotation, and each second motion unit corresponding to the target expression feature; the first feature annotation is obtained by performing pixel annotation on the first face image ;
S302:将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元;S302: Record the second motion unit different from the first motion unit as the motion unit to be matched;
可以理解地,第一运动单元与第一特征标注中对第一人脸图像标注的部位相关,第二运动单元与目标表情特征中对第二人脸图像标注的部位相关。It can be understood that the first motion unit is related to the part marked on the first face image in the first feature annotation, and the second motion unit is related to the part marked on the second face image in the target expression feature.
示例性地,假设第一特征标注为第一人脸图像中眉毛的位置以及嘴巴位置,则与该第一特征标注中包括眉毛运动单元以及嘴巴运动单元;同理,在上述说明中已经指出目标表情特征对应的第二特征标注与第一特征标注具有相同的标注部位,因此目标表情特征中也包括眉毛运动单元以及嘴巴运动单元。而第一特征标注的眉毛运动单元可能为眉毛齐平,而目标表情特征的眉毛运动单元可能为眉毛上扬,因此第一运动单元中眉毛运动单元即为眉毛齐平运动单元,而第二运动单元中眉毛运动单元即为眉毛上扬运动单元。Exemplarily, assuming that the first feature is labeled as the position of the eyebrow and the position of the mouth in the first face image, then the first feature label includes the eyebrow motion unit and the mouth motion unit; for the same reason, the target has been pointed out in the above description. The second feature label corresponding to the expression feature has the same label position as the first feature label, so the target expression feature also includes the eyebrow motion unit and the mouth motion unit. The eyebrow motion unit marked by the first feature may be the eyebrow flush, and the eyebrow motion unit of the target expression feature may be the eyebrow raised. Therefore, the eyebrow motion unit in the first motion unit is the eyebrow flush motion unit, and the second motion unit is the eyebrow flush motion unit. The middle eyebrow motor unit is the eyebrow raising motor unit.
进一步地,在获取所述第一特征标注对应的各第一运动单元,以及与所述目标表情特征对应的各第二运动单元之后,将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元,也即如上述说明中第一运动单元中眉毛运动单元即为眉毛齐平运动单元,而第二运动单元中眉毛运动单元即为眉毛上扬运动单元,则第一运动单元与第二运动单元中不同的运动单元即为眉毛运动单元。Further, after acquiring each first motion unit corresponding to the first feature label and each second motion unit corresponding to the target facial expression feature, the second motion unit different from the first motion unit is The unit is recorded as the motion unit to be matched, that is, the eyebrow motion unit in the first motion unit is the eyebrow flush motion unit in the above description, and the eyebrow motion unit in the second motion unit is the eyebrow raising motion unit, then the first motion unit is the eyebrow raising motion unit. The motion unit different from the second motion unit is the eyebrow motion unit.
进一步地,还可以通过确定第一特征标注与目标表情特征之间存在不同之处的表情特 征,进而将与该不同之处的表情特征对应的肌肉运动单元记录为待匹配运动单元。Further, it is also possible to record the muscle motion unit corresponding to the facial expression feature of the difference as the motion unit to be matched by determining the facial expression feature that is different between the first feature label and the target facial expression feature.
S303:确定与所述待匹配运动单元匹配的肌肉运动单元,并自预设表情编码系统中获取与其匹配的肌肉运动单元对应的表情编码;S303: determine the muscle movement unit matched with the to-be-matched movement unit, and obtain the expression code corresponding to the muscle movement unit matched with it from the preset expression encoding system;
具体地,在将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元之后,确定与待匹配运动单元匹配的肌肉运动单元,并获取与该肌肉运动单元对应的表情编码。示例性地,假设待匹配运动单元为眉毛运动单元,则自预设表情编码系统中获取与眉毛运动单元对应的表情编码。Specifically, after recording the second motion unit different from the first motion unit as the motion unit to be matched, determine the muscle motion unit that matches the motion unit to be matched, and acquire the expression corresponding to the muscle motion unit coding. Exemplarily, assuming that the motion unit to be matched is an eyebrow motion unit, the expression code corresponding to the eyebrow motion unit is obtained from a preset expression encoding system.
S304:自所述表情编码中,确定与所述待匹配运动单元对应的表情子编码;S304: from the expression encoding, determine the expression sub-encoding corresponding to the to-be-matched motion unit;
进一步地,在确定与所述待匹配运动单元匹配的肌肉运动单元,并自预设表情编码系统中获取与其匹配的肌肉运动单元对应的表情编码之后,确定与待匹配运动单元对应的表情子编码,示例性地,假设该待匹配运动单元为眉毛运动单元中的眉毛上扬运动单元,则自眉毛表情编码中,确定与眉毛上扬对应的表情子编码。Further, after determining the muscle movement unit matched with the to-be-matched movement unit, and obtaining the expression code corresponding to the muscle movement unit matched with it from the preset expression coding system, determine the expression sub-code corresponding to the to-be-matched movement unit. , exemplarily, assuming that the motion unit to be matched is an eyebrow raising motion unit in the eyebrow motion unit, then from the eyebrow expression encoding, the expression sub-code corresponding to the eyebrow raising is determined.
S305:根据确定的所述表情编码以及所述表情子编码,确定与所述目标表情特征对应的目标表情类别。S305: Determine a target expression category corresponding to the target expression feature according to the determined expression code and the expression sub-code.
可以理解地,在确定与待匹配运动单元对应的表情编码以及表情子编码之后,由于在预设表情编码系统中存储由与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合,进而根据该表情编码以及表情子编码确定与目标表情特征对应的目标表情类别。进一步地,一个微表情可能是由多个不同的表情子编码构成的,进而根据各待匹配肌肉运动单元对应的表情编码以及表情子编码,即可确定目标表情类别。It can be understood that, after determining the expression code and the expression sub-coding corresponding to the motion unit to be matched, since the expression label, the expression sub-coding and the expression encoding corresponding to the same micro-expression sample image are stored in the preset expression encoding system, It is recorded as the code combination of the micro-expression sample images, and then the target expression category corresponding to the target expression feature is determined according to the expression code and the expression sub-code. Further, a micro-expression may be composed of a plurality of different expression sub-codes, and then the target expression category can be determined according to the expression code and the expression sub-code corresponding to each muscle motion unit to be matched.
示例性地,假设疲劳表情类别中,对应的各个部位的信息为,眉毛下垂,双眼紧闭等,则在对应的表情编码为眉毛运动单元对应的表情编码,以及眼睛运动单元对应的表情编码,对应的表情子编码包括眉毛下垂对应的表情子编码,以及双眼紧闭对应的表情子编码,进而根据上述的表情编码以及表情子编码,确定与目标表情特征对应的目标表情类别即为疲劳表情类别。Exemplarily, assuming that in the fatigue expression category, the information of the corresponding parts is drooping eyebrows, closed eyes, etc., then the corresponding expression encoding is the expression encoding corresponding to the eyebrow motion unit, and the expression encoding corresponding to the eye motion unit, The corresponding expression sub-coding includes the expression sub-coding corresponding to drooping eyebrows, and the expression sub-coding corresponding to closed eyes, and then according to the above-mentioned expression encoding and the expression sub-coding, it is determined that the target expression category corresponding to the target expression feature is the fatigue expression category. .
S40:若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;S40: If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
其中,预设危险表情类别可以为疲劳表情类别。多轮对话装置可以设置在车辆上的智能语音系统中,该多轮对话装置通过TTS播报技术,与驾驶员进行对话沟通,提高驾驶员的精神。The preset dangerous expression category may be a fatigue expression category. The multi-round dialogue device can be set in the intelligent voice system on the vehicle, and the multi-round dialogue device can communicate with the driver through the TTS broadcast technology, so as to improve the driver's spirit.
具体地,在将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别之后,确定目标表情类别是否为预设危险表情类别,以在目标表情类别属于预设危险表情类别时,启动多轮对话装置,并通过多轮对话装置询问驾驶员当前状态,亦或者向驾驶员播报一些有趣的消息,进而与驾驶员进行对话,并获取驾驶员的对话信息。Specifically, after inputting the target facial expression feature into the preset facial expression coding system, and after determining the target facial expression category corresponding to the target facial expression feature, it is determined whether the target facial expression category is a preset dangerous facial expression category, so as to determine whether the target facial expression category is a preset dangerous facial expression category. When it belongs to the preset dangerous expression category, start the multi-round dialogue device, and ask the driver's current status through the multi-round dialogue device, or broadcast some interesting messages to the driver, and then have a dialogue with the driver and obtain the driver's dialogue information.
S50:提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;S50: Extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver is fatigued according to the voiceprint feature and a preset fatigue scale;
可以理解地,预设疲劳量表是通过多轮对话装置预先对驾驶员各种状态下的声音进行学习之后,根据对话中的声音特性生成的,示例性地,预先通过对驾驶员进行场景模拟测试,如提取驾驶员正常驾驶时的声纹特征,并对该声纹特征进行编码且打上正常驾驶声纹的标签,又比如提取驾驶员初期疲劳时的声纹特征,并对该声纹特征进行编码且打上初始疲劳声纹的标签,进而根据各个不同驾驶时期的声纹特征以及对应的标签,构建预设疲劳量表。It can be understood that the preset fatigue scale is generated according to the characteristics of the voice in the dialogue after learning the driver's voice in various states in advance through the multi-round dialogue device. Tests, such as extracting the voiceprint features of the driver during normal driving, encoding the voiceprint features and labeling the normal driving voiceprint, or extracting the voiceprint features of the driver when they are initially fatigued, and encoding the voiceprint features Code and label the initial fatigue voiceprint, and then construct a preset fatigue scale according to the voiceprint features and corresponding labels in different driving periods.
可以理解地,预设疲劳量表中存在各个疲劳量对应的等级,以及与该等级对应的样本声纹特征,进而在提取对话信息中驾驶员的声纹特征之后,可以根据该声纹特征与样本声 纹特征进行匹配,如对声纹特征以及样本声纹特征进行电平调整和对齐,并通过IRS滤波模拟声纹特征以及样本声纹特征的频率特性,以在对声纹特征以及样本声纹特征的频率特性进行补偿之后,通过不对称处理算法确定声纹特征和样本声纹特征之间的相似度,进而选取最高相似度的样本声纹特征作为对声纹特征判断的依据,从而自预设疲劳量度表中确定与该相似度最高的样本声纹特征对应的疲劳度等级,从而确定驾驶员当前的疲劳度,以对驾驶员是否存在疲劳驾驶现象进行判定。Understandably, there are levels corresponding to each fatigue level in the preset fatigue scale, and sample voiceprint features corresponding to the levels, and after extracting the driver's voiceprint features in the dialogue information, you can use the voiceprint features and the corresponding voiceprint features. The sample voiceprint features are matched, such as level adjustment and alignment of the voiceprint features and the sample voiceprint features, and the frequency characteristics of the voiceprint features and the sample voiceprint features are simulated by IRS filtering, so as to compare the voiceprint features and the sample voiceprint features. After compensating the frequency characteristics of the voiceprint feature, the similarity between the voiceprint feature and the sample voiceprint feature is determined by the asymmetric processing algorithm, and then the sample voiceprint feature with the highest similarity is selected as the basis for judging the voiceprint feature, so as to automatically The fatigue level corresponding to the voiceprint feature of the sample with the highest similarity is determined in the preset fatigue measurement table, so as to determine the current fatigue level of the driver, so as to determine whether the driver has a fatigue driving phenomenon.
S60:在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。S60: Trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued.
可以理解地,在确定驾驶员存在疲劳驾驶时,可以根据声纹特征亦或者目标表情类别确定当前驾驶员的疲劳程度(如轻度疲劳,重度疲劳等),如根据声纹特征与预设疲劳度量表确定驾驶员存在疲劳驾驶时,可以根据与该声纹特征对应的疲劳等级确定驾驶员当前的疲劳程度,亦或者在根据目标表情特征确定目标表情类别时,由于不同疲劳程度对应的微表情的表情特征也是不同的,进而在确定目标表情类别时可以得到具体的疲劳程度表情(如根据上眼皮与下眼皮之间的距离范围限定不同的疲劳程度),进而在确定所述驾驶员存在疲劳驾驶时,可以根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示,示例性地,在根据所述声纹特征以及所述目标表情类别确定驾驶员当前为轻度疲劳驾驶时,可以与驾驶员进行持续语音聊天,亦或者播报轻松诙谐的脱口秀节目等危险驾驶语音提示;若为重度疲劳驾驶时,可以通过较大分贝的语音提示广播,并在驾驶员驾驶自动汽车时切换至自动驾驶状态。Understandably, when it is determined that the driver is driving fatigued, the current driver's fatigue level (such as mild fatigue, severe fatigue, etc.) can be determined according to the voiceprint feature or the target expression category, for example, according to the voiceprint feature and preset fatigue. When the metric table determines that the driver is driving fatigued, the current fatigue level of the driver can be determined according to the fatigue level corresponding to the voiceprint feature, or when the target expression category is determined according to the target expression feature, due to the micro-expressions corresponding to different fatigue levels. The expression characteristics of the two are also different, and then the specific fatigue level expressions can be obtained when determining the target expression category (for example, different fatigue levels are defined according to the distance range between the upper eyelid and the lower eyelid), and then the driver is determined to be fatigued. When driving, a dangerous driving voice prompt can be triggered according to the voiceprint feature and the target expression category. It can conduct continuous voice chat with the driver, or broadcast voice prompts for dangerous driving such as light-hearted talk shows; if it is heavily fatigued, it can broadcast through a louder voice prompt and switch when the driver is driving an autonomous car to automatic driving.
进一步地,可以根据司机每次开车的疲劳频率(如经常疲劳,一般疲劳),通常在某个时间段疲劳(例晚上10点到12点),调整疲劳提醒策略,例如经常疲劳的司机可进行提前提醒,在司机还没产生疲劳时就自动进行语音提醒(经常疲劳的比一般疲劳的提醒频率更高);或在司机容易疲劳的时间(晚上10点)播放提醒信息或音乐等,进而可以通过不断与驾驶员进行交互,可以防止驾驶员陷入深度睡眠,降低事故发生率。Further, the fatigue reminder strategy can be adjusted according to the fatigue frequency of the driver every time (such as frequent fatigue, general fatigue), usually in a certain period of time (for example, 10:00 to 12:00 in the evening). For example, drivers who are often tired can Reminder in advance, automatically give voice reminders when the driver is not fatigued (the frequency of reminders for frequent fatigue is higher than that of general fatigue); or play reminder information or music at the time when the driver is prone to fatigue (10 o'clock in the evening), and then you can By constantly interacting with the driver, the driver can be prevented from falling into a deep sleep, reducing the accident rate.
在本申请中,采用智能表情技术以及语音分析能够更加敏感准确地捕捉到司机的疲惫状态,一旦发现该情况,就采用多轮对话技术,进行提醒,提高了危险驾驶预警的准确性,并且在发现人脸图像存在疲劳驾驶时,不是立即进行提示,缓解了立即触发预警提示带来的突发性。In this application, the use of intelligent expression technology and voice analysis can more sensitively and accurately capture the driver's fatigue state. Once the situation is found, multiple rounds of dialogue technology are used to remind, which improves the accuracy of dangerous driving warning, and in When it is found that there is fatigue driving in the face image, it is not prompted immediately, which alleviates the suddenness caused by the immediate triggering of the warning prompt.
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。It should be understood that the size of the sequence numbers of the steps in the above embodiments does not mean the sequence of execution, and the execution sequence of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.
在一实施例中,提供一种危险驾驶预警装置,该危险驾驶预警装置与上述实施例中危险驾驶预警方法一一对应。如图7所示,该危险驾驶预警装置包括人脸图像序列记录模块10、表情特征获取模块20、表情类别确定模块30、对话信息获取模块40、声纹特征匹配模块50和语音提示模块60。各功能模块详细说明如下:In one embodiment, a dangerous driving early warning device is provided, and the dangerous driving early warning device is in one-to-one correspondence with the dangerous driving early warning method in the above-mentioned embodiment. As shown in FIG. 7 , the dangerous driving warning device includes a face image sequence recording module 10 , an expression feature acquisition module 20 , an expression category determination module 30 , a dialogue information acquisition module 40 , a voiceprint feature matching module 50 and a voice prompt module 60 . The detailed description of each functional module is as follows:
人脸图像序列记录模块10,用于在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;The face image sequence recording module 10 is used to acquire the driver's face image in real time during the driving process of the vehicle, and record the acquired face image as a face image sequence according to the acquisition sequence;
表情特征获取模块20,用于检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;The facial expression feature acquisition module 20 is used to detect whether the facial image in the sequence of facial images has a micro-expression change, and when detecting that the facial image has a micro-expression change, obtain the target of the facial image after the micro-expression change facial features;
表情类别确定模块30,用于将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;An expression category determination module 30, configured to input the target expression feature into a preset expression encoding system, and determine the target expression category corresponding to the target expression characteristic;
对话信息获取模块40,用于若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取所述驾驶员的对话信息;Dialogue information acquisition module 40, configured to conduct dialogue with the driver through a multi-round dialogue device and acquire dialogue information of the driver if the target expression category belongs to the preset dangerous expression category;
声纹特征匹配模块50,用于提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;A voiceprint feature matching module 50, configured to extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver has fatigued driving according to the voiceprint feature and a preset fatigue scale;
语音提示模块60,用于在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。The voice prompt module 60 is configured to trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued driving.
优选地,如图8所示,人脸图像序列记录模块10包括如下单元:Preferably, as shown in FIG. 8 , the face image sequence recording module 10 includes the following units:
图像拍摄单元101,用于在车辆行驶过程中,通过预设拍摄设备拍摄预设范围内的图像;The image capturing unit 101 is used for capturing images within a preset range through a preset capturing device during the driving of the vehicle;
人脸图像序列记录单元102,用于在所述预设拍摄设备拍摄到驾驶员的人脸图像时,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;The face image sequence recording unit 102 is configured to associate and record the obtained face images as a face image sequence according to the acquisition order when the preset photographing device captures the driver's face images;
危险提示单元103,用于在所述预设拍摄设备在预设范围内未拍摄到驾驶员的人脸图像时,触发危险驾驶提示,并在重新拍摄到包含驾驶员的人脸图像时,停止危险驾驶提示。The danger prompting unit 103 is used for triggering a dangerous driving prompt when the preset photographing device fails to photograph the driver's face image within a preset range, and stops when the driver's face image is re-photographed Dangerous driving tips.
优选地,如图9所示,表情特征获取模块20包括:Preferably, as shown in FIG. 9 , the expression feature acquisition module 20 includes:
第一像素标注单元201,用于将所述人脸图像序列中第一帧人脸图像记录为初始人脸图像,并对所述初始人脸图像进行像素标注,得到与所述初始人脸图像对应的初始特征标注;The first pixel labeling unit 201 is configured to record the first frame of the face image in the sequence of face images as an initial face image, and perform pixel labeling on the initial face image to obtain the same value as the initial face image. The corresponding initial feature annotation;
第二像素标注单元202,用于将所述人脸图像序列中与所述初始人脸图像对应的下一帧人脸图像记录为对比人脸图像,并对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特征标注;The second pixel labeling unit 202 is configured to record the next frame of face image corresponding to the initial face image in the sequence of face images as a comparison face image, and perform pixel labeling on the comparison face image , obtain the contrast feature annotation corresponding to the contrast face image;
标注差异值确定单元203,用于将所述初始特征标注与所述对比特征标注进行像素特征比较,确定所述初始特征标注与所述对比特征标注之间的标注差异值;Annotation difference value determination unit 203, configured to perform pixel feature comparison between the initial feature label and the comparison feature label, and determine the label difference value between the initial feature label and the comparison feature label;
差异比较单元204,用于将所述标注差异值与预设差异阈值进行比较;a difference comparison unit 204, configured to compare the marked difference value with a preset difference threshold;
第二人脸图像记录单元205,用于在所述标注差异值大于或等于预设差异阈值时,提示所述人脸图像序列中的人脸图像发生微表情变化,并将所述初始人脸图像记录为所述第一人脸图像,将所述对比人脸图像以及排序在对比人脸图像之后的人脸图像关联记录为所述第二人脸图像。The second face image recording unit 205 is configured to, when the marked difference value is greater than or equal to a preset difference threshold, prompt the face images in the face image sequence to have micro-expression changes, and record the initial face image The image is recorded as the first face image, and the comparison face image and the face images ranked after the comparison face image are associated and recorded as the second face image.
优选地,如图10所示,表情特征获取模块20还包括:Preferably, as shown in FIG. 10 , the expression feature acquisition module 20 further includes:
第三像素标注单元206,用于对所述第一人脸图像进行像素标注,得到与所述第一人脸图像对应的第一特征标注;A third pixel labeling unit 206, configured to perform pixel labeling on the first face image to obtain a first feature label corresponding to the first face image;
第四像素标注单元207,用于对所有所述第二人脸图像进行像素标注,得到与各所述第二人脸图像对应的第二特征标注;a fourth pixel labeling unit 207, configured to perform pixel labeling on all the second face images to obtain second feature labels corresponding to each of the second face images;
特征标注比对单元208,用于将所述第一特征标注与各所述第二特征标注进行比对,确定所述第一特征标注与各所述第二特征标注之间的标注差异值;A feature label comparison unit 208, configured to compare the first feature label with each of the second feature labels, and determine a label difference value between the first feature label and each of the second feature labels;
目标表情特征确定单元209,用于将最大的所述标注差异值对应第二特征标注记录为所述目标表情特征。The target facial expression feature determining unit 209 is configured to record the second feature label corresponding to the largest label difference value as the target facial expression feature.
优选地,危险驾驶预警装置还包括:Preferably, the dangerous driving warning device further includes:
肌肉运动单元获取模块01,用于获取对预设人脸图像进行区域划分之后得到的多个肌肉运动单元,一个所述肌肉运动单元关联一个表情编码;The muscle movement unit acquisition module 01 is used to obtain a plurality of muscle movement units obtained after the preset face image is divided into regions, and one of the muscle movement units is associated with an expression code;
表情图像集获取模块02,用于获取预设表情图像集;所述预设表情图像集中包含至少一张微表情样本图像;一个微表情样本图像关联一个表情标签;An expression image set obtaining module 02, configured to obtain a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
表情运动单元确定模块03,用于对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,确定与所述样本图像特征对应的所有表情运动单元;Expression motion unit determination module 03, used to perform pixel labeling on the micro-expression sample image to obtain sample image features corresponding to the micro-expression sample image, and determine all the expression motion units corresponding to the sample image features;
表情子编码设置模块04,用于将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,并根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联;Expression sub-coding setting module 04, for classifying each described expression movement unit into the described muscle movement unit matched with it, and set an expression for each expression movement unit according to the expression code associated with its matching muscle movement unit subcoding, and associate the expression subcoding with the expression encoding;
编码组合记录模块05,用于将与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合;The coding combination recording module 05 is used to associate and record the expression label, the expression sub-coding and the expression coding associated with the same micro-expression sample image as the coding combination of the micro-expression sample image;
表情编码系统构建模块06,用于根据各所述微表情样本图像的编码组合构建预设表情 编码系统。Expression coding system building module 06, for constructing a preset expression coding system according to the coding combination of each described micro-expression sample image.
优选地,如图11所示,表情类别确定模块30包括:Preferably, as shown in FIG. 11 , the expression category determination module 30 includes:
运动单元获取单元301,用于获取第一特征标注对应的各第一运动单元,以及与所述目标表情特征对应的各第二运动单元;所述第一特征标注是通过对所述第一人脸图像进行像素标注得到;The motion unit acquisition unit 301 is configured to acquire each first motion unit corresponding to the first feature label, and each second motion unit corresponding to the target expression feature; the first feature label is obtained by identifying the first person The face image is obtained by pixel labeling;
待匹配运动单元记录单元302,用于将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元;A motion unit recording unit 302 to be matched, configured to record the second motion unit different from the first motion unit as the motion unit to be matched;
表情编码获取单元303,用于确定与所述待匹配运动单元匹配的肌肉运动单元,并自预设表情编码系统中获取与其匹配的肌肉运动单元的表情编码;The expression code obtaining unit 303 is used to determine the muscle movement unit matched with the described movement unit to be matched, and obtain the expression code of the muscle movement unit matched with it from the preset expression code system;
表情子编码获取单元304,用于自所述表情编码中,确定与所述待匹配运动单元对应的表情子编码;An expression code obtaining unit 304, configured to determine the expression code corresponding to the motion unit to be matched from the expression encoding;
目标表情类别确定单元305,用于根据确定的所述表情编码以及所述表情子编码,确定与所述目标表情特征对应的目标表情类别。The target expression category determination unit 305 is configured to determine a target expression category corresponding to the target expression feature according to the determined expression code and the expression sub-code.
关于危险驾驶预警装置的具体限定可以参见上文中对于危险驾驶预警方法的限定,在此不再赘述。上述危险驾驶预警装置中的各个模块可全部或部分通过软件、硬件及其组合来实现。上述各模块可以硬件形式内嵌于或独立于计算机设备中的处理器中,也可以以软件形式存储于计算机设备中的存储器中,以便于处理器调用执行以上各个模块对应的操作。For the specific limitation of the dangerous driving warning device, reference may be made to the above limitation on the dangerous driving warning method, which will not be repeated here. Each module in the above-mentioned dangerous driving warning device can be implemented in whole or in part by software, hardware and combinations thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
在一个实施例中,提供了一种计算机设备,该计算机设备可以是服务器,其内部结构图可以如图12所示。该计算机设备包括通过系统总线连接的处理器、存储器、网络接口和数据库。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括可读存储介质、内存储器。该可读存储介质存储有操作系统、计算机可读指令和数据库。该内存储器为可读存储介质中的操作系统和计算机可读指令的运行提供环境。该计算机设备的数据库用于存储上述实施例中危险驾驶预警方法所使用到的数据。该计算机设备的网络接口用于与外部的终端通过网络连接通信。该计算机可读指令被处理器执行时以实现一种危险驾驶预警方法。In one embodiment, a computer device is provided, and the computer device may be a server, and its internal structure diagram may be as shown in FIG. 12 . The computer device includes a processor, memory, a network interface, and a database connected by a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a readable storage medium, an internal memory. The readable storage medium stores an operating system, computer readable instructions and a database. The internal memory provides an environment for the execution of the operating system and computer-readable instructions in the readable storage medium. The database of the computer device is used to store the data used in the dangerous driving warning method in the above embodiment. The network interface of the computer device is used to communicate with an external terminal through a network connection. The computer readable instructions, when executed by a processor, implement a dangerous driving warning method.
在一个实施例中,提供了一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,所述处理器执行所述计算机可读指令时实现如下步骤:In one embodiment, there is provided a computer apparatus comprising a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, the processor executing the computer readable instructions Implement the following steps when instructing:
在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is driving fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
在一个实施例中,提供了一个或多个存储有计算机可读指令的可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:In one embodiment, one or more readable storage media are provided that store computer-readable instructions that, when executed by one or more processors, cause the one or more processors to execute Follow the steps below:
在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is driving fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机可读指令来指令相关的硬件来完成,所述的计算机可读指令可存储于一非易失性计算机可读取存储介质或者易失性计算机可读取存储介质中,该计算机可读指令在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、存储、数据库或其它介质的任何引用,均可包括非易失性和/或易失性存储器。非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM)或者外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDRSDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)等。Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing relevant hardware through computer-readable instructions, and the computer-readable instructions can be stored in a non-volatile computer. In a readable storage medium or a volatile computer-readable storage medium, the computer-readable instructions, when executed, may include the processes of the foregoing method embodiments. Wherein, any reference to memory, storage, database or other medium used in the various embodiments provided in this application may include non-volatile and/or volatile memory. Nonvolatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous chain Road (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。Those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned functions can be allocated to different functional units, Module completion, that is, dividing the internal structure of the device into different functional units or modules to complete all or part of the functions described above.
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above-mentioned embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the above-mentioned embodiments, those of ordinary skill in the art should understand that: it can still be used for the above-mentioned implementations. The technical solutions described in the examples are modified, or some technical features thereof are equivalently replaced; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions in the embodiments of the application, and should be included in the within the scope of protection of this application.

Claims (20)

  1. 一种危险驾驶预警方法,其中,包括:A dangerous driving warning method, comprising:
    在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
    检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
    将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
    若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
    提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
    在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is driving fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  2. 如权利要求1所述的危险驾驶预警方法,其中,所述在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列,包括:The method for early warning of dangerous driving according to claim 1, wherein, acquiring the face image of the driver in real time during the driving of the vehicle, and recording the acquired face image as a sequence of face images in an order of acquisition, including:
    在车辆行驶过程中,通过预设拍摄设备拍摄预设范围内的图像;During the driving process of the vehicle, the image within the preset range is shot by the preset shooting device;
    在所述预设拍摄设备拍摄到驾驶员的人脸图像时,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;When the preset photographing device captures the face image of the driver, the obtained face image is associated and recorded as a sequence of face images according to the acquisition sequence;
    在所述预设拍摄设备在预设范围内未拍摄到驾驶员的人脸图像时,触发危险驾驶提示,并在重新拍摄到包含驾驶员的人脸图像时,停止危险驾驶提示。When the preset photographing device fails to photograph the driver's face image within the preset range, the dangerous driving prompt is triggered, and when the driver's face image is re-shot, the dangerous driving prompt is stopped.
  3. 如权利要求1所述的危险驾驶预警方法,其中,所述检测所述人脸图像序列中的人脸图像是否发生微表情变化,包括:The dangerous driving warning method according to claim 1, wherein the detecting whether the facial images in the sequence of facial images have micro-expression changes, comprising:
    将所述人脸图像序列中第一帧人脸图像记录为初始人脸图像,并对所述初始人脸图像进行像素标注,得到与所述初始人脸图像对应的初始特征标注;recording the first frame of face image in the face image sequence as an initial face image, and performing pixel labeling on the initial face image to obtain an initial feature label corresponding to the initial face image;
    将所述人脸图像序列中与所述初始人脸图像对应的下一帧人脸图像记录为对比人脸图像,并对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特征标注;Recording the next frame of face image corresponding to the initial face image in the face image sequence as a comparison face image, and performing pixel labeling on the comparison face image to obtain the comparison face image with the comparison face image Corresponding contrast feature annotation;
    将所述初始特征标注与所述对比特征标注进行像素特征比较,确定所述初始特征标注与所述对比特征标注之间的标注差异值;performing pixel feature comparison between the initial feature annotation and the comparison feature annotation, and determining the annotation difference value between the initial feature annotation and the comparison feature annotation;
    将所述标注差异值与预设差异阈值进行比较;comparing the marked difference value with a preset difference threshold;
    在所述标注差异值大于或等于预设差异阈值时,提示所述人脸图像序列中的人脸图像发生微表情变化,并将所述初始人脸图像记录为第一人脸图像,将所述对比人脸图像以及排序在对比人脸图像之后的人脸图像关联记录为第二人脸图像。When the marked difference value is greater than or equal to the preset difference threshold, prompt the facial images in the sequence of facial images to have micro-expression changes, record the initial facial image as the first facial image, and record all the facial images as the first facial image. The above-mentioned comparison face images and the face images ranked after the comparison face images are associated and recorded as the second face image.
  4. 如权利要求1所述的危险驾驶预警方法,其中,所述目标表情特征是指所有第二人脸图像中与第一人脸图像差异最大的表情特征;第一人脸图像是指微表情变化之前的首个第一微表情类型的人脸图像;第二人脸图像是指所述人脸图像序列中与第一人脸图像连续的后端序列段中的人脸图像,所述后端序列段中的所有第二人脸图像均为第二微表情类型;所述获取微表情变化之后的人脸图像的目标表情特征,包括:The dangerous driving warning method according to claim 1, wherein the target facial expression feature refers to the facial expression feature with the largest difference from the first facial image in all the second facial images; the first facial image refers to the change of micro-expression The first face image of the first micro-expression type before; the second face image refers to the face image in the back-end sequence segment that is continuous with the first face image in the face image sequence, and the back-end All the second face images in the sequence segment are of the second micro-expression type; the acquisition of the target expression features of the face images after the micro-expression changes includes:
    对所述第一人脸图像进行像素标注,得到与所述第一人脸图像对应的第一特征标注;performing pixel labeling on the first face image to obtain a first feature label corresponding to the first face image;
    对所有所述第二人脸图像进行像素标注,得到与各所述第二人脸图像对应的第二特征标注;Perform pixel labeling on all the second face images to obtain second feature labels corresponding to each of the second face images;
    将所述第一特征标注与各所述第二特征标注进行比对,确定所述第一特征标注与各所述第二特征标注之间的标注差异值;Comparing the first feature label with each of the second feature labels, and determining a label difference value between the first feature label and each of the second feature labels;
    将最大的所述标注差异值对应第二特征标注记录为所述目标表情特征。Record the second feature label corresponding to the largest label difference value as the target expression feature.
  5. 如权利要求1所述的危险驾驶预警方法,其中,所述将所述目标表情特征输入至预设表情编码系统中之前,还包括:The dangerous driving warning method according to claim 1, wherein, before the inputting the target facial expression feature into the preset facial expression coding system, the method further comprises:
    获取对预设人脸图像进行区域划分之后得到的多个肌肉运动单元,一个所述肌肉运动单元关联一个表情编码;Obtain multiple muscle movement units obtained after the preset face image is divided into regions, and each of the muscle movement units is associated with an expression code;
    获取预设表情图像集;所述预设表情图像集中包含至少一张微表情样本图像;一个微表情样本图像关联一个表情标签;Obtaining a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
    对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,确定与所述样本图像特征对应的所有表情运动单元;After pixel labeling is performed on the micro-expression sample image to obtain the sample image features corresponding to the micro-expression sample image, all expression motion units corresponding to the sample image features are determined;
    将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,并根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联;Each described expression movement unit is classified into the described muscle movement unit that it is matched, and according to the expression code associated with its matching muscle movement unit, an expression code is set for each expression movement unit, and the expression code is set. encoding is associated with the expression encoding;
    将与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合;Correspondingly record the expression label, the expression sub-code and the expression code corresponding to the same micro-expression sample image as the coding combination of the micro-expression sample image;
    根据各所述微表情样本图像的编码组合构建预设表情编码系统。A preset expression encoding system is constructed according to the encoding combinations of the micro-expression sample images.
  6. 如权利要求5所述的危险驾驶预警方法,其中,所述将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别,包括:The dangerous driving warning method according to claim 5, wherein the inputting the target facial expression feature into a preset facial expression coding system to determine the target facial expression category corresponding to the target facial expression feature comprises:
    获取第一特征标注对应的各第一运动单元,以及与所述目标表情特征对应的各第二运动单元;所述第一特征标注是通过对第一人脸图像进行像素标注得到;Obtain each first motion unit corresponding to the first feature label, and each second motion unit corresponding to the target expression feature; the first feature label is obtained by performing pixel labeling on the first face image;
    将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元;recording the second motion unit different from the first motion unit as the motion unit to be matched;
    确定与所述待匹配运动单元匹配的肌肉运动单元,并自预设表情编码系统中获取与其匹配的肌肉运动单元的表情编码;Determine the muscle movement unit matched with the described movement unit to be matched, and obtain the expression code of the muscle movement unit matched with it from the preset expression coding system;
    自所述表情编码中,确定与所述待匹配运动单元对应的表情子编码;From the expression encoding, determine the expression sub encoding corresponding to the motion unit to be matched;
    根据确定的所述表情编码以及所述表情子编码,确定与所述目标表情特征对应的目标表情类别。According to the determined expression code and the expression sub-code, a target expression category corresponding to the target expression feature is determined.
  7. 一种危险驾驶预警装置,其中,包括:A dangerous driving warning device, comprising:
    人脸图像序列记录模块,用于在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;A face image sequence recording module, configured to acquire the driver's face image in real time during the driving process of the vehicle, and record the acquired face image as a face image sequence according to the acquisition sequence;
    表情特征获取模块,用于检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;An expression feature acquisition module, configured to detect whether a micro-expression change occurs in the face image in the sequence of face images, and when detecting a micro-expression change in the face image, acquire the target expression of the face image after the micro-expression change feature;
    表情类别确定模块,用于将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;an expression category determination module, configured to input the target expression feature into a preset expression encoding system, and determine the target expression category corresponding to the target expression characteristic;
    对话信息获取模块,用于若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取所述驾驶员的对话信息;a dialogue information acquisition module, configured to conduct dialogue with the driver through a multi-round dialogue device if the target expression category belongs to the preset dangerous expression category, and acquire dialogue information of the driver;
    声纹特征匹配模块,用于提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;A voiceprint feature matching module, configured to extract the voiceprint feature of the driver in the dialogue information, and determine whether the driver has fatigued driving according to the voiceprint feature and a preset fatigue scale;
    语音提示模块,用于在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。The voice prompt module is used to trigger a dangerous driving voice prompt according to the voiceprint feature and the target expression category when it is determined that the driver is fatigued driving.
  8. 如权利要求7所述的危险驾驶预警装置,其中,所述人脸图像序列记录模块,包括:The dangerous driving warning device according to claim 7, wherein the face image sequence recording module comprises:
    图像拍摄单元,用于在车辆行驶过程中,通过预设拍摄设备拍摄预设范围内的图像;an image capturing unit, used for capturing an image within a preset range through a preset shooting device during the driving process of the vehicle;
    人脸图像序列记录单元,用于在所述预设拍摄设备拍摄到驾驶员的人脸图像时,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;A face image sequence recording unit, configured to associate and record the obtained face images as a face image sequence according to the acquisition order when the preset photographing device captures the driver's face images;
    危险提示单元,用于在所述预设拍摄设备在预设范围内未拍摄到驾驶员的人脸图像时,触发危险驾驶提示,并在重新拍摄到包含驾驶员的人脸图像时,停止危险驾驶提示。A danger prompting unit, used for triggering a dangerous driving prompt when the preset photographing device fails to photograph the driver's face image within a preset range, and stops the danger when the driver's face image is re-photographed Driving Tips.
  9. 一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,其中,所述处理器执行所述计算机可读指令时实现如下步骤:A computer device comprising a memory, a processor, and computer-readable instructions stored in the memory and executable on the processor, wherein the processor implements the following steps when executing the computer-readable instructions:
    在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and record the acquired face image as a sequence of face images according to the acquisition sequence;
    检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
    将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
    若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
    提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
    在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  10. 如权利要求9所述的计算机设备,其中,所述在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列,包括:The computer device according to claim 9, wherein, acquiring the face image of the driver in real time during the driving of the vehicle, and recording the acquired face image as a sequence of face images in an order of acquisition, including:
    在车辆行驶过程中,通过预设拍摄设备拍摄预设范围内的图像;During the driving process of the vehicle, the image within the preset range is shot by the preset shooting device;
    在所述预设拍摄设备拍摄到驾驶员的人脸图像时,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;When the preset photographing device captures the face image of the driver, the obtained face image is associated and recorded as a sequence of face images according to the acquisition sequence;
    在所述预设拍摄设备在预设范围内未拍摄到驾驶员的人脸图像时,触发危险驾驶提示,并在重新拍摄到包含驾驶员的人脸图像时,停止危险驾驶提示。When the preset photographing device fails to photograph the driver's face image within the preset range, the dangerous driving prompt is triggered, and when the driver's face image is re-shot, the dangerous driving prompt is stopped.
  11. 如权利要求9所述的计算机设备,其中,所述检测所述人脸图像序列中的人脸图像是否发生微表情变化,包括:The computer device according to claim 9, wherein the detecting whether the facial images in the sequence of facial images have micro-expression changes, comprising:
    将所述人脸图像序列中第一帧人脸图像记录为初始人脸图像,并对所述初始人脸图像进行像素标注,得到与所述初始人脸图像对应的初始特征标注;recording the first frame of face image in the face image sequence as an initial face image, and performing pixel labeling on the initial face image to obtain an initial feature label corresponding to the initial face image;
    将所述人脸图像序列中与所述初始人脸图像对应的下一帧人脸图像记录为对比人脸图像,并对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特征标注;Recording the next frame of face image corresponding to the initial face image in the face image sequence as a comparison face image, and performing pixel labeling on the comparison face image to obtain the comparison face image with the comparison face image Corresponding contrast feature annotation;
    将所述初始特征标注与所述对比特征标注进行像素特征比较,确定所述初始特征标注与所述对比特征标注之间的标注差异值;performing pixel feature comparison between the initial feature annotation and the comparison feature annotation, and determining the annotation difference value between the initial feature annotation and the comparison feature annotation;
    将所述标注差异值与预设差异阈值进行比较;comparing the marked difference value with a preset difference threshold;
    在所述标注差异值大于或等于预设差异阈值时,提示所述人脸图像序列中的人脸图像发生微表情变化,并将所述初始人脸图像记录为第一人脸图像,将所述对比人脸图像以及排序在对比人脸图像之后的人脸图像关联记录为第二人脸图像。When the marked difference value is greater than or equal to the preset difference threshold, prompt the facial images in the sequence of facial images to have micro-expression changes, record the initial facial image as the first facial image, and record all the facial images as the first facial image. The above-mentioned comparison face images and the face images ranked after the comparison face images are associated and recorded as the second face image.
  12. 如权利要求9所述的计算机设备,其中,所述目标表情特征是指所有第二人脸图像中与第一人脸图像差异最大的表情特征;第一人脸图像是指微表情变化之前的首个第一微表情类型的人脸图像;第二人脸图像是指所述人脸图像序列中与第一人脸图像连续的后端序列段中的人脸图像,所述后端序列段中的所有第二人脸图像均为第二微表情类型;所述获取微表情变化之后的人脸图像的目标表情特征,包括:The computer device according to claim 9, wherein the target facial expression feature refers to the facial expression feature with the greatest difference from the first facial image among all the second facial images; The first face image of the first micro-expression type; the second face image refers to the face image in the back-end sequence segment that is continuous with the first face image in the sequence of face images, and the back-end sequence segment All the second face images in are the second micro-expression type; the target expression features of the obtained face images after the micro-expression change include:
    对所述第一人脸图像进行像素标注,得到与所述第一人脸图像对应的第一特征标注;performing pixel labeling on the first face image to obtain a first feature label corresponding to the first face image;
    对所有所述第二人脸图像进行像素标注,得到与各所述第二人脸图像对应的第二特征标注;Perform pixel annotation on all the second face images to obtain second feature annotations corresponding to each of the second face images;
    将所述第一特征标注与各所述第二特征标注进行比对,确定所述第一特征标注与各所述第二特征标注之间的标注差异值;Comparing the first feature label with each of the second feature labels, and determining a label difference value between the first feature label and each of the second feature labels;
    将最大的所述标注差异值对应第二特征标注记录为所述目标表情特征。Record the second feature label corresponding to the largest label difference value as the target expression feature.
  13. 如权利要求9所述的计算机设备,其中,所述将所述目标表情特征输入至预设表情编码系统中之前,所述处理器执行所述计算机可读指令时还实现如下步骤:The computer device according to claim 9, wherein before the input of the target facial expression feature into the preset facial expression coding system, the processor further implements the following steps when executing the computer-readable instruction:
    获取对预设人脸图像进行区域划分之后得到的多个肌肉运动单元,一个所述肌肉运动单元关联一个表情编码;Obtain multiple muscle movement units obtained after the preset face image is divided into regions, and each of the muscle movement units is associated with an expression code;
    获取预设表情图像集;所述预设表情图像集中包含至少一张微表情样本图像;一个微表情样本图像关联一个表情标签;Obtaining a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
    对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,确定与所述样本图像特征对应的所有表情运动单元;After pixel labeling is performed on the micro-expression sample image to obtain the sample image features corresponding to the micro-expression sample image, all expression motion units corresponding to the sample image features are determined;
    将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,并根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联;Each described expression movement unit is classified into the described muscle movement unit matched with it, and according to the expression code associated with its matching muscle movement unit, an expression sub-code is set for each expression movement unit, and the expression sub-code is set. encoding is associated with the expression encoding;
    将与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合;Correspondingly record the expression label, the expression sub-code and the expression code corresponding to the same micro-expression sample image as the coding combination of the micro-expression sample image;
    根据各所述微表情样本图像的编码组合构建预设表情编码系统。A preset expression encoding system is constructed according to the encoding combinations of the micro-expression sample images.
  14. 如权利要求13所述的计算机设备,其中,所述将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别,包括:The computer device according to claim 13, wherein the inputting the target facial expression feature into a preset facial expression coding system to determine the target facial expression category corresponding to the target facial expression feature comprises:
    获取第一特征标注对应的各第一运动单元,以及与所述目标表情特征对应的各第二运动单元;所述第一特征标注是通过对第一人脸图像进行像素标注得到;Obtain each first motion unit corresponding to the first feature label, and each second motion unit corresponding to the target expression feature; the first feature label is obtained by performing pixel labeling on the first face image;
    将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元;recording the second motion unit different from the first motion unit as the motion unit to be matched;
    确定与所述待匹配运动单元匹配的肌肉运动单元,并自预设表情编码系统中获取与其匹配的肌肉运动单元的表情编码;Determine the muscle movement unit matched with the described movement unit to be matched, and obtain the expression code of the muscle movement unit matched with it from the preset expression coding system;
    自所述表情编码中,确定与所述待匹配运动单元对应的表情子编码;From the expression encoding, determine the expression sub encoding corresponding to the motion unit to be matched;
    根据确定的所述表情编码以及所述表情子编码,确定与所述目标表情特征对应的目标表情类别。According to the determined expression code and the expression sub-code, a target expression category corresponding to the target expression feature is determined.
  15. 一个或多个存储有计算机可读指令的可读存储介质,其中,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:One or more readable storage media storing computer-readable instructions, wherein the computer-readable instructions, when executed by one or more processors, cause the one or more processors to perform the following steps:
    在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;Acquire the face image of the driver in real time during the driving of the vehicle, and associate and record the acquired face image as a sequence of face images according to the acquisition sequence;
    检测所述人脸图像序列中的人脸图像是否发生微表情变化,并在检测到人脸图像发生微表情变化时,获取微表情变化之后的人脸图像的目标表情特征;Detecting whether the facial images in the sequence of facial images have micro-expression changes, and when detecting that the facial images have micro-expression changes, acquiring the target expression features of the facial images after the micro-expression changes;
    将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别;Inputting the target facial expression feature into a preset facial expression coding system, and determining the target facial expression category corresponding to the target facial expression feature;
    若所述目标表情类别属于预设危险表情类别,则通过多轮对话装置与所述驾驶员进行对话,并获取驾驶员的对话信息;If the target expression category belongs to the preset dangerous expression category, conduct a dialogue with the driver through a multi-round dialogue device, and obtain the dialogue information of the driver;
    提取所述对话信息中所述驾驶员的声纹特征,根据所述声纹特征与预设疲劳度量表确定所述驾驶员是否存在疲劳驾驶;extracting the voiceprint features of the driver in the dialogue information, and determining whether the driver has fatigued driving according to the voiceprint features and a preset fatigue scale;
    在确定所述驾驶员存在疲劳驾驶时,根据所述声纹特征以及所述目标表情类别触发危险驾驶语音提示。When it is determined that the driver is driving fatigued, a dangerous driving voice prompt is triggered according to the voiceprint feature and the target expression category.
  16. 如权利要求15所述的可读存储介质,其中,所述在车辆行驶过程中实时获取驾驶员的人脸图像,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列,包括:The readable storage medium according to claim 15 , wherein the acquiring the face image of the driver in real time during the driving of the vehicle, and recording the acquired face images as a sequence of face images in an order of acquisition, comprises:
    在车辆行驶过程中,通过预设拍摄设备拍摄预设范围内的图像;During the driving process of the vehicle, the image within the preset range is shot by the preset shooting device;
    在所述预设拍摄设备拍摄到驾驶员的人脸图像时,将获取的所述人脸图像按照获取顺序关联记录为人脸图像序列;When the preset photographing device captures the face image of the driver, the obtained face image is associated and recorded as a sequence of face images according to the acquisition sequence;
    在所述预设拍摄设备在预设范围内未拍摄到驾驶员的人脸图像时,触发危险驾驶提示,并在重新拍摄到包含驾驶员的人脸图像时,停止危险驾驶提示。When the preset photographing device fails to photograph the driver's face image within the preset range, the dangerous driving prompt is triggered, and when the driver's face image is re-shot, the dangerous driving prompt is stopped.
  17. 如权利要求15所述的可读存储介质,其中,所述检测所述人脸图像序列中的人脸图像是否发生微表情变化,包括:The readable storage medium according to claim 15, wherein the detecting whether the facial images in the sequence of facial images have micro-expression changes, comprising:
    将所述人脸图像序列中第一帧人脸图像记录为初始人脸图像,并对所述初始人脸图像进行像素标注,得到与所述初始人脸图像对应的初始特征标注;recording the first frame of face image in the face image sequence as an initial face image, and performing pixel labeling on the initial face image to obtain an initial feature label corresponding to the initial face image;
    将所述人脸图像序列中与所述初始人脸图像对应的下一帧人脸图像记录为对比人脸图像,并对所述对比人脸图像进行像素标注,得到与所述对比人脸图像对应的对比特征标注;Recording the next frame of face image corresponding to the initial face image in the face image sequence as a comparison face image, and performing pixel labeling on the comparison face image to obtain the comparison face image with the comparison face image Corresponding contrast feature annotation;
    将所述初始特征标注与所述对比特征标注进行像素特征比较,确定所述初始特征标注与所述对比特征标注之间的标注差异值;performing pixel feature comparison between the initial feature annotation and the comparison feature annotation, and determining the annotation difference value between the initial feature annotation and the comparison feature annotation;
    将所述标注差异值与预设差异阈值进行比较;comparing the marked difference value with a preset difference threshold;
    在所述标注差异值大于或等于预设差异阈值时,提示所述人脸图像序列中的人脸图像发生微表情变化,并将所述初始人脸图像记录为第一人脸图像,将所述对比人脸图像以及排序在对比人脸图像之后的人脸图像关联记录为第二人脸图像。When the marked difference value is greater than or equal to the preset difference threshold, prompt the facial images in the sequence of facial images to have micro-expression changes, record the initial facial image as the first facial image, and record all the facial images as the first facial image. The above-mentioned comparison face images and the face images ranked after the comparison face images are associated and recorded as the second face image.
  18. 如权利要求15所述的可读存储介质,其中,所述目标表情特征是指所有第二人脸图像中与第一人脸图像差异最大的表情特征;第一人脸图像是指微表情变化之前的首个第一微表情类型的人脸图像;第二人脸图像是指所述人脸图像序列中与第一人脸图像连续的后端序列段中的人脸图像,所述后端序列段中的所有第二人脸图像均为第二微表情类型;所述获取微表情变化之后的人脸图像的目标表情特征,包括:The readable storage medium according to claim 15, wherein the target facial expression feature refers to the facial expression feature with the largest difference from the first facial image in all the second facial images; the first facial image refers to the change of micro-expression The first face image of the first micro-expression type before; the second face image refers to the face image in the back-end sequence segment that is continuous with the first face image in the face image sequence, and the back-end All the second face images in the sequence segment are of the second micro-expression type; the acquisition of the target expression features of the face images after the micro-expression changes includes:
    对所述第一人脸图像进行像素标注,得到与所述第一人脸图像对应的第一特征标注;performing pixel labeling on the first face image to obtain a first feature label corresponding to the first face image;
    对所有所述第二人脸图像进行像素标注,得到与各所述第二人脸图像对应的第二特征标注;Perform pixel labeling on all the second face images to obtain second feature labels corresponding to each of the second face images;
    将所述第一特征标注与各所述第二特征标注进行比对,确定所述第一特征标注与各所述第二特征标注之间的标注差异值;Comparing the first feature label with each of the second feature labels, and determining a label difference value between the first feature label and each of the second feature labels;
    将最大的所述标注差异值对应第二特征标注记录为所述目标表情特征。Record the second feature label corresponding to the largest label difference value as the target expression feature.
  19. 如权利要求15所述的可读存储介质,其中,所述将所述目标表情特征输入至预设表情编码系统中之前,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器还执行如下步骤:16. The readable storage medium of claim 15, wherein, before the input of the target expression feature into the preset expression encoding system, the computer-readable instructions, when executed by one or more processors, cause the The one or more processors also perform the following steps:
    获取对预设人脸图像进行区域划分之后得到的多个肌肉运动单元,一个所述肌肉运动单元关联一个表情编码;Obtain multiple muscle movement units obtained after the preset face image is divided into regions, and each of the muscle movement units is associated with an expression code;
    获取预设表情图像集;所述预设表情图像集中包含至少一张微表情样本图像;一个微表情样本图像关联一个表情标签;Obtaining a preset expression image set; the preset expression image set includes at least one micro-expression sample image; a micro-expression sample image is associated with an expression label;
    对所述微表情样本图像进行像素标注得到与该微表情样本图像对应的样本图像特征之后,确定与所述样本图像特征对应的所有表情运动单元;After pixel labeling is performed on the micro-expression sample image to obtain the sample image features corresponding to the micro-expression sample image, all expression motion units corresponding to the sample image features are determined;
    将各所述表情运动单元归类至与其匹配的所述肌肉运动单元中,并根据与其匹配的肌肉运动单元关联的表情编码为每一个表情运动单元设置一个表情子编码,并将所述表情子编码与所述表情编码关联;Each described expression movement unit is classified into the described muscle movement unit matched with it, and according to the expression code associated with its matching muscle movement unit, an expression sub-code is set for each expression movement unit, and the expression sub-code is set. encoding is associated with the expression encoding;
    将与同一个微表情样本图像对应的表情标签、表情子编码以及表情编码关联记录为所述微表情样本图像的编码组合;Correspondingly record the expression label, the expression sub-code and the expression code corresponding to the same micro-expression sample image as the coding combination of the micro-expression sample image;
    根据各所述微表情样本图像的编码组合构建预设表情编码系统。A preset expression encoding system is constructed according to the encoding combination of each of the micro-expression sample images.
  20. 如权利要求19所述的可读存储介质,其中,所述将所述目标表情特征输入至预设表情编码系统中,确定与所述目标表情特征对应的目标表情类别,包括:The readable storage medium according to claim 19, wherein the inputting the target facial expression feature into a preset facial expression coding system to determine the target facial expression category corresponding to the target facial expression feature comprises:
    获取第一特征标注对应的各第一运动单元,以及与所述目标表情特征对应的各第二运动单元;所述第一特征标注是通过对第一人脸图像进行像素标注得到;Obtain each first motion unit corresponding to the first feature label, and each second motion unit corresponding to the target expression feature; the first feature label is obtained by performing pixel labeling on the first face image;
    将与所述第一运动单元不同的所述第二运动单元记录为待匹配运动单元;recording the second motion unit different from the first motion unit as the motion unit to be matched;
    确定与所述待匹配运动单元匹配的肌肉运动单元,并自预设表情编码系统中获取与其 匹配的肌肉运动单元的表情编码;Determine the muscle movement unit matched with the described movement unit to be matched, and obtain the expression code of the muscle movement unit matched with it from the preset expression coding system;
    自所述表情编码中,确定与所述待匹配运动单元对应的表情子编码;From the expression encoding, determine the expression sub encoding corresponding to the motion unit to be matched;
    根据确定的所述表情编码以及所述表情子编码,确定与所述目标表情特征对应的目标表情类别。According to the determined expression code and the expression sub-code, a target expression category corresponding to the target expression feature is determined.
PCT/CN2021/125225 2020-12-28 2021-10-21 Dangerous driving early warning method and apparatus, computer device and storage medium WO2022142614A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011584251.0A CN112820072A (en) 2020-12-28 2020-12-28 Dangerous driving early warning method and device, computer equipment and storage medium
CN202011584251.0 2020-12-28

Publications (1)

Publication Number Publication Date
WO2022142614A1 true WO2022142614A1 (en) 2022-07-07

Family

ID=75854947

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/125225 WO2022142614A1 (en) 2020-12-28 2021-10-21 Dangerous driving early warning method and apparatus, computer device and storage medium

Country Status (2)

Country Link
CN (1) CN112820072A (en)
WO (1) WO2022142614A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115359545A (en) * 2022-10-19 2022-11-18 深圳海星智驾科技有限公司 Staff fatigue detection method and device, electronic equipment and storage medium

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112820072A (en) * 2020-12-28 2021-05-18 深圳壹账通智能科技有限公司 Dangerous driving early warning method and device, computer equipment and storage medium
CN113276827A (en) * 2021-05-26 2021-08-20 朱芮叶 Control method and system for electric automobile energy recovery system and automobile
CN114022944A (en) * 2022-01-05 2022-02-08 北京国信网联科技有限公司 Intelligent monitoring system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120229248A1 (en) * 2011-03-12 2012-09-13 Uday Parshionikar Multipurpose controller for electronic devices, facial expressions management and drowsiness detection
CN106541915A (en) * 2016-11-28 2017-03-29 墨宝股份有限公司 A kind of electric automobile safety pre-warning system and its method for early warning
CN109598899A (en) * 2018-11-09 2019-04-09 南京大学 A kind of system and method for personalization fatigue monitoring and prompting
CN110091874A (en) * 2019-05-07 2019-08-06 绍兴天宏激光科技有限公司 A kind of safety driving system and recognition methods based on Expression Recognition
CN112820072A (en) * 2020-12-28 2021-05-18 深圳壹账通智能科技有限公司 Dangerous driving early warning method and device, computer equipment and storage medium

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103824059B (en) * 2014-02-28 2017-02-15 东南大学 Facial expression recognition method based on video image sequence
CN105354986B (en) * 2015-11-12 2017-12-01 熊强 Driver's driving condition supervision system and method
CN106650633A (en) * 2016-11-29 2017-05-10 上海智臻智能网络科技股份有限公司 Driver emotion recognition method and device
GB2579656A (en) * 2018-12-11 2020-07-01 Ge Aviat Systems Ltd Method of assessing a pilot emotional state
CN109766461A (en) * 2018-12-15 2019-05-17 深圳壹账通智能科技有限公司 Photo management method, device, computer equipment and medium based on micro- expression
CN109795319A (en) * 2019-01-15 2019-05-24 威马智慧出行科技(上海)有限公司 Detection and the methods, devices and systems for intervening driver tired driving
US11875603B2 (en) * 2019-04-30 2024-01-16 Hewlett-Packard Development Company, L.P. Facial action unit detection
CN110399793A (en) * 2019-06-19 2019-11-01 深圳壹账通智能科技有限公司 Driving behavior method for early warning, device and computer equipment based on image recognition

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120229248A1 (en) * 2011-03-12 2012-09-13 Uday Parshionikar Multipurpose controller for electronic devices, facial expressions management and drowsiness detection
CN106541915A (en) * 2016-11-28 2017-03-29 墨宝股份有限公司 A kind of electric automobile safety pre-warning system and its method for early warning
CN109598899A (en) * 2018-11-09 2019-04-09 南京大学 A kind of system and method for personalization fatigue monitoring and prompting
CN110091874A (en) * 2019-05-07 2019-08-06 绍兴天宏激光科技有限公司 A kind of safety driving system and recognition methods based on Expression Recognition
CN112820072A (en) * 2020-12-28 2021-05-18 深圳壹账通智能科技有限公司 Dangerous driving early warning method and device, computer equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115359545A (en) * 2022-10-19 2022-11-18 深圳海星智驾科技有限公司 Staff fatigue detection method and device, electronic equipment and storage medium
CN115359545B (en) * 2022-10-19 2023-01-24 深圳海星智驾科技有限公司 Staff fatigue detection method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN112820072A (en) 2021-05-18

Similar Documents

Publication Publication Date Title
WO2022142614A1 (en) Dangerous driving early warning method and apparatus, computer device and storage medium
CN105488957B (en) Method for detecting fatigue driving and device
US10311289B2 (en) Face recognition method and device and apparatus
CN106557726B (en) Face identity authentication system with silent type living body detection and method thereof
CN107895146A (en) Micro- expression recognition method, device, system and computer-readable recording medium
EP2813064A1 (en) Method and apparatus for unattended image capture
US20130271361A1 (en) Method and apparatus for detecting talking segments in a video sequence using visual cues
WO2022174699A1 (en) Image updating method and apparatus, and electronic device and computer-readable medium
US9406295B2 (en) Apparatus and method for voice based user enrollment with video assistance
CN107424266A (en) The method and apparatus of recognition of face unblock
US9633542B2 (en) Electronic device and computer-based method for reminding using the electronic device
RU2316051C2 (en) Method and system for automatically checking presence of a living human face in biometric safety systems
WO2021082045A1 (en) Smile expression detection method and apparatus, and computer device and storage medium
CN111080827A (en) Attendance system and method
CN115471824A (en) Eye state detection method and device, electronic equipment and storage medium
US11393249B2 (en) Apparatus and method of providing vehicle service based on individual emotion recognition
RU2768797C1 (en) Method and system for determining synthetically modified face images on video
US20220269761A1 (en) Cognitive multi-factor authentication
CN115147818A (en) Method and device for identifying mobile phone playing behaviors
US20230018693A1 (en) Method and system for confidence level detection from eye features
CN114510700A (en) Course supervision method and related device
WO2021095153A1 (en) Driver anomaly response system, driver anomaly response method, and program
US8379104B2 (en) Camera device and method for capturing non-blinking images of people
CN112487980A (en) Micro-expression-based treatment method, device, system and computer-readable storage medium
CN110751810A (en) Fatigue driving detection method and device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21913359

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 06-10-2023)