Method for checking detected key points of human body and method for identifying blackboard writing behavior
By calculating and comparing the lengths of the head and arms, the correctness of the key points of the human body is solved, and the problems of low accuracy and high computing power detection in the existing technology are solved, achieving higher accuracy and lower computing power requirements.
Patent Information
- Application Number
- CN202411710110.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-27
- Publication Date
- 2025-03-14
AI Technical Summary
In the prior art, the posture recognition method based on human body key point detection has low accuracy in teaching and research recording scenarios, and has a high demand for computing power, so it is not suitable for edge devices.
By obtaining the key points of the head and arm, calculating the length of the head and arm, comparing the preset comparison model, determining whether the relative scale estimate is within the preset threshold range, and determining the correctness of the key points of the human body.
It improves the accuracy of human key points detection, reduces the demand for computing power, and is suitable for more scenarios, especially edge devices.
Smart Images

Figure CN119625786A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of video image processing, and more specifically, to a method for checking detected key points of a human body and a method for identifying blackboard writing behavior. Background Art
[0002] With the development of information technology in the field of education, it is becoming more and more common to observe and count the interactive behaviors of teachers and students in classrooms through automated and intelligent means, supervise and objectively evaluate the learning status of each student, and improve teaching management and teachers' teaching quality in a targeted manner. Raising hands is the most typical behavior of students in the classroom, the most intuitive form of students' active participation in classroom content, and the most direct way for teachers to interact with students. It can be used as an effective way to evaluate students' learning status and teachers' teaching quality.
[0003] At present, the application logic of posture recognition methods based on human key point detection in common teaching and research recording and broadcasting scenarios is generally as follows: ① Use the human key point detection algorithm to detect the skeletal key points of all candidate targets. For example, in the detection of table lying behavior, it is necessary to first detect the key points such as the head, shoulder joints, elbow joints and wrist joints; ② Use the detected key points to set different posture judgment methods according to different geometric arrangements; ③ Or use the posture classification model to directly classify the posture of the detected human targets. There is an important premise in the above scheme, that is, the detection result of the human key point detection algorithm in step ① has a high accuracy rate. To meet this condition, common methods are: ① In the single-stage method, an algorithm model with a large number of parameters and computational complexity is used. Generally, the accuracy of such models is high; ② In the two-stage method, the human body detection algorithm is first used to obtain the human body bounding box in the image, and then the target in the bounding box is passed to the high-precision single-target human key point detector; The above two methods can suppress the false detection rate to a certain extent. But obviously, these schemes have high requirements for computing power, which is not friendly to edge devices with insufficient computing power. Summary of the invention
[0004] In order to overcome the defect of low accuracy of the current blackboard writing detection method, the present invention provides a method for checking detected key points of the human body and a method for blackboard writing behavior recognition. The technical solution adopted by the present invention is as follows.
[0005] In a first aspect, the present invention provides a method for checking detected key points of a human body, comprising:
[0006] Obtain the key points of the head and neck of the detection target;
[0007] Calculate the distance from the key point of the head to the key point of the neck, and record it as the head length;
[0008] Obtain the elbow key points and wrist key points on the same side of the detection target;
[0009] Calculate the distance from the elbow key point to the wrist key point, and record it as the length of one side of the arm;
[0010] Based on a preset comparison model, the head length is compared with the arm length on one side to obtain a relative scale estimation value;
[0011] When the relative scale estimation value is within a preset scale threshold range, it is determined that the detected human body key points are correct.
[0012] In one embodiment, the preset comparison model is:
[0013] Among them, β is the relative scale estimate, D H is the head length, D A is the arm length, W and b are preset parameters.
[0014] In one embodiment, it further includes:
[0015] If the head length is not within the preset head length range, it is determined that the human body key points of the current detection target are unavailable;
[0016] If the arm length on one side is not within the preset arm length range, it is determined that the human body key point of the current detection target is unavailable;
[0017] When it is determined that the human body key points of the current detection target are unavailable, it is determined that the detected human body key points are incorrect.
[0018] In a second aspect, the present invention provides a method for identifying blackboard writing behavior, comprising:
[0019] Obtain the key points of the head and neck of the detected target, as well as the key points of the elbow and wrist on the same side;
[0020] The detected human key points are checked using the method described above. If the detected human key points cannot be concluded to be correct, the use of the key points for blackboard writing behavior recognition is terminated.
[0021] Identify the face orientation of the detection target and determine whether the face orientation is within a preset orientation range;
[0022] Obtain the elbow key points and wrist key points on the same side of the detection target;
[0023] When the position of the wrist key point is higher than the position of the elbow key point and the face orientation is within a preset orientation range, it is determined that the detection target performs blackboard writing behavior.
[0024] In one embodiment, the process of identifying the face orientation of the detection target and determining whether the face orientation is within a preset orientation range includes:
[0025] Use the head detection algorithm to detect the head position of the detection target and obtain a valid head position detection area;
[0026] Use the face detection algorithm to detect the face position of the detection target and obtain a valid face position detection area;
[0027] When the ratio of the effective face position detection area to the effective head position detection area is within a preset ratio range, it is determined that the face orientation is within a preset orientation range.
[0028] In one implementation, the preset ratio range is 0.
[0029] In a third aspect, the present invention provides a device for checking detected key points of a human body, comprising the steps of:
[0030] An acquisition module is used to acquire the key points of the head and neck of the detection target; and acquire the key points of the elbow and wrist on the same side of the detection target;
[0031] A calculation module is used to calculate the distance from the key point of the head to the key point of the neck, which is recorded as the head length; and calculate the distance from the key point of the elbow to the key point of the wrist, which is recorded as the length of one side of the arm;
[0032] A comparison module, used for comparing the head length with the arm length on one side based on a preset comparison model to obtain a relative scale estimation value;
[0033] The judging module is used to judge whether the detected key points of the human body are correct when the relative scale estimation value is within a preset scale threshold range.
[0034] In a fourth aspect, the present invention provides a device for identifying blackboard writing behavior, comprising:
[0035] The first acquisition module is used to acquire the key points of the head and neck of the detection target, as well as the key points of the elbow and wrist on the same side;
[0036] The first judgment module is used to use the device for checking the detected human key points to check the detected human key points, and if the correct conclusion of the detected human key points cannot be drawn, the use of the key points for blackboard writing behavior recognition is terminated;
[0037] An orientation judgment module is used to identify the face orientation of the detection target and determine whether the face orientation is within a preset orientation range;
[0038] The second acquisition module is used to acquire the elbow key points and the wrist key points on the same side of the detection target;
[0039] The second judgment module is used to judge whether the detection target performs blackboard writing when the position of the wrist key point is higher than the position of the elbow key point and the face orientation is within a preset orientation range.
[0040] In a fifth aspect, the present invention provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any of the above-mentioned methods when executing the program.
[0041] In a sixth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, characterized in that when the program is executed by a processor, the method of any of the above-mentioned embodiments is implemented.
[0042] In the present invention, for the classroom teaching scenario, the relationship between the head length and the arm length is used to check whether the detected key points of the human body are correct in a relatively simple way; then, if the key points are correct, the face orientation and the position of the key points are combined to determine whether the blackboard writing behavior occurs. Compared with the judgment method in the prior art, the present invention has lower computing power requirements, higher accuracy, and wider applicable scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1 It is a flowchart of an implementation method of Example 1 of the present invention.
[0044] Figure 2 It is a flow chart of an implementation method of Example 21 of the present invention.
[0045] Figure 3 It is a schematic diagram of the overall structure of an implementation method of Example 31 of the present invention.
[0046] Figure 4 It is a schematic diagram of the overall structure of another implementation method of Example 3 of the present invention. DETAILED DESCRIPTION
[0047] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0048] It should be noted that the terms "first\second\..." involved in the embodiments of the present invention are only used to distinguish similar objects, and do not represent a specific order for the objects. It is understandable that the specific order or sequence of "first\second\..." can be interchanged where permitted. It should be understood that the objects distinguished by "first\second\..." can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein.
[0049] Embodiment 1
[0050] See also Figure 1 , Figure 1 A flowchart of a method for checking detected key points of a human body provided in Embodiment 1 of the present invention is provided, the method comprising step S110, step S120, step S130, step S140, step S150 and step S160. It should be noted that step S110, step S120, step S130, step S140, step S150 and step S160 are merely reference numerals for the purpose of clearly explaining the embodiment and the appendix. Figure 1 The corresponding relationship does not limit the order of the steps in this embodiment.
[0051] Step S110, obtaining key points of the head and neck of the detection target;
[0052] Step S120, calculating the distance from the key point of the head to the key point of the neck, and recording it as the head length;
[0053] Step S130, acquiring the elbow key points and wrist key points on the same side of the detection target;
[0054] Step S140, calculating the distance from the elbow key point to the wrist key point, and recording it as the length of one side of the arm;
[0055] Step S150, based on a preset comparison model, the head length is compared with the arm length on one side to obtain a relative scale estimation value;
[0056] Step S160, when the relative scale estimation value is within a preset scale threshold range, it is determined that the detected human body key points are correct.
[0057] This method is applicable to devices that can analyze human body movements, such as recording and broadcasting hosts. For the sake of convenience, this method will be described below using the recording and broadcasting host as an example. The recording and broadcasting host obtains the captured video stream from the recording and broadcasting terminal, uses the human key point detection algorithm to perform full-image detection on the video frames in the video stream, and obtains all the human skeleton key points in the video frame and the human body information corresponding to the key points. The details are as follows:
[0058] (1) The human body key points include: head, neck, shoulders, elbows, and wrists, a total of 8 key points;
[0059] (2) In classroom scenes, only the upper body of a human target can be seen. Therefore, the six key points of the lower body, namely the hips, knees, and ankles, are not considered. Only the key points of the upper body are calculated and decoded, which can reduce computational overhead.
[0060] Common posture recognition methods based on skeleton key points often ignore an important premise, which is the accuracy of the key points detected by the human key point detection algorithm. Since the human key point detection algorithm cannot guarantee that every key point detected is correct, it is necessary to add a judgment criterion for preliminary screening. This method is a set of judgment criteria for this filtering process.
[0061] In the recorded scenes of classroom teaching and research analysis, the head is a relatively less obscured human body part. In the human key point detection algorithm, the probability of error is lower than that of other key points because of the relatively less occlusion. Therefore, in steps S110 and S120, it is appropriate to use the length of the head of the detected target as the scale standard for the target, calculate the distance between the head key point and the neck key point, and obtain D H The head length of the detected target at the current scale (panoramic or close-up).
[0062] Compared to the head, the arm is often mis-estimated or estimated with low precision by the human key point detection algorithm because of its smaller area in the picture or easy to be blocked, which will seriously affect the accuracy of the subsequent posture recognition based on the skeleton key points. In step S130 and step S140, it is first assumed that all human key points are accurately detected. If the elbow and wrist key points on the same side can be detected by the human key point detection algorithm, the distance between the elbow key point and the wrist key point is calculated to obtain D A The length of the left / right arm of the detected target at the current scale.
[0063] In step S150, the arm length D A and head length D H The preset comparison model formula is used to calculate and compare, and the relative scale estimation value β between the head and the arm is obtained. In step S160, the relative scale estimation value β is compared with the preset scale threshold range. If it is within the preset scale threshold range, it is determined that the detected human body key point is correct.
[0064] Because there are several situations for targets that do not meet the conditions of step S150 and step S160: the first is that the target does not make detectable behavior gestures under the premise that the human key point detection algorithm correctly detects all key points; the second is that the human key points are misdetected, resulting in unreliable data obtained by length calculation; the third is that when the camera shoots at different angles, the target's arms and other parts have too small or too large imaging scales due to angle differences. These three situations will seriously affect the accuracy of the subsequent key point-based gesture recognition method. Therefore, only when the above conditions are met can the detected human key points be judged to be correct.
[0065] In one embodiment, the preset comparison model is:
[0066] Among them, β is the relative scale estimate, D H is the head length, D A is the arm length, W and b are preset parameters.
[0067] Among them, W and b can be parameters obtained through training. Using an image data set with labeled key points of the human body, using image scale information in the training data, and position information of each labeled key point, W and b are trained.
[0068] In one implementation, the method further includes: step S170, step S180 and step S190.
[0069] Step S170, if the head length is not within the preset head length range, determining that the human body key points of the current detection target are unavailable;
[0070] Step S180, if the arm length on one side is not within the preset arm length range, it is determined that the human body key point of the current detection target is unavailable;
[0071] Step S190, when it is determined that the human body key points of the current detection target are not available, it is determined that the detected human body key points are incorrect.
[0072] The head length and arm length are compared with their respective preset length threshold ranges. If any of the head length and arm length is not within the respective preset length threshold ranges, the human key points of the current detection target are considered unavailable. This is because there are two situations where the target does not meet this condition: the first is that the size of the target in the image is very small and does not meet the minimum standard for detection and recognition; the second is that the human key points are misdetected, resulting in unreliable data obtained by length calculation.
[0073] It should be noted here that step S170 and step S180 are used to determine whether the detected human body key points are usable. If they are not usable, it must be that the human body key points are incorrect. Therefore, these two steps are preferably performed before step S150 and step S160. If it is determined that they are not usable, there is no need to execute the subsequent steps.
[0074] In this method, for classroom teaching scenarios, the relationship between head length and arm length is used to check whether the detected key points of the human body are correct in a relatively simple way. Compared with the judgment method in the prior art, this method has lower computing power requirements and is applicable to a wider range of scenarios.
[0075] Embodiment 2
[0076] See also Figure 2 , Figure 2 1 is a flow chart of a method for identifying blackboard writing behavior provided in the first embodiment of the present invention, the method comprising step S210, step S220, step S230, step S240 and step S250. It should be noted that step S210, step S220, step S230, step S240 and step S250 are only reference numerals for clearly explaining the embodiment and the appendix. Figure 1 The corresponding relationship does not limit the order of the steps in this embodiment.
[0077] Step S210, obtaining the key points of the head and neck of the detection target, as well as the key points of the elbow and wrist on the same side;
[0078] Step S220, using a method for checking the detected human key points to check the detected human key points, if a conclusion that the detected human key points are correct cannot be drawn, terminating the use of this key point for blackboard writing behavior recognition;
[0079] Step S230, identifying the face orientation of the detection target, and determining whether the face orientation is within a preset orientation range;
[0080] Step S240, acquiring the elbow key points and wrist key points on the same side of the detection target;
[0081] Step S250, when the position of the wrist key point is higher than the position of the elbow key point and the face orientation is within a preset orientation range, it is determined that the detection target performs blackboard writing behavior.
[0082] As in the first embodiment, this method is applicable to devices capable of analyzing human body movements, such as a recording and broadcasting host, etc. For the sake of convenience, this method is described below using the recording and broadcasting host as an example. The recording and broadcasting host obtains the captured video stream from the recording and broadcasting terminal, uses the human key point detection algorithm to perform full-image detection on the video frames in the video stream, and obtains all the human skeleton key points in the video frame and the human body information corresponding to the key points.
[0083] Step S210 and step S220 use the method of embodiment 1 to first determine the correctness of the key points of the detection target. If it is incorrect, these key points will not be used to identify the blackboard writing behavior. After the correctness check of the key points of the detection target in step S210 and step S220, if it is determined to be correct, the subsequent link of substantially detecting the blackboard writing behavior is entered.
[0084] In the recording scene of classroom teaching, research and analysis, there is usually a camera facing the blackboard / whiteboard, which can capture people writing on the blackboard / whiteboard, such as teachers or students. These cameras facing the blackboard / whiteboard can be teacher panoramic cameras, teacher tracking cameras, cameras specifically for shooting teaching blackboards, etc.
[0085] When writing on the blackboard, people usually write facing the blackboard. Since the camera is facing the blackboard / whiteboard, the detected target captured should only be the back, and the front face cannot be seen. Therefore, it is not necessary to identify the face direction of the detected target in S130. The face can only be written on the blackboard when it is within the preset direction range facing the blackboard.
[0086] In the teaching scenario, when a person's face is facing the blackboard, there are not many things that can be done. It is likely that the person is writing on the blackboard, so this method can use a slightly simpler "writing on the blackboard" posture to determine whether the person is writing on the blackboard. The judgment process of step S150 is the process of identifying the "writing on the blackboard" posture. When writing, the hand is generally written vertically, and the palm is above the elbow at this time. Therefore, in this method, the position relationship between the wrist key point and the elbow key point is determined. When the position of the wrist key point is higher than the position of the elbow key point, it is determined that the posture is "writing on the blackboard".
[0087] In step S250, when the face orientation and the "writing on the blackboard" posture meet the requirements, it can be determined that the detection target is performing the blackboard writing behavior.
[0088] In one implementation, the process of step S230 includes: step S231, step S232, and step S233.
[0089] Step S231, using a head detection algorithm to detect the head position of the detection target, and obtain a valid head position detection area;
[0090] Step S232, using a face detection algorithm to detect the face position of the detection target and obtain a valid face position detection area;
[0091] Step S233, when the ratio of the valid face position detection area to the valid head position detection area is within a preset ratio range, it is determined that the face orientation is within a preset orientation range.
[0092] Taking the target object as a teacher as an example, in step S231, within the range of image detection, the head position of the teacher in the video screen is detected using the head detection algorithm to obtain a valid head position detection area. In step S232, within the range of image detection, the face position of the teacher in the video screen is detected using the face detection algorithm to obtain a valid face position detection area.
[0093] At this time, a person skilled in the art can analyze the percentage of the face that is exposed during the writing process based on the actual screen of the writing on the blackboard, thereby obtaining a preset ratio range. Then, the ratio of the effective face position detection area to the effective head position detection area is compared with the relationship between the preset ratio range to determine whether the face orientation is within the preset orientation range.
[0094] In one implementation, the preset ratio range is 0.
[0095] This embodiment is a situation where there is an effective head position detection area but no effective face position detection area. This embodiment is aimed at a scene where the camera is photographed facing the blackboard relatively directly.
[0096] In this method, for the classroom teaching scenario, the relationship between the head length and the arm length is used to check whether the detected key points of the human body are correct in a relatively simple way; then, if the key points are correct, the face orientation and the position of the key points are combined to determine whether the blackboard writing behavior occurs. Compared with the judgment method in the prior art. Compared with the judgment method in the prior art, this method has lower computing power requirements, higher accuracy, and wider applicable scenarios.
[0097] Embodiment 3
[0098] Corresponding to the method of embodiment 1, as Figure 3 As shown, the present invention further provides a device 3 for checking detected key points of a human body, comprising: an acquisition module 310 , a calculation module 320 , a comparison module 330 and a judgment module 340 .
[0099] The acquisition module 310 is used to acquire the key points of the head and the neck of the detection target; acquire the key points of the elbow and the wrist on the same side of the detection target;
[0100] The calculation module 320 is used to calculate the distance from the key point of the head to the key point of the neck, which is recorded as the head length; calculate the distance from the key point of the elbow to the key point of the wrist, which is recorded as the length of one side of the arm;
[0101] A comparison module 330, configured to compare the head length with the arm length on one side based on a preset comparison model to obtain a relative scale estimation value;
[0102] The judgment module 340 is used to judge whether the detected human body key points are correct when the relative scale estimation value is within a preset scale threshold range.
[0103] In one embodiment, the preset comparison model is:
[0104] Among them, β is the relative scale estimate, D H is the head length, D A is the arm length, W and b are preset parameters.
[0105] In one embodiment, the judgment module is also used to judge that the human body key points of the current detection target are unavailable if the head length is not within the preset head length range; if the arm length on one side is not within the preset arm length range, judge that the human body key points of the current detection target are unavailable; when it is judged that the human body key points of the current detection target are unavailable, judge that the detected human body key points are incorrect.
[0106] In this device, for classroom teaching scenarios, the relationship between head length and arm length is used to check whether the detected key points of the human body are correct in a relatively simple way. Compared with the judgment method in the prior art, this device has lower computing power requirements and is applicable to a wider range of scenarios.
[0107] Corresponding to the method of the second embodiment, as Figure 4 As shown, the present invention further provides a device 4 for blackboard writing behavior recognition, comprising: a first acquisition module 410 , a first judgment module 420 , a direction judgment module 430 , a second acquisition module 440 and a second judgment module 450 .
[0108] A first acquisition module 410 is used to acquire the key points of the head and neck of the detection target, as well as the key points of the elbow and wrist on the same side;
[0109] The first judgment module 420 is used to check the detected human key points using a device for checking the detected human key points, and if a conclusion that the detected human key points are correct cannot be drawn, the use of the key points for blackboard writing behavior recognition is terminated;
[0110] The orientation determination module 430 is used to identify the orientation of the face of the detection target and determine whether the orientation of the face is within a preset orientation range;
[0111] The second acquisition module 440 is used to acquire the elbow key points and the wrist key points on the same side of the detection target;
[0112] The second judgment module 450 is used to judge whether the detection target performs blackboard writing when the position of the wrist key point is higher than the position of the elbow key point and the face orientation is within a preset orientation range.
[0113] In one embodiment, the process of the orientation determination module executing the identification of the face orientation of the detection target and determining whether the face orientation is within a preset orientation range includes:
[0114] Use the head detection algorithm to detect the head position of the detection target and obtain a valid head position detection area;
[0115] Use the face detection algorithm to detect the face position of the detection target and obtain a valid face position detection area;
[0116] When the ratio of the effective face position detection area to the effective head position detection area is within a preset ratio range, it is determined that the face orientation is within a preset orientation range.
[0117] In one implementation, the preset ratio range is 0.
[0118] In this device, for classroom teaching scenarios, the relationship between head length and arm length is used to check whether the detected key points of the human body are correct in a relatively simple way; then, if the key points are correct, the face orientation and the position of the key points are combined to determine whether the blackboard writing behavior occurs. Compared with the judgment method in the prior art, this device has lower computing power requirements, higher accuracy, and wider applicable scenarios.
[0119] Embodiment 4
[0120] An embodiment of the present invention further provides a storage medium on which computer instructions are stored. When the instructions are executed by a processor, the method for checking detected key points of the human body and / or the method for recognizing blackboard writing behavior of any of the above embodiments is implemented.
[0121] Those skilled in the art can understand that: all or part of the steps of implementing the above method embodiments can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above method embodiments; and the aforementioned storage medium includes: mobile storage devices, random access memories (RAM), read-only memories (ROM), magnetic disks or optical disks, etc., various media that can store program codes.
[0122] Alternatively, if the above-mentioned integrated unit of the present invention is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present invention can be essentially or partly reflected in the form of a software product that contributes to the relevant technology. The computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, terminal, or network device, etc.) to execute all or part of the methods of each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, RAM, ROM, magnetic disks or optical disks.
[0123] Corresponding to the above-mentioned computer storage medium, in one embodiment, a computer device is also provided, which includes a memory, an encoder, and a computer program stored in the memory and run on the encoder, wherein when the encoder executes the program, it implements any one of the methods for checking and detecting key points of the human body and / or the method for recognizing blackboard writing behaviors in the above-mentioned embodiments.
[0124] The above computer device, for classroom teaching scenarios, uses the relationship between head length and arm length to check whether the detected key points of the human body are correct in a relatively simple way; then, if the key points are correct, it combines the face direction and the position of the key points to determine whether the blackboard writing behavior occurs. Compared with the judgment method in the prior art, the above computer device has lower computing power requirements, higher accuracy, and wider application scenarios.
[0125] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0126] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the embodiments here. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the claims of the present invention.
Claims
1. A method for checking detected key points of a human body, characterized in that: include: Obtain the key points of the head and neck of the detection target; Calculate the distance from the key point of the head to the key point of the neck, and record it as the head length; Obtain the elbow key points and wrist key points on the same side of the detection target; Calculate the distance from the elbow key point to the wrist key point, and record it as the length of one side of the arm; Based on a preset comparison model, the head length is compared with the arm length on one side to obtain a relative scale estimation value; When the relative scale estimation value is within a preset scale threshold range, it is determined that the detected human body key points are correct.
2. The method for checking detected key points of a human body according to claim 1, characterized in that: The preset comparison model is: Among them, β is the relative scale estimate, D H is the head length, D A is the arm length, W and b are preset parameters.
3. The method for checking detected key points of a human body according to claim 1, characterized in that: Also includes: If the head length is not within the preset head length range, it is determined that the human body key points of the current detection target are unavailable; If the arm length on one side is not within the preset arm length range, it is determined that the human body key point of the current detection target is unavailable; When it is determined that the human body key points of the current detection target are unavailable, it is determined that the detected human body key points are incorrect.
4. A method for identifying blackboard writing behavior, characterized in that: include: Obtain the key points of the head and neck of the detected target, as well as the key points of the elbow and wrist on the same side; Using the method for checking the detected human key points as described in any one of claims 1 to 3 to check the detected human key points, if no conclusion can be drawn that the detected human key points are correct, terminating the use of the key points for blackboard writing behavior recognition; Identify the face orientation of the detection target and determine whether the face orientation is within a preset orientation range; Obtain the elbow key points and wrist key points on the same side of the detection target; When the position of the wrist key point is higher than the position of the elbow key point and the face orientation is within a preset orientation range, it is determined that the detection target performs blackboard writing behavior.
5. The method for blackboard writing behavior recognition according to claim 4, characterized in that: The process of identifying the face orientation of the detection target and determining whether the face orientation is within a preset orientation range includes: Use the head detection algorithm to detect the head position of the detection target and obtain a valid head position detection area; Use the face detection algorithm to detect the face position of the detection target and obtain a valid face position detection area; When the ratio of the effective face position detection area to the effective head position detection area is within a preset ratio range, it is determined that the face orientation is within a preset orientation range.
6. The method for blackboard writing behavior recognition according to claim 5, characterized in that: The preset ratio range is 0.
7. A device for checking detected key points of a human body, characterized in that: Includes steps: An acquisition module is used to acquire the key points of the head and neck of the detection target; and acquire the key points of the elbow and wrist on the same side of the detection target; A calculation module, used for calculating the distance from the key point of the head to the key point of the neck, recorded as the head length; Calculate the distance from the elbow key point to the wrist key point, and record it as the length of one side of the arm; A comparison module, used for comparing the head length with the arm length on one side based on a preset comparison model to obtain a relative scale estimation value; The judging module is used to judge whether the detected key points of the human body are correct when the relative scale estimation value is within a preset scale threshold range.
8. A device for blackboard writing behavior recognition, characterized in that: include: The first acquisition module is used to acquire the key points of the head and neck of the detection target, as well as the key points of the elbow and wrist on the same side; A first judgment module is used to check the detected human key points using the device for checking the detected human key points as claimed in claim 7, and if a conclusion that the detected human key points are correct cannot be drawn, the use of the key points for blackboard writing behavior recognition is terminated; An orientation judgment module is used to identify the face orientation of the detection target and determine whether the face orientation is within a preset orientation range; The second acquisition module is used to acquire the elbow key points and the wrist key points on the same side of the detection target; The second judgment module is used to judge whether the detection target performs blackboard writing when the position of the wrist key point is higher than the position of the elbow key point and the face orientation is within a preset orientation range.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 6 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.