Method and device for identifying handheld article, vehicle and storage medium

By acquiring and processing the driver's driving image in the vehicle, identifying the hand image area and using the target classification model for recognition, the problem of inaccurate hand movement detection in the existing technology is solved, and the accuracy and accuracy of handheld object recognition are improved. speed, enhancing the driver’s driving safety.

CN118658147APending Publication Date: 2024-09-17GREAT WALL MOTOR CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202410838433.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-26
Publication Date
2024-09-17

AI Technical Summary

Technical Problem

In the existing technology, driver hand movement detection mainly relies on human observation, which can easily lead to inaccuracies due to the distraction of the observer, resulting in insufficient accuracy and speed in identifying the items held by the driver, and cannot effectively prevent traffic accidents caused by distraction. ACCIDENT.

Method used

By acquiring the driver's driving image while the vehicle is moving, performing area detection to determine the hand image area, and using the target classification model to identify the hand image, it improves the accuracy and speed of identifying handheld objects and avoids occurrences when there is no driver. Error alert.

Benefits of technology

It improves the accuracy and speed of recognition of handheld objects, reduces the influence of background noise information, ensures the accuracy of voice warnings, and enhances the driver's driving safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118658147A
    Figure CN118658147A
Patent Text Reader

Abstract

The invention provides a method and device for identifying a handheld article, a vehicle and a storage medium. The method comprises the steps of obtaining a driving image of a driver when a vehicle runs and the driver exists in a driving position; and carrying out area detection on the driving image, and determining an image area where the hand of the driver is located from the driving image, namely, a hand image. And identifying an article held by the hand based on the hand image so as to perform voice warning when the article is a dangerous article. According to the method, the hand image is firstly determined from the driving image, then the hand image is processed, the concept of first detection and then classification is adopted, and only the hand image area of the driver is concerned, so that the influence of the background image area in the driving image on the recognition efficiency when the handheld article is recognized can be reduced. In addition, by means of the method, wrong warning and the like possibly caused by the fact that the handheld article is still recognized when no driver exists in the driving position can be avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of vehicles, and more particularly, to a method, a device, a vehicle and a storage medium for identifying a handheld object in the field of vehicles. Background Art

[0002] With the development of vehicle technology, more and more vehicles are entering people's lives. However, there are also more and more vehicle-related problems, including the problem of vehicle driving safety.

[0003] In order to solve the traffic accidents caused by the driver's distracted actions such as making phone calls during driving, the hand action detection algorithm in the prior art mainly judges the driver's hand state by manual observation. The above manual observation method often leads to inaccurate detection results due to the observer's own distraction.

[0004] Therefore, there is an urgent need for a method for identifying handheld objects to improve the accuracy of identifying objects held in the driver's hands. Summary of the invention

[0005] The present application provides a method, device, vehicle and storage medium for identifying a handheld object. The method can improve the speed and accuracy of identifying a handheld object.

[0006] In a first aspect, a method for identifying handheld items is provided, the method comprising: when a vehicle is moving and there is a driver in the driving seat, obtaining a driving image of the driver; performing area detection on the driving image to determine a hand image of the driver, the hand image including an image area where the driver's hand is located; and based on the hand image, identifying an item held in the driver's hand.

[0007] In the above technical solution, when the vehicle is running and there is a driver in the driving seat, the driving image of the driver is obtained; the driving image is detected in the region, and the image region where the driver's hand is located, that is, the hand image, is determined from the driving image. Further, based on the hand image, the object held by the driver's hand is identified so that a voice warning can be given when the object is a dangerous object. The method first determines the hand image from the driving image, and then processes the hand image to identify the object held by the hand. In other words, the method adopts the concept of first detection and then classification, and only focuses on the driver's hand image region, which can reduce the noise information brought by the background image region in the driving image, thereby affecting the speed and accuracy of identifying the handheld object. In addition, the method obtains the driving image and performs subsequent processing only when the vehicle is running and there is a driver in the driving seat, which can avoid the erroneous voice warning caused by still identifying the object held by the hand when there is no driver in the driving seat.

[0008] In combination with the first aspect, in some possible implementations, area detection is performed on the driving image to determine the hand image of the driver, including: based on multiple target areas, generating multiple circumscribed rectangular frames on the driving image, the multiple target areas are areas where the hands of multiple test subjects are located in the test image when they hold objects, and the test image and the driving image have the same image size and shooting conditions; cropping the image area enclosed by the multiple circumscribed rectangular frames in the driving image, and determining the cropped multiple image areas as the hand image.

[0009] In the above technical solution, the method generates multiple circumscribed rectangular frames on the driving image based on the target areas of the hands of multiple test subjects when they hold objects in the test image. The number of test subjects is large enough, and the image size and shooting conditions of the test image and the driving image are the same. Therefore, the method can accurately capture the driver's hand image area through multiple circumscribed rectangular frames based on multiple target areas. Furthermore, the image area surrounded by the multiple circumscribed rectangular frames is cropped, and the cropped multiple image areas are used as hand images. In this way, the method can identify the hand-held object based on the hand image, without paying attention to the background image area in the driving image, which can improve the speed and accuracy of identifying the hand-held object, and then can make accurate voice warnings.

[0010] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, multiple circumscribed rectangular frames are generated on the driving image based on multiple target areas, including: in the driving image, the bounding boxes of the image area corresponding to the multiple target areas are determined as the multiple circumscribed rectangular frames; or, based on the bounding boxes of the image area corresponding to the multiple target areas, a preset distance is extended to the outside of the multiple bounding boxes, and the multiple bounding boxes after the preset distance are extended are determined as the multiple circumscribed rectangular frames.

[0011] In the above technical solution, in the driving image, the bounding boxes of the image areas corresponding to the multiple target areas are determined as the multiple circumscribed rectangular boxes. This method completely relies on the positions of the hands of multiple test subjects when holding objects determined during the test to infer the area of ​​the driver's hands in the driving image, and can accurately determine the image area where the hands are located without increasing the image area of ​​the hand image. Or, based on the bounding boxes of the image areas corresponding to the multiple target areas, a preset distance is extended to the outside of the multiple bounding boxes, which increases the image area of ​​the hand image. However, this method does not completely rely on the positions of the hands of multiple test subjects when holding objects determined during the test, and therefore, this method can more accurately determine the image area where the driver's hands are located.

[0012] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the item held in the driver's hand is identified based on the hand image, including: inputting the hand image into a target classification model, and using the target classification model to detect the type of item held in the hand in the hand image and the corresponding probability; based on the type of item held in the hand and the corresponding probability, identifying the item held in the driver's hand.

[0013] In the above technical solution, the method processes the hand image through the target classification model to determine the type of item held by the hand in the hand image and the corresponding probability. Further, based on the type of item and the corresponding probability, the item held by the driver's hand is identified. In other words, the method identifies the item held by the driver's hand through the target classification model trained by the neural network, which can improve the accuracy of identifying the handheld item.

[0014] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the item held in the driver's hand is identified based on the type of item held in the hand and the corresponding probability, including: when the type of the item satisfies a first condition, determining that the item is a first type of item, and the first condition is that the type of the item is the first type and the corresponding probability is greater than or equal to a first probability threshold; when the type of the item satisfies a second condition, determining the type of item held in the driver's hand at each of multiple moments after a first moment and the corresponding probability, the second condition includes that the type of the item is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to the second probability threshold, and the first moment is the moment when the driving image is acquired; based on the type of item held in the hand at each of the multiple moments and the corresponding probability, and the time interval between adjacent moments, the item held in the driver's hand is identified.

[0015] In the above technical solution, when the type of the item is the first type and the corresponding probability is greater than or equal to the first probability threshold, the item is determined to be the first type of item. When the type of the item meets the second condition (the second condition includes that the type of the item is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to the second probability threshold), the type of the item held by the driver's hand at each of the multiple moments after the first moment and the corresponding probability are determined; then based on the type of the item held by the hand at each of the multiple moments and the corresponding probability, and the time interval between adjacent moments, the item held by the driver's hand is identified. In other words, the item held by the driver's hand can be identified based on a single-frame driving image. In order to improve the accuracy of identifying handheld items, the method also considers the item recognition results corresponding to the multiple frames of driving images following the single frame. In other words, the hand states in the multiple frames of driving images are statistically analyzed, and the handheld items are determined based on the long-term statistical results.

[0016] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, based on the types of items held by the hand at each of the multiple moments and the corresponding probabilities, and the time interval between adjacent moments, the item held by the driver's hand is identified, including: determining a first number corresponding to multiple time periods in which the item type continuously meets the first condition, and a second number corresponding to multiple time periods in which the item type continuously does not meet the first condition among the types of items held by the hand at the multiple moments; determining a first duration in which the item is an item of the first category in each time period based on the first number corresponding to the multiple time periods and the time interval; in the process of determining a preset cumulative duration in which the item is an item of the first category based on the first time period corresponding to each time period, determining a first cumulative duration in which the item is not an item of the first category within the preset cumulative duration based on the second number corresponding to the multiple time periods and the time interval; when the first cumulative duration is less than the preset duration, determining that the item is an item of the first category; when the first cumulative duration is greater than or equal to the preset duration, determining that the item is not an item of the first category.

[0017] In the above technical solution, the number (first number) corresponding to the multiple time periods in which the item type meets the first condition in succession and the number (second number) corresponding to the multiple time periods in which the item type does not meet the first condition in succession are counted for the item types held by the hand at the multiple moments and the corresponding probabilities, and the first duration of the item being the first type of item in each time period is determined. Further, in the process of determining that the item is the first type of item based on the first duration and reaches the preset cumulative duration, the duration (first cumulative duration) in which the item is not the first type of item within the preset cumulative duration is determined; and then based on the size relationship between the first cumulative duration and the preset duration, the handheld item is identified. That is, the method adopts a two-layer probability threshold, and when the probability corresponding to the item type of a single-frame driving image is a low probability, the hand state in the multiple-frame driving image is counted and a smoothing strategy is performed. When the method identifies the handheld item as the first type of item, in the process of the duration of the item being the first type of item reaching the preset cumulative duration, the duration of the item not being the first type of item within the preset cumulative duration is allowed to be less than the preset duration. This can maximize the use of time to identify handheld objects, while taking into account possible instability in the target classification model and improving the accuracy of handheld object recognition.

[0018] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, when the first cumulative time is greater than or equal to the preset time, determining that the item is not an item of the first category includes: when the first cumulative time is greater than or equal to the preset time, recounting the duration of time that the item is an item of the first category; during the process when the duration reaches the preset cumulative time, when it is detected that the item is not an item of the first category, continuing to accumulate time based on the original cumulative time that the item is not an item of the first category; when the accumulated time is greater than or equal to the preset time, determining that the item is not an item of the first category.

[0019] In the above technical solution, when the first accumulated time is greater than or equal to the preset time, the method re-counts the duration of the item being an item of the first category, which is equivalent to re-determining the item category of the item. In the process of counting the duration to reach the preset accumulated time, if the item is not an item of the first category, the method continues to accumulate the time based on the original accumulated time (the accumulated time that the item is not an item of the first category), and then compares the accumulated time with the preset time to determine the item category of the item. In other words, the method comprehensively determines the item category based on the accumulated time that the item is not an item of the first category during the process of counting the duration of the item being an item of the first category to reach the preset accumulated time. Therefore, the method can determine the item category more accurately.

[0020] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, area detection is performed on the driving image to determine the hand image of the driver, including: inputting the driving image into a hand detection model, and performing feature extraction on the driving image by the hand detection model to obtain a target feature, and the target feature is used to describe the hand feature in the driving image; the hand detection model detects the image area where the hand in the driving image is located based on the target feature, and determines the image area where the hand detected in the driving image is located as the hand image.

[0021] In the above technical solution, the method detects the image area where the hand is located in the driving image based on the hand features by the hand detection model. Since the hand detection model is trained based on the neural network technology, the method can detect an accurate hand image through the hand detection model.

[0022] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the method also includes any one of the following: when the object is a mobile phone, outputting a first reminder message, and the first reminder message is used to remind the driver not to play with the mobile phone during driving; or, when the object is a water cup, controlling the vehicle to drive through the automatic driving system; or, when the object is a cigarette, controlling the steering wheel to vibrate with a first preset intensity.

[0023] In the above technical solution, when the object is a mobile phone, a first reminder message is output. This method can remind the driver not to play with the mobile phone when the driver plays with the mobile phone during driving, so as to improve the driver's driving safety. Or, when the object is a water cup, the vehicle is controlled to travel by the automatic driving system, which can not only enable the driver to replenish water in time when thirsty, but also avoid traffic accidents during driving. Or, when the object is a cigarette, the steering wheel is controlled to vibrate with a first preset intensity. This method can vibrate the steering wheel with a first preset intensity when the driver smokes during driving, which can not only achieve a good reminder effect, but also avoid affecting driving safety.

[0024] In a second aspect, a device for identifying handheld objects is provided, the device comprising: an acquisition module for acquiring a driving image of the driver when a vehicle is moving and there is a driver in the driving seat; a determination module for performing area detection on the driving image to determine a hand image of the driver, the hand image including an image area where the driver's hand is located; and a recognition module for identifying an object held in the driver's hand based on the hand image.

[0025] In combination with the second aspect, in some possible implementations, the device also includes: a generation module, used to generate multiple circumscribed rectangular frames on the driving image based on multiple target areas, the multiple target areas are the areas where the hands of multiple test subjects are located in the test image when they hold objects, and the image size and shooting conditions of the test image and the driving image are the same; a determination module, specifically used to crop the image area enclosed by the multiple circumscribed rectangular frames in the driving image, and determine the cropped multiple image areas as the hand image.

[0026] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the generation module is specifically used to: in the driving image, determine the bounding boxes of the image area corresponding to the multiple target areas as the multiple circumscribed rectangular boxes; or, on the basis of the bounding boxes of the image area corresponding to the multiple target areas, extend a preset distance to the outside of the multiple bounding boxes, and determine the multiple bounding boxes after extending the preset distance as the multiple circumscribed rectangular boxes.

[0027] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the recognition module is specifically used to: input the hand image into a target classification model, and the target classification model detects the types of items held by the hand in the hand image and the corresponding probabilities; based on the types of items held by the hand and the corresponding probabilities, identify the items held in the driver's hand.

[0028] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the determination module is also used to: determine that the item is a first type of item when the item type satisfies a first condition, and the first condition is that the item type is the first type and the corresponding probability is greater than or equal to a first probability threshold; determine the type of item held in the driver's hand at each of multiple moments after the first moment and the corresponding probability when the item type satisfies a second condition, and the second condition includes that the item type is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to the second probability threshold, and the first moment is the moment when the driving image is acquired; the identification module is specifically used to identify the item held in the driver's hand based on the type of item held in the hand at each of the multiple moments and the corresponding probability, and the time interval between adjacent moments.

[0029] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the determination module is also used to: determine the types of items held by the hand at the multiple moments and the first number corresponding to the multiple time periods in which the type of item meets the first condition continuously, and the second number corresponding to the multiple time periods in which the type of item does not meet the first condition continuously in the corresponding probabilities; determine the first duration in each time period that the item is an item of the first type based on the first number corresponding to the multiple time periods and the time interval; in the process of determining the preset cumulative duration that the item is an item of the first type based on the first time period corresponding to each time period, determine the first cumulative duration that the item is not an item of the first type within the preset cumulative duration based on the second number corresponding to the multiple time periods and the time interval; the identification module is specifically further used to: determine that the item is an item of the first type when the first cumulative duration is less than the preset duration; and determine that the item is not an item of the first type when the first cumulative duration is greater than or equal to the preset duration.

[0030] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the determination module is specifically further used to: when the first cumulative time is greater than or equal to the preset time, re-count the duration of the item being an item of the first category; in the process of the duration reaching the preset cumulative time, when it is detected that the item is not an item of the first category, continue to accumulate the time based on the original cumulative time that the item is not an item of the first category; when the accumulated time is greater than or equal to the preset time, determine that the item is not an item of the first category.

[0031] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the determination module is specifically used to: input the driving image into a hand detection model, and the hand detection model performs feature extraction on the driving image to obtain a target feature, and the target feature is used to describe the hand feature in the driving image; the hand detection model detects the image area where the hand in the driving image is located based on the target feature, and determines the image area where the hand detected in the driving image is located as the hand image.

[0032] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the device also includes: an output module, which is used to output a first reminder message when the object is a mobile phone, and the first reminder message is used to remind the driver not to play with the mobile phone during driving; the device also includes: a control module, which is used to: when the object is a water cup, control the vehicle to travel through the automatic driving system; when the object is a cigarette, control the steering wheel to vibrate with a first preset intensity.

[0033] In a third aspect, a vehicle is provided, comprising a memory and a processor. The memory is used to store executable program code, and the processor is used to call and run the executable program code from the memory, so that the vehicle executes the method in the first aspect or any possible implementation of the first aspect.

[0034] In a fourth aspect, a computer-readable storage medium is provided, which stores an executable program code. When the executable program code runs on a computer, the computer executes the method in the above-mentioned first aspect or any possible implementation of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 is a schematic diagram of a scenario of using a vehicle provided in an embodiment of the present application;

[0036] Figure 2 is a schematic flow chart of a method for identifying a handheld object provided in an embodiment of the present application;

[0037] Figure 3 is a schematic diagram of determining a first duration of an object in each time period as an object of the first category provided by an embodiment of the present application;

[0038] Figure 4 is a schematic diagram of determining whether an object is a first category object provided by an embodiment of the present application;

[0039] Figure 5 is a schematic diagram of the structure of a device for identifying a handheld object provided in an embodiment of the present application;

[0040] Figure 6 It is a structural schematic diagram of a vehicle provided in an embodiment of the present application. DETAILED DESCRIPTION

[0041] The technical solution in the present application will be described clearly and in detail below in conjunction with the accompanying drawings. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B: "and / or" in the text is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.

[0042] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as suggesting or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features.

[0043] Figure 1 It is a schematic diagram of a scenario of using a vehicle provided in an embodiment of the present application.

[0044] For example, Figure 1 As shown, the driver can drive vehicle A to reach the destination. During the driving process, the driver may have some driving behaviors due to his own needs, such as playing with mobile phones, drinking water and smoking. These driving behaviors may cause the driver to be distracted during driving and cause traffic accidents.

[0045] In order to solve the traffic accidents caused by the driver's distracted actions such as playing with mobile phones during driving, the hand action detection algorithm in the prior art mainly judges the driver's hand state by manual observation. The above manual observation method often leads to inaccurate detection results due to the observer's own distraction.

[0046] Therefore, the present application proposes a method for identifying handheld objects to improve the accuracy of identifying objects held in the driver's hand. The specific implementation steps are as follows: Figure 2 shown.

[0047] Figure 2 It is a schematic flowchart of a method for identifying a handheld object provided in an embodiment of the present application.

[0048] For example, Figure 2 As shown, the method 200 includes:

[0049] It should be understood that the method for identifying a handheld object provided in the present application is applied to Figure 1 The vehicle A shown (hereinafter referred to as the vehicle) is, or the method for identifying handheld objects can also be applied to the vehicle controller in the vehicle.

[0050] Step 201: When the vehicle is moving and there is a driver in the driving seat, the vehicle obtains a driving image of the driver.

[0051] It should be understood that the "vehicle driving" in the above step 201 means that the vehicle has power output and displacement changes. It should also be understood that the "driving position" in the above step 201 refers to the position of the driver in the vehicle. The position of the driving position may be different in different countries and regions. For example, in my country, vehicles drive on the right and the driving position is located on the left side of the cockpit; while in some other European countries, vehicles drive on the left and the driving position is located on the right side of the cockpit. This design is mainly to better observe vehicles coming from the opposite road and ensure the driving safety of drivers and passengers.

[0052] It should also be understood that the "driving image" in the above step 201 generally refers to an image including the driver taken when the driver is in the driving seat.

[0053] In some embodiments, the method for determining whether there is a driver in the driving seat includes any one of the following: when the pressure on the seat corresponding to the driving seat is greater than a preset pressure, the vehicle determines that there is a driver in the driving seat; when it is detected that the brake pedal or the accelerator pedal is pressed, the vehicle determines that there is a driver in the driving seat; when it is detected by a seat belt sensor that the seat belt is used, the vehicle determines that there is a driver in the driving seat.

[0054] In some embodiments, the "seat corresponding to the driver's seat" in the above solution refers to the seat that the driver sits in the cockpit. The pressure on the seat can be detected by a weight sensor, and the preset pressure is the minimum weight of an adult. In some embodiments, the preset pressure is 40kg.

[0055] In some embodiments, the vehicle in step 201 obtains the driving image of the driver, including: the vehicle collects the driving image of the driver through a vehicle-mounted camera in front of the driver.

[0056] It should be understood that the "vehicle-mounted camera" in the above solution can be regarded as a driver monitoring system (DMS) camera.

[0057] It should also be understood that in order to include the driver's hands in the driving image of the driver captured by the vehicle camera, the method has requirements for the location and shooting angle of the vehicle camera. In some embodiments, the vehicle camera is installed in front of the driver's seat in the cabin, close to the roof, and the shooting angle of the vehicle camera is greater than a°, which is related to the width between the seats corresponding to the driver's seat.

[0058] Step 202: The vehicle performs region detection on the driving image to determine the hand image of the driver, where the hand image includes the image region where the driver's hand is located.

[0059] In a possible implementation, step 202 includes: the vehicle generates a plurality of circumscribed rectangular frames on the driving image based on a plurality of target areas, the plurality of target areas being areas where the hands of a plurality of test subjects are located in the test image when they hold objects, and the image size and shooting conditions of the test image and the driving image are the same; the vehicle crops the image area enclosed by the plurality of circumscribed rectangular frames in the driving image, and determines the cropped plurality of image areas as the hand image.

[0060] It should be understood that the “individual target areas in the multiple target areas” in the above scheme are the image areas of the hands of any test subject in the test image when the test subject holds an object. The multiple test subjects usually have different heights and driving habits, and the image areas of their hands in the test image when they hold objects are different. That is to say, the above scheme obtains the image areas of the hands of multiple test subjects in the test image when they hold objects through the test process of the positions of the hands of multiple different test subjects in the test image when they hold objects. Since the number of test subjects in this method is large enough, the driving habits of the multiple test subjects are also consistent with the behavioral habits of the driver. Therefore, the method can infer the image area of ​​the driver's hand in the driving image, that is, the hand image, from the driving image based on multiple target areas.

[0061] It should also be understood that the "image size and shooting conditions of the test image and the driving image are the same" in the above scheme can be specifically understood as: the first in-vehicle camera used to shoot the test image and the second in-vehicle camera used to shoot the driving image have the same position, shooting angle, shooting focal length and image size after shooting in the vehicle, but different shooting times, and the seat position corresponding to the driving seat when the first in-vehicle camera shoots and the second in-vehicle camera shoots are the same.

[0062] It should also be understood that the method does not limit the shape of the "target area" in the above scheme. In some embodiments, when the target area is circular, the target area can be characterized by the position of any boundary point in the test image, and the diameter or radius of the target area. When the target area is rectangular, the target area can be characterized by the position of any boundary endpoint in the test image, and the length and width of the target area. When the target area is an irregular shape, the target area can be characterized by the positions of multiple boundary points in the test image.

[0063] It should also be understood that the "circumscribed rectangular frame" in the above solution refers to a rectangle used to completely surround the target object in the image, and the target object is a hand.

[0064] It should also be understood that the number of target areas in the above solution may be large. When multiple bounding rectangular frames are generated on the driving image based on multiple target areas, the multiple bounding rectangular frames may overlap. Therefore, the method can copy the driving image, and for any driving image, a corresponding bounding rectangular frame can be generated on the driving image based on any target area.

[0065] In the above technical solution, the method generates multiple circumscribed rectangular frames on the driving image based on the target areas of the hands of multiple test subjects when they hold objects in the test image. The number of test subjects is large enough, and the image size and shooting conditions of the test image and the driving image are the same. Therefore, the method can accurately capture the driver's hand image area through multiple circumscribed rectangular frames based on multiple target areas. Furthermore, the image area surrounded by the multiple circumscribed rectangular frames is cropped, and the cropped multiple image areas are used as hand images. In this way, the method can identify the hand-held object based on the hand image, without paying attention to the background image area in the driving image, which can improve the speed and accuracy of identifying the hand-held object, and then can make accurate voice warnings.

[0066] In some embodiments, the vehicle generates multiple circumscribed rectangular frames on the driving image based on multiple target areas, including: for any target area among the multiple target areas, when the target area is circular, the vehicle determines in the driving image, based on the position of any boundary point on the target area in the driving image and the diameter or radius of the target area, a bounding box of the image area corresponding to the target area is a circumscribed rectangular frame to determine the multiple circumscribed rectangular frames; for any target area among the multiple target areas, when the target area is rectangular, the vehicle determines in the driving image, based on the position of any boundary endpoint on the target area in the driving image and the length and / or width of the target area, a bounding box of the image area corresponding to the target area is a circumscribed rectangular frame to determine the multiple circumscribed rectangular frames; for any target area among the multiple target areas, when the target area is irregular in shape, the vehicle determines in the driving image, based on the positions of multiple boundary points on the target area in the driving image, a bounding box of the image area corresponding to the target area is a circumscribed rectangular frame to determine the multiple circumscribed rectangular frames.

[0067] In a possible implementation, the vehicle generates a plurality of circumscribed rectangular frames on the driving image based on the plurality of target areas, including: in the driving image, the vehicle determines the bounding frames of the image area corresponding to the plurality of target areas as the plurality of circumscribed rectangular frames; or, based on the bounding frames of the image area corresponding to the plurality of target areas, the vehicle extends a preset distance to the outside of the plurality of bounding boxes, and determines the plurality of bounding boxes after being extended by the preset distance as the plurality of circumscribed rectangular frames.

[0068] It should be understood that the above scheme provides two ways to determine the circumscribed rectangular frame: in the first way, the bounding box of the image area corresponding to the target area is determined as the circumscribed rectangular frame; in the second way, a new bounding box obtained by extending the bounding box outward by a preset distance is determined as the circumscribed rectangular frame. This is equivalent to that any circumscribed rectangular frame in the first way is directly determined based on the corresponding target area, and the image area enclosed by the circumscribed rectangular frame is the same as the target area; while for the second way, any circumscribed rectangular frame is indirectly determined based on the corresponding target area, and the image area enclosed by the circumscribed rectangular frame is different from the target area, and the image area of ​​the former is larger than that of the latter.

[0069] In the above technical solution, in the driving image, the bounding boxes of the image areas corresponding to the multiple target areas are determined as the multiple circumscribed rectangular boxes. This method completely relies on the positions of the hands of multiple test subjects when holding objects determined during the test to infer the area of ​​the driver's hands in the driving image, and can accurately determine the image area where the hands are located without increasing the image area of ​​the hand image. Or, based on the bounding boxes of the image areas corresponding to the multiple target areas, a preset distance is extended to the outside of the multiple bounding boxes, which increases the image area of ​​the hand image. However, this method does not completely rely on the positions of the hands of multiple test subjects when holding objects determined during the test, and therefore, this method can more accurately determine the image area where the driver's hands are located.

[0070] In some embodiments, the preset distance is 0.5 cm.

[0071] In one possible implementation, step 202 includes: the vehicle inputs the driving image into a hand detection model, and the hand detection model extracts features from the driving image to obtain target features, where the target features are used to describe the hand features in the driving image; the hand detection model detects an image region where the hand in the driving image is located based on the target features, and determines the image region where the hand detected in the driving image is located as the hand image.

[0072] In the above technical solution, the method detects the image area where the hand is located in the driving image based on the hand features by the hand detection model. Since the hand detection model is trained based on the neural network technology, the method can detect an accurate hand image through the hand detection model.

[0073] Step 203: The vehicle identifies the object held in the driver's hand based on the hand image.

[0074] It should be understood that the "hand image" in the above step 203 includes the image area where the driver's hand is located. Since the hand image is obtained based on multiple target areas, which are the areas where the hands of multiple test subjects are located in the test image when they hold objects, the hand image includes other image areas, which do not include the image area where the hand is located.

[0075] In one possible implementation, step 203 includes: the vehicle inputs the hand image into a target classification model, and the target classification model detects the types of items held in the hand in the hand image and the corresponding probabilities; the vehicle identifies the items held in the driver's hand based on the types of items held in the hand and the corresponding probabilities.

[0076] It should be understood that the "target classification model" in the above solution is used to classify objects in the image, determine the object type and the corresponding probability, specifically the probability that the object is of the object type is b. The target classification model is obtained by training with neural network technology based on a large number of training samples.

[0077] It should also be understood that the target classification model is a neural network model, the neural network model is a MobileNetV2 model, and the architecture of the MobileNetV2 model is a baseline.

[0078] In the above technical solution, the method processes the hand image through the target classification model to determine the type of items held by the hand in the hand image and the corresponding probability. Further, based on the type of items and the corresponding probability, the items held by the driver's hand are identified. In other words, the method identifies the items held by the driver's hand through the target classification model trained by the neural network technology, which can improve the accuracy of identifying the handheld items.

[0079] In one possible implementation, the vehicle identifies the item held in the driver's hand based on the type of item held in the hand and the corresponding probability, including: when the type of item satisfies a first condition, the vehicle determines that the item is a first type of item, and the first condition is that the type of item is the first type and the corresponding probability is greater than or equal to a first probability threshold; when the type of item satisfies a second condition, the vehicle determines the type of item held in the driver's hand at each of multiple moments after a first moment and the corresponding probability, and the second condition includes that the type of item is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to a second probability threshold, and the first moment is the moment when the driving image is acquired; the vehicle identifies the item held in the driver's hand based on the type of item held in the hand at each of the multiple moments and the corresponding probability, as well as the time interval between adjacent moments.

[0080] It should be understood that the "item type" in the above solution is a specific functional type of the item. In some embodiments, the item type includes any one of no type, steering wheel, mobile phone, water cup, cigarette, mask, tissue and book, where no type means that the driver's hand does not hold an item. It should also be understood that the "first probability threshold" in the above solution is a very high probability value, while the "second probability threshold" is a relatively high probability value.

[0081] In the above technical solution, when the type of the item is the first type and the corresponding probability is greater than or equal to the first probability threshold, the item is determined to be the first type of item. When the type of the item meets the second condition (the second condition includes that the type of the item is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to the second probability threshold), the type of the item held by the driver's hand at each of the multiple moments after the first moment and the corresponding probability are determined; then based on the type of the item held by the hand at each of the multiple moments and the corresponding probability, and the time interval between adjacent moments, the item held by the driver's hand is identified. In other words, the item held by the driver's hand can be identified based on a single-frame driving image. In order to improve the accuracy of identifying handheld items, the method also considers the item identification results corresponding to the multiple frames of driving images following the single frame. In other words, the hand states in the multiple frames of driving images are statistically analyzed, and the handheld items are determined based on the long-term statistical results.

[0082] In some embodiments, the first probability threshold is 0.95, and the second probability threshold is any probability value between 0.87 and 0.95.

[0083] In some embodiments, the time interval is 0.4 s.

[0084] In a possible implementation, the vehicle identifies the item held in the driver's hand based on the type of item held in the hand at each of the multiple moments and the corresponding probability, as well as the time interval between adjacent moments, including: the vehicle determines a first number corresponding to a plurality of time periods in which the type of item meets the first condition continuously, and a second number corresponding to a plurality of time periods in which the type of item does not meet the first condition continuously among the types of item held in the hand at the multiple moments; the vehicle determines a first duration in each time period that the item is an item of the first category based on the first number corresponding to the plurality of time periods and the time interval; in the process of determining a preset cumulative duration that the item is an item of the first category based on the first time period corresponding to each time period, the vehicle determines a first cumulative duration that the item is not an item of the first category within the preset cumulative duration based on the second number corresponding to the plurality of time periods and the time interval; when the first cumulative duration is less than the preset duration, the vehicle determines that the item is an item of the first category; when the first cumulative duration is greater than or equal to the preset duration, the vehicle determines that the item is not an item of the first category.

[0085] It should be understood that each of the "multiple moments" in the above scheme has a corresponding driving image, and the method processes the driving image to obtain the type of items held by the driver's hand in the hand image in the driving image and the corresponding probability. Therefore, each of the multiple moments has a corresponding type of item and a corresponding probability. There may be some moments in the multiple moments where the corresponding type of item and the corresponding probability are the same.

[0086] In the above technical solution, the number (first number) corresponding to the multiple time periods in which the item type meets the first condition in succession and the number (second number) corresponding to the multiple time periods in which the item type does not meet the first condition in succession are counted for the item types held by the hand at the multiple moments and the corresponding probabilities, and the first duration of the item being the first type of item in each time period is determined. Further, in the process of determining that the item is the first type of item based on the first duration and reaches the preset cumulative duration, the duration (first cumulative duration) in which the item is not the first type of item within the preset cumulative duration is determined; and then based on the size relationship between the first cumulative duration and the preset duration, the handheld item is identified. That is, the method adopts a two-layer probability threshold, and when the probability corresponding to the item type of a single-frame driving image is a low probability, the hand state in the multiple-frame driving image is counted and a smoothing strategy is performed. When the method identifies the handheld item as the first type of item, in the process of the duration of the item being the first type of item reaching the preset cumulative duration, the duration of the item not being the first type of item within the preset cumulative duration is allowed to be less than the preset duration. This can maximize the use of time to identify handheld objects, while taking into account possible instability in the target classification model and improving the accuracy of handheld object recognition.

[0087] In some embodiments, the vehicle determines the first duration that the item is an item of the first type in each time period based on the first quantities corresponding to multiple time periods and the time interval, including: for any time period among the multiple time periods, the vehicle subtracts the first value from the first quantity to obtain a third quantity corresponding to the time period; the vehicle determines the product of the third quantity and the time interval as the first duration that the item is an item of the first type in the time period, so as to determine the first duration that the item is an item of the first type in each time period.

[0088] It should be understood that the process of "the vehicle determines the first accumulated time that the item is not an item of the first category within the preset accumulated time period based on the second quantity corresponding to multiple time periods and the time interval" in the above scheme is similar to the process of "the vehicle determines the first time that the item is an item of the first category in each time period based on the first quantity corresponding to multiple time periods and the time interval" in the above scheme, and will not be repeated here. It should be explained that the timing of determining the first accumulated time that the item is not an item of the first category within the preset accumulated time period based on the second quantity corresponding to multiple time periods and the time interval is when the first time that the item is an item of the first category is accumulated to the preset accumulated time period.

[0089] In some embodiments, the preset duration is 1 second.

[0090] In some embodiments, the preset cumulative time is 3.5 seconds.

[0091] Figure 3 It is a schematic diagram of a first duration for determining that an item in each time period is an item of the first category provided by an embodiment of the present application.

[0092] For example, Figure 3 As shown, taking the case where the item corresponding to the first moment is an item of the first category and the corresponding probability is greater than the first probability threshold, there are multiple moments after the first moment, the time interval between adjacent moments is 0.4s, the items corresponding to the 1st to 4th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, the items corresponding to the 6th to 8th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, and the items corresponding to the 11th to 15th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold as an example, the process of determining the first duration of the items in each time period being items of the first category is taken.

[0093] like Figure 3As shown, the vehicle determines the first quantity corresponding to each of the multiple time periods in which the types of items held by the hand at the multiple moments and the corresponding probabilities are continuously that the type of item is the first type of item and the corresponding probability is greater than the first probability threshold, namely, 4, 3 and 5 respectively; based on the first quantities corresponding to the multiple time periods and the time intervals, the vehicle determines the first duration that the item is the first type of item in each time period, namely, the first duration of the first time period is 1.2 (3*0.4), the first duration of the second time period is 0.8 (2*0.4) and the first duration of the third time period is 1.6 (4*0.4).

[0094] Figure 4 It is a schematic diagram of determining whether an object is a first category object provided in an embodiment of the present application.

[0095] For example, Figure 4 As shown in (a), taking the case where the item corresponding to the first moment is an item of the first category and the corresponding probability is greater than a first probability threshold, there are multiple moments after the first moment, the time interval between adjacent moments is 0.4s, the items corresponding to the 1st to 4th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, the items corresponding to the 6th to 8th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, and the items corresponding to the 11th to 15th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, the first condition is that the item is an item of the first category and the corresponding probability is greater than the first probability threshold, the item types corresponding to the 5th, 9th and 10th moments among the multiple moments do not meet the first condition, the preset cumulative time is 3.5s and the preset time is 1s as an example, the process of determining whether an item is an item of the first category.

[0096] like Figure 4 As shown in (a), in the process of determining the preset cumulative time (3.5s<1.2s+0.8s+1.6s) that the item is a first type of item based on the first time corresponding to each time period, the vehicle determines the second time that the item is not the first type of item in each time period based on the second numbers corresponding to multiple time periods and the time interval, namely, the second time of the first time period is 0.8(2*0.4) and the second time of the second time period is 1.2(3*0.4), and determines that the first cumulative time that the item is not the first type of item within the preset cumulative time (3.5s) is 2s; 2s is greater than 1s, so the vehicle determines that the item is not the first type of item.

[0097] For example, Figure 4As shown in (b), taking the case where the item corresponding to the first moment is an item of the first category and the corresponding probability is greater than a first probability threshold, there are multiple moments after the first moment, the time interval between adjacent moments is 0.4s, the items corresponding to the 1st to 4th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, and the items corresponding to the 6th to 15th moments among the multiple moments are items of the first category and the corresponding probability is greater than the first probability threshold, the first condition is that the item is an item of the first category and the corresponding probability is greater than the first probability threshold, the item type corresponding to the 5th moment among the multiple moments does not meet the first condition, the preset cumulative time is 3.5s and the preset time is 1s as an example, the process of determining whether an item is an item of the first category.

[0098] like Figure 4 As shown in (b), in the process of determining that the item is a preset cumulative duration of the first type of item (3.5s<1.2s (i.e., the first duration of the first time period) + 3.6s (i.e., the first duration of the second time period)) based on the first duration corresponding to each time period, the vehicle determines the second duration of the item not being the first type of item in each time period based on the second quantities corresponding to the multiple time periods and the time interval. The second duration of the first time period is 0.8(2*0.4), i.e., the first cumulative duration that the item is not the first type of item within the preset cumulative duration (3.5s) is 0.8s; 0.8s is less than 1s, so the vehicle determines that the item is a first type of item.

[0099] In one possible implementation, when the first cumulative time is greater than or equal to the preset time, the vehicle determines that the item is not an item of the first category, including: when the first cumulative time is greater than or equal to the preset time, the vehicle recounts the duration of time that the item is an item of the first category; during the process when the duration reaches the preset cumulative time, when it is detected that the item is not an item of the first category, the vehicle continues to accumulate time based on the original cumulative time that the item is not an item of the first category; when the accumulated time is greater than or equal to the preset time, the vehicle determines that the item is not an item of the first category.

[0100] It should be understood that the method can obtain multiple driving images of the driver, and one driving image corresponds to one object. Therefore, the changes in the driver's handheld objects can be determined based on multiple driving images. In order to improve the accuracy of identifying handheld objects, the method counts the hand states in multiple frames of driving images. When the duration of the item being a certain type of item reaches a preset cumulative duration, the cumulative duration of the item not being a certain type of item must be less than the preset duration before the item is identified as a certain type of item. This is to avoid erroneous detection results caused by the instability of the target classification model. In addition, the identification of handheld objects is a continuous process. Therefore, when the first cumulative duration is greater than or equal to the preset duration, the method will re-count the duration of the item being the first type of item and re-identify the item.

[0101] In the above technical solution, when the first accumulated time is greater than or equal to the preset time, the method re-counts the duration of the item being an item of the first category, which is equivalent to re-determining the item category of the item. In the process of counting the duration to reach the preset accumulated time, if the item is not an item of the first category, the method continues to accumulate the time based on the original accumulated time (the accumulated time that the item is not an item of the first category), and then compares the accumulated time with the preset time to determine the item category of the item. In other words, the method comprehensively determines the item category based on the accumulated time that the item is not an item of the first category during the process of counting the duration of the item being an item of the first category to reach the preset accumulated time. Therefore, the method can determine the item category more accurately.

[0102] In some embodiments, after step 203, the method 200 further includes: the vehicle performs state detection on the mouth area in the driving image to determine the mouth state of the driver; the vehicle determines the driving behavior of the driver based on the mouth state and the object.

[0103] It should be understood that the "mouth state" in the above scheme includes an open state or a closed mouth state.

[0104] In some embodiments, the method for determining the mouth area in the driving image includes: the vehicle determines the first key point on the face of the person in the driving image, the first key point including the left corner of the mouth, the right corner of the mouth, the center of the upper lip and the center of the lower lip; the vehicle determines the boundary of the mouth based on the first key point; the vehicle crops out the image area surrounded by the boundary of the mouth in the driving image, and determines the image area as the mouth area.

[0105] In some embodiments, the vehicle determines a first key point on a human face in the driving image, including: the vehicle aligns the driving image to adjust the driving image to a target size and a target direction; the vehicle extracts features from the aligned driving image to obtain a first facial feature, where the first facial feature is used to describe a mouth feature on the face; and the vehicle locates the first key point in the aligned driving image based on the mouth feature.

[0106] It should be understood that the vehicle can obtain the driver's mouth features by performing feature extraction on the aligned driving image. The mouth features may include the positions of the left corner of the mouth, the right corner of the mouth, the center of the upper lip, and the center of the lower lip on the driving image, respectively. Therefore, the vehicle can locate the first key point in the aligned driving image based on the mouth features.

[0107] In some embodiments, the vehicle performs state detection on the mouth area in the driving image to determine the driver's mouth state, including: the vehicle identifies the center of the upper lip and the center of the lower lip in the mouth area; the vehicle determines a first distance between the center of the upper lip and the center of the lower lip; when the first distance is greater than or equal to a first preset distance, the vehicle determines that the mouth state is an open state; when the first distance is less than the first preset distance, the vehicle determines that the mouth state is a closed state.

[0108] It should be understood that the first preset distance is usually smaller. In some embodiments, the first preset distance is 0.3 cm.

[0109] In some embodiments, the vehicle determines the driver's driving behavior based on the mouth state and the object, including: when the mouth state is open and the object is a mobile phone, the vehicle determines that the driver is making a call; when the mouth state is closed and the object is a mobile phone, the vehicle obtains the position of the hand; when the hand is around the ear, the vehicle determines that the driver is making a call; when the hand is not around the ear, the vehicle determines that the driver is playing with the mobile phone.

[0110] In some embodiments, the method 200 also includes any one of the following: when it is determined that the driver is making a phone call, the vehicle outputs a second reminder message, and the second reminder message is used to remind the driver to use Bluetooth to make a phone call; when it is determined that the driver is playing with a mobile phone, the vehicle outputs the first reminder message.

[0111] In one possible implementation, after step 203, the method 200 further includes any one of the following: when the object is a mobile phone, the vehicle outputs a first reminder message, and the first reminder message is used to remind the driver not to play with the mobile phone while driving; or, when the object is a water cup, the vehicle controls the driving of the vehicle through the automatic driving system; or, when the object is a cigarette, the vehicle controls the steering wheel to vibrate with a first preset intensity.

[0112] It should be understood that the "autonomous driving system" in the above scheme refers to the process in which the vehicle collects environmental information around the vehicle through various sensors, determines its own position using positioning technology, and then determines the vehicle control decision based on machine learning technology and preset driving rules, thereby automatically controlling the vehicle's driving based on the vehicle control decision.

[0113] In the above technical solution, when the object is a mobile phone, a first reminder message is output. This method can remind the driver not to play with the mobile phone when the driver plays with the mobile phone during driving, so as to improve the driver's driving safety. Or, when the object is a water cup, the vehicle is controlled to travel by the automatic driving system, which can not only enable the driver to replenish water in time when thirsty, but also avoid traffic accidents during driving. Or, when the object is a cigarette, the steering wheel is controlled to vibrate with a first preset intensity. This method can vibrate the steering wheel with a first preset intensity when the driver smokes during driving, which can not only achieve a good reminder effect, but also avoid affecting driving safety.

[0114] Figure 5 It is a structural schematic diagram of a device for identifying handheld objects provided in an embodiment of the present application.

[0115] For example, Figure 5 As shown, the device 500 includes:

[0116] Acquisition module 501: used for acquiring a driving image of the driver when the vehicle is moving and there is a driver in the driving seat;

[0117] Determination module 502: used to perform region detection on the driving image to determine the hand image of the driver, where the hand image includes the image region where the driver's hand is located;

[0118] Identification module 503: used to identify the object held in the driver's hand based on the hand image.

[0119] Optionally, the device 500 also includes: a generation module, used to generate multiple circumscribed rectangular frames on the driving image based on multiple target areas, the multiple target areas are the areas where the hands of multiple test subjects are located in the test image when they hold objects, and the image size and shooting conditions of the test image and the driving image are the same; a determination module 502, specifically used to crop the image area enclosed by the multiple circumscribed rectangular frames in the driving image, and determine the cropped multiple image areas as the hand image.

[0120] Optionally, the generating module is specifically used to: in the driving image, determine the bounding boxes of the image area corresponding to the multiple target areas as the multiple circumscribed rectangular boxes; or, based on the bounding boxes of the image area corresponding to the multiple target areas, extend a preset distance to the outside of the multiple bounding boxes, and determine the multiple bounding boxes after extending the preset distance as the multiple circumscribed rectangular boxes.

[0121] Optionally, the recognition module 503 is specifically used to: input the hand image into a target classification model, and the target classification model detects the types of items held by the hand in the hand image and the corresponding probabilities; based on the types of items held by the hand and the corresponding probabilities, identify the items held in the driver's hand.

[0122] Optionally, the determination module 502 is further used to: determine that the item is a first type of item when the item type satisfies a first condition, and the first condition is that the item type is the first type and the corresponding probability is greater than or equal to a first probability threshold; determine the item type and the corresponding probability held by the driver's hand at each of multiple moments after the first moment when the item type satisfies a second condition, and the second condition includes that the item type is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to a second probability threshold, and the first moment is the moment when the driving image is acquired; the identification module 503 is further specifically used to identify the item held in the driver's hand based on the item type and the corresponding probability held by the hand at each of the multiple moments, and the time interval between adjacent moments.

[0123] Optionally, the determination module 502 is further used to: determine the types of items held by the hand at the multiple moments and the first number corresponding to multiple time periods in which the type of item meets the first condition continuously, and the second number corresponding to multiple time periods in which the type of item does not meet the first condition continuously in the corresponding probabilities; determine a first duration in each time period that the item is an item of the first type based on the first number corresponding to the multiple time periods and the time interval; in the process of determining a preset cumulative duration that the item is an item of the first type based on the first time period corresponding to each time period, determine a first cumulative duration that the item is not an item of the first type within the preset cumulative duration based on the second number corresponding to the multiple time periods and the time interval; the identification module 503 is further specifically used to: determine that the item is an item of the first type when the first cumulative duration is less than the preset duration; and determine that the item is not an item of the first type when the first cumulative duration is greater than or equal to the preset duration.

[0124] Optionally, the determination module is further specifically used to: when the first cumulative time is greater than or equal to the preset time, recount the duration of the item being an item of the first category; when the duration reaches the preset cumulative time, if it is detected that the item is not an item of the first category, continue to accumulate time based on the original cumulative time that the item is not an item of the first category; when the accumulated time is greater than or equal to the preset time, determine that the item is not an item of the first category.

[0125] Optionally, the determination module is further specifically used to: input the driving image into a hand detection model, and the hand detection model performs feature extraction on the driving image to obtain a target feature, where the target feature is used to describe the hand feature in the driving image; the hand detection model detects the image area where the hand in the driving image is located based on the target feature, and determines the image area where the hand detected in the driving image is located as the hand image.

[0126] Optionally, the device 500 also includes: an output module, used to output a first reminder message when the object is a mobile phone, and the first reminder message is used to remind the driver not to play with the mobile phone while driving; the device 500 also includes: a control module, used to: when the object is a water cup, control the vehicle to travel through the automatic driving system; when the object is a cigarette, control the steering wheel to vibrate with a first preset intensity.

[0127] Figure 6 It is a structural schematic diagram of a vehicle provided in an embodiment of the present application.

[0128] For example, Figure 6As shown, the vehicle 600 includes: a memory 601 and a processor 602, wherein the memory 601 stores an executable program code 603, and the processor 602 is used to call and execute the executable program code 603 to perform a method for identifying a handheld object.

[0129] In addition, an embodiment of the present application also protects a device, which may include a memory and a processor, wherein the memory stores an executable program code, and the processor is used to call and execute the executable program code to execute a method for identifying a handheld object provided in an embodiment of the present application.

[0130] In this embodiment, the functional modules of the device can be divided according to the above method example. For example, each functional module can be corresponded, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware. It should be noted that the division of modules in this embodiment is schematic and is only a logical function division. There may be other division methods in actual implementation.

[0131] In the case of dividing each functional module according to each function, the device may also include an acquisition module, a determination module, an identification module, a generation module, an output module, and a control module, etc. It should be noted that all relevant contents involved in the above method embodiment can be referred to the functional description of the corresponding functional module, which will not be repeated here.

[0132] It should be understood that the device provided in this embodiment is used to execute the above-mentioned method for identifying a handheld object, and thus can achieve the same effect as the above-mentioned implementation method.

[0133] In the case of an integrated unit, the device may include a processing module and a storage module. When the device is applied to a vehicle, the processing module may be used to control and manage the actions of the vehicle. The storage module may be used to support the vehicle in executing related executable program codes, etc.

[0134] The processing module may be a processor or a controller, which may implement or execute various exemplary logic blocks, modules and circuits shown in conjunction with the disclosure of the present application. The processor may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of digital signal processing (DSP) and a microprocessor, etc. The storage module may be a memory.

[0135] In addition, the device provided in the embodiments of the present application may specifically be a chip, component or module, and the chip may include a connected processor and memory; wherein the memory is used to store instructions, and when the processor calls and executes the instructions, the chip can execute a method for identifying handheld objects provided in the above embodiments.

[0136] This embodiment also provides a computer-readable storage medium, in which executable program code is stored. When the executable program code is run on a computer, the computer executes the above-mentioned related method steps to implement a method for identifying handheld objects provided in the above embodiment.

[0137] This embodiment also provides a computer program product. When the computer program product is run on a computer, the computer is caused to execute the above-mentioned related steps to implement a method for identifying a handheld object provided in the above embodiment.

[0138] Among them, the device, computer-readable storage medium, computer program product or chip provided in this embodiment is used to execute the corresponding method provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be repeated here.

[0139] Through the description of the above implementation methods, technical personnel in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0140] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0141] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method for identifying a handheld object, It is characterized in that The method comprises: When the vehicle is moving and there is a driver in the driving seat, acquiring a driving image of the driver; Performing region detection on the driving image to determine a hand image of the driver, wherein the hand image includes an image region where the driver's hand is located; Based on the hand image, the object held by the driver's hand is identified.

2. The method according to claim 1, It is characterized in that The performing area detection on the driving image to determine the hand image of the driver includes: Based on multiple target areas, multiple circumscribed rectangular frames are generated on the driving image, where the multiple target areas are areas where the hands of multiple test subjects are located in the test image when they hold objects, and the image size and shooting conditions of the test image and the driving image are the same; The image areas enclosed by the multiple circumscribed rectangular frames in the driving image are cropped, and the cropped multiple image areas are determined as the hand images.

3. The method according to claim 2, It is characterized in that The step of generating a plurality of circumscribed rectangular frames on the driving image based on the plurality of target areas comprises: In the driving image, determining the bounding boxes of the image areas corresponding to the multiple target areas as the multiple circumscribed rectangular boxes; or, On the basis of the boundary boxes of the image areas corresponding to the multiple target areas, a preset distance is extended to the outside of the multiple boundary boxes, and the multiple boundary boxes extended by the preset distance are determined as the multiple circumscribed rectangular boxes.

4. The method according to claim 1, It is characterized in that The identifying the object held by the driver's hand based on the hand image includes: Inputting the hand image into a target classification model, and detecting the type of object held by the hand in the hand image and the corresponding probability by the target classification model; The object held in the driver's hand is identified based on the type of the object held in the hand and the corresponding probability.

5. The method according to claim 4, It is characterized in that The identifying the object held in the driver's hand based on the type of the object held in the hand and the corresponding probability includes: In the case where the item type satisfies a first condition, determining that the item is an item of the first type, the first condition being that the item type is the first type and the corresponding probability is greater than or equal to a first probability threshold; determining the type of the item held by the driver's hand and the corresponding probability at each of a plurality of moments after a first moment, when the item type satisfies a second condition, wherein the second condition includes that the item type is the first type and the corresponding probability is less than the first probability threshold and greater than or equal to a second probability threshold, and the first moment is the moment when the driving image is acquired; The object held in the driver's hand is identified based on the type of the object held in the hand at each of the multiple moments and the corresponding probability, as well as the time interval between adjacent moments.

6. The method according to claim 5, It is characterized in that The identifying the object held by the driver's hand based on the type of the object held by the hand at each of the multiple moments and the corresponding probability, and the time interval between adjacent moments, includes: Determine, among the types of objects held by the hand at the multiple moments and the corresponding probabilities, a first quantity corresponding to a plurality of time periods in which the types of objects continuously meet the first condition, and a second quantity corresponding to a plurality of time periods in which the types of objects continuously do not meet the first condition; Determine, based on the first quantities corresponding to the plurality of time periods and the time intervals, a first duration during which the item is an item of the first category in each time period; In the process of determining the preset cumulative time duration that the item is an item of the first category based on the first time duration corresponding to each time period, determining the first cumulative time duration that the item is not an item of the first category within the preset cumulative time duration based on the second quantities corresponding to the plurality of time periods and the time interval; When the first accumulated time is less than a preset time, determining that the object is an object of the first category; When the first accumulated time is greater than or equal to the preset time, it is determined that the object is not an object of the first category.

7. The method according to claim 5, It is characterized in that The determining that the object is not an object of the first category when the first accumulated time is greater than or equal to the preset time includes: When the first accumulated time is greater than or equal to the preset time, recalculating the duration of time that the item is an item of the first category; In the process that the duration reaches the preset cumulative duration, if it is detected that the object is not an object of the first category, the duration is continued to be accumulated based on the original cumulative duration that the object is not an object of the first category; When the accumulated time is greater than or equal to the preset time, it is determined that the object is not an object of the first category.

8. The method according to claim 1, It is characterized in that The performing area detection on the driving image to determine the hand image of the driver includes: Inputting the driving image into a hand detection model, and extracting features of the driving image by the hand detection model to obtain target features, wherein the target features are used to describe hand features in the driving image; The hand detection model detects the image region where the hand in the driving image is located based on the target feature, and determines the image region where the hand detected in the driving image is located as the hand image.

9. The method according to any one of claims 1 to 8, It is characterized in that The method further comprises any of the following: In the case where the object is a mobile phone, outputting a first reminder message, wherein the first reminder message is used to remind the driver not to play with the mobile phone during driving; When the object is a cup, the vehicle is controlled to travel by an automatic driving system; In case the object is a cigarette, the steering wheel is controlled to vibrate at a first preset intensity.

10. A device for identifying a handheld object, It is characterized in that The device comprises: An acquisition module, used for acquiring a driving image of the driver when the vehicle is moving and there is a driver in the driving seat; A determination module, configured to determine a hand image of the driver based on the driving image, wherein the hand image includes an image region where the driver's hand is located; The recognition module is used to recognize the object held in the driver's hand based on the hand image.

11. A vehicle, It is characterized in that The vehicle comprises: A memory for storing executable program codes; A processor, configured to call and run the executable program code from the memory so that the vehicle executes the method according to any one of claims 1 to 9.

12. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores executable program codes, and when the executable program codes are executed, the method according to any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • Vehicle taillight recognition method and device and vehicle

    CN108021856A

  • Detection method for call behavior of mobile phone in driving process of driver

    CN108509902A

  • The invention discloses a real-time monitoring method for a hand-held mobile phone call of a driver

    CN109685026A

  • Driving behavior detection method and device and readable storage medium

    CN112183356A

  • Driver multi-part detection method and device, electronic control unit and vehicle

    CN117392642A