Method, device and equipment for determining area of external frame of human head, medium and vehicle

By determining and correcting the area of ​​the head's external frame, the system solves the problem of misjudgment caused by headwear, achieves more accurate detection of the head's external frame area, and supports more precise depth estimation.

CN120689388APending Publication Date: 2025-09-23BEIJING CO WHEELS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410339284.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-03-22
Publication Date
2025-09-23

AI Technical Summary

Technical Problem

When identifying the area of ​​the external frame of a human head in an image, existing technologies may misjudge the area due to the wearing of headwear, resulting in inaccurate prediction results and an inability to accurately reflect the actual head area.

Method used

By determining the length and width of the initial head bounding box, it is determined whether there is an associated face and headwear bounding box, and the Hungarian algorithm is used for matching. The ratio of the head width to the face width is corrected. If the ratio is greater than the preset value, the bounding box area is corrected to obtain the actual head bounding box area.

Benefits of technology

Improves the accuracy of head bounding box area detection, ensuring more accurate depth estimation for subsequent tasks such as head collision avoidance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120689388A_ABST
    Figure CN120689388A_ABST
Patent Text Reader

Abstract

The invention provides a head external frame area determination method and device, electronic equipment, a storage medium and a vehicle. The method comprises the following steps: acquiring an initial head bounding box area corresponding to an initial head bounding box of a to-be-predicted figure object in an input image; if the initial head external connection frame has an associated face external connection frame and an associated headwear external connection frame, and the face information corresponding to the associated face external connection frame is credible, determining the ratio of the head width to the face width corresponding to the associated face external connection frame; if the ratio of the human head width to the human face width is greater than or equal to a preset value, correcting the initial human head external connection frame area, and obtaining the corrected actual human head external connection frame area, so as to achieve the discrimination and separation of the human head external connection frame and the headwear external connection frame. Therefore, the predicted human head external connection frame area is successfully returned to the actual human head external connection frame area without the influence of headwear, the accuracy of human head external connection frame area detection is improved, and more accurate depth estimation can be conveniently carried out on subsequent tasks such as head collision prevention and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of image processing technology, and in particular to a method, device, electronic device, storage medium, and vehicle for determining the area of ​​a human head circumference frame. Background Art

[0002] In image recognition and detection tasks, especially for application scenarios such as security monitoring, autonomous driving, and human-computer interaction, it is crucial to accurately identify and locate the position of the head in the image and determine the area of ​​the head's external frame.

[0003] Currently, related technologies within the cockpit typically use the head bounding box area derived from a human head detection and classification network as the final result for tasks such as head collision warning. However, in real-world applications, since people may wear headwear such as hats and hairpins, the human head detection and classification network may misjudge the headwear as part of the head, resulting in an inaccurate prediction of the head bounding box area, which differs significantly from the actual head area. Summary of the Invention

[0004] The present disclosure provides a method, device, electronic device, and storage medium for determining the area of ​​a human head external frame.

[0005] According to a first aspect of the present disclosure, a method for determining the area of ​​a head circumscribed frame is provided, comprising: determining the head length and head width corresponding to an initial head circumscribed frame of a person object to be predicted in an input image, and multiplying the head length and head width to obtain the area of ​​an initial head circumscribed frame corresponding to the initial head circumscribed frame; if the initial head circumscribed frame has an associated face circumscribed frame and an associated headwear circumscribed frame, and the face information corresponding to the associated face circumscribed frame is credible, determining the ratio of the head width to the face width corresponding to the associated face circumscribed frame, and the associated face circumscribed frame and the associated headwear circumscribed frame are the face circumscribed frame and the headwear circumscribed frame that are the only matching frames for the initial head circumscribed frame; if the ratio of the head width to the face width is greater than or equal to a preset value, correcting the area of ​​the initial head circumscribed frame to obtain the corrected actual area of ​​the head circumscribed frame.

[0006] In some embodiments of the present disclosure, determining the head length and head width corresponding to the initial head circumscribed frame of the person object to be predicted in the input image includes: obtaining the vertex coordinates of the initial head circumscribed frame of the person object to be predicted in the input image; determining the boundary length and boundary width of the initial head circumscribed frame corresponding to the vertex coordinates, and using the boundary length as the head length and the boundary width as the head width.

[0007] In some embodiments of the present disclosure, if the initial head external bounding box has an associated face external bounding box and an associated headwear external bounding box, and the facial information corresponding to the associated face external bounding box is credible, determining the ratio of the head width to the face width corresponding to the associated face external bounding box includes: judging whether there is an associated face external bounding box and an associated headwear external bounding box in the initial head external bounding box; if the initial head external bounding box does not have an associated face external bounding box or an associated headwear external bounding box, taking the area of ​​the initial head external bounding box as the actual head external bounding box area; if the initial head external bounding box has an associated face external bounding box and an associated headwear external bounding box, judging the confidence level of the associated face external bounding box. Whether it is greater than or equal to the face confidence threshold, the confidence of the associated face bounding box is obtained through detection network detection; if the confidence of the associated face bounding box is less than the face confidence threshold, it is determined that the face information is unreliable, and the area of ​​the initial head bounding box is used as the actual head bounding box area; if the confidence of the associated face bounding box is greater than or equal to the face confidence threshold, it is determined that the face information corresponding to the associated face bounding box is credible, and the ratio of the head width to the face width corresponding to the associated face bounding box is determined, and the associated face bounding box and the associated headwear bounding box are the face bounding box and headwear bounding box that uniquely match the initial head bounding box.

[0008] In some embodiments of the present disclosure, determining whether there is an associated face bounding box and an associated headwear bounding box in the initial head bounding box includes: obtaining at least two initial face bounding boxes and at least two initial headwear bounding boxes corresponding to the initial head bounding box of the person object to be predicted in the input image; traversing at least two initial face bounding boxes and at least two initial headwear bounding boxes, and respectively determining the face intersection-over-union ratios between the at least two initial face bounding boxes and the initial head bounding box, and the headwear intersection-over-union ratios between the at least two initial face bounding boxes and the initial head bounding box; if the face intersection-over-union ratio is greater than or equal to a first preset threshold, determining that there is an associated face bounding box in the initial head bounding box, and, if the headwear intersection-over-union ratio is greater than or equal to a second preset threshold, determining that there is an associated headwear bounding box in the initial head bounding box.

[0009] In some embodiments of the present disclosure, after the step of determining that there is an associated face bounding box in the initial head bounding box if the face intersection-over-union ratio is greater than or equal to a first preset threshold, the method includes: if the number of associated face bounding boxes is greater than or equal to two, determining the face matching degree between the initial head bounding box and the two or more associated face bounding boxes; comparing the face matching degree between the initial head bounding box and the two or more associated face bounding boxes, and taking the associated face bounding box with the highest face matching degree as the associated face bounding box that uniquely matches the initial head bounding box.

[0010] In some embodiments of the present disclosure, after the step of determining that there is an associated headgear external frame in the initial human head external frame if the headgear intersection-union ratio is greater than or equal to a second preset threshold, the method includes: if the number of associated headgear external frames is greater than or equal to two, determining the headgear matching degree between the initial human head external frame and the two associated headgear external frames respectively; comparing the headgear matching degree between the initial human head external frame and the two associated headgear external frames respectively, and taking the associated headgear external frame with the highest headgear matching degree as the associated headgear external frame that uniquely matches the initial human head external frame.

[0011] In some embodiments of the present disclosure, if the ratio of the head width to the face width is greater than or equal to a preset value, the initial head external frame area is corrected, and obtaining the corrected actual head external frame area includes: if the ratio of the head width to the face width is greater than or equal to a preset value, multiplying the initial head external frame area by the ratio to obtain the actual head external frame area.

[0012] According to a second aspect of the present disclosure, a device for determining the area of ​​a human head circumscribed frame is provided, comprising:

[0013] an acquisition unit, configured to determine a head length and a head width corresponding to an initial head bounding box of a person to be predicted in an input image, and multiply the head length and the head width to obtain an initial head bounding box area corresponding to the initial head bounding box;

[0014] a determining unit for determining, if the initial head external bounding box has an associated face external bounding box and an associated headwear external bounding box, and if the facial information corresponding to the associated face external bounding box is credible, a ratio of the head width to the face width corresponding to the associated face external bounding box, and the associated face external bounding box and the associated headwear external bounding box are the face external frames and headwear external frames that uniquely match the initial head external bounding box;

[0015] The correction unit is used to correct the initial head circumference frame area if the ratio of the head width to the face width is greater than or equal to a preset value, and obtain the corrected actual head circumference frame area.

[0016] According to a third aspect of the present disclosure, there is provided an electronic device, including:

[0017] at least one processor; and

[0018] a memory communicatively connected to the at least one processor; wherein,

[0019] The memory stores instructions that can be executed by the at least one processor. The instructions are executed by the at least one processor to enable the at least one processor to perform the method described in the first aspect.

[0020] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the method described in the first aspect.

[0021] According to a fifth aspect of the present disclosure, a vehicle is provided, comprising the apparatus for determining the area of ​​a circumscribed frame of a human head as described in the second aspect or the electronic device as described in the third aspect.

[0022] The present disclosure provides a method, device, electronic device, storage medium and vehicle for determining the area of ​​a head external frame, which determines the head length and head width corresponding to the initial head external frame of the person object to be predicted in the input image, and multiplies the head length and head width to obtain the initial head external frame area corresponding to the initial head external frame; if the initial head external frame has an associated face external frame and an associated headwear external frame, and the face information corresponding to the associated face external frame is credible, the ratio of the head width to the face width corresponding to the associated face external frame is determined, and the associated face external frame and the associated headwear external frame are the face external frame and headwear external frame that uniquely match the initial head external frame; if If the ratio of the head width to the face width is greater than or equal to the preset value, the initial head bounding box area is corrected to obtain the corrected actual head bounding box area; face and head matching and head hat matching are performed separately for the predicted person object, and the associated face bounding box and associated headwear bounding box that match the initial head bounding box are determined, and the initial head bounding box area is corrected using the associated face bounding box and the associated headwear bounding box, respectively, so as to successfully return the predicted head bounding box area to the actual head bounding box area without the influence of headwear, thereby improving the accuracy of head bounding box area detection and facilitating more accurate depth estimation for subsequent tasks such as head collision avoidance.

[0023] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present application, nor is it intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The accompanying drawings are provided to facilitate a better understanding of the present invention and do not constitute a limitation of the present disclosure.

[0025] Figure 1 A flowchart of a method for determining the area of ​​a human head circumference frame provided in an embodiment of the present disclosure;

[0026] Figure 2 A flowchart of another method for determining the area of ​​a human head circumference frame provided by an embodiment of the present disclosure;

[0027] Figure 3 A schematic diagram of obtaining an external frame using a human head detection and classification network provided by an embodiment of the present disclosure;

[0028] Figure 4 A schematic diagram of an initial head circumference frame intersecting with an initial face circumference frame provided in an embodiment of the present disclosure;

[0029] Figure 5 A schematic structural diagram of a device for determining the area of ​​a human head circumference frame provided in an embodiment of the present disclosure;

[0030] Figure 6 A schematic block diagram of an exemplary electronic device 600 is provided for an embodiment of the present disclosure. DETAILED DESCRIPTION

[0031] The following description of exemplary embodiments of the present disclosure is made in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding. These details should be considered as merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0032] In order to solve the problems in the related art, the present invention distinguishes and separates the external frame of the human head and the external frame of the headwear, so as to return the predicted external frame area of ​​the human head to the actual external frame area of ​​the human head without the influence of the headwear, thereby avoiding the problem of inaccurate predicted external frame area of ​​the human head caused by the person to be predicted wearing headwear, improving the accuracy of the detection of the external frame area of ​​the human head, and facilitating more accurate depth estimation for subsequent tasks such as head collision avoidance.

[0033] The following describes a method, device, electronic device, storage medium, and vehicle for determining the area of ​​a human head circumference frame according to embodiments of the present disclosure with reference to the accompanying drawings.

[0034] Figure 1 This is a flow chart of a method for determining the area of ​​a human head's external frame provided in an embodiment of the present disclosure. This method can be executed by an electronic device, specifically, a PC, server, or other electronic device. This method can be applied to scenarios where a human head is recognized and located in an image or video, specifically, in a car's smart cockpit or security monitoring scenario, and is not limited in this embodiment of the present disclosure. Figure 1 As shown, the method includes:

[0035] Step 101: Determine the head length and head width corresponding to the initial head bounding box of the person object to be predicted in the input image, and multiply the head length and head width to obtain the initial head bounding box area corresponding to the initial head bounding box.

[0036] In some embodiments, the person object to be predicted refers to any person that needs to be detected in the input image collected by the acquisition device. In the present disclosure, the person object to be predicted can be a person who can be identified in front of a surveillance camera, or a user who is using a device that requires head tracking or anti-collision functions (such as a virtual reality helmet).

[0037] A head bounding box is a geometric model used to represent the external contours of a head and to estimate and identify its size and position. The head bounding box can be a simplified head shape composed of a series of line segments that describe the basic shape and size of the head. In this disclosure, the head bounding box takes the form of an outer rectangular box surrounding the head.

[0038] The initial head bounding box in this disclosure is formed by detecting the vertex coordinates of the head bounding box through a detection network, and using these vertex coordinates to form a corresponding head bounding box. The head length corresponding to the initial head bounding box is the boundary length of the initial head bounding box, and similarly, the head width is the boundary width of the initial head bounding box.

[0039] In the present disclosure, since the initial human head circumference frame is in the form of an external rectangular frame, the area of ​​the initial human head circumference frame is calculated using a rectangular area calculation formula, and the product of the length and width is used as the final area of ​​the initial human head circumference frame.

[0040] Step 102: If the initial head bounding box has an associated face bounding box and an associated headwear bounding box, and the facial information corresponding to the associated face bounding box is credible, determine the ratio of the head width to the face width corresponding to the associated face bounding box, and the associated face bounding box and the associated headwear bounding box are the face bounding box and headwear bounding box that uniquely match the initial head bounding box.

[0041] In some embodiments, when acquiring an initial head bounding box, the present disclosure also acquires an initial face bounding box and an initial headwear bounding box. Since a head can only have one face and one headwear, if at least two initial face bounding boxes and at least two initial headwear bounding boxes are detected during detection, the present disclosure needs to perform head-face pairing and head-headwear pairing to acquire a uniquely associated face bounding box and headwear bounding box corresponding to the initial head bounding box. Headwear may refer to head accessories such as hats and hairpins that may cause errors in the detection of the head bounding box area.

[0042] When determining that the initial head bounding box has an associated face bounding box and an associated headwear bounding box, the present disclosure further needs to determine whether the facial information corresponding to the associated face bounding box is credible. Whether the facial information is credible refers to whether the recognition result of the facial image in the associated face bounding box is accurate and reliable, that is, whether it can fully reflect the facial features of the person to be predicted. Facial information may include geometric features of the face (such as the size, position, and shape of the eyes, nose, and mouth, etc.), facial posture and expression (such as the direction of the face, tilt angle, degree of smile, etc.), and facial texture and color (such as skin color, texture distribution, etc.).

[0043] The face width corresponding to the associated face bounding box refers to the boundary width of the associated face bounding box, and is obtained through the vertex coordinates of the associated face bounding box.

[0044] Step 103: If the ratio of the head width to the face width is greater than or equal to a preset value, correct the initial head bounding box area to obtain the corrected actual head bounding box area.

[0045] In some embodiments, if the ratio of the head width to the face width is greater than or equal to a preset value, and it is determined in step 102 that there is an associated headwear external frame, it can be determined that the associated headwear external frame affects the initial head external frame area, and the initial head external frame area needs to be corrected to obtain the actual head external frame area that is not affected by the associated headwear external frame.

[0046] Among them, the preset value is pre-set by the staff based on actual experience and actual conditions, and the specific data is not limited in the embodiments of this disclosure.

[0047] In summary, the technical solution provided by the present disclosure is to determine the head length and head width corresponding to the initial head bounding box of the person to be predicted, and multiply the head length and head width to obtain the initial head bounding box area corresponding to the initial head bounding box; if the initial head bounding box has an associated face bounding box and an associated headwear bounding box, and the face information corresponding to the associated face bounding box is credible, determine the ratio of the head width to the face width corresponding to the associated face bounding box, and the associated face bounding box and the associated headwear bounding box are the initial The head bounding box uniquely matches the face bounding box and the headwear bounding box; if the ratio of the head width to the face width is greater than or equal to the preset value, the initial head bounding box area is corrected to obtain the corrected actual head bounding box area, so as to distinguish and separate the head bounding box and the headwear bounding box, thereby successfully returning the predicted head bounding box area to the actual head bounding box area without the influence of the headwear, thereby improving the accuracy of the head bounding box area detection and facilitating more accurate depth estimation for subsequent tasks such as head collision avoidance.

[0048] Figure 2This is a flow chart of another method for determining the area of ​​a human head circumference frame provided in an embodiment of the present disclosure. The method can be executed by an electronic device, specifically, by an electronic device such as a PC or a server. Figure 2 based on Figure 1 In the embodiment shown, steps 102 and 103 are further defined. Figure 2 In the embodiment shown, step 102 includes step 202, step 203, step 204 and step 205, and step 103 includes step 206. Figure 2 As shown, the method may include:

[0049] Step 201: Determine the head length and head width corresponding to the initial head bounding box of the person object to be predicted in the input image, and multiply the head length and head width to obtain the initial head bounding box area corresponding to the initial head bounding box.

[0050] In some embodiments, determining the head length and head width corresponding to an initial head bounding box of a person to be predicted in an input image, and multiplying the head length and head width to obtain an initial head bounding box area corresponding to the initial head bounding box includes: obtaining vertex coordinates of the initial head bounding box of the person to be predicted in the input image; determining a boundary length and boundary width of the initial head bounding box corresponding to the vertex coordinates, and using the boundary length H1 as the head length and the boundary width W1 as the head width. The vertex coordinates may be the vertex coordinates of the upper left corner and the vertex coordinates of the lower right corner of the head external bounding box.

[0051] Use formula 1 to obtain the initial head bounding box area S_:

[0052] S_ = W1 * H1 Formula 1

[0053] Among them, W1 is the length of the human head and W2 is the width of the human head.

[0054] In an optional embodiment of the present disclosure, a detection network may be used to obtain vertex coordinates of an initial head bounding box of a person to be predicted in an input image, thereby forming an initial head bounding box. The detection network refers to a deep learning network used to extract features from the input image, and in this disclosure, may specifically be a human head detection and classification network.

[0055] The human head detection and classification network is a deep learning network built for detection and classification scenarios. It is usually composed of a backbone network, a shoulder network (neck), and a head network (head). It is used to detect whether there is a human body or a human head and return the vertex coordinates of the human body's bounding box and the vertex coordinates of the head's bounding box. In the present disclosure, before processing the input image through the human head detection and classification network, it is necessary to train a human head detection and classification network through a large amount of training data. These training data can be various image or video data sets, which contain different human and head postures, different backgrounds and lighting conditions, etc. Figure 3 The figure shows a schematic diagram of obtaining an external bounding box using a human head detection and classification network. Before inputting the input image into the human head detection and classification network, the input image (original image) needs to be preprocessed. The preprocessing may include operations such as scaling, cropping, and normalization to facilitate the human head detection and classification network to better extract features. The human head detection and classification network then uses the preprocessed input image to extract features through the backbone network (backbone), shoulder network (neck), and head network (head). The output of the head network is parsed and processed through post-processing, such as non-maximum suppression (NMS) operations, to eliminate overlapping detection frames and return the vertex coordinates of the initial human external bounding box (human body frame coordinates), the vertex coordinates of the initial head external bounding box (head frame coordinates), the vertex coordinates of the initial face external bounding box (face frame coordinates), and the vertex coordinates of the initial headwear external bounding box (hat frame coordinates). Among them, during the detection process of the human head detection and classification network, the confidence corresponding to the initial human body external frame, the initial head external frame, the initial face external frame and the initial headwear external frame can be directly obtained.

[0056] Step 202: Determine whether there is an associated face bounding box and an associated headwear bounding box in the initial head bounding box.

[0057] In some embodiments, determining whether there is an associated face circumscribed frame and an associated headwear circumscribed frame in the initial head circumscribed frame includes: obtaining at least two initial face circumscribed frames and at least two initial headwear circumscribed frames corresponding to the initial head circumscribed frame of the person object to be predicted in the input image; traversing at least two initial face circumscribed frames and at least two initial headwear circumscribed frames, and respectively determining the face intersection-over-union ratios between the at least two initial face circumscribed frames and the initial head circumscribed frame, and the headwear intersection-over-union ratios between the at least two initial face circumscribed frames and the initial head circumscribed frame; if the face intersection-over-union ratio is greater than or equal to a first preset threshold, determining that an associated face circumscribed frame exists in the initial head circumscribed frame, and, if the headwear intersection-over-union ratio is greater than or equal to a second preset threshold, determining that an associated headwear circumscribed frame exists in the initial head circumscribed frame.

[0058] If the face intersection-over-union ratio is greater than or equal to a first preset threshold, determining that there is an associated face bounding box in the initial head bounding box includes: if the number of associated face bounding boxes is greater than or equal to two, determining the face matching degree between the initial head bounding box and the two associated face bounding boxes respectively; comparing the face matching degree between the initial head bounding box and the two associated face bounding boxes respectively, and taking the associated face bounding box with the highest face matching degree as the associated face bounding box that uniquely matches the initial head bounding box.

[0059] If the headwear intersection-union ratio is greater than or equal to the second preset threshold, determining that there is an associated headwear external frame in the initial head external frame includes: if the number of associated headwear external frames is greater than or equal to two, determining the headwear matching degree between the initial head external frame and the associated headwear external frames greater than or equal to two respectively; comparing the headwear matching degree between the initial head external frame and the associated headwear external frames greater than or equal to two respectively, and taking the associated headwear external frame with the highest headwear matching degree as the associated headwear external frame that uniquely matches the initial head external frame. Among them, the first preset threshold and the second preset threshold can be set by the staff based on actual conditions and actual experience, and are not limited in the present disclosed embodiment. Face matching refers to the similarity or difference between the associated face external frame and the initial head external frame, and headwear matching refers to the similarity or difference between the associated headwear external frame and the initial head external frame.

[0060] The face matching degree can be calculated based on various factors, for example, it can be calculated through the position, size, shape, color, texture, intersection-over-union and other features of the initial head bounding box and the associated face bounding box; the headwear matching degree can be calculated based on various factors, for example, it can be calculated through the position, size, shape, color, texture, intersection-over-union and other features of the initial head bounding box and the associated headwear bounding box.

[0061] In an optional embodiment of the present disclosure, when performing head-face pairing, for any initial head bounding box, all initial face bounding boxes corresponding to the initial head bounding box are traversed, and the face intersection-over-union ratio (IOU) 1 between all initial face bounding boxes and the initial head bounding box is calculated. IOU is the abbreviation of Intersection over Union, which is an indicator to measure the similarity of two rectangular boxes (usually used for target detection).

[0062] like Figure 4 The figure shows a schematic diagram of the intersection of an initial head bounding box and an initial face bounding box, where A is the area of ​​the first rectangular box, which can be regarded as the initial head bounding box in this disclosure; B is the area of ​​the second rectangular box, which can be regarded as the initial face bounding box in this disclosure, and A and B intersect at C. In this disclosure, the intersection-over-union (IOU) of A and B can be calculated using Formula 2:

[0063] IOU 1 = (A∩B) / (A∪B) Formula 2

[0064] Among them, ∩ represents the intersection of two areas A and B; ∪ represents the union of two areas A and B.

[0065] It is understood that the range of IOU is [0, 1], and a larger value indicates that the two rectangular boxes are more similar or overlap more. In the present disclosure, the first preset threshold can be set to T1, which refers to the IOU 1 confidence threshold of the head and face.

[0066] For all the calculated face intersection-over-union (IOU) 1s, the present disclosure only retains the part with face intersection-over-union (IOU) 1 ≥ T1. The initial face bounding box corresponding to the face intersection-over-union (IOU) 1 is the face that the initial head bounding box may correspond to, that is, the associated face bounding box, and the associated face bounding box is stored in the database.

[0067] If the detection network detects multiple initial head bounding boxes, it is necessary to perform the head-face matching operation on all initial head bounding boxes, so that the matching relationship of the initial face bounding box corresponding to each initial head bounding box can be obtained, that is, the associated face bounding box corresponding to each initial head bounding box can be obtained.

[0068] Among them, it should be noted that when actually performing the head-face matching operation, due to factors such as the accuracy of face detection, face similarity, occlusion, rotation, etc., there may be a situation where an initial head bounding box corresponds to multiple associated face bounding boxes. Therefore, the present disclosure can use the Hungarian algorithm to re-match the initial head bounding box with at least two associated face bounding boxes, so that the initial head bounding box and the associated face bounding boxes correspond one to one.

[0069] The Hungarian algorithm is an algorithm for finding perfect matches in a graph. It can find a perfect matching path with the lowest cost in a graph with multiple source points and multiple sink points. In this disclosure, the initial head bounding box and the associated face bounding boxes can be used as nodes of the graph. If an initial head bounding box corresponds to multiple associated face bounding boxes, multiple edges are constructed from the initial head bounding box node to each associated face bounding box node, and the corresponding matching degrees are assigned. Then, the Hungarian algorithm will find a perfect matching path with the maximum or minimum matching degree on these nodes and edges, so that each initial head bounding box corresponds to only one associated face bounding box, improving the accuracy and reliability of head and face pairing. Among them, the perfect matching path can be specifically determined according to the actual meaning of the matching degree. For example, if the matching degree is the intersection-over-union ratio, the one with the largest intersection-over-union ratio can be selected as the perfect matching path. Conversely, if the matching degree is the color difference, the one with the smallest color difference can be selected as the perfect matching path. This is not limited in the embodiments of the present disclosure.

[0070] In an optional embodiment of the present disclosure, the method used for matching human heads and headwear is the same as that for matching human heads and faces. For any initial human head circumference frame, all initial headwear circumference frames corresponding to the initial human head circumference frame are traversed, and the headwear intersection-union ratio (IOU) 2 between all initial headwear circumference frames and the initial human head circumference frame is calculated.

[0071] Reference Figure 4 , you can Figure 4 A is regarded as the initial human head external frame; B is regarded as the initial headwear external frame, and A and B intersect at C. In this disclosure, the intersection-and-union ratio (IOU) 2 of A and B can be calculated by formula 2:

[0072] IOU 2 = (A∩B) / (A∪B) Formula 2

[0073] Among them, ∩ represents the intersection of two areas A and B; ∪ represents the union of two areas A and B.

[0074] In the present disclosure, the second preset threshold can be set to T2, and the second preset threshold refers to the confidence threshold of the human headwear IOU 2.

[0075] For all the calculated headgear intersection-over-union ratios (IOU) 2, the present disclosure only retains the part where the headgear intersection-over-union ratio (IOU) 2≥T2. The initial headgear external bounding box corresponding to the headgear intersection-over-union ratio (IOU) 2 is the headgear that the initial head external bounding box may correspond to, that is, the associated headgear external bounding box, and the associated headgear external bounding box is stored in the database.

[0076] If the detection network detects multiple initial head external frames, it is necessary to perform the head and headgear pairing operation on all initial headgear external frames, so that the matching relationship of the initial headgear external frames corresponding to each initial head external frame can be obtained, that is, the associated headgear external frame corresponding to each initial head external frame can be obtained.

[0077] Among them, when actually performing the head and headwear pairing operation, due to factors such as the accuracy of face detection, face similarity, occlusion, rotation, etc., there may be a situation where an initial head external frame corresponds to multiple associated headwear external frames. Therefore, the present invention can use the Hungarian algorithm to re-match the initial head external frame with at least two associated headwear external frames, so that the initial head external frame and the associated headwear external frames correspond one to one.

[0078] In addition, in the present disclosure, if there is no associated face bounding box or associated headdress bounding box for the initial head bounding box, the area of the initial head bounding box is used as the actual head bounding box area. That is, if the face intersection over union (IoU) between the initial head bounding box and the initial face bounding box is less than the first preset threshold or the headdress IoU between the initial head bounding box and the initial headdress bounding box is less than the second preset threshold, then at this time, there is no associated face bounding box or no associated headdress bounding box for the initial head bounding box, and the area of the initial head bounding box obtained through the detection network is directly used as the final actual head bounding box area.

[0079] Step 203: If there are an associated face bounding box and an associated headdress bounding box for the initial head bounding box, determine whether the confidence of the associated face bounding box is greater than or equal to the face confidence threshold. The confidence of the associated face bounding box is obtained through detection by the detection network.

[0080] Step 204: If the confidence of the associated face bounding box is greater than or equal to the face confidence threshold, determine that the face information corresponding to the associated face bounding box is credible.

[0081] In some embodiments, due to较多遮挡 in the internal space of the cockpit, and at the same time the position of the camera is relatively high (for example, in the intelligent cockpit scenario of a car, the camera may be located on the roof), and the obtained face pixel area is small, the face detection task is relatively difficult, resulting in low detection accuracy. Therefore, when it is determined that there are an associated face bounding box and an associated headdress bounding box in the initial head bounding box, the confidence of the associated face bounding box obtained by the detection network needs to be used to compare with the face confidence threshold. If the confidence is greater than or equal to the face confidence threshold, it is determined that the face information in the associated face bounding box is credible. Among them, the face confidence threshold is set in advance and is determined according to the actual experience and actual situation of the staff, and is not limited in the embodiments of the present disclosure

[0082] In addition, in the present disclosure, if the confidence of the associated face bounding box is less than the face confidence threshold, it is determined that the face information is not credible, and the area of the initial head bounding box is directly used as the actual head bounding box area.

[0083] In an optional embodiment of the present disclosure, the confidence m of the associated face bounding box is determined; the face confidence threshold is set to Tf.

[0084] When the confidence is less than the face confidence threshold, that is, m < Tf, it is determined that the face information of the associated face bounding box is not credible, and the initial head area_ is directly returned, and the process ends.

[0085] When the confidence is greater than or equal to the face confidence threshold, that is, m ≥ Tf, it is determined that the face information of the associated face bounding box is credible.

[0086] It should be noted that the Chinese phrase "较多遮挡" in the original text needs to be further clarified or more accurately translated according to the specific context. Here, a rough translation is provided for the overall content.Step 205: Determine the ratio of the head width to the face width corresponding to the associated face bounding box, where the associated face bounding box and the associated headwear bounding box are the face bounding box and the headwear bounding box that uniquely match the initial head bounding box.

[0087] In some embodiments, if the facial information corresponding to the associated face outside the bounding box is credible, the bounding box's border length H2 and width W2 can be determined based on the vertex coordinates of the bounding box obtained through the detection network. The bounding box's width W2 is then used as the face width of the bounding box.

[0088] At this time, the ratio of the head width to the face width obtained by associating the face bounding box is obtained.

[0089] Step 206: If the ratio of the head width to the face width is greater than or equal to a preset value, multiply the initial head bounding box area by the ratio to obtain the actual head bounding box area.

[0090] In some embodiments, the ratio obtained above is compared with a preset value. When the ratio is greater than or equal to the preset value, the initial head circumference frame area is multiplied by the ratio to obtain the actual head circumference frame area.

[0091] Furthermore, if the ratio of the head width to the face width is less than a preset value, the initial head bounding box area is used as the actual head bounding box area. The preset value is a threshold set by the staff based on actual experience and actual conditions, and the specific value is not limited in the disclosed embodiments.

[0092] In an optional embodiment of the present disclosure, taking the preset value of 1.2 as an example, it is determined whether the current initial human head external frame area is enlarged due to the headwear.

[0093] When the ratio of head width W1 to face width W2 is less than the preset value 1.2, that is, It is determined that the initial head bounding box and the associated face bounding box are highly overlapped in width, and the head width is not affected by the headwear. The area S_ of the initial head bounding box is directly used as the actual head bounding box area.

[0094] When the ratio of head width W1 to face width W2 is greater than or equal to the preset value 1.2, It is determined that the initial head bounding box and the associated face bounding box have a large difference in width. Combined with the fact that the associated headwear bounding box is detected at this time, it is very likely that the headwear is too wide and the detection network considers the headwear as part of the head. Therefore, the initial head bounding box is the union of the headwear and the actual head. It needs to be corrected to obtain the area S of the actual head bounding box, as shown in Formula 3:

[0095]

[0096] Among them, S_ is the initial head external frame area, is the calculated ratio of the head width W1 to the face width W2.

[0097] In summary, the technical solution provided by the present invention utilizes a detection network to obtain an initial head bounding box, an initial face bounding box, and an initial headwear bounding box, and uses the Hungarian algorithm in the head-face matching and headwear matching process to make the head, face, and headwear correspond one-to-one, and uses this matching relationship to successfully distinguish and separate the associated headwear bounding box and the actual head bounding box, thereby improving the accuracy of determining the area of ​​the head bounding box, and returning the initial head bounding box area to the actual head bounding box area without the influence of headwear. Under this same scale standard, using the actual head bounding box area for depth estimation is more robust and accurate, thereby facilitating more accurate depth estimation for subsequent tasks such as head collision avoidance, thereby improving the precision and recall of these tasks.

[0098] Corresponding to the aforementioned method for determining the area of ​​a human head's circumscribed frame, the present invention also provides a device for determining the area of ​​a human head's circumscribed frame. Since the device embodiments of the present invention correspond to the aforementioned method embodiments, details not disclosed in the device embodiments can be referred to in the aforementioned method embodiments and will not be further elaborated in this invention.

[0099] Figure 5 This is a schematic diagram of a device for determining the area of ​​a human head circumference frame provided by an embodiment of the present disclosure. Figure 5 Shown, including:

[0100] An acquisition unit 510 is configured to determine a head length and a head width corresponding to an initial head bounding box of a person to be predicted in the input image, and multiply the head length and the head width to obtain an initial head bounding box area corresponding to the initial head bounding box;

[0101] A determining unit 520 is configured to determine, if the initial head bounding box has an associated face bounding box and an associated headwear bounding box, and if the facial information corresponding to the associated face bounding box is credible, a ratio of the head width to the facial width corresponding to the associated face bounding box, and the associated face bounding box and the associated headwear bounding box are the face bounding box and the headwear bounding box that uniquely match the initial head bounding box;

[0102] The correction unit 530 is configured to correct the initial head bounding box area if the ratio of the head width to the face width is greater than or equal to a preset value, and obtain the corrected actual head bounding box area.

[0103] In some embodiments of the present disclosure, the acquisition unit 510 is used to: obtain the vertex coordinates of the initial head circumscribed frame of the person object to be predicted in the input image; determine the boundary length and boundary width of the initial head circumscribed frame corresponding to the vertex coordinates, and use the boundary length as the head length and the boundary width as the head width.

[0104] In some embodiments of the present disclosure, the determination unit 520 is used to: determine whether there is an associated face bounding box and an associated headwear bounding box in the initial head bounding box; if the initial head bounding box does not have an associated face bounding box or an associated headwear bounding box, use the area of ​​the initial head bounding box as the actual head bounding box area; if the initial head bounding box has an associated face bounding box and an associated headwear bounding box, determine whether the confidence of the associated face bounding box is greater than or equal to the face confidence threshold, and the confidence of the associated face bounding box is determined by detecting obtained by network detection; if the confidence of the associated face bounding box is less than the face confidence threshold, it is determined that the face information is unreliable, and the area of ​​the initial head bounding box is used as the actual head bounding box area; if the confidence of the associated face bounding box is greater than or equal to the face confidence threshold, it is determined that the face information corresponding to the associated face bounding box is credible, and the ratio of the head width to the face width corresponding to the associated face bounding box is determined, and the associated face bounding box and the associated headwear bounding box are the face bounding box and headwear bounding box that uniquely match the initial head bounding box.

[0105] In some embodiments of the present disclosure, the determination unit 520 is used to: obtain at least two initial face circumscribed frames and at least two initial headwear circumscribed frames corresponding to the initial head circumscribed frame of the person object to be predicted in the input image; traverse the at least two initial face circumscribed frames and at least two initial headwear circumscribed frames, and respectively determine the face intersection-over-union ratios between the at least two initial face circumscribed frames and the initial head circumscribed frame, and the headwear intersection-over-union ratios between the at least two initial face circumscribed frames and the initial head circumscribed frame; if the face intersection-over-union ratio is greater than or equal to a first preset threshold, determine that there is an associated face circumscribed frame in the initial head circumscribed frame, and, if the headwear intersection-over-union ratio is greater than or equal to a second preset threshold, determine that there is an associated headwear circumscribed frame in the initial head circumscribed frame.

[0106] In some embodiments of the present disclosure, the determination unit 520 is used to: if the number of associated face bounding boxes is greater than or equal to two, determine the face matching degree between the initial head bounding box and the two or more associated face bounding boxes; compare the face matching degree between the initial head bounding box and the two or more associated face bounding boxes, and take the associated face bounding box with the highest face matching degree as the associated face bounding box that uniquely matches the initial head bounding box.

[0107] In some embodiments of the present disclosure, the determination unit 520 is used to: if the number of associated headgear external frames is greater than or equal to two, determine the headgear matching degree between the initial human head external frame and the two associated headgear external frames respectively; compare the headgear matching degree between the initial human head external frame and the two associated headgear external frames respectively, and take the associated headgear external frame with the highest headgear matching degree as the associated headgear external frame that uniquely matches the initial human head external frame.

[0108] In some embodiments of the present disclosure, the correction unit 530 is configured to: if the ratio of the head width to the face width is greater than or equal to a preset value, multiply the initial head bounding box area by the ratio to obtain the actual head bounding box area.

[0109] It should be noted that the above explanation of the method embodiment is also applicable to the device of this embodiment, and the principles are the same, which is not limited in this embodiment.

[0110] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a vehicle.

[0111] Figure 6 A schematic block diagram of an example electronic device 600 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are provided as examples only and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0112] like Figure 6 As shown, the device 600 includes a computing unit 601, which can perform various appropriate actions and processes according to a computer program stored in a ROM (Read-Only Memory) 602 or a computer program loaded from a storage unit 608 into a RAM (Random Access Memory) 603. Various programs and data required for the operation of the device 600 can also be stored in the RAM 603. The computing unit 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An I / O (Input / Output) interface 605 is also connected to the bus 604.

[0113] Various components in device 600 are connected to I / O interface 605, including an input unit 606, such as a keyboard, mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a magnetic disk, optical disk, etc.; and a communication unit 609, such as a network card, modem, wireless communication transceiver, etc. The communication unit 609 allows device 600 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0114] The computing unit 601 can be any general-purpose and / or specialized processing component with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a CPU (Central Processing Unit), a GPU (Graphic Processing Unit), various specialized AI (Artificial Intelligence) computing chips, various computing units that run machine learning model algorithms, a DSP (Digital Signal Processor), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above, such as the method for determining the area of ​​a human head circumscribed frame. For example, in some embodiments, the method for determining the area of ​​a human head circumscribed frame can be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device 600 via the ROM 602 and / or the communication unit 609. When the computer program is loaded into the RAM 603 and executed by the computing unit 601, one or more steps of the method described above can be performed. Alternatively, in other embodiments, the computing unit 601 may be configured to execute the aforementioned method for determining the area of ​​the circumscribed frame of a human head in any other appropriate manner (for example, by means of firmware).

[0115] Various embodiments of the systems and techniques described herein can be implemented in digital electronic circuit systems, integrated circuit systems, FPGAs (Field Programmable Gate Arrays), ASICs (Application-Specific Integrated Circuits), ASSPs (Application-Specific Standard Products), SOCs (System on Chips), CPLDs (Complex Programmable Logic Devices), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include being implemented in one or more computer programs that are executable and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special-purpose or general-purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0116] The program code for implementing the method of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device so that when the program code is executed by the processor or controller, the functions / operations specified in the flow chart and / or block diagram are implemented. The program code can be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0117] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or apparatus. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or apparatus, or any suitable combination of the foregoing. More specific examples of machine-readable storage media may include an electrical connection based on one or more wires, a portable computer disk, a hard disk, RAM, ROM, EPROM (Electrically Programmable Read-Only-Memory) or flash memory, optical fiber, CD-ROM (Compact Disc Read-Only Memory), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0118] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (Cathode-Ray Tube) or LCD (Liquid Crystal Display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0119] The systems and techniques described herein can be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: LAN (Local Area Network), WAN (Wide Area Network), the Internet, and blockchain networks.

[0120] A computer system may include a client and a server. The client and server are generally remote from each other and typically interact via a communication network. This client-server relationship is established by computer programs running on the respective computers, establishing a client-server relationship. The server may be a cloud server, also known as a cloud computing server or cloud host, a host product within the cloud computing service ecosystem that addresses the management difficulties and limited scalability of traditional physical hosts and VPS services ("Virtual Private Servers" or simply "VPS"). The server may also be a server in a distributed system or a server integrated with blockchain.

[0121] It's important to note that artificial intelligence (AI) is the study of how computers can simulate certain human thought processes and intelligent behaviors (such as learning, reasoning, thinking, and planning). This encompasses both hardware and software technologies. AI hardware technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, and big data processing. AI software technologies primarily encompass computer vision, speech recognition, natural language processing, machine learning / deep learning, big data processing, and knowledge graphs.

[0122] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved. This is not a limitation herein.

[0123] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the scope of protection of this disclosure.

Claims

1. A method for determining the area of ​​a human head circumference frame, characterized in that: The method comprises: Determine a head length and a head width corresponding to an initial head bounding box of a person object to be predicted in the input image, and multiply the head length and the head width to obtain an initial head bounding box area corresponding to the initial head bounding box; If the initial head external bounding box has an associated face external bounding box and an associated headwear external bounding box, and the facial information corresponding to the associated face external bounding box is credible, determine the ratio of the head width to the face width corresponding to the associated face external bounding box, and the associated face external bounding box and the associated headwear external bounding box are the face external bounding boxes and headwear external bounding boxes that uniquely match the initial head external bounding box; If the ratio of the head width to the face width is greater than or equal to a preset value, the initial head bounding box area is corrected to obtain the corrected actual head bounding box area.

2. The method according to claim 1, characterized in that The step of determining the head length and head width corresponding to the initial head bounding box of the person object to be predicted in the input image comprises: Obtaining vertex coordinates of an initial head circumscribed frame of the person object to be predicted in the input image; Determine the boundary length and boundary width of the initial head circumscribed frame corresponding to the vertex coordinates, and use the boundary length as the head length and the boundary width as the head width.

3. The method according to claim 1, characterized in that If the initial head bounding box has an associated face bounding box and an associated headwear bounding box, and the facial information corresponding to the associated face bounding box is credible, determining the ratio of the head width to the face width corresponding to the associated face bounding box includes: Determine whether there is an associated face bounding box and an associated headwear bounding box in the initial head bounding box; If the initial head bounding box does not have an associated face bounding box or an associated headwear bounding box, the area of ​​the initial head bounding box is used as the actual head bounding box area; If the initial head circumscribed frame has an associated face circumscribed frame and an associated headwear circumscribed frame, determining whether the confidence of the associated face circumscribed frame is greater than or equal to a face confidence threshold, where the confidence of the associated face circumscribed frame is obtained through detection by a detection network; If the confidence level of the associated face bounding box is less than the face confidence level threshold, the face information is determined to be unreliable, and the area of ​​the initial head bounding box is used as the actual head bounding box area; If the confidence of the associated face circumscribed frame is greater than or equal to the face confidence threshold, it is determined that the face information corresponding to the associated face circumscribed frame is credible, and the ratio of the head width to the face width corresponding to the associated face circumscribed frame is determined, and the associated face circumscribed frame and the associated headwear circumscribed frame are the face circumscribed frame and headwear circumscribed frame that uniquely match the initial head circumscribed frame.

4. The method according to claim 3, characterized in that The determining whether there is an associated face bounding box and an associated headwear bounding box in the initial head bounding box includes: Obtaining at least two initial human face circumscribed frames and at least two initial headwear circumscribed frames corresponding to the initial human head circumscribed frame of the person object to be predicted in the input image; Traversing the at least two initial face circumscribed frames and the at least two initial headwear circumscribed frames, and respectively determining face intersection-over-union ratios between the at least two initial face circumscribed frames and the initial head circumscribed frame, and headwear intersection-over-union ratios between the at least two initial headwear circumscribed frames and the initial head circumscribed frame; If the face intersection-over-union ratio is greater than or equal to a first preset threshold, it is determined that there is an associated face bounding box in the initial head bounding box, and, If the headwear intersection-over-union ratio is greater than or equal to a second preset threshold, it is determined that an associated headwear circumscribed frame exists in the initial human head circumscribed frame.

5. The method according to claim 4, characterized in that After the step of determining that an associated face bounding box exists in the initial head bounding box if the face intersection-over-union ratio is greater than or equal to a first preset threshold, the method includes: If the number of the associated face circumference frames is greater than or equal to two, determining the face matching degree between the initial head circumference frame and the greater than or equal to two associated face circumference frames respectively; Compare the face matching degrees between the initial head circumscribed frame and the two or more associated face circumscribed frames, and take the associated face circumscribed frame with the highest face matching degree as the associated face circumscribed frame that uniquely matches the initial head circumscribed frame.

6. The method according to claim 4, characterized in that After the step of determining that an associated headwear circumscribed frame exists in the initial human head circumscribed frame if the headwear intersection-over-union ratio is greater than or equal to a second preset threshold, the method includes: If the number of the associated headwear external frames is greater than or equal to two, determining the headwear matching degree between the initial human head external frame and the greater than or equal to two associated headwear external frames; The headwear matching degrees between the initial human head circumference frame and the two or more associated headwear circumference frames are compared, and the associated headwear circumference frame with the highest headwear matching degree is used as the associated headwear circumference frame that uniquely matches the initial human head circumference frame.

7. The method according to claim 1, characterized in that If the ratio of the head width to the face width is greater than or equal to a preset value, correcting the initial head bounding box area to obtain the corrected actual head bounding box area includes: If the ratio of the head width to the face width is greater than or equal to a preset value, the initial head circumference frame area is multiplied by the ratio to obtain the actual head circumference frame area.

8. A device for determining the area of ​​a human head external frame, characterized in that: include: an acquisition unit, configured to determine a head length and a head width corresponding to an initial head bounding box of a person object to be predicted in an input image, and multiply the head length and the head width to obtain an initial head bounding box area corresponding to the initial head bounding box; a determining unit configured to determine, if the initial head external bounding box has an associated face external bounding box and an associated headwear external bounding box, and if the facial information corresponding to the associated face external bounding box is credible, a ratio of the head width to the face width corresponding to the associated face external bounding box, wherein the associated face external bounding box and the associated headwear external bounding box are face external bounding boxes and headwear external bounding boxes that uniquely match the initial head external bounding box; The correction unit is used to correct the initial head circumference frame area if the ratio of the head width to the face width is greater than or equal to a preset value, and obtain the corrected actual head circumference frame area.

9. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 7.

10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 7.

11. A vehicle, characterized in that: It includes the device for determining the area of ​​the external frame of a human head as described in claim 8 or the electronic device as described in claim 9.