Human trunk anomaly detection method based on computer vision

Through a computer vision-based method, using deep learning algorithms to obtain the key nodes and back contour curvature of the trunk frame image, the problems of high cost, low efficiency and insufficient refinement analysis in the prior art are solved, and efficient and accurate trunk anomaly detection is achieved.

CN120259241APending Publication Date: 2025-07-04XIAN VISARI DIGITAL TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510338420.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-21
Publication Date
2025-07-04

AI Technical Summary

Technical Problem

The existing human posture detection methods rely on wearable sensors or manual observations with high cost, low efficiency and susceptibility to interference from factors such as light and occlusion. They lack refined analysis of trunk posture, and the detection accuracy and robustness are insufficient.

Method used

Using a computer vision-based method, the trunk frame images are collected by setting angles, the deep learning algorithm is used to obtain key nodes, the attitude angle and the curvature of the back contour are calculated, and the trunk abnormalities are detected in combination with feature point searches.

Benefits of technology

It realizes efficient and accurate trunk abnormality detection in complex scenarios, simplifies operation and reduces costs, and improves the robustness of detection and refined analysis capabilities.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120259241A_ABST
    Figure CN120259241A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of human body posture detection, in particular to a human body trunk anomaly detection method based on computer vision. Collecting a trunk frame image of the target human body at a set angle; acquiring key joint points in the trunk frame image of the target human body by using a deep learning algorithm; according to the key joint points, obtaining a forward-leaning attitude angle of the target human body, and judging whether the attitude angle is within a set range or not; when the position is within the set range, extracting a back contour area of the target human body; performing feature point search in the back contour area, and calculating the back contour curvature of the target human body by using the searched feature points; and detecting the trunk abnormity of the target human body according to the back contour curvature of the target human body. The detection method provided by the invention is simple to operate and easy to implement, and an accurate detection result can be obtained.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of human body posture detection, and particularly to a method for detecting human torso abnormalities based on computer vision. Background Art

[0002] There are various existing methods for human body posture detection. Traditional methods for detecting human body posture abnormalities mostly rely on wearable sensors or manual observation, which have defects such as high cost, low efficiency, and strong subjectivity. Although existing image processing-based technologies can partially achieve automated detection, they are vulnerable to factors such as illumination and occlusion in complex scenarios, and lack the ability to perform refined analysis of torso postures. In addition, existing methods usually do not comprehensively judge by combining important parameters such as joint angles and contour curvatures, resulting in insufficient detection accuracy and robustness. Summary of the Invention

[0003] To solve the problems existing in the prior art, the present invention provides a method for detecting human torso abnormalities based on computer vision. The method includes: collecting torso frame images of a target human body at a set angle; using a deep learning algorithm to obtain key joint points in the torso frame images of the target human body; obtaining the posture angle of the target human body leaning forward according to the key joint points, and judging whether the posture angle is within a set range; when it is within the set range, extracting the back contour area of the target human body; performing feature point search in the back contour area, and calculating the back contour curvature of the target human body using the searched feature points; detecting abnormalities of the target human body torso according to the back contour curvature of the target human body. The detection method proposed by the present invention is simple to operate and easy to implement, and can obtain accurate detection results.

[0004] The present invention adopts the following technical solutions. A method for detecting human torso abnormalities based on computer vision includes:

[0005] Collecting torso frame images of a target human body at a set angle;

[0006] Using a deep learning algorithm to obtain key joint points in the torso frame images of the target human body;

[0007] Obtaining the posture angle of the target human body leaning forward according to the key joint points, and judging whether the posture angle is within a set range;

[0008] When it is within the set range, extracting the back contour area of the target human body;

[0009] Performing feature point search in the back contour area, and calculating the back contour curvature of the target human body using the searched feature points;

[0010] Detecting abnormalities of the target human body torso according to the back contour curvature of the target human body.

[0011] Further, the key joint points in the torso frame image of the target human body include: shoulder joint points, hip joint points, and knee joint points.

[0012] Further, extract the back contour area of the target human body, including:

[0013] Extract the human mask image of the target human body torso frame image;

[0014] Obtain the vertical line at the shoulder joint point of the line connecting the shoulder joint point and the hip joint point;

[0015] Take the line vector connecting the hip joint point and the shoulder joint point as the first vector, and the line vector connecting the hip joint point and the knee joint point as the second vector;

[0016] Obtain the angular bisector of the first vector and the second vector at the hip joint point;

[0017] Use the vertical line at the shoulder joint point of the line connecting the shoulder joint point and the hip joint point and the angular bisector of the first vector and the second vector at the hip joint point to perform region segmentation on the human mask image to obtain the back contour area of the target human body.

[0018] Further, perform feature point search in the back contour area, including:

[0019] Search from the shoulder joint point in the direction of the vertical line until reaching the first boundary point of the back contour area of the target human body, and take the first boundary point as the upper feature point;

[0020] Search from the hip joint point along the angular bisector towards the back contour area of the target human body until reaching the second boundary point of the back contour area of the target human body, and take the second boundary point as the lower feature point;

[0021] Scan pixel points row by row between the upper feature point and the lower feature point to obtain the median pixel point as the middle feature point.

[0022] Further, detect the abnormality of the target human body torso according to the back contour curvature of the target human body, including:

[0023] Obtain the back contour curvature of the target human body in each frame image;

[0024] Take the frame image corresponding to the back contour curvature greater than the first threshold as the abnormal frame image;

[0025] Obtain the abnormal proportion of the abnormal frame image in all frame images. When the abnormal proportion is greater than the second threshold, it is determined that the target human body torso is abnormal.

[0026] The beneficial effects of the present invention are: those of the present invention. Description of the Drawings

[0027] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0028] Figure 1 Schematic flow chart of a method for detecting abnormal human torso based on computer vision according to an embodiment of the present invention. Detailed implementation manners

[0029] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, rather than all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of protection of the present invention.

[0030] A schematic flow chart of a method for detecting abnormal human torso based on computer vision according to an embodiment of the present invention is as Figure 1 shown, including:

[0031] Collect torso frame images of the target human body at a set angle;

[0032] In the embodiment of the present invention, the video captured of the target human body can be read and input into the YOLO pose detection model for detection. Optionally, key frame images can be extracted for detection by extracting one frame image every three frames.

[0033] Use a deep learning algorithm to obtain key joint points in the torso frame image of the target human body;

[0034] In the embodiment of the present invention, the key joint points in the torso frame image of the target human body include: shoulder joint points, hip joint points, and knee joint points, and the pose angle of the human body during the torso forward tilt is calculated by a three-point angle calculation method.

[0035] Obtain the pose angle of the target human body's forward tilt according to the key joint points, and determine whether the pose angle is within a set range;

[0036] Set the three sides of the triangle formed by the shoulder joint point, hip joint point, and knee joint point, and its calculation formula can be expressed as:

[0037] BA = (xA - xB, yA - yB)

[0038] BC = (xC - xB, yC - yB)

[0039]

[0040]

[0041] BA·BC = (xA - xB)(xC - xB) + (yA - yB)(yC - yB)

[0042] BA×BC = (xA - xB)(yC - yB) - (yA - yB)(xC - xB)

[0043] cosθ = (BA·BC) / (|BA|·|BC|)

[0044] sinθ = (BA×BC) / (|BA|·|BC|)

[0045] θ = arctan2(sinθ, cosθ)

[0046] angle = |θ×180 / π|

[0047] Wherein, A represents the shoulder joint point, B represents the hip joint point, and C represents the knee joint point. Then the above formula represents calculating the included angle between the connection BA between the hip joint and the shoulder joint point and the connection BC between the hip joint point and the knee joint point at the hip joint point B.

[0048] When within the set range, extract the back contour area of the target human body;

[0049] In the embodiments of the present invention, the set range of the posture angle is set to be between 5° and 50°. When the posture angle is within this range, it is considered that the human body in the current frame image has a back bend. If the posture angle is not within this set area, it is considered that there is no bend in the trunk of the target human body at this time, and no trunk abnormality detection is required.

[0050] The steps of extracting the back contour area of the target human body include:

[0051] Optionally in the embodiments of the present invention, use the YOLO pose detection model to extract the human mask image of the target human body trunk frame image;

[0052] Obtain the perpendicular line of the connection between the shoulder joint point and the hip joint point at the shoulder joint point; calculate the slope of this perpendicular line as:

[0053] m = (y2 - y1) / (x2 - x1) m⊥ = -1 / m

[0054] Then the equation of this perpendicular line can be expressed as:

[0055] y - y0 = m⊥(x - x0)

[0056] Take the line vector connecting the hip joint point and the shoulder joint point as the first vector, and the line vector connecting the hip joint point and the knee joint point as the second vector; perform normalization processing on the first vector and the second vector, which is expressed as:

[0057] v1 = (x1 - x2, y1 - y2)

[0058] v2 = (x3 - x2, y3 - y2)

[0059]

[0060]

[0061] Obtain the angular bisector of the included angle between the first vector and the second vector at the hip joint point, and the vector representation of this angular bisector is:

[0062] v m = (v 1u + v 2u ) / |v 1u + v 2u |

[0063] Use the perpendicular line of the line connecting the shoulder joint point and the hip joint point at the shoulder joint point and the angular bisector of the included angle between the first vector and the second vector at the hip joint point to perform region segmentation on the human eye membrane map. Calculate the region between the two lines pixel by pixel according to the directions of the perpendicular line and the bisector, and retain the original mask pixel values within this region, then the back contour region of the target human body can be obtained.

[0064] Perform feature point search in the back contour region, and calculate the back contour curvature of the target human body using the searched feature points;

[0065] The method for performing feature point search in the back contour region specifically includes:

[0066] Search from the shoulder joint point in the direction of the perpendicular line. During the search process, monitor the difference change of the pixels on the left and right of the monitored point until reaching the first boundary point of the back contour region of the target human body. At this time, the pixel values on both the left and right of the first boundary point are 0, then take the first boundary point as the upper feature point;

[0067] Search from the hip joint point along the angular bisector towards the back contour region of the target human body. During the search process, monitor the difference change of the pixels on the left and right of the monitored point until reaching the second boundary point of the back contour region of the target human body. At this time, the pixel values on both the left and right of the second boundary point are 0, then take the second boundary point as the lower feature point;

[0068] Scan pixel points line by line between the upper feature point and the lower feature point, record the boundary point coordinates of each line and ensure that there are at least 4 valid points. Use the cubic spline function to perform spline curve fitting on the back contour area. Then, the upper feature point and the lower feature point each move 10% along the back contour towards each other, aiming to remove the possible abnormal points at both ends of the contour curve. Then, take the midpoint between the upper and lower points as the middle feature point for subsequent curvature calculation.

[0069] Detect the abnormality of the target human body trunk according to the back contour curvature of the target human body.

[0070] In the embodiment of the present invention, calculate the curvature of the back contour according to the obtained upper feature point, middle feature point and lower feature point. First, establish a circle fitting equation set, expressed as:

[0071] (x - h) 2 +(y - k) 2 =r 2

[0072] Expand it to:

[0073] x 2 +y 2 -2hx - 2ky+(h 2 +k 2 -r 2 )=0

[0074] Subsequently, represent the above formula in matrix form:

[0075]

[0076] |x2 2 +y2 2 x2y2 1||b|=|-1|

[0077]

[0078] Then the expressions for calculating the radius and curvature are:

[0079]

[0080] κ=1 / r

[0081] In the formula, (x, y) represents the coordinates of any point on the circle, which is a variable and is used to determine the position of the point on the circle in the plane rectangular coordinate system. (h, k) represents the coordinates of the center of the circle, which is a key parameter of the circle and determines the position of the circle in the plane rectangular coordinate system. r represents the radius of the circle and determines the size of the circle. a, b, c, d have specific corresponding relationships in the matrix form. In the expansion formula: x 2 +y 2 -2hz - 2ky+(h2 +k 2 -r 2 ) = 0, where a = 1, b = -2h, c = -2k, d = h 2 +k 2 -r 2 。

[0082] After obtaining the curvature of the back contour region in each frame image in the embodiments of the present invention, the curvature value of each frame is recorded, and the total number of frames processed is counted. In the embodiments of the present invention, the first threshold for determining whether the curvature value is abnormal is set to 1.0, then the number of frames with a curvature value > 1.0 is counted, and the abnormal ratio is calculated: the number of abnormal frames / the total number of frames

[0083] R = N a / N t ×100%

[0084] Where: N a represents the number of abnormal frames, and N t represents the total number of frames. In the embodiments of the present invention, the second threshold is set to 30%, that is, when the abnormal ratio is greater than 30%, it is determined that there is an abnormality in the target human torso in the current video.

[0085] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A method for detecting abnormal human torso based on computer vision, characterized in that, Including: Collecting trunk frame images of a target human body at a set angle; Using a deep learning algorithm to obtain key joint points in the trunk frame images of the target human body; Obtaining the posture angle of the target human body leaning forward according to the key joint points, and determining whether the posture angle is within a set range; When it is within the set range, extracting the back contour area of the target human body; Performing feature point search in the back contour area, and calculating the back contour curvature of the target human body using the searched feature points; Detecting abnormalities in the trunk of the target human body according to the back contour curvature of the target human body.

2. The method for detecting abnormal human torso based on computer vision according to claim 1, characterized in that: The key joint points in the trunk frame images of the target human body include: shoulder joint points, hip joint points and knee joint points.

3. A method for detecting abnormal human torso based on computer vision according to claim 1, characterized in that: Extracting the back contour area of the target human body includes: Extracting the human mask image of the trunk frame image of the target human body; Obtaining the vertical line of the shoulder joint point of the line connecting the shoulder joint point and the hip joint point; Taking the connection vector between the hip joint point and the shoulder joint point as the first vector, and the connection vector between the hip joint point and the knee joint point as the second vector; Obtaining the angle bisector of the first vector and the second vector at the hip joint point; Using the vertical line of the shoulder joint point of the line connecting the shoulder joint point and the hip joint point and the angle bisector of the first vector and the second vector at the hip joint point to perform region segmentation on the human mask image to obtain the back contour area of the target human body.

4. A method for detecting abnormal human torso based on computer vision according to claim 1, characterized in that: Performing feature point search in the back contour area includes: Searching from the shoulder joint point in the direction of the vertical line until reaching the first boundary point of the back contour area of the target human body, and taking the first boundary point as the upper feature point; Searching from the hip joint point along the angle bisector towards the back contour area of the target human body until reaching the second boundary point of the back contour area of the target human body, and taking the second boundary point as the lower feature point; Scanning pixel points row by row between the upper feature point and the lower feature point to obtain the median pixel point as the middle feature point.

5. The method for detecting abnormal human torso based on computer vision according to claim 1, wherein: Detecting abnormalities in the trunk of the target human body according to the back contour curvature of the target human body includes: Obtaining the back contour curvature of the target human body in each frame image; Taking the frame images corresponding to the back contour curvature greater than the first threshold as abnormal frame images; Obtaining the abnormal proportion of the abnormal frame images in all frame images, and when the abnormal proportion is greater than the second threshold, determining that there are abnormalities in the trunk of the target human body.