Child mode control method and device, computer equipment and storage medium
Automatically identifying and soothing children through image recognition technology solves the problem of driver distraction caused by the need for users to manually turn on the child mode in existing cars, achieving automatic soothing and reducing driving risks.
Patent Information
- Application Number
- CN202410662704.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-27
- Publication Date
- 2024-09-10
AI Technical Summary
Existing car child modes require users to manually turn on them, which distracts the driver and increases the risk of accidents. It is especially difficult to comfort children in time when they are crying.
Image recognition technology is used to obtain a sequence of human facial images in the cabin to determine whether there are children, and a binary classification model is used to identify the child's emotional state. When negative emotions are recognized, soothing instructions are automatically executed to reduce the user's manual operations.
It can automatically identify and comfort children without manual operation by the user, reducing driving risks and improving driving safety.
Smart Images

Figure CN118629018A
Abstract
Description
Technical Field
[0001] The present application relates to the field of vehicle control technology, and in particular to a method, device, computer equipment and storage medium for controlling a child mode. Background Art
[0002] The main purpose of car child mode is to provide additional safety features and convenience to protect the safety and comfort of child passengers.
[0003] The current child mode is mainly turned on based on the user's active operation. When the child in the car starts crying, the user actively turns on the child mode, and the car computer then executes a series of pre-set soothing instructions. This method has major flaws, especially it will distract the driver's attention, thereby affecting driving and increasing the risk of accidents. Summary of the invention
[0004] Based on this, a method, device, computer equipment and storage medium for controlling a child mode are provided to improve the problem in the prior art that users need to manually turn on the child mode to soothe their children.
[0005] On the one hand, a method for controlling a child mode is provided, comprising:
[0006] Acquire a first image sequence containing a human face in the vehicle cabin;
[0007] Acquire facial feature values according to the first image sequence, and determine whether there is a child in the car according to the facial feature values;
[0008] If yes, determining a second image sequence including the child's face from the first image sequence;
[0009] According to the second image sequence, calling a binary classification model to obtain a child emotion result, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label;
[0010] When the child's emotional result is a negative emotion, a soothing instruction is executed.
[0011] In one embodiment, acquiring facial feature values according to the first image sequence includes:
[0012] Obtaining the length of the palpebral fissure of the human face, and obtaining the morphological face length of the human face;
[0013] Determining the facial feature value according to the ratio of the palpebral fissure length to the morphological face length;
[0014] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0015] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than a length ratio threshold, it is determined that there is a child in the vehicle.
[0016] In one embodiment, acquiring facial feature values according to the first image sequence includes:
[0017] Acquire a first area of the entire human face, and acquire a second area of a characteristic part of the human face, wherein the characteristic part is an iris area;
[0018] determining the facial feature value according to a ratio of the second area to the first area;
[0019] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0020] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than the area ratio threshold value, it is determined that there is a child in the vehicle.
[0021] In one embodiment, after determining whether there is a child in the car according to the facial feature value, the method further includes:
[0022] When it is determined that there are children in the vehicle, execute child protection instructions, including:
[0023] The child lock is locked, or the air conditioning temperature and air volume are adjusted according to the preset parameters.
[0024] In one embodiment, after determining whether there is a child in the car according to the facial feature value, the method further includes:
[0025] When it is determined that there is a child in the car, judging whether there is a person other than the child in the car according to the facial feature value;
[0026] When the number of persons other than the children is zero, it is determined that a child is left behind, and a child left behind prompt instruction is executed.
[0027] In one embodiment, after determining the second image sequence containing the child's face from the first image sequence, the method further includes:
[0028] According to the second image sequence, obtaining the palpebral fissure width of the child's face;
[0029] judging whether the child has fallen asleep according to the palpebral fissure width;
[0030] When the child falls asleep, the sleep protection command is executed.
[0031] In one embodiment, executing the soothing instruction includes:
[0032] Play a preset multimedia file; or,
[0033] The second image sequence is displayed on the central control screen in the front row of the vehicle.
[0034] On the other hand, a control device for a child mode is provided, the device comprising:
[0035] An image acquisition module, used to acquire a first image sequence containing a human face in the vehicle cabin;
[0036] A facial judgment module, configured to obtain facial feature values according to the first image sequence, and judge whether there is a child in the car according to the facial feature values;
[0037] An image screening module, configured to determine a second image sequence including a child's face from the first image sequence when there is a child in the vehicle;
[0038] an emotion recognition module, configured to call a binary classification model to obtain a child emotion result according to the second image sequence, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label;
[0039] The execution module is used to execute a soothing instruction when the child's emotional result is a negative emotion.
[0040] In yet another aspect, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the steps of the method are implemented when the processor executes the computer program.
[0041] A computer-readable storage medium is also provided, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the method described are implemented.
[0042] The control method, device, computer equipment and storage medium of the child mode obtain a first image sequence containing human faces in the vehicle cabin, obtain facial feature values, and determine whether there are children based on the facial feature values. When a child appears, a second image sequence containing the child's face is determined from the first image sequence, and then a binary classification model is called to identify the child's emotions. When negative emotions are identified, soothing is automatically performed without the need for manual operation by the user, thereby reducing driving risks. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1 is a flow chart of a method for controlling a child mode in one embodiment;
[0044] Figure 2is a structural block diagram of a control device for a child mode in one embodiment;
[0045] Figure 3 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0046] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0047] Young children, especially infants, need adult care in the car, especially when they are crying or making a fuss, they need to be comforted. However, for safety reasons, children generally sit in the back seat. If the driver travels with the child alone, it is difficult for the driver to directly care for and comfort the child. Therefore, a child mode is developed in the vehicle to meet user needs.
[0048] However, generally, the child mode requires manual operation by the user to turn on. That is, when the user finds that the child in the back seat is crying, irritable, or other emotions, the user manually operates the central control interface to enter the child mode, and the car computer then executes a series of instructions related to the child mode. In this process, the user needs to always pay attention to the children in the back seat, which distracts the driving attention, and manual operation is also likely to bring driving risks.
[0049] The present application provides a method for controlling a child mode, which automatically identifies children's emotions based on image recognition technology, automatically executes soothing instructions, and reduces driving risks caused by manual operations of the driver.
[0050] like Figure 1 As shown, a method for controlling a child mode in one embodiment includes the following steps:
[0051] Step 100: Acquire a first image sequence containing human faces in a vehicle cabin.
[0052] For example, the OMS (Occupancy Monitoring System) system in the car can obtain images in the cabin at a certain frequency based on the OMS camera. The OMS system uses computer vision technology to determine whether there is a human face in the image. In this application, since the forehead area is easily blocked by hair, etc., when identifying, the line from the upper edge of the eyebrow to the lower edge of the mandible and the area between the two sides to the posterior edge of the mandibular branch is used as the human face. Computer vision technology uses, for example, feature point detection, edge detection, and region segmentation to identify human faces. Common facial detection algorithms include Haar feature classifiers, which determine whether it is a human face by calculating and comparing different features in the image; for example, deep learning methods such as convolutional neural networks are used to learn more complex and abstract facial features through a large amount of training data, thereby achieving efficient and accurate face recognition.
[0053] When a person enters the car, the OMS system can identify and filter out the first image sequence containing human faces. This process can reduce the amount of subsequent data processing.
[0054] It should be noted that the human faces in the first image sequence may be those of adults or children, or both.
[0055] Step 200: Obtain facial feature values according to the first image sequence, and determine whether there is a child in the car according to the facial feature values.
[0056] There are some differences between an adult's face and a child's face in various aspects, including the following dimensions:
[0057] Eye socket depth: Adults' eyes are generally deeper-set than children's, and the eye sockets are more pronounced.
[0058] Nose size: An adult's nose is generally larger and more prominent than a child's nose.
[0059] Mouth width: An adult's mouth is generally wider than a child's, and the shape of the lips may also change.
[0060] Mandibular prominence: Adults usually have a more prominent mandible, whereas children have a smaller mandible.
[0061] It's important to note that children's facial features change as they age, so these differences may fade over time.
[0062] In the actual implementation process, individual or combined judgments are made based on the differences in the above dimensions. The facial feature values of each dimension provide corresponding judgment components for the judgment results based on their corresponding judgment conditions, and the final judgment result is obtained after the various judgment components are combined.
[0063] Exemplarily, in one embodiment, step 200 includes the following sub-steps:
[0064] Step 210, obtaining the length of the palpebral fissure of the human face, and obtaining the morphological face length of the human face.
[0065] The palpebral fissure refers to the gap between the upper and lower eyelids of the human eye. The length of the palpebral fissure is also the length of the eyelid fissure. The palpebral fissure increases with the growth of the face. After a certain age (generally 10-12 years old), the change range becomes smaller. In the general population, the length of the palpebral fissure in adults is generally 25-30 mm.
[0066] The morphological face length, also known as the morphological face height, refers to the straight-line distance from the root of the nose to the subchin point. In the commonly collected images of human faces in cars, the forehead part of the face is easily blocked by hair, etc., while the morphological face length is not easily affected by occlusion.
[0067] The morphological face length is related to the development of bones and muscles during the growth process. When a baby is born, the morphological face height is relatively small, usually about half of that of an adult. From about two to twelve years old, the growth rate of the child's morphological face length begins to slow down. Generally, around the age of twenty, the human body's skeletal and muscle development is basically completed, and the morphological face length enters a stable stage.
[0068] Step 211, determining the facial feature value according to the ratio of the palpebral fissure length to the morphological face length.
[0069] That is, in this embodiment, facial feature value = palpebral fissure length / morphological face length.
[0070] Step 212, performing a threshold determination based on the facial feature value, and when the facial feature value is greater than a length ratio threshold, determining that there is a child in the vehicle.
[0071] Children's facial length is shorter, while the length of their palpebral fissures is not much different from that of adults. Therefore, children's facial feature values are larger, while adults' facial feature values are smaller.
[0072] The length ratio threshold was calibrated based on the distribution of the ratio of palpebral fissure length to morphofacial length in children and adults.
[0073] In another implementation of this embodiment, another method for determining facial feature values is provided. Specifically, step 200 includes:
[0074] Step 220, obtaining a first area of the entire human face, and obtaining a second area of a characteristic part of the human face, wherein the characteristic part is an iris area.
[0075] The iris is a colored ring-shaped structure located in the middle of the eyeball. In this embodiment, the iris region includes the pupil portion in the middle, and the iris region appears as a circular dark-colored region.
[0076] After acquiring the above-mentioned first image sequence, the OMS system analyzes and processes the images in the first image sequence to obtain the facial image of the user contained in the image. The first area of the entire human face (i.e., the line starting from the upper edge of the eyebrow, extending to the lower edge of the mandible, and the area between the posterior edge of the mandibular branch on both sides) is obtained by counting the pixels of the facial image.
[0077] The facial image is further segmented to obtain an image of the characteristic part, and the second area of the characteristic part is obtained by counting the pixel points of the image of the characteristic part.
[0078] In the above process, the Active Appearance Model (AAM) is exemplarily used to extract facial contour features and geometric features of characteristic parts, etc. The specific implementation process will not be repeated here.
[0079] Step 221: Determine the facial feature value according to the ratio of the second area to the first area.
[0080] That is, in this embodiment, the facial feature value = the second area / the first area.
[0081] Step 222, performing a threshold determination based on the facial feature value, and when the facial feature value is greater than the area ratio threshold, determining that there is a child in the vehicle.
[0082] In the facial images of children and adults, the proportion of the eyes in the face is often different. During the development of the human body, the change in facial size is a continuous process. In infancy, the face is generally small. As the body grows, the face gradually becomes larger and adapts to the growth of the head. Adolescence is an important stage in facial development. At this time, due to the influence of hormones, facial features begin to mature, including changes in the jaw and adjustments to the facial contour. After adulthood, the size of the face will gradually stabilize. As for the iris in the eye, as the individual grows and develops, the size of the iris will gradually increase with the development of the eyeball, but there will generally be no significant changes, and in the main population, the size error of the iris is subtle.
[0083] The area ratio threshold is obtained by calibrating the typical distribution of the iris area of children and adults in the facial area.
[0084] In actual implementation, the iris area in the facial image may be blocked by the eyelids. Directly using the number of image pixels in the iris area as the area may result in inaccurate calculation results. As a further improvement, obtaining the second area of the characteristic part of the human face includes:
[0085] The diameter of the iris region is determined according to the distance between the farthest pixels in the image of the iris region to calculate the area of the iris region, and the calculated area of the iris region is used as the second area.
[0086] Furthermore, a relatively stable second area is obtained by filtering the calculated value.
[0087] After determining that there is a child in the vehicle through step 200, on the one hand, a child protection instruction is executed, such as locking the child lock, or adjusting the air conditioning temperature and air volume according to preset parameters, etc., and on the other hand, it also includes:
[0088] Step 300: Determine a second image sequence containing a child's face from the first image sequence.
[0089] As mentioned above, the human faces in the first image sequence may be adults or children, or both. Step 300 selects images containing children from the first image sequence and removes images containing only adults. This process can significantly reduce the amount of subsequent data processing.
[0090] Step 400: Based on the second image sequence, a binary classification model is called to obtain a child emotion result.
[0091] Since children, especially infants, have incompletely developed faces, the way of emotion recognition using machine vision is quite different from that of adults. In adult emotion recognition, the facial expressions of adults can accurately reflect emotions such as happiness, anger, sadness, fear, surprise, disgust, and shame, but children cannot make such accurate expressions. Therefore, the emotion recognition model trained based on adult expressions will have large errors when recognizing the emotions of children, especially infants.
[0092] In this embodiment, the binary classification model is trained based on training data containing children's facial images, and the training data includes positive emotion labels and negative situation labels.
[0093] A binary classification model is a model that divides input data into two categories, such as logistic regression models, logic tree models, and deep learning models that handle binary classification problems. Compared with large neural networks that can recognize more emotions, binary classification models have smaller parameters and require fewer computing resources for model training, so training can be completed in a shorter time. In addition, the binary classification model has a faster inference speed and can make rapid predictions in real-time applications, making it suitable for vehicle child mode scenarios that require real-time decision-making. On the other hand, precisely because the binary classification model has a small number of parameters and the input image data is screened multiple times, the binary classification model consumes fewer computing resources when it is called, which is conducive to the deployment of binary classification models on cars with limited computing power.
[0094] The binary classification model is trained using training data labeled with positive emotion labels and negative situation labels. Therefore, the output result of the binary classification model indicates whether the child in the car currently has a positive emotion or a negative emotion.
[0095] In particular, children’s negative emotions are mainly divided into crying and irritability, and all emotions except negative emotions can be regarded as positive emotions.
[0096] Step 500: When the child's emotion result is a negative emotion, execute a soothing instruction.
[0097] If a child is identified to be showing negative emotions, especially when the identification result of negative emotions lasts for a certain period of time, pre-set soothing instructions can be executed, such as playing preset multimedia files, such as music and videos suitable for soothing children, or displaying the obtained second image sequence (that is, the current image containing the child's face) on the vehicle's central control screen for the driver sitting in the front row to view.
[0098] This application selects images containing children's faces from the image sequence inside the car through screening and identification, and performs emotion recognition through a binary classification model to determine whether the child is currently experiencing negative emotions. When negative emotions occur, the application actively comforts the child, without the need for the user to manually enter the child mode, thereby reducing driving risks.
[0099] In particular, the image screening process significantly reduces the amount of data input into the binary classification model and ensures that the data input into the binary classification model are all data containing children's facial images. Image data containing only adults is screened out, which is conducive to the binary classification model to obtain accurate recognition results.
[0100] In one embodiment, it is also identified whether the child has entered a sleeping state. For example, when it is determined that there is a child in the car, after determining the second image sequence including the child's face from the first image sequence, the palpebral fissure width of the child's face is obtained according to the second image sequence. The palpebral fissure width is the maximum distance between the upper and lower eyelids. Whether the child has entered a sleeping state is determined based on the palpebral fissure width. When the palpebral fissure width is zero for a long time, it can be considered that the child has entered a sleeping state, and sleep protection instructions can be executed, such as turning off music, video, rear windows, rear lights and sunroof shades.
[0101] In one embodiment, the child mode also monitors whether a child is left alone in the car. During the left-behind monitoring, when it is determined that there is a child in the car, it is determined whether there are people other than children in the car based on the facial feature values; when the number of people other than children is zero, it is determined that a child is left in the car, and a child left-behind prompt instruction is executed, such as sending a message with specific prompt content to a bound mobile device. If an abnormality or crying state occurs, a photo is taken and uploaded to the user's mobile phone.
[0102] It should be understood that although Figure 1 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1 At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.
[0103] In one embodiment, Figure 2 As shown, a control device for a child mode is provided, comprising: an image acquisition module 10, a face determination module 20, an image screening module 30, an emotion recognition module 40 and an execution module 50, wherein:
[0104] An image acquisition module 10 is used to acquire a first image sequence containing a human face in the vehicle cabin;
[0105] A facial recognition module 20 is used to obtain facial feature values according to the first image sequence, and to judge whether there is a child in the car according to the facial feature values;
[0106] The image screening module 30 is used to determine a second image sequence including a child's face from the first image sequence when there is a child in the vehicle;
[0107] The emotion recognition module 40 is used to call a binary classification model to obtain a child emotion result according to the second image sequence, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label;
[0108] The execution module 50 is used to execute a soothing instruction when the child's emotional result is a negative emotion.
[0109] The control device of the child mode obtains a first image sequence containing human faces in the vehicle cabin, obtains facial feature values, and determines whether there are children based on the facial feature values. When a child appears, a second image sequence containing the child's face is determined from the first image sequence, and then a binary classification model is called to identify the child's emotions. When negative emotions are identified, the child is automatically soothed without the need for manual operation by the user, thereby reducing driving risks.
[0110] In one embodiment, the facial determination module 20 obtains facial feature values according to the first image sequence, including:
[0111] Obtaining the length of the palpebral fissure of the human face, and obtaining the morphological face length of the human face;
[0112] Determining the facial feature value according to the ratio of the palpebral fissure length to the morphological face length;
[0113] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0114] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than a length ratio threshold, it is determined that there is a child in the vehicle.
[0115] In one embodiment, the facial determination module 20 obtains facial feature values according to the first image sequence, including:
[0116] Acquire a first area of the entire human face, and acquire a second area of a characteristic part of the human face, wherein the characteristic part is an iris area;
[0117] determining the facial feature value according to a ratio of the second area to the first area;
[0118] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0119] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than the area ratio threshold value, it is determined that there is a child in the vehicle.
[0120] In one embodiment, the execution module 50 is further configured to execute child protection instructions, including locking the child lock, or adjusting the air conditioning temperature and air volume according to preset parameters, when it is determined that there is a child in the vehicle.
[0121] In one embodiment, it also includes a child status judgment module, which is used to judge whether the child has fallen asleep. Specifically, the child status judgment module obtains the palpebral fissure width of the child's face according to the second image sequence; and judges whether the child has fallen asleep according to the palpebral fissure width. When the child is sleeping, the execution module 50 executes the sleep protection instruction.
[0122] The facial recognition module is also used to determine whether there are people other than children in the car based on the facial feature values when it is determined that there are children in the car; when the number of people other than children is zero, it is determined that a child is left behind, and the execution module 50 executes a child left behind prompt instruction.
[0123] For the specific definition of the control device of the child mode, please refer to the definition of the control method of the child mode above, which will not be repeated here. Each module in the above-mentioned control device of the child mode can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0124] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 3 As shown. The computer device includes a processor, a memory, a network interface, a display screen and an input device connected through 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 non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a control method for a child mode is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.
[0125] Those skilled in the art will understand that Figure 3The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0126] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the following steps when executing the computer program:
[0127] Acquire a first image sequence containing a human face in the vehicle cabin;
[0128] Acquire facial feature values according to the first image sequence, and determine whether there is a child in the car according to the facial feature values;
[0129] If yes, determining a second image sequence including the child's face from the first image sequence;
[0130] According to the second image sequence, calling a binary classification model to obtain a child emotion result, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label;
[0131] When the child's emotional result is a negative emotion, a soothing instruction is executed.
[0132] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0133] The step of acquiring facial feature values according to the first image sequence includes:
[0134] Obtaining the length of the palpebral fissure of the human face, and obtaining the morphological face length of the human face;
[0135] Determining the facial feature value according to the ratio of the palpebral fissure length to the morphological face length;
[0136] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0137] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than a length ratio threshold, it is determined that there is a child in the vehicle.
[0138] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0139] The step of acquiring facial feature values according to the first image sequence includes:
[0140] Acquire a first area of the entire human face, and acquire a second area of a characteristic part of the human face, wherein the characteristic part is an iris area;
[0141] determining the facial feature value according to a ratio of the second area to the first area;
[0142] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0143] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than the area ratio threshold value, it is determined that there is a child in the vehicle.
[0144] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0145] After determining whether there is a child in the car according to the facial feature value, the method further includes:
[0146] When it is determined that there are children in the vehicle, execute child protection instructions, including:
[0147] The child lock is locked, or the air conditioning temperature and air volume are adjusted according to the preset parameters.
[0148] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0149] After determining whether there is a child in the car according to the facial feature value, the method further includes:
[0150] When it is determined that there is a child in the car, judging whether there is a person other than the child in the car according to the facial feature value;
[0151] When the number of persons other than the children is zero, it is determined that a child is left behind, and a child left behind prompt instruction is executed.
[0152] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0153] After determining the second image sequence containing the child's face from the first image sequence, the method further includes:
[0154] According to the second image sequence, obtaining the palpebral fissure width of the child's face;
[0155] judging whether the child has fallen asleep according to the palpebral fissure width;
[0156] When the child falls asleep, the sleep protection command is executed.
[0157] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0158] The executing of the soothing instruction includes:
[0159] Play a preset multimedia file; or,
[0160] The second image sequence is displayed on the central control screen in the front row of the vehicle.
[0161] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0162] Acquire a first image sequence containing a human face in the vehicle cabin;
[0163] Acquire facial feature values according to the first image sequence, and determine whether there is a child in the car according to the facial feature values;
[0164] If yes, determining a second image sequence including the child's face from the first image sequence;
[0165] According to the second image sequence, calling a binary classification model to obtain a child emotion result, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label;
[0166] When the child's emotional result is a negative emotion, a soothing instruction is executed.
[0167] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0168] The step of acquiring facial feature values according to the first image sequence includes:
[0169] Obtaining the length of the palpebral fissure of the human face, and obtaining the morphological face length of the human face;
[0170] Determining the facial feature value according to the ratio of the palpebral fissure length to the morphological face length;
[0171] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0172] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than a length ratio threshold, it is determined that there is a child in the vehicle.
[0173] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0174] The step of acquiring facial feature values according to the first image sequence includes:
[0175] Acquire a first area of the entire human face, and acquire a second area of a characteristic part of the human face, wherein the characteristic part is an iris area;
[0176] determining the facial feature value according to a ratio of the second area to the first area;
[0177] The determining whether there is a child in the vehicle according to the facial feature value includes:
[0178] A threshold value is judged according to the facial feature value, and when the facial feature value is greater than the area ratio threshold value, it is determined that there is a child in the vehicle.
[0179] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0180] After determining whether there is a child in the car according to the facial feature value, the method further includes:
[0181] When it is determined that there are children in the vehicle, execute child protection instructions, including:
[0182] The child lock is locked, or the air conditioning temperature and air volume are adjusted according to the preset parameters.
[0183] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0184] After determining whether there is a child in the car according to the facial feature value, the method further includes:
[0185] When it is determined that there is a child in the car, judging whether there is a person other than the child in the car according to the facial feature value;
[0186] When the number of persons other than the children is zero, it is determined that a child is left behind, and a child left behind prompt instruction is executed.
[0187] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0188] After determining the second image sequence containing the child's face from the first image sequence, the method further includes:
[0189] According to the second image sequence, obtaining the palpebral fissure width of the child's face;
[0190] judging whether the child has fallen asleep according to the palpebral fissure width;
[0191] When the child falls asleep, the sleep protection command is executed.
[0192] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing related hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile 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 many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct RAMbus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM), etc.
[0193] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0194] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A method for controlling a child mode, characterized in that: include: Acquire a first image sequence containing a human face in the vehicle cabin; Acquire facial feature values according to the first image sequence, and determine whether there is a child in the car according to the facial feature values; If yes, determining a second image sequence including the child's face from the first image sequence; According to the second image sequence, calling a binary classification model to obtain a child emotion result, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label; When the child's emotional result is a negative emotion, a soothing instruction is executed.
2. A method for controlling a child mode according to claim 1, characterized in that: The step of acquiring facial feature values according to the first image sequence includes: Obtaining the length of the palpebral fissure of the human face, and obtaining the morphological face length of the human face; Determining the facial feature value according to the ratio of the palpebral fissure length to the morphological face length; The determining whether there is a child in the vehicle according to the facial feature value includes: A threshold value is judged according to the facial feature value, and when the facial feature value is greater than a length ratio threshold, it is determined that there is a child in the vehicle.
3. A method for controlling a child mode according to claim 1, characterized in that: The step of acquiring facial feature values according to the first image sequence includes: Acquire a first area of the entire human face, and acquire a second area of a characteristic part of the human face, wherein the characteristic part is an iris area; determining the facial feature value according to a ratio of the second area to the first area; The determining whether there is a child in the vehicle according to the facial feature value includes: A threshold value is judged according to the facial feature value, and when the facial feature value is greater than the area ratio threshold value, it is determined that there is a child in the vehicle.
4. The method for controlling a child mode according to claim 1, characterized in that: After determining whether there is a child in the car according to the facial feature value, the method further includes: When it is determined that there are children in the vehicle, execute child protection instructions, including: The child lock is locked, or the air conditioning temperature and air volume are adjusted according to the preset parameters.
5. The method for controlling a child mode according to claim 1, characterized in that: After determining whether there is a child in the car according to the facial feature value, the method further includes: When it is determined that there is a child in the car, judging whether there is a person other than the child in the car according to the facial feature value; When the number of persons other than the children is zero, it is determined that a child is left behind, and a child left behind prompt instruction is executed.
6. A method for controlling a child mode according to claim 1, characterized in that: After determining the second image sequence containing the child's face from the first image sequence, the method further includes: According to the second image sequence, obtaining the palpebral fissure width of the child's face; judging whether the child has fallen asleep according to the palpebral fissure width; When the child falls asleep, the sleep protection command is executed.
7. The method for controlling a child mode according to claim 1, characterized in that: The executing of the soothing instruction comprises: Play a preset multimedia file; or, The second image sequence is displayed on the central control screen in the front row of the vehicle.
8. A control device for a child mode, characterized in that: The device comprises: An image acquisition module, used to acquire a first image sequence containing a human face in the vehicle cabin; A facial judgment module, configured to obtain facial feature values according to the first image sequence, and judge whether there is a child in the car according to the facial feature values; An image screening module, configured to determine a second image sequence including a child's face from the first image sequence when there is a child in the vehicle; an emotion recognition module, configured to call a binary classification model to obtain a child emotion result according to the second image sequence, wherein the child emotion result includes a positive emotion or a negative emotion, wherein the binary classification model is trained based on training data including child facial images, wherein the training data includes a positive emotion label and a negative emotion label; The execution module is used to execute a soothing instruction when the child's emotional result is a negative emotion.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
