Posture type recognition method, device and equipment and storage medium

By performing matrix processing and target detection on human images, combined with a body posture key point recognition model, the problem of low efficiency and accuracy in body posture type recognition in existing technologies has been solved, achieving efficient and accurate body posture type recognition.

CN114898401BActive Publication Date: 2026-04-10KANG JIAN INFORMATION TECH (SHENZHEN) CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
KANG JIAN INFORMATION TECH (SHENZHEN) CO LTD
Filing Date
2022-04-26
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

Existing human body posture recognition technologies suffer from low efficiency and accuracy due to the large amount of data they need to process and the difficulty in assessing whether movements conform to standards.

Method used

By matrixing the initial human body image, using a pre-set target detection algorithm and a pre-trained body key point recognition model, the human body key points are identified and the offset is calculated to determine the body type.

Benefits of technology

It improves the efficiency and accuracy of body shape recognition, reduces the hardware requirements of image acquisition terminals, and achieves real-time recognition on hardware with limited resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114898401B_ABST
    Figure CN114898401B_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of artificial intelligence, and discloses a body posture type recognition method, device and equipment and a storage medium, which are used for improving the efficiency and accuracy of body posture type recognition. The body posture type recognition method comprises the following steps: obtaining an initial human body image to be detected, and performing matrix processing on the initial human body image to obtain a human body image matrix; performing human body target detection on the human body image matrix through a preset target detection algorithm to obtain target human body information; performing human body key point recognition on the target human body information through a pre-trained body posture key point recognition model to obtain human body key point information; performing offset calculation on the human body key point information to obtain a body posture offset, and determining body posture type information according to the body posture offset. In addition, the present application also relates to the blockchain technology, and the body posture type information can be stored in a blockchain node.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image classification technology, and in particular to a method, apparatus, device, and storage medium for recognizing body types. Background Technology

[0002] With the development of image processing technology, human body posture can also be recognized through intelligent image processing technology. A standard posture is not only a manifestation of beauty, but also a symbol of health.

[0003] Existing human posture type recognition technologies typically assess posture by analyzing images of combined movements. This approach suffers from low efficiency and accuracy due to the large amount of data required and the difficulty in evaluating whether the movements conform to standards. Summary of the Invention

[0004] This invention provides a method, apparatus, device, and storage medium for recognizing body types, which improves the efficiency and accuracy of body type recognition.

[0005] The first aspect of this invention provides a method for identifying body posture types, comprising:

[0006] Acquire the initial human image to be detected, and perform matrix processing on the initial human image to obtain the human image matrix;

[0007] Human target detection is performed on the human image matrix using a preset target detection algorithm to obtain target human information;

[0008] Human body key point information is obtained by identifying human body key points through a pre-trained body key point recognition model.

[0009] The offset of the key points of the human body is calculated to obtain the body posture offset, and the body posture type information is determined based on the body posture offset.

[0010] Optionally, in a first implementation of the first aspect of the present invention, the step of acquiring an initial human image to be detected and performing matrix processing on the initial human image to obtain a human image matrix includes:

[0011] Acquire an initial human body image to be detected, and read the pixel values ​​of all pixels in the initial human body image;

[0012] By using a preset mask matrix, the pixel values ​​of all pixels in the initial human body image are masked to obtain the human body image matrix.

[0013] Optionally, in a second implementation of the first aspect of the present invention, the step of performing human target detection on the human image matrix using a preset target detection algorithm to obtain target human information includes:

[0014] Human features are extracted from the human image matrix using a pre-set target detection algorithm to obtain human feature information. Regression calculations are then performed on the human feature information to obtain at least one target information, with each target information including the type information of each target.

[0015] By determining human target information from at least one target information using the target type information, target human information is obtained, and the target human information is used to indicate the detection frame information of the human target.

[0016] Optionally, in a third implementation of the first aspect of the present invention, the pre-trained body key point recognition model includes multiple deep convolutional layers, upsampling layers, cross-stage local layers, spatial pyramid pooling layers, and regression layers. The step of using the pre-trained body key point recognition model to perform body key point recognition on the target human body information to obtain human key point information includes:

[0017] The body posture features are extracted from the target human body information through the multi-layer deep convolutional layers to obtain body posture feature information;

[0018] The body feature information is segmented and spliced ​​through the upsampling layer to obtain body feature sampling information.

[0019] The body feature sampling information is fused by the cross-stage local layer and the spatial pyramid pooling layer to obtain body feature fusion information.

[0020] The regression layer is used to classify and regress the fused body features into key human points to obtain key human point information.

[0021] Optionally, in a fourth implementation of the first aspect of the present invention, the step of calculating the offset of the key human body points to obtain a body posture offset, and determining the body posture type information based on the body posture offset, includes:

[0022] The human body key point information is classified into human postures to obtain posture type information, and it is determined whether the posture type information is a preset posture type information.

[0023] If the posture type information is preset posture type information, then the joint offset and joint offset direction are calculated based on the human body key point information to obtain the body posture offset, and the body posture type information is determined based on the body posture offset.

[0024] Optionally, in a fifth implementation of the first aspect of the present invention, the step of calculating joint offset and joint offset direction based on the human body key point information to obtain body posture offset, and determining body posture type information based on the body posture offset, includes:

[0025] Calculate the joint angle of each joint point by using the position information of multiple joint points in the human body key point information;

[0026] The difference between the joint angle of each joint point and the standard angle of the corresponding joint point is calculated to obtain the body posture offset, which includes the joint offset and the joint offset direction of each joint point;

[0027] Based on the joint offset and direction of each joint, the body posture type information is determined.

[0028] Optionally, in a sixth implementation of the first aspect of the present invention, determining the body posture type information based on the joint offset and joint offset direction of each joint point includes:

[0029] Obtain the offset threshold corresponding to each joint, and determine at least one target joint point by the joint offset and joint offset direction of each joint point. The target joint point is used to indicate the joint point among multiple joint points whose joint offset is greater than the offset threshold corresponding to each joint.

[0030] Body type information is determined based on at least one target joint and the joint offset direction corresponding to the target joint.

[0031] A second aspect of the present invention provides a body type recognition device, comprising:

[0032] The acquisition module is used to acquire the initial human image to be detected and to perform matrix processing on the initial human image to obtain a human image matrix.

[0033] The detection module is used to perform human target detection on the human image matrix using a preset target detection algorithm to obtain target human information;

[0034] The recognition module is used to identify human body key points of the target human body information through a pre-trained body key point recognition model to obtain human body key point information.

[0035] The calculation module is used to calculate the offset of the key points of the human body, obtain the body posture offset, and determine the body posture type information based on the body posture offset.

[0036] Optionally, in a first implementation of the second aspect of the present invention, the acquisition module is specifically used for:

[0037] Acquire an initial human body image to be detected, and read the pixel values ​​of all pixels in the initial human body image;

[0038] By using a preset mask matrix, the pixel values ​​of all pixels in the initial human body image are masked to obtain the human body image matrix.

[0039] Optionally, in a second implementation of the second aspect of the present invention, the detection module is specifically used for:

[0040] Human features are extracted from the human image matrix using a pre-set target detection algorithm to obtain human feature information. Regression calculations are then performed on the human feature information to obtain at least one target information, with each target information including the type information of each target.

[0041] By determining human target information from at least one target information using the target type information, target human information is obtained, and the target human information is used to indicate the detection frame information of the human target.

[0042] Optionally, in a third implementation of the second aspect of the present invention, the pre-trained body key point recognition model includes multiple deep convolutional layers, upsampling layers, cross-stage local layers, spatial pyramid pooling layers, and regression layers, and the recognition module is specifically used for:

[0043] The body posture features are extracted from the target human body information through the multi-layer deep convolutional layers to obtain body posture feature information;

[0044] The body feature information is segmented and spliced ​​through the upsampling layer to obtain body feature sampling information.

[0045] The body feature sampling information is fused by the cross-stage local layer and the spatial pyramid pooling layer to obtain body feature fusion information.

[0046] The regression layer is used to classify and regress the fused body features into key human points to obtain key human point information.

[0047] Optionally, in a fourth implementation of the second aspect of the present invention, the computing module includes:

[0048] The classification submodule is used to classify the human body key point information into human postures, obtain posture type information, and determine whether the posture type information is a preset posture type information.

[0049] The calculation submodule is used to calculate the joint offset and joint offset direction based on the human body key point information if the posture type information is a preset posture type information, to obtain the body posture offset, and to determine the body posture type information based on the body posture offset.

[0050] Optionally, in a fifth implementation of the second aspect of the present invention, the computing submodule includes:

[0051] An angle calculation unit is used to calculate the joint angle of each joint point using the position information of multiple joint points in the human body key point information.

[0052] The difference calculation unit is used to calculate the difference between the joint angle of each joint point and the standard angle of the corresponding joint point to obtain the body offset, which includes the joint offset and the joint offset direction of each joint point.

[0053] The posture determination unit is used to determine posture type information based on the joint offset and direction of each joint.

[0054] Optionally, in a sixth implementation of the second aspect of the present invention, the posture determination unit is specifically used for:

[0055] Obtain the offset threshold corresponding to each joint, and determine at least one target joint point by the joint offset and joint offset direction of each joint point. The target joint point is used to indicate the joint point among multiple joint points whose joint offset is greater than the offset threshold corresponding to each joint.

[0056] Body type information is determined based on at least one target joint and the joint offset direction corresponding to the target joint.

[0057] A third aspect of the present invention provides a body type recognition device, comprising: a memory and at least one processor, wherein the memory stores a computer program; the at least one processor invokes the computer program in the memory to cause the body type recognition device to perform the aforementioned body type recognition method.

[0058] A fourth aspect of the present invention provides a computer-readable storage medium storing a computer program that, when run on a computer, causes the computer to perform the above-described body type recognition method.

[0059] The technical solution provided by this invention involves acquiring an initial human image to be detected and performing matrix processing on the initial human image to obtain a human image matrix; performing human target detection on the human image matrix using a preset target detection algorithm to obtain target human information; performing human keypoint recognition on the target human information using a pre-trained posture keypoint recognition model to obtain human keypoint information; calculating the offset of the human keypoint information to obtain posture offset, and determining posture type information based on the posture offset. In this embodiment of the invention, after acquiring the initial human image to be detected, the initial human image is matrix-processed to obtain a digitally represented human image matrix to improve image processing efficiency. Then, the target human information in the human image matrix is ​​efficiently detected using a target detection algorithm. After determining the human information, the human keypoints in the target human information are identified. Human keypoints are used to indicate the overall skeleton and joints of the human body. Finally, the posture offset is calculated accurately using the human keypoint information to accurately calculate the offset of the joints, thereby accurately determining the corresponding posture type based on the posture offset. This invention can improve the efficiency and accuracy of posture type recognition. Attached Figure Description

[0060] Figure 1 This is a schematic diagram of an embodiment of the body shape type recognition method in this invention;

[0061] Figure 2 This is a schematic diagram of another embodiment of the body shape type recognition method in this invention;

[0062] Figure 3 This is a schematic diagram of one embodiment of the body shape type recognition device of the present invention;

[0063] Figure 4 This is a schematic diagram of another embodiment of the body type recognition device of the present invention;

[0064] Figure 5 This is a schematic diagram of one embodiment of the body shape type recognition device in this invention. Detailed Implementation

[0065] This invention provides a method, apparatus, device, and storage medium for recognizing body types, which improves the efficiency and accuracy of body type recognition.

[0066] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” or “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0067] The embodiments of this application can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) refers to the theories, methods, technologies, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.

[0068] Foundational technologies for artificial intelligence generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies mainly encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.

[0069] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0070] It is understood that the executing entity of this invention can be a body type recognition device, a terminal, or a server; no specific limitation is made here. This embodiment of the invention uses a server as the executing entity as an example for illustration. The server can be an independent server or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms.

[0071] For ease of understanding, the specific process of the embodiments of the present invention is described below. Please refer to [link / reference]. Figure 1 One embodiment of the body type recognition method in this invention includes:

[0072] 101. Obtain the initial human image to be detected, and perform matrix processing on the initial human image to obtain the human image matrix;

[0073] In this embodiment, the initial human image to be detected can be a human image taken and uploaded by the user via a mobile terminal, or a human image acquired by a body posture recognition device. In one embodiment, after the server acquires the initial human image to be detected, it reads the image parameters of the initial human image to obtain the clarity parameters of the initial human image, and determines whether the clarity parameters meet the preset clarity image conditions. If the clarity parameters do not meet the preset clarity image conditions, the initial human image is filtered through a preset blur image filter to obtain a filtered initial human image. The filtered initial human image is then matrixed to obtain a human image matrix. This embodiment can improve the clarity of the human image to be detected, thereby reducing the hardware requirements of the image acquisition terminal and improving the accuracy of subsequent body posture detection.

[0074] In one implementation, after the server acquires the initial human body image to be detected, it performs matrix processing on the initial human body image using a pre-built cross-platform image processing tool to obtain a human body image matrix. The cross-platform image processing tool is a cross-platform computer vision and machine learning software library based on OpenCV, which can efficiently convert images into digital representations, thereby improving the recognition efficiency of body shape types.

[0075] In one implementation, after the server acquires the initial human body image to be detected, it acquires a preset kernel matrix and performs a weighted average operation on the pixel values ​​corresponding to each pixel in the initial human body image using the kernel matrix to obtain a human body image matrix, thereby quickly converting the human body image into a digital matrix and improving the efficiency of body shape recognition.

[0076] 102. Human target detection is performed on the human image matrix using a pre-set target detection algorithm to obtain target human information;

[0077] In this embodiment, in order to identify human target information in the human image matrix, the server performs human target detection on the human image matrix using a preset target detection algorithm to obtain target human information. The target detection algorithm includes a single-stage target detection algorithm and a two-stage target detection algorithm. In one embodiment, the server extracts features from the human image matrix using a preset single-stage target detection algorithm to obtain target feature information, and performs classification and regression on the target feature information to obtain target human information. The target human information includes the position information and size information of the target human. In a preferred embodiment, the preset single-stage target detection algorithm adopts the YOLO (you only look once) algorithm, which has high-precision target detection capabilities, thereby improving the accuracy of body shape type recognition.

[0078] 103. By using a pre-trained body key point recognition model, the key points of the target human body are identified to obtain human key point information;

[0079] In this embodiment, in order to perform posture detection on the detected human body information, the server uses a pre-trained posture key point recognition model to identify human body key points of the target human body information, thereby obtaining human body key point information. The human body key point information includes the position coordinate information of multiple skeletal points (joint points). As an example and not a limitation, the multiple skeletal points include at least 17 skeletal points: right shoulder, right elbow, right wrist, right hip, right knee, right ankle, right hip, left shoulder, left elbow, left wrist, left hip, left knee, left ankle, left hip, lumbar spine, top of head, and neck. In order to improve the recognition accuracy of lumbar spine deformity posture, during the training process of the posture key point recognition model, training samples with multiple skeletal point annotations are obtained. Among the multiple skeletal point annotations, at least 3 lumbar spine skeletal point annotations are included, so that the pre-trained posture key point recognition model can more accurately identify the type of lumbar spine deformity posture, thereby improving the refinement and accuracy of posture type.

[0080] In one implementation, to improve the efficiency of human body key point recognition, the body key point recognition model includes a lightweight 3D human pose prediction network (MovNect). MovNect is a CNN-based three-dimensional pose regression network structure with a lightweight network structure that has a model search process. It has a good balance between accuracy and inference time. It is a lightweight body key point recognition model that can run in real time on hardware with limited resources (such as mobile phones), thereby improving the efficiency of body type recognition.

[0081] 104. Calculate the offset of key points on the human body to obtain the body posture offset, and determine the body posture type information based on the body posture offset.

[0082] In one implementation, after obtaining the key point information of the human body, adjacent skeletal points in the key point information are connected to obtain multiple human body connection lines. The angle between each human body connection line and the corresponding standard connection line is calculated to obtain the posture offset corresponding to each human body connection line. The posture type information is determined based on the posture offset corresponding to each human body connection line. For example, assuming the posture offset corresponding to the lumbar spine connection line is 20 degrees, then the posture type information corresponding to this posture offset can be lumbar scoliosis. Assuming the posture offset corresponding to the connection line between the left and right shoulders is 10 degrees, then the posture type information corresponding to this posture offset can be uneven shoulders. This implementation can accurately and quickly determine the posture type by calculating the offset through the connection of different skeletal points.

[0083] Furthermore, the server stores body type information in a blockchain database, the specifics of which are not limited here.

[0084] In this embodiment of the invention, after acquiring the initial human image to be detected, the initial human image is matrixed to obtain a digitally represented human image matrix, thereby improving image processing efficiency. Then, the target human information in the human image matrix is ​​efficiently detected by a target detection algorithm. After determining the human information, the key points of the human body in the target human information are identified. The key points of the human body are used to indicate the overall skeleton and joints of the human body. Finally, the body posture offset is calculated using the key point information to accurately calculate the offset of the joints, thereby accurately determining the corresponding body posture type based on the body posture offset. This invention can improve the efficiency and accuracy of body posture type recognition.

[0085] Please see Figure 2 Another embodiment of the body type recognition method in this invention includes:

[0086] 201. Obtain the initial human image to be detected, and perform matrix processing on the initial human image to obtain the human image matrix;

[0087] Specifically, step 201 includes: acquiring an initial human image to be detected and reading the pixel values ​​of all pixels in the initial human image; and performing a masking operation on the pixel values ​​of all pixels in the initial human image using a preset mask matrix to obtain a human image matrix. In this embodiment, to improve the efficiency of image matrix processing, the server performs a masking operation on the initial human image using a preset mask matrix (also known as a kernel). Specifically, after acquiring the initial human image to be detected, the server reads the pixel values ​​of each pixel in the initial human image and then calculates the mask value corresponding to each pixel in the initial human image using the preset mask matrix to obtain the human image matrix. This embodiment can adjust the influence of adjacent pixels on the current pixel value through the mask matrix, thereby enhancing the human image information and improving the accuracy of human body type recognition.

[0088] 202. Human target detection is performed on the human image matrix using a preset target detection algorithm to obtain target human information;

[0089] Specifically, step 202 includes: extracting human features from the human image matrix using a preset target detection algorithm to obtain human feature information, and performing regression calculation on the human feature information to obtain at least one target information corresponding to the human image matrix, each target information including the type information of each target; determining the human target information in at least one target information through the target type information to obtain target human information, the target human information being used to indicate the detection box information of the human target. In this embodiment, when the preset target detection algorithm performs human target detection on the human image matrix, it first extracts the human features corresponding to the human image matrix to obtain human feature information. Then, it performs regression classification operation on the human feature information to obtain at least one target object information of the human image matrix. Each target object information includes the type information of each target object. The server then filters the at least one target object information according to the target object type information to obtain target human information. The target human information includes the detection box information of the human target object. In one embodiment, if the target human information includes the detection box information of two or more human target objects, the target human information is sent to the user terminal so that the user terminal can select the human information to be detected from the detection box information of two or more human target objects. The server receives the human information to be detected uploaded by the user terminal and determines the human information to be detected as the target human information. This embodiment can accurately identify the human information to be detected, thereby improving the accuracy of body type recognition.

[0090] 203. By using a pre-trained body key point recognition model, the key points of the target human body are identified to obtain the key point information of the human body.

[0091] Specifically, the pre-trained body key point recognition model includes multiple deep convolutional layers, upsampling layers, cross-stage local layers, spatial pyramid pooling layers, and regression layers. Step 203 includes: extracting body features from the target human body information through multiple deep convolutional layers to obtain body feature information; dividing the body feature information into blocks and splicing them through upsampling layers to obtain body feature sampling information; fusing the body feature sampling information through cross-stage local layers and spatial pyramid pooling layers to obtain body feature fusion information; and performing human key point classification regression on the body feature fusion information through regression layers to obtain human key point information. In this embodiment, to improve the accuracy of body key point recognition, a special structure for the body key point recognition model is designed. The pre-trained body key point recognition model includes multiple deep convolutional layers, upsampling layers, cross-stage local layers (CSP Net), spatial pyramid pooling (SPP) layers, and regression layers. Among them, the multiple deep convolutional layers are used to extract body features from the target human body information to obtain body feature information. The upsampling layers are used to segment and concatenate the body feature information to obtain body feature sampling information. The cross-stage local layers and spatial pyramid pooling layers are used to fuse body feature sampling information to obtain body feature fusion information. The regression layer is used to perform human key point classification regression on the body feature fusion information to obtain human key point information. Since the high computational cost during neural network inference is caused by the repetition of gradient information in network optimization, the gradient changes are integrated into the feature map from beginning to end through the cross-stage local layers, which can reduce the computational cost while ensuring accuracy, thereby improving the efficiency and accuracy of body type recognition.

[0092] 204. Classify human body postures based on key human body information to obtain posture type information, and determine whether the posture type information is a preset posture type information;

[0093] In this embodiment, in order to ensure that the human posture in the human image meets the detection conditions, the server classifies the human posture by the key point information of the human body to obtain posture type information, and determines whether the posture type information is a preset posture type information, such as frontal upright posture, side upright posture, and back upright posture. If the posture type information obtained by classification is a sitting posture, it is not a preset posture type information. The server sends a posture mismatch prompt message to the user terminal so that the user terminal can adjust the posture according to the posture mismatch prompt message and re-upload the human image.

[0094] 205. If the posture type information is preset posture type information, then calculate the joint offset and joint offset direction based on the human body key point information to obtain the body posture offset, and determine the body posture type information based on the body posture offset.

[0095] Specifically, the process involves calculating joint offsets and their directions based on key human body information to obtain posture offsets, and then determining posture type information based on these offsets. This includes: calculating the joint angles of each joint using the positional information of multiple joints in the key human body information; calculating the difference between the joint angles of each joint and the standard angle of the corresponding joint to obtain posture offsets, which include the joint offsets and their directions; and determining posture type information based on the joint offsets and their directions. In this embodiment, to accurately calculate the posture offset, the server calculates the joint angles of each joint using the positional information of multiple joints in the human body keypoint information. The positional information of each joint indicates its coordinates in the initial human body image. The server then calculates the difference between the joint angle of each joint and its standard angle to obtain the posture offset. The posture offset includes the joint offset amount and the direction of the joint offset. For example, if the difference between the joint angle of the cervical spine joint and its standard angle is +30 degrees, then the joint offset of the cervical spine joint is 30 degrees, and the direction of the joint offset is positive. Finally, based on the joint offset amount and direction of the cervical spine joint, the server determines the posture type information as cervical spine bending to the right. This embodiment can accurately calculate the posture offset, thereby improving the accuracy of posture type recognition.

[0096] Furthermore, the above-mentioned determination of body type information based on the joint offset and joint offset direction of each joint includes: obtaining the offset threshold corresponding to each joint, and determining at least one target joint point through the joint offset and joint offset direction of each joint point, wherein the target joint point is used to indicate the joint point among multiple joint points whose joint offset is greater than the offset threshold corresponding to each joint; and determining the body type information based on at least one target joint point and the joint offset direction corresponding to the target joint point. In this embodiment, since some body postures need to be determined by combining the offset of two or more joint points, in order to further improve the accuracy and subdivision of body posture type recognition, the server obtains the offset threshold corresponding to each joint point, and determines at least one target joint point by the joint offset amount and joint offset direction of each joint point. The target joint point is used to indicate the joint point among multiple joint points whose joint offset amount is greater than the offset threshold corresponding to each joint. For example, the O-leg body posture type and the X-leg body posture type need to be determined by combining multiple target joint points of both legs. Therefore, when the joint offset amount of the left leg joint point and the right leg joint point are both greater than the corresponding offset threshold, the left leg joint point and the right leg joint point are determined as target joint points. Then, according to the joint offset direction of these two target joint points, the body posture type information is determined as O-leg body posture type or X-leg body posture type.

[0097] In this embodiment of the invention, after acquiring the initial human image to be detected, the initial human image is matrixed to obtain a digitally represented human image matrix, thereby improving image processing efficiency. Then, the target human information in the human image matrix is ​​efficiently detected by a target detection algorithm. After determining the human information, the key points of the human body in the target human information are identified. The key points of the human body are used to indicate the overall skeleton and joints of the human body. In order to determine whether the human posture meets the detection requirements, the posture type information is identified by the key points of the human body, and it is determined whether the posture type is a preset posture type. If the posture type meets the detection requirements, the body posture offset is calculated by the key point information to accurately calculate the offset of the joints, thereby accurately determining the corresponding body posture type based on the body posture offset. This invention can improve the efficiency and accuracy of body posture type recognition.

[0098] The body type recognition method in the embodiments of the present invention has been described above. The body type recognition device in the embodiments of the present invention will be described below. Please refer to [link / reference]. Figure 3 One embodiment of the body shape type recognition device of the present invention includes:

[0099] The acquisition module 301 is used to acquire the initial human image to be detected and to perform matrix processing on the initial human image to obtain a human image matrix.

[0100] Detection module 302 is used to perform human target detection on the human image matrix using a preset target detection algorithm to obtain target human information;

[0101] The recognition module 303 is used to perform human body key point recognition on the target human body information through a pre-trained body key point recognition model to obtain human body key point information;

[0102] The calculation module 304 is used to calculate the offset of the key points of the human body, obtain the body posture offset, and determine the body posture type information based on the body posture offset.

[0103] Furthermore, body type information is stored in a blockchain database, the specifics of which are not limited here.

[0104] In this embodiment of the invention, after acquiring the initial human image to be detected, the initial human image is matrixed to obtain a digitally represented human image matrix, thereby improving image processing efficiency. Then, the target human information in the human image matrix is ​​efficiently detected by a target detection algorithm. After determining the human information, the key points of the human body in the target human information are identified. The key points of the human body are used to indicate the overall skeleton and joints of the human body. Finally, the body posture offset is calculated using the key point information to accurately calculate the offset of the joints, thereby accurately determining the corresponding body posture type based on the body posture offset. This invention can improve the efficiency and accuracy of body posture type recognition.

[0105] Please see Figure 4 Another embodiment of the body type recognition device in this invention includes:

[0106] The acquisition module 301 is used to acquire the initial human image to be detected and to perform matrix processing on the initial human image to obtain a human image matrix.

[0107] Detection module 302 is used to perform human target detection on the human image matrix using a preset target detection algorithm to obtain target human information;

[0108] The recognition module 303 is used to perform human body key point recognition on the target human body information through a pre-trained body key point recognition model to obtain human body key point information;

[0109] The calculation module 304 is used to calculate the offset of the key points of the human body, obtain the body posture offset, and determine the body posture type information based on the body posture offset.

[0110] Optionally, the acquisition module 301 is specifically used for:

[0111] Acquire an initial human body image to be detected, and read the pixel values ​​of all pixels in the initial human body image;

[0112] By using a preset mask matrix, the pixel values ​​of all pixels in the initial human body image are masked to obtain the human body image matrix.

[0113] Optionally, the detection module 302 is specifically used for:

[0114] Human features are extracted from the human image matrix using a pre-set target detection algorithm to obtain human feature information. Regression calculations are then performed on the human feature information to obtain at least one target information, with each target information including the type information of each target.

[0115] By determining human target information from at least one target information using the target type information, target human information is obtained, and the target human information is used to indicate the detection frame information of the human target.

[0116] Optionally, the pre-trained body key point recognition model includes multiple deep convolutional layers, upsampling layers, cross-stage local layers, spatial pyramid pooling layers, and regression layers. The recognition module 303 is specifically used for:

[0117] The body posture features are extracted from the target human body information through the multi-layer deep convolutional layers to obtain body posture feature information;

[0118] The body feature information is segmented and spliced ​​through the upsampling layer to obtain body feature sampling information.

[0119] The body feature sampling information is fused by the cross-stage local layer and the spatial pyramid pooling layer to obtain body feature fusion information.

[0120] The regression layer is used to classify and regress the fused body features into key human points to obtain key human point information.

[0121] Optionally, the computing module 304 includes:

[0122] The classification submodule 3041 is used to classify the human body key point information into human posture information, obtain posture type information, and determine whether the posture type information is a preset posture type information.

[0123] The calculation submodule 3042 is used to calculate the joint offset and joint offset direction based on the human body key point information if the posture type information is preset posture type information, to obtain the body posture offset, and to determine the body posture type information based on the body posture offset.

[0124] Optionally, the computing submodule 3042 includes:

[0125] Angle calculation unit 30421 is used to calculate the joint angle of each joint point using the position information of multiple joint points in the human body key point information.

[0126] The difference calculation unit 30422 is used to calculate the difference between the joint angle of each joint point and the standard angle of the corresponding joint point to obtain the body offset. The body offset includes the joint offset of each joint point and the joint offset direction.

[0127] The posture determination unit 30423 is used to determine posture type information based on the joint offset and joint offset direction of each joint point.

[0128] Optionally, the posture determination unit 30423 is specifically used for:

[0129] Obtain the offset threshold corresponding to each joint, and determine at least one target joint point by the joint offset and joint offset direction of each joint point. The target joint point is used to indicate the joint point among multiple joint points whose joint offset is greater than the offset threshold corresponding to each joint.

[0130] Body type information is determined based on at least one target joint and the joint offset direction corresponding to the target joint.

[0131] In this embodiment of the invention, after acquiring the initial human image to be detected, the initial human image is matrixed to obtain a digitally represented human image matrix, thereby improving image processing efficiency. Then, the target human information in the human image matrix is ​​efficiently detected by a target detection algorithm. After determining the human information, the key points of the human body in the target human information are identified. The key points of the human body are used to indicate the overall skeleton and joints of the human body. In order to determine whether the human posture meets the detection requirements, the posture type information is identified by the key points of the human body, and it is determined whether the posture type is a preset posture type. If the posture type meets the detection requirements, the body posture offset is calculated by the key point information to accurately calculate the offset of the joints, thereby accurately determining the corresponding body posture type based on the body posture offset. This invention can improve the efficiency and accuracy of body posture type recognition.

[0132] above Figure 3 and Figure 4 The body type recognition device in the embodiments of the present invention will be described in detail from the perspective of modular functional entities. The body type recognition device in the embodiments of the present invention will be described in detail from the perspective of hardware processing.

[0133] Figure 5 This is a schematic diagram of the structure of a body type recognition device 500 provided in an embodiment of the present invention. The body type recognition device 500 can vary significantly due to different configurations or performance. It may include one or more central processing units (CPUs) 510 (e.g., one or more processors) and a memory 520, and one or more storage media 530 (e.g., one or more mass storage devices) for storing application programs 533 or data 532. The memory 520 and storage media 530 can be temporary or persistent storage. The program stored in the storage media 530 may include one or more modules (not shown in the diagram), each module may include a series of computer program operations on the body type recognition device 500. Furthermore, the processor 510 may be configured to communicate with the storage media 530 and execute the series of computer program operations in the storage media 530 on the body type recognition device 500.

[0134] The body posture recognition device 500 may also include one or more power supplies 540, one or more wired or wireless network interfaces 550, one or more input / output interfaces 560, and / or one or more operating systems 531, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, etc. Those skilled in the art will understand that... Figure 5 The illustrated body type recognition device structure does not constitute a limitation on the body type recognition device, and may include more or fewer components than illustrated, or combine certain components, or have different component arrangements.

[0135] The present invention also provides a computer device, the computer device including a memory and a processor, the memory storing a computer-readable computer program, which, when executed by the processor, causes the processor to perform the steps of the body type recognition method in the above embodiments.

[0136] The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium, wherein a computer program is stored in the computer program, and when the computer program is run on a computer, the computer performs the steps of the body type recognition method.

[0137] Furthermore, the computer-readable storage medium may primarily include a program storage area and a data storage area, wherein the program storage area may store the operating system, at least one application required for a function, etc.; and the data storage area may store data created based on the use of blockchain nodes, etc.

[0138] The blockchain referred to in this invention is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Essentially, a blockchain is a decentralized database, a chain of data blocks linked together using cryptographic methods. Each data block contains information about a batch of network transactions, used to verify the validity of the information (anti-counterfeiting) and generate the next block. A blockchain can include an underlying blockchain platform, a platform product service layer, and an application service layer.

[0139] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0140] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several computer programs to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0141] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A body type recognition method characterized by, The posture type recognition method comprises: An initial human body image to be detected is acquired, and matrix processing is performed on the initial human body image to obtain a human body image matrix; Human body target detection is performed on the human body image matrix by using a preset target detection algorithm to obtain target human body information; Human body key point recognition is performed on the target human body information by using a pre-trained posture key point recognition model to obtain human body key point information, wherein the posture key point recognition model comprises a light-weight 3D human posture prediction network MovNect, and the MovNect is a three-dimensional posture regression network structure based on a CNN. Offset calculation is performed on the human body key point information to obtain posture offset, and posture type information is determined according to the posture offset, wherein the posture offset is used to indicate the included angle between each human body connection information and corresponding standard connection information, and the human body connection information is used to indicate the connection between adjacent skeletal points in the human body key point information. After the initial human body image to be detected is acquired, a preset kernel matrix is acquired, and weighted average operation is performed on the pixel value corresponding to each pixel point in the initial human body image by using the kernel matrix to obtain the human body image matrix. The offset calculation on the human body key point information to obtain the posture offset, and the determination of the posture type information according to the posture offset, comprise: Human posture classification is performed on the human body key point information to obtain posture type information, and it is judged whether the posture type information is preset posture type information; If the posture type information is preset posture type information, joint offset and joint offset direction are calculated based on the human body key point information to obtain posture offset, and posture type information is determined according to the posture offset, wherein the preset posture type information comprises a front upright posture, a side upright posture and a back upright posture, and does not comprise a sitting posture.

2. The body type recognition method according to claim 1, wherein The acquisition of the initial human body image to be detected and the matrix processing on the initial human body image to obtain the human body image matrix comprise: The initial human body image to be detected is acquired, and the pixel values of all pixel points in the initial human body image are read; Masking operation is performed on the pixel values of all pixel points in the initial human body image by using a preset mask matrix to obtain the human body image matrix.

3. The body type recognition method according to claim 1, wherein The human body target detection on the human body image matrix by using the preset target detection algorithm to obtain the target human body information comprises: Human feature extraction is performed on the human body image matrix by using a preset target detection algorithm to obtain human feature information, and regression operation is performed on the human feature information to obtain at least one target object information, each target object information comprising type information of each target object; Human target object information in the at least one target object information is determined by using the target object type information to obtain target human body information, and the target human body information is used to indicate the detection frame information of the human target object.

4. The body type recognition method according to claim 1, wherein The pre-trained body posture key point recognition model comprises a plurality of deep convolution layers, an up-sampling layer, a cross-stage local layer, a spatial pyramid pooling layer and a regression layer, the body posture key point recognition model is used for body posture key point recognition on the target human body information, and body posture key point information is obtained, comprising: The plurality of deep convolution layers are used for extracting body posture features from the target human body information, and body posture feature information is obtained; The up-sampling layer is used for block division and splicing processing on the body posture feature information, and body posture feature sampling information is obtained; The cross-stage local layer and the spatial pyramid pooling layer are used for body posture feature fusion on the body posture feature sampling information, and body posture feature fusion information is obtained; The regression layer is used for body posture key point classification regression on the body posture feature fusion information, and body posture key point information is obtained.

5. The body type recognition method according to claim 1, wherein The joint offset and the joint offset direction are calculated based on the body posture key point information, the body posture offset is obtained, and the body posture type information is determined according to the body posture offset, comprising: The joint angles of the plurality of joint nodes in the body posture key point information are calculated; The difference between the joint angles of the plurality of joint nodes and the standard angles of the plurality of joint nodes is calculated, and the body posture offset is obtained, the body posture offset comprising the joint offset and the joint offset direction of each joint node; The body posture type information is determined according to the joint offset and the joint offset direction of each joint node.

6. The body type recognition method according to claim 5, wherein The body posture type information is determined according to the joint offset and the joint offset direction of each joint node, comprising: The offset threshold corresponding to each joint is obtained, at least one target joint node is determined according to the joint offset and the joint offset direction of each joint node, and the target joint node is used for indicating the joint node whose joint offset is greater than the offset threshold corresponding to each joint in the plurality of joint nodes; The body posture type information is determined according to the at least one target joint node and the joint offset direction corresponding to the target joint node.

7. A posture type recognition device characterized by comprising: The body posture type recognition device comprises: An acquisition module is configured to acquire an initial human body image to be detected and perform matrix processing on the initial human body image to obtain a human body image matrix; A detection module is configured to perform human body target detection on the human body image matrix by using a preset target detection algorithm to obtain target human body information; An identification module is configured to perform body posture key point recognition on the target human body information by using a pre-trained body posture key point recognition model to obtain body posture key point information, wherein the body posture key point recognition model comprises a lightweight 3D human posture prediction network MovNect, and the MovNect is a CNN-based three-dimensional posture regression network structure; A calculation module is configured to perform offset calculation on the body posture key point information to obtain a body posture offset, and determine body posture type information according to the body posture offset, wherein the body posture offset is used to indicate the included angle between each human body line information and corresponding standard line information, and the human body line information is used to indicate the line between adjacent skeletal points in the body posture key point information. After obtaining the initial human body image to be detected, a preset kernel matrix is obtained, and a weighted average operation is performed on pixel values corresponding to each pixel point in the initial human body image by using the kernel matrix, so as to obtain a human body image matrix; The computing module is further configured to: perform human posture classification on the human key point information to obtain posture type information, and determine whether the posture type information is preset posture type information; If the posture type information is the preset posture type information, calculate a joint offset and a joint offset direction based on the human key point information to obtain a body posture offset, and determine body posture type information according to the body posture offset, wherein the preset posture type information includes a front upright posture, a side upright posture and a back upright posture, and does not include a sitting posture.

8. A body type identifying apparatus characterized by comprising: The body posture type recognition device comprises a memory and at least one processor, and the memory stores a computer program; The at least one processor invokes the computer program in the memory, so that the body posture type recognition device performs the body posture type recognition method according to any one of claims 1-6.

9. A computer-readable storage medium having stored thereon a computer program, characterized in that The computer program is executed by the processor to implement the body posture type recognition method according to any one of claims 1-6.

Citation Information

Patent Citations

  • Posture detection method, device and equipment based on gait characteristics and storage medium

    CN111639533A

  • Figure posture recognition method and device, computer equipment and storage medium

    CN111753643A

  • Image recognition method and device, electronic equipment and storage medium

    CN111783626A

  • Method and device for detecting human body postures

    CN112149455A