A method for action matching based on sensor images using convolutional neural networks

By constructing a multi-skeletal rigid joint constraint model and body shape adaptive correction factor through convolutional neural networks, body shape features and motion features are decoupled, solving the misjudgment problem caused by body shape differences and viewpoint noise in existing technologies, and achieving high-accuracy motion matching and smooth training.

CN122676573BActive Publication Date: 2026-11-24PEOPLES HOSPITAL PEKING UNIV +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611087214.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-21
Publication Date
2026-11-24
Estimated Expiration
2046-07-21

AI Technical Summary

Technical Problem

In intelligent assisted training scenarios such as aerobics, yoga, or rehabilitation exercises, existing technologies for motion matching and evaluation are sensitive to differences in body shape and visual noise, resulting in a high misjudgment rate, poor generalization ability, and affecting the smoothness of training and user experience.

Method used

A convolutional neural network is used for motion matching based on sensor images. By constructing a rigid joint constraint model of multiple bone segments, introducing a body shape adaptive correction factor, decoupling body shape features and motion features, extracting the coordinates of core bone points that are not affected by body shape using geometric topological relationships, and setting a set of joint angle extraction instructions for comparing motion feature state sets.

Benefits of technology

It effectively eliminates body size differences and visual noise interference, reduces false alarm rate, improves the accuracy of motion matching and the smoothness of training, and enhances user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122676573B_ABST
    Figure CN122676573B_ABST
Patent Text Reader

Abstract

This invention discloses a method for action matching based on sensor images using a convolutional neural network, belonging to the technical field of machine vision detection. The method first uses a pre-trained convolutional neural network to identify and obtain the temporal sequence corresponding to each core skeletal point in action video frames from multiple camera positions. After obtaining the skeletal point set, a rigid joint constraint of multiple skeletal segments is constructed, and a body shape adaptive correction factor is introduced to adaptively reconstruct the nonlinear scale of each skeletal point to achieve action feature extraction across body shapes. Finally, the action feature set unaffected by body shape contours is calculated and compared with a standard action set. This invention can decouple human body shape features from motion action features, effectively eliminating projection distortion caused by different body postures and non-horizontal shooting angles. It solves the problems of severe interference from body shape differences and perspective noise, poor generalization ability, and high false alarm rate in traditional action assessment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the technical field of machine vision inspection, and more specifically, to a method for action matching based on sensor images using convolutional neural networks. Background Technology

[0002] In intelligent assisted training scenarios such as aerobics, yoga, or rehabilitation exercises, existing motion matching and evaluation schemes typically employ video comparison methods based on computer vision or skeletal frame matching methods based on convolutional neural networks (CNNs) (i.e., relying on a simple topological frame extracted from global skeletal points of the human body for comparison). However, these traditional methods have the following significant drawbacks in practical applications:

[0003] First, existing methods are highly scale-sensitive, and cannot decouple body shape features from motion features when processing sensor images of different individuals. The pixel coordinates of global skeletal feature points extracted from the image are easily affected by the trainee's height, body shape (such as differences in BMI index), as well as external shooting distance and angle. When faced with trainees who are "obese", "long-limbed", or have large differences in body shape, the original pixel coordinates output by the network will inevitably carry a lot of body shape noise. Traditional absolute coordinate or simple frame comparison algorithms often cannot distinguish between "visual configuration distortion caused by body shape differences" and "non-standard movements", which leads to the algorithm misjudging accurate movements. The system has a very low fault tolerance rate and is extremely unsuitable for groups with non-standard body shapes.

[0004] Secondly, the evaluation criteria of existing methods focus too much on surface morphology and lack robust generalization ability. They rely excessively on external image contours and absolute spatial postures, failing to address the essential movement state of joints and the core skeleton during motion training. This surface comparison mechanism, which only looks at the shape and not the core, makes the auxiliary training standards too strict. As a result, trainees are frequently disturbed by erroneous prompts during training, and training may even be interrupted because they cannot meet the standard spatial conditions set by the machine. This greatly affects the smoothness of auxiliary training and user experience.

[0005] Therefore, there is an urgent need for a motion matching method that can effectively isolate the interference of the trainee's appearance and eliminate the differences between body shape and shooting angle, accurately locate and extract the essential motion state of the core points that is not affected by body shape, thereby significantly reducing the false alarm rate of the system while ensuring that the core training is up to standard. Summary of the Invention

[0006] The purpose of this invention is to provide a method for action matching based on sensor images using convolutional neural networks, in order to solve the problems in the prior art that, due to the inability to decouple human body shape features from motion action features, the action assessment suffers from severe interference from differences in the body shape of trainees and visual noise, poor generalization ability, and high false alarm rate.

[0007] The technical solution of this invention is: to provide a method for action matching based on sensor images using a convolutional neural network, the method comprising:

[0008] Step 1: Collect motion video frames of the target test subject from N camera positions, use a pre-trained convolutional neural network to identify the motion video frames, and obtain the temporal sequence corresponding to each core skeletal point from the N camera positions. Each camera position corresponds to a set of core skeletal points to be extracted.

[0009] Step 2: For each frame image under a single camera position, a local coordinate system is uniformly constructed and the core bone points in each frame image are translated and normalized. Then, a multi-bone rigid joint constraint model of the target test person is constructed under the local coordinate system, and a body shape adaptive correction factor is introduced to adaptively reconstruct the coordinates of each core bone point after translation and normalization.

[0010] Step 3: Set up the joint angle extraction instruction set. In each frame image under single camera position, based on the joint angle extraction instruction set, use the geometric topological relationship constructed by the coordinates of each core bone point after scale reconstruction to calculate the geometric joint angle of the target test person and form a set of motion feature states that are not affected by the body shape contour.

[0011] Step 4: Compare the set of action feature states with the pre-built set of standard action features to calculate the matching degree of the target test character's actions under different instructions.

[0012] Furthermore, step 2 specifically includes:

[0013] Calculate the length L of the trunk skeletal segment trunk Length L of the rigid bone segment on the left side left and the length L of the right rigid bone segment right , represented as:

[0014] ;

[0015] ;

[0016] ;

[0017] In the formula, The neck site is after translation and normalization. The midpoint of the hip after translation and normalization. The point is the left shoulder area after translation and normalization. The left hip area is the normalized point after translation. The point is the right shoulder area after translation and normalization. The point is the right hip area after translation and normalization. It represents the L2 norm.

[0018] Furthermore, step 2 also includes:

[0019] Based on the L trunk L left and L right Calculate the joint reference scale S of the multi-skeletal segments corresponding to the t-th frame image. ref :

[0020] ;

[0021] In the formula, The weights corresponding to the trunk skeletal segments. The weights are the corresponding weights for the rigid skeletal segments on the left and right sides.

[0022] Furthermore, step 2 also includes:

[0023] Calculate the mean of the lateral distances from the left shoulder point to the right shoulder point and from the left hip point to the right hip point, and use this as the lateral posture representation W. body :

[0024] ;

[0025] In the formula, W body The lateral body width feature value of the target test subject; based on the multi-skeletal joint reference scale S ref and lateral body width characteristic value W body Calculate the length-to-width ratio of the body. , represented as Then calculate the aspect ratio. Compared with the standard human anatomy golden ratio template By comparing the results, the nonlinear body shape adaptive correction factor was obtained. :

[0026] ;

[0027] In the formula, This is the sensitivity adjustment coefficient.

[0028] Furthermore, step 2 also includes:

[0029] Using multi-skeletal joint reference scale S ref Body size adaptive correction factor For the relative coordinates P' of all core skeleton points in the t-th frame image f = (x' f , y' f Nonlinear adaptive scaling is performed to obtain the final normalized coordinates P. * f = (x* f , y * f ), represented as: , .

[0030] Furthermore, step 3 specifically includes:

[0031] Pre-set a corresponding joint angle extraction instruction set for each camera position based on the current action type to be measured. The joint angle extraction instruction set for a single camera position is K={k1,k2,...,k r ,...,k R}, R is the total number of joint angles to be calculated for the current motion type, r is the index of the joint angle calculation instruction, and k is the index of each joint angle calculation instruction. r Each of these corresponds to a topological triplet consisting of three specific core skeletal points, represented as follows: ,in, The center vertex of the joint being measured. and This refers to the distal endpoint connected to the joint currently being tested.

[0032] Furthermore, step 3 also includes:

[0033] Iterate through the N images captured from a single camera position at time t in the current frame. For each image captured from a single camera position, iterate through each instruction in the current joint angle extraction instruction set, where the r-th instruction... The mapped triples are Retrieve the normalized two-dimensional coordinates of these three points in the t-th frame image from the normalized coordinate set after scale reconstruction: , , The center vertex of the joint being tested Starting from the origin, proceed to the two distant endpoints respectively. and Construct two outward-facing spatial geometric feature vectors for the limb segments, denoted as vectors. sum vector , represented as:

[0034] ;

[0035] ;

[0036] calculate and cosine value of the angle between Then, the relative geometric angle value of the joint being measured is calculated using the inverse cosine function. This yields the geometric angle value corresponding to each instruction in the current joint angle extraction instruction set. After traversing the images from N single-camera positions corresponding to the current frame t, the calculated geometric angle values ​​from all camera positions are arranged in a predetermined order and cascaded in multiple dimensions to assemble a set of motion feature states representing the completed action state of the target test subject at the current frame t. .

[0037] Furthermore, step 4 specifically includes:

[0038] Standard action feature set The standard expected angle corresponding to the t-th frame and the r-th instruction in the data is: The actual set of action feature states acquired The actual geometric angle value corresponding to the t-th frame and the r-th instruction in the data is Comparison under the condition of frame alignment and And calculate the angle deviation under the r-th command in the t-th frame. Then, the absolute deviation is normalized, and the individual action matching degree S of the r-th instruction in the t-th frame is calculated. mat (t), represented as:

[0039] ;

[0040] In the formula, This is the preset maximum allowable deviation threshold for the r-th instruction; when the measured deviation... Reaching or exceeding the threshold If the matching degree of the instruction is zero, the single action instruction is determined to have been executed incorrectly.

[0041] Furthermore, the set of core skeletal points to be extracted configured under a single camera position in step 1 includes head points and waist points, and selectively includes at least one of the following combinations based on the camera position perspective: left and right shoulder points and left and right elbow points; left and right shoulder points, left and right elbow points and left and right wrist points; left and right hip points and left and right knee points; left and right hip points, left and right knee points and left and right ankle points.

[0042] The beneficial effects of this invention are:

[0043] The technical solution of this invention constructs a multi-skeletal segment rigid joint constraint model of the target test subject, and introduces a body shape adaptive correction factor to adaptively reconstruct the coordinates of each core skeletal point using nonlinear scaling. This enables the extraction of essential movement features across body shapes. Specifically, this invention selects the midpoint of the left and right hips as the origin to establish a local coordinate system to eliminate absolute positional deviations. It constructs a multi-skeletal segment rigid joint constraint model by combining the lengths of three quasi-rigid skeletal segments: the torso, the left spinal side, and the right spinal side. Then, it uses lateral posture representation to compare with the standard human anatomy golden ratio template to solve for the body shape adaptive correction factor, thereby adaptively reconstructing the position coordinates using nonlinear scaling. Linear scale reconstruction is performed, followed by setting a joint angle extraction instruction set. The geometric topological relationship (cosine of the vector angle) corresponding to the scale-reconstructed coordinates is used to abstract the human action into a set of geometric angle feature states that are not affected by the body shape contour. The standard action feature set is compared to calculate the matching degree of the target test human action. The technical solution in this invention achieves complete decoupling of the target test human's body shape and weight (BMI difference), effectively eliminating the three-dimensional projection distortion caused by body rotation and non-horizontal shooting angle. During subsequent matching, it can effectively avoid algorithm misjudgment caused by the non-standard body shape and body shape difference of the target test human, and reduce system false alarms. Attached Figure Description

[0044] The advantages of the above and additional aspects of the present invention will become apparent and readily understood in the description of the embodiments in conjunction with the following drawings, wherein:

[0045] Figure 1 This is a schematic flowchart of a method for action matching based on sensor images using a convolutional neural network according to an embodiment of the present invention;

[0046] Figure 2 This is a predicted trajectory diagram of the left wrist point obtained by the method of the present invention according to Example 1 of the present invention;

[0047] Figure 3 This is a predicted trajectory diagram of the left wrist location points obtained using a conventional linear prediction algorithm according to Example 1 of the present invention.

[0048] Figure 4 This is a comparison diagram of the first set of action images corresponding to the action matching performed using the method of the present invention in Example 2 of the present invention;

[0049] Figure 5 This is a comparison diagram of the second set of motion images corresponding to the motion matching performed using the method of the present invention in Example 2 of the present invention. Detailed Implementation

[0050] To better understand the above-mentioned objectives, features, and advantages of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments of the present invention and the features thereof can be combined with each other.

[0051] In the following description, many specific details are set forth in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and therefore the scope of protection of the invention is not limited to the specific embodiments disclosed below.

[0052] like Figure 1 As shown, this embodiment provides a method for action matching based on sensor images using a convolutional neural network. The method includes:

[0053] Step 1: Collect motion video frames (i.e., high-definition image frame sequences from multiple perspectives) of the target test subject (such as aerobics or yoga athletes) from N camera positions. Use a pre-trained convolutional neural network to identify the motion video frames and obtain the temporal sequence corresponding to each core skeletal point under the N camera positions. According to the shooting field of view and training motion characteristics of each camera position, each camera position is configured with a set of core skeletal points to be extracted. The core skeletal point sets corresponding to different camera positions are the same, partially different, or completely different.

[0054] First, it should be noted that this embodiment uses different camera positions to capture human movements from multiple angles, thereby achieving omnidirectional capture of human movements. Under a single camera position, the set of core skeleton points to be extracted can be adaptively configured according to the shooting field of view corresponding to that position and the training action features (or action type) to be identified. For example, when the shooting field of view corresponds to the front of the human body and the action to be identified is an upper limb action, the set of core skeleton points only contains upper limb skeleton points; when the action to be identified is a lower limb action, the set of core skeleton points only contains lower limb skeleton points, so as to perform targeted angle calculations and action matching later. The reason is that comprehensive evaluation of human movements or motion matching assessment usually requires the complete reconstruction and display of all key skeletal points in the image frame. However, a single camera position has limited field of view and cannot capture every skeletal point from all angles and without obstruction at all times. When the target test subject's movements are large, some skeletal points are easily obscured by the body, resulting in blurred images or unrecognizable images, leading to missing data or instantaneous coordinate jumps. If subsequent coordinate corrections are made directly to such defective skeletal point sequences, it is easy to introduce and amplify accumulated errors, thereby reducing the accuracy of motion matching or assessment. This embodiment, by introducing multi-camera collaborative configuration of different core skeletal point sets, can effectively overcome the occlusion and jump errors of a single camera position, ensuring the accuracy of motion matching and assessment.

[0055] In this embodiment, the convolutional neural network used to identify motion video frames and obtain the temporal sequence corresponding to each core skeleton point under different shooting positions can be an existing convolutional neural network, such as a convolutional neural network constructed with HRNet (High Resolution Network) as the backbone network. This network includes an input layer, a multi-scale feature extraction layer, a cross-scale feature fusion layer, and a heatmap output layer. The input layer consists of convolutional layers and activation functions, used to perform preliminary feature extraction on the original input image frames. The multi-scale feature extraction layer consists of multiple parallel convolutional branches, each branch consisting of multiple residual units (composed of stacked layers, batch normalization layers, and ReLU activation functions, with residual connections introduced) stacked together, with different resolution scales. The multi-scale feature extraction layer uses different branches to perform preliminary feature extraction on the original image frames. Feature extraction is performed on the feature data to obtain parallel multidimensional feature sets at different scales. The cross-scale feature fusion layer consists of a cross-branch fusion module, including a downsampling part (composed of stacked convolutional layers to reduce the feature map), an upsampling part (composed of convolutional layers and bilinear interpolation to enlarge the feature map), a fusion layer (pixel-wise addition of feature maps at different scales), and a ReLU activation function. The cross-scale feature fusion layer is used to repeatedly fuse features at different resolutions to obtain a deep fused feature map. The heatmap output layer consists of convolutional layers and a sigmoid activation function, which is used to map the deep fused feature map into a predetermined number of heatmaps and corresponding confidence scores. Each heatmap corresponds to a core skeleton point, and the coordinates of the point with the largest pixel value are the two-dimensional coordinates of the core skeleton point.

[0056] In this embodiment, the training of the convolutional neural network follows the standard supervised learning process for deep neural networks. Video frames or images containing human movements are captured in advance. A predetermined number of target key points are manually labeled in each image (in this embodiment, 14 points can be set, including head, neck, waist, left and right shoulders, left and right elbows, left and right wrists, left and right hips, left and right knees, left and right ankles, etc., which can be increased or decreased according to specific training needs). Heatmap labels are then set (a response value is generated for each labeled key point using a Gaussian function centered on itself, and a single image ultimately generates a tensor of a predetermined number of dimensions). These form training samples. The target detection model is trained using these training samples. The network parameters are updated using an optimizer (Adam or RMSprop), and the loss function L uses mean squared error loss (MSE). Convergence is determined when the training reaches a specific number of epochs or when the loss function value reaches a preset range. After training, the network parameters are frozen, and the convolutional neural network is copied N times and applied to N camera positions.

[0057] From a single camera position, an industrial camera or a high-definition network camera is used to capture a set of motion video frames. A convolutional neural network is then used to identify each frame, obtaining heatmaps and confidence scores for all core skeleton points in each image frame. The confidence scores range from 0 to 1. For each image frame, only the heatmap and confidence score of the core skeleton point set corresponding to the current camera position are retained, while other heatmaps and confidence scores are deleted. The coordinates of the point with the largest pixel value on the heatmap are extracted as the two-dimensional coordinates of the core skeleton point, resulting in a predetermined number of core skeleton points. By traversing each image frame, the temporal sequence corresponding to each core skeleton point under N camera positions is finally obtained.

[0058] After step 1, the core skeleton points in each image frame can be corrected. Specifically, the following steps can be performed: For the time sequence corresponding to a single type of core skeleton point under a single camera position, the time period of the frame corresponding to one or more sites with confidence scores lower than a preset confidence threshold is taken as the occlusion interval. The coordinate sequence of the site in the preceding and subsequent frames of the occlusion interval is extracted, and the motion trajectory of the site is constructed. Based on the motion trajectory, the actual coordinate sequence of the site in the occlusion interval is determined, and the original time sequence of the site is corrected using the actual coordinate sequence.

[0059] The preset global confidence threshold is T, T [0.4,0.6] For the temporal sequence corresponding to a single core skeleton point in each image frame under a single camera position, each point is traversed sequentially in time order. When the confidence score of any point is less than or equal to the confidence threshold T, it is determined that it has occlusion in the corresponding image frame (i.e., it is an unreliable point due to occlusion, which requires kinematic trajectory prediction and reconstruction based on temporal context information). When the confidence score of the point is greater than the confidence threshold T, it is determined that it has not occluded in the corresponding image frame (i.e., it is a reliable point, which does not require kinematic trajectory prediction and reconstruction). Then, the time period of the frame corresponding to one or more consecutive points with occlusion in the current temporal sequence is taken as the occlusion interval.

[0060] It should be noted that when the core skeleton point is clearly visible, the confidence level can reach 0.95. However, when the core skeleton point is occluded and does not exist in the image, the network will still give an incorrect coordinate, and the confidence level is usually lower than 0.4. Therefore, the incorrect position can be found by the confidence level.

[0061] The coordinate sequences of this type of site are extracted from the preceding and subsequent frames of the occluded area, and the motion trajectory of this type of site is constructed. Based on the motion trajectory, the actual coordinate sequence of this type of site within the occluded area is determined, and the original temporal sequence of this type of site is corrected using the actual coordinate sequence. Specifically, for the temporal sequence corresponding to various core skeleton points under a single camera position, the following steps are performed:

[0062] Step 101: Using the head, neck, and waist points in the core skeleton points as base points, traverse each occlusion interval in the temporal sequence of a single class of base points in chronological order. For a single occlusion interval, extract the coordinate sequence of the base points of that class in the preceding and subsequent frames and construct a first state vector set. Calculate the local motion trajectory of the current class of base points based on the first state vector set, and then predict and reconstruct the coordinates of the current base point in each frame (i.e., the coordinate position in each image frame) within the current occlusion interval based on the local motion trajectory.

[0063] Specifically, for a single occlusion interval in a single-class basic site time series, the coordinates of the M1 frame preceding the first occlusion point are extracted as the preceding coordinate sequence, and the coordinates of the M2 frame following the last occlusion point are extracted as the subsequent coordinate sequence (in order to ensure the integrity of the site motion trajectory, both single-frame occlusion points and consecutive multi-frame occlusion points are defined as occlusion intervals for coordinate reconstruction). M1 takes the value [7,10], and M2 takes the value [3,5].

[0064] For a single occlusion interval corresponding to a single basic site, its first state vector set is constructed based on its preceding coordinate sequence and subsequent coordinate sequence. The first state vector set includes the coordinates, instantaneous linear velocity, and instantaneous acceleration corresponding to the basic position of this type in each frame, and is represented as:

[0065] ;

[0066] ;

[0067] In the formula, This is the first state vector corresponding to the preceding coordinate sequence. This is the first state vector corresponding to the subsequent coordinate sequence. The coordinates of the preceding base site at time t1 (corresponding to the coordinates in the two-dimensional image). , The instantaneous linear velocity of the preceding base point in the x and y directions is calculated using the following formula: , , The instantaneous acceleration of the preceding foundation site in the x and y directions is calculated using the following formula: , This is the inter-frame time interval. This provides the coordinates of the subsequent base site at time t2. , This represents the instantaneous linear velocity of the subsequent base site in the x and y directions. , t1 and t2 represent the instantaneous accelerations of the subsequent base points in the x and y directions, respectively, and the time intervals of the frames in the preceding and subsequent coordinate sequences.

[0068] It should be noted that since the coordinates of the previous frame are within the occlusion area, the first frame in the subsequent coordinate sequence cannot be calculated using the above formula. Here, a linear regression compensation algorithm based on the assumption of motion continuity can be used. That is, the velocity values ​​of the next three frames are used to perform least squares fitting to obtain a function v(t) = a0t + b0 that changes velocity over time. The instantaneous linear velocity is obtained by substituting the time of the first frame in the subsequent coordinate sequence, and a0 is used as the instantaneous acceleration value corresponding to that frame. The directions of the instantaneous linear velocity and instantaneous acceleration are the same as those of the instantaneous linear velocity and instantaneous acceleration of the next adjacent frame.

[0069] The angle between the instantaneous linear velocity vector of the last frame before occlusion (i.e., the last frame preceding the current occlusion interval) and the instantaneous linear velocity vector of the first frame after reappearance (i.e., the first frame following the current occlusion interval) is used. Determine the movement pattern of the current base site, if Then it is determined to be unidirectional movement, that is, the base point maintains its original trend in the general direction. This indicates a reciprocating motion, meaning that the base site retraces its course within the occluded area. Obtained through vector dot product (inner product) operation.

[0070] For unidirectional motion, a polynomial (second to fourth order polynomials can be used for ease of calculation; a second order polynomial is used here for illustration) is used to construct the local first trajectory function f1(t) of the current class of basic sites. The coefficients are then solved by numerical fitting using the preceding and subsequent coordinate sequences corresponding to the current occlusion interval. The first trajectory function f1(t) is expressed as:

[0071] ;

[0072] In the formula, , , The coefficients of the local first trajectory function are given, where t is the time corresponding to the frame (t1 and t2 during fitting); the time of the k-th frame within the occlusion interval is t. k Independent coordinate mapping calculations (i.e., predictions) are performed on the x-axis and y-axis respectively to obtain the predicted coordinates of the current base point in each frame within the current occlusion interval, as shown below:

[0073] ;

[0074] ;

[0075] ;

[0076] In the formula, =( , () represents the coordinates of the base site predicted in the k-th frame. , for Components in the x and y directions, , for Components in the x and y directions, , for The components in the x and y directions; then, using the predicted coordinates of each frame within the current occlusion interval, the original coordinates within the occlusion interval in the current time series are replaced accordingly, so as to complete the correction and reconstruction of the time series of this type of basic site.

[0077] For reciprocating motion (with turning points), it is necessary to calculate and determine the first turning frame t where the instantaneous linear velocity is zero in segments. zero,1 The first turning frame t of the reciprocating motion is determined based on the ratio of the linear velocity magnitudes before and after the current occlusion section. zero,1 , represented as:

[0078] ;

[0079] In the formula, The instantaneous velocity vector of the last frame before occlusion (its magnitude and direction are determined by the corresponding...) Sure), The instantaneous velocity vector of the first frame after reproduction. Represents the modulus operation, t start To occlude the start frame, The time of the first frame following the occlusion interval (i.e., the time when the target key point reappears); based on the first turning frame t zero,1 The obstructed section is divided into deceleration sections. and reverse acceleration phase Construct a deceleration section The corresponding local second trajectory function f2(t), and the reverse acceleration segment. The corresponding local third trajectory function f3(t) is used to determine the coefficients of the second trajectory function f2(t) through numerical fitting by using the preceding coordinate sequence corresponding to the current occlusion interval. The second trajectory function f2(t) is expressed as:

[0080] ;

[0081] In the formula, , , The coefficients of the second trajectory function; for the deceleration phase, tstart For the start frame, calculate t start arrive The mapped coordinates of the current base point on the x-axis and y-axis in all occluded frames are represented as follows: , t k =t start +(k-1) .

[0082] Among them, is the prediction. Set boundary constraints for the corresponding coordinates: Let If the calculated coordinates of the target test subject are located within the detected body contour of the image and exceed the boundary, then the intersection of the body contour boundary and the second trajectory function is forcibly taken as the corrected coordinates. Coordinates, and then using the corrected The coordinates and the preceding coordinate sequence corresponding to the current occlusion interval are used again to determine the coefficients of the second trajectory function f2(t) through numerical fitting, and t is calculated again. start arrive The mapping coordinates of the current base point on the x and y axes in all occluded frames.

[0083] Using the subsequent coordinate sequence corresponding to the current occluded region and the corrected Given the coordinates, the coefficients of the local third trajectory function f3(t) are obtained through numerical fitting. The third trajectory function f3(t) is expressed as:

[0084] ;

[0085] In the formula, , , The coefficients of the third trajectory function; for the reverse acceleration segment, with + For the start frame, calculate + arrive - The mapped coordinates of the current base point on the x-axis and y-axis in all occluded frames are represented as follows: .

[0086] After obtaining the predicted coordinates of the current basic site in each frame within the current occlusion interval, the original coordinates within the occlusion interval in the current time series are replaced with the corresponding coordinates to complete the correction and reconstruction of the time series of this type of basic site.

[0087] Step 102: Using the left and right shoulder points and the left and right hip points as parent joint points, traverse each occlusion interval in the time sequence of a single type of parent joint point in chronological order. For a single occlusion interval, predict and reconstruct the coordinates of the parent joint point of that type in each frame within the current occlusion interval based on the line connecting the head point and the waist point.

[0088] Specifically, the left and right shoulder points and the left and right hip points are processed separately. For any type of site time sequence in the left and right shoulder points, in a single frame of a single occluded interval, the equation of the longitudinal central axis of the target test subject is first calculated based on the coordinates of the head and waist points reconstructed in step 101 (two points determine the straight line). Then, the symmetrical point of the known site symmetrical to the currently selected site with respect to the equation of the straight line is calculated, and the coordinates of the symmetrical point are used as the predicted coordinates of the currently selected site. The same processing is performed on any type of site time sequence in the left and right hip points to obtain the predicted coordinates.

[0089] After obtaining the predicted coordinates of each type of parent joint site in each frame within the current occlusion interval, the original coordinates within the occlusion interval in the current time sequence are replaced with the corresponding coordinates to complete the correction and reconstruction of the time sequence of the parent joint site.

[0090] Step 103: Using the left and right elbow points and the left and right knee points as sub-joint points, traverse each occlusion interval in the temporal sequence of a single type of sub-joint point in chronological order. For a single occlusion interval, extract the coordinate sequence of the sub-joint point of that type in the preceding and subsequent frames and construct a second state vector set. Use the angular velocity and rotation radius parameters in the second state vector set to determine the motion type of the sub-joint point, including restricted rotational motion and free motion. Then, based on the motion type and the second state vector set, generate the local motion trajectory of the current type of sub-joint point. For restricted rotational motion, superimpose the centripetal acceleration term calculated by the coordinate sequence of the corresponding parent joint point into the constructed local motion trajectory model to correct the trajectory curvature through the physical constraints corresponding to the human skeleton features. Finally, based on the local motion trajectory, predict and reconstruct the coordinates of the current sub-joint point in each frame within the current occlusion interval.

[0091] Specifically, the set of core skeletal points to be extracted under a single camera position includes head points, neck points and waist points, and selectively includes at least one of the following combinations according to the camera position angle: (1) left and right shoulder points and left and right elbow points; (2) left and right shoulder points, left and right elbow points and left and right wrist points; (3) left and right hip points and left and right knee points; (4) left and right hip points, left and right knee points and left and right ankle points.

[0092] Using the left hip point as the first reference point for the left knee point, the right hip point as the first reference point for the right knee point, the left shoulder point as the first reference point for the left elbow point, and the right shoulder point as the first reference point for the right elbow point; for a single occlusion interval in the temporal sequence of a single type of sub-joint point, the coordinates of the M1 frame preceding the first occluded point are extracted as the preceding coordinate sequence, and the coordinates of the M2 frame following the last occluded point are extracted as the following coordinate sequence. Based on the preceding and following coordinate sequences of this type of sub-joint point, a corresponding second state vector set is constructed. , represented as:

[0093] ;

[0094] ;

[0095] In the formula, This is the second state vector corresponding to the preceding coordinate sequence. This is the second state vector corresponding to the subsequent coordinate sequence. Let be the coordinates of the subjoint site at time t1. Let be the coordinates of the subjoint site at time t2. Let be the instantaneous linear velocity of the subjoint site at time t1. Let be the instantaneous linear velocity of the subjoint site at time t2. Let be the instantaneous tangential acceleration at the subjoint site at time t1. This represents the instantaneous tangential acceleration at the subjoint site at time t2. Tangential acceleration is the acceleration along or in the opposite direction of the linear velocity. Let be the instantaneous angular velocity of the subjoint site relative to its first reference site at time t1. Let be the instantaneous angular velocity of the subjoint site relative to its first reference site at time t2. , The radius of rotation of the subjoint site at times t1 and t2 (i.e., the Euclidean distance from the subjoint site to the first reference site) is used to reflect the true bone length of the human body.

[0096] Taking the preceding coordinate sequence as an example, the instantaneous angular velocity... The calculation formula is: , The coordinates of the first reference point corresponding to the current subjoint position at time t1; instantaneous linear velocity. Instantaneous tangential acceleration All are vectors, instantaneous linear velocity The calculation formula is: Instantaneous tangential acceleration The calculation formula is: ; where, for the first frame in the subsequent coordinate sequence, and Similarly, a linear regression compensation algorithm based on the assumption of motion continuity is used to obtain a velocity-time function by least-squares fitting of the velocity values ​​of the next three frames. The instantaneous linear velocity is obtained by substituting the time of the first frame in the subsequent coordinate sequence, and the slope of the function is used as the instantaneous acceleration value corresponding to that frame. The direction of the instantaneous linear velocity and instantaneous acceleration is the same as that of the instantaneous linear velocity and instantaneous acceleration of the next frame.

[0097] The instantaneous angular velocities of all frames corresponding to the sub-joint positions in the preceding coordinate sequence are obtained based on the second state vector set. and radius of rotation Based on the instantaneous angular velocity of all frames Calculate the absolute value of the average instantaneous angular velocity. Simultaneously, based on the rotation radius of all frames Calculate the standard deviation of the radius of rotation ,like Greater than the preset angular velocity threshold and If the value is less than the preset standard deviation threshold, it indicates that the sub-joint site has a continuous and stable rotational trend relative to its first reference site and satisfies the rigid constraint of the skeleton. In this case, the joint site is determined to undergo restricted rotational movement. Otherwise, the movement trajectory of the sub-joint site tends to be linear or exhibits an irregular discrete distribution, and does not have stable geometric constraint characteristics. In this case, the first sub-joint site is determined to undergo unconstrained free movement.

[0098] For restricted rotational motion, the angle between the instantaneous linear velocity vector of the last frame before occlusion and the instantaneous linear velocity vector of the first frame after reproduction is used. Determine the motion pattern of the current sub-joint site; if Then it is determined to be a unidirectional motion, if This is a reciprocating motion. Obtained through vector dot product operation, represented as .

[0099] For unidirectional motion in restricted rotational motion, a first centripetal acceleration a is introduced. n,1 Describes the change in rotational motion direction at the current subjoint position, with the first centripetal acceleration a. n,1 Represented as:

[0100] ;

[0101] In the formula, This represents the centripetal acceleration vector corresponding to the sub-joint position in the k-th frame within the current occlusion interval. For the index of the frame within the occlusion interval, Using the reference rotation radius, it is determined by all elements corresponding to the current occlusion region. and The average is obtained by summing them up. This is the pointing unit vector of the centripetal acceleration corresponding to the k-th frame within the current occlusion interval, with its direction pointing from the sub-joint point to the first reference point. The instantaneous angular velocity function corresponding to the sub-joint point in the k-th frame within the current occlusion interval is expressed as: In the formula, To determine the instantaneous angular velocity corresponding to the subjoint site in the last frame before occlusion, The instantaneous angular velocity corresponding to the subjoint site in the first frame after reproduction. The duration of the occlusion.

[0102] The motion of the subjoint site in the occluded region is described as a second state vector corresponding to its preceding coordinate sequence. Driven and subject to the coordinates of subsequent frames The anchored force-driven motion process is dynamically modeled based on the tangential acceleration vector and the centripetal acceleration vector to represent the trajectory of the sub-joint site:

[0103] ;

[0104] In the formula, The coordinates of the sub-joint position in the k-th frame within the occlusion interval. The coordinates of the k-th sub-joint point within the deceleration phase are the coordinates of the previous frame, including the coordinates of the last sub-joint point before occlusion. And the coordinates of the joint points within the occluded area that have already been determined. The instantaneous linear velocity of the sub-joint point corresponding to the k-th frame within the deceleration phase is the instantaneous linear velocity of the sub-joint point in the previous frame, which includes the instantaneous linear velocity of the last sub-joint point before occlusion. And the instantaneous linear velocity of the joint sites within the occluded region, This refers to the known instantaneous tangential acceleration of the previous frame corresponding to the k-th frame sub-joint point to be calculated. Similarly, it includes the tangential acceleration of the last frame sub-joint point before occlusion and the instantaneous tangential acceleration of the first sub-joint point within the occlusion interval that has been calculated. This is the correction coefficient for the sub-joint position of the first frame after reproduction relative to the position of the sub-joint position of the kth frame to be calculated; This is a preceding inertial term, used to predict basic displacements. This is a tangential acceleration term used to control the rate change of the first subjoint site along its motion trajectory. The term is the centripetal acceleration term, used to measure angular velocity. The trajectory curvature of the first subjoint site is constrained by the reference rotation radius to prevent the predicted site coordinates from diverging outwards. Anchoring correction term, used to predict accumulated deviations by reproducing the coordinates of the first frame, eliminate long-distance extrapolation drift, and achieve trajectory closure.

[0105] The trajectory model of the sub-joint site is fitted by combining the preceding and subsequent coordinate sequences corresponding to the current occlusion interval. First, the second state vector corresponding to the preceding coordinate sequence is used. The coordinates of a series of temporary sites affected by centripetal force within the current occlusion interval and the coordinates of the sub-joint sites in the first frame after reproduction are blindly derived, and represented as follows:

[0106] ;

[0107] Then, based on the coordinates of the subjoint sites in the first frame after actual reproduction... The coordinates of the subjoint sites in the first frame after blind derivation and reproduction Calculate the global displacement deviation vector , displacement deviation vector The time-based reallocation and superposition of the data into the trajectory model of the first sub-joint site are used to adjust the correction coefficients. To supplement, it is expressed as:

[0108] ;

[0109] In the formula, Let be the coordinates of the sub-joint position in the k-th frame within the corrected occlusion interval, where The term is the correction factor. The corresponding correction amount is used to ensure that the trajectory of the sub-joint point can accurately fall on the real position of the subsequent frame at the end of the occlusion, without misalignment or divergence; the time corresponding to each frame in the occlusion interval is substituted into the trajectory model of the corrected sub-joint point to calculate the predicted coordinates of the current sub-joint point in each frame image.

[0110] After obtaining the predicted coordinates of the current subjoint site in each frame within the current occlusion interval, the original coordinates within the occlusion interval in the current time sequence are replaced with the corresponding coordinates to complete the correction and reconstruction of the time sequence of this type of subjoint site.

[0111] For reciprocating motion within a restricted rotational motion, first determine the second transition frame t where the angular velocity is zero. zero,2 Based on the second transition frame t zero,2 Divide the current occlusion zone into deceleration segments. and reverse acceleration phase , The time of the first frame in the current occlusion interval. The time of the first frame after reproduction, where the second transition frame t zero,2 Determined based on the ratio of the linear velocity modulus before and after the current occlusion zone, expressed as: , To determine the instantaneous linear velocity corresponding to the last frame before occlusion, The instantaneous linear velocity corresponding to the first frame after reproduction; a piecewise second centripetal acceleration 'a' is introduced. n,2 Describes the change in direction of rotational motion at the first subjoint site, and the piecewise second centripetal acceleration a. n,2 Represented as:

[0112] ;

[0113] In the formula, Let be the instantaneous angular velocity function corresponding to the deceleration segment, which is in Within the interval Decelerate to 0, The instantaneous angular velocity function corresponding to the reverse acceleration segment is... Accelerate from 0 to within the range , , They are represented as follows:

[0114] ;

[0115] ;

[0116] In the formula, To determine the instantaneous angular velocity corresponding to the subjoint site in the last frame before occlusion, The instantaneous angular velocity corresponding to the sub-joint position in the first frame after reproduction; in this reciprocating motion, the centripetal acceleration and angular velocity are highly coupled. As the angular velocity decreases to 0 at the turnaround point, the centripetal acceleration also decreases to 0 to prevent erroneous centripetal deviation at the turnaround point.

[0117] The motion of the first subjoint point in the occluded region is described as the second state vector corresponding to its preceding coordinate sequence. Driven and subject to the coordinates of subsequent frames The anchored force-driven motion process is modeled dynamically based on the tangential acceleration vector and the centripetal acceleration vector, respectively, to model the trajectory of the sub-joint point in the deceleration and reverse acceleration phases. The trajectory of the i-th sub-joint point corresponding to the deceleration phase (movement towards the turning point) is represented as:

[0118] ;

[0119] In the formula, These are the coordinates of the sub-joint position in the k-th frame during the deceleration phase. The coordinates of the corrected trajectory turnaround point. The correction coefficient for the k-th frame sub-joint position to be calculated within the deceleration phase is the coordinate of the turnaround point; the trajectory of the sub-joint position corresponding to the reverse acceleration phase (rebound from the turnaround point) is represented as:

[0120] ;

[0121] In the formula, These are the coordinates of the sub-joint position in the k-th frame within the reverse acceleration segment. This is the correction coefficient for the subjoint position in the first frame after reproduction, relative to the position of the subjoint position in the kth frame to be calculated.

[0122] By combining the preceding and subsequent coordinate sequences corresponding to the current occlusion interval, the trajectory model of the sub-joint point in the deceleration and reverse acceleration phases is fitted. First, the second state vector corresponding to the preceding coordinate sequence is used. A series of temporary sites affected by centripetal force during the blind push deceleration phase. , represented as:

[0123] ;

[0124] Among them, substitution = Obtain the coordinates of the predicted trajectory turnaround point. Then, using the reference rotation radius... and the coordinates of the first reference point corresponding to the current subjoint position. coordinates Corrections were made, and the coordinates of the corrected trajectory turning points were obtained. for:

[0125] ;

[0126] for Set boundary constraints: Let If the calculated coordinates are within the body outline of the detected target person in the image, If the boundary is exceeded, the first reference site will be forcibly used. Centered on the circle, with reference radius of rotation The intersection of the constraint circle with radius and the boundary of the figure's body outline in the image is used as the final corrected coordinate; then, the coordinates of the turning point of the corrected trajectory are used. The displacement deviation vector of the deceleration phase is calculated as follows: ,Will The time-based reallocation and superposition of the data into the trajectory model of the deceleration segment sub-joint sites are used to adjust the correction coefficients. To supplement, it is expressed as:

[0127] ;

[0128] In the formula, These are the coordinates corresponding to the joint positions of the corrected deceleration segment.

[0129] Then, using the second state vector corresponding to the preceding coordinate sequence... and coordinates A series of temporary sites affected by centripetal force in the blind push-out reverse acceleration segment. , represented as:

[0130] ;

[0131] Then, based on the coordinates corresponding to the subjoint sites in the first frame after reconstruction... Calculate the displacement deviation vector during the reverse acceleration phase. , To deduce the coordinates of the sub-joint sites in the first frame after reconstruction from the trajectory blind of the reverse-accelerated sub-joint sites, The time-based reallocation and superposition of the data into the trajectory model of the reverse acceleration segment joint points are used to adjust the correction coefficients. By supplementing the coordinates, the coordinates of the corrected reverse acceleration segment joint points are obtained. , represented as:

[0132] when hour:

[0133] ;

[0134] when hour:

[0135] ;

[0136] In the formula, Given the known instantaneous tangential acceleration of the two frames preceding the k-th sub-joint position to be calculated, substitute the time corresponding to each frame within the occlusion interval into the trajectory model of the sub-joint position in the corrected deceleration and reverse acceleration segments to calculate the coordinates corresponding to the first sub-joint position in each frame image.

[0137] After obtaining the predicted coordinates of the current subjoint site in each frame within the current occlusion interval, the original coordinates within the occlusion interval in the current time sequence are replaced with the corresponding coordinates to complete the correction and reconstruction of the time sequence of this type of subjoint site.

[0138] For unconstrained free motion, the angle between the instantaneous linear velocity vector of the last frame before occlusion and the instantaneous linear velocity vector of the first frame after reproduction is used. Determine the motion pattern of the current reference point, if Then it is determined to be a unidirectional motion, if This is a reciprocating motion.

[0139] For unidirectional motion in unconstrained free motion, a polynomial is also used to construct its corresponding fourth trajectory function f4(t), and the coefficients are solved by numerical fitting using the preceding and subsequent coordinate sequences corresponding to the current occlusion interval. f4(t) is expressed as: In the formula , , The coefficients of the fourth trajectory function are given, where t is the time corresponding to the frame; based on the time t corresponding to the k-th frame within the occlusion interval. k Independent coordinate mapping calculations are performed on the x-axis and y-axis respectively to obtain the coordinates of the occluded k-th frame sub-joint position. This mapping calculation process is the same as the mapping calculation process of the first trajectory function f2(t) in step 22, and will not be repeated here.

[0140] For reciprocating motion in unconstrained free motion, the third turning frame t of the reciprocating motion is first determined based on the ratio of the linear velocity magnitudes before and after the current occlusion interval. zero,3 , Based on the third transition frame t zero,3 The obstructed section is divided into deceleration sections. and reverse acceleration phase Construct a deceleration section The corresponding fifth trajectory function f5(t) and the reverse acceleration segment The corresponding sixth trajectory function f6(t) is then used, and the coefficients of the fifth trajectory function f5(t) are determined by numerical fitting using the preceding coordinate sequence corresponding to the current occlusion interval. The fifth trajectory function f5(t) is expressed as:

[0141] ;

[0142] In the formula, , , The coefficients of the fifth trajectory function; with t start For the start frame, calculate t start arrive The mapped coordinates of the current reference point on the x-axis and y-axis in all occluded frames (the same mapping calculation process as the second trajectory function f2(t) in step 22), where is the predicted coordinates. The corresponding coordinates are constrained by boundary conditions: the coordinates are required to lie within the detected outline of the target person's body in the image; if the calculated coordinates exceed the boundary, the intersection of the outline boundary and the fifth trajectory function is forcibly taken as the corrected coordinates. The coordinates are then used, and the coefficients of the fifth trajectory function f5(t) are determined again through numerical fitting using the corrected coordinates and the preceding coordinate sequence corresponding to the current occlusion interval. Finally, t is recalculated. start arrive The mapping coordinates of the current reference point on the x and y axes in all occluded frames.

[0143] Using the subsequent coordinate sequence corresponding to the current occluded region and the corrected The coefficients of the sixth trajectory function f6(t) are obtained by numerical fitting of the coordinates. The sixth trajectory function f6(t) is expressed as:

[0144] ;

[0145] In the formula, , , The coefficients of the sixth trajectory function; + For the start frame, calculate + arrive - The mapping coordinates of the current reference point on the x and y axes in all occluded frames.

[0146] After obtaining the predicted coordinates of the current subjoint site in each frame within the current occlusion interval, the original coordinates within the occlusion interval in the current time sequence are replaced with the corresponding coordinates to complete the correction and reconstruction of the time sequence of this type of subjoint site.

[0147] Step 104: Using the left and right wrist points and the left and right ankle points as end points, traverse each occlusion interval in the time sequence of a single type of end point in chronological order. For a single occlusion interval, construct the third state vector set, determine the motion type, and generate the local motion trajectory in sequence. The centripetal acceleration term calculated by the coordinate sequence of the corresponding sub-joint point is superimposed in the local motion trajectory model corresponding to the restricted rotational motion. Finally, based on the local motion trajectory, predict and reconstruct the coordinates of the current end point in each frame within the current occlusion interval.

[0148] Specifically, for the timing sequence corresponding to each core skeleton point under a single shooting position, if the combination corresponding to (2) or (4) in step 103 is selected, then step 104 is executed; if other combinations are selected, step 104 is omitted, and step 2 is executed directly. For the case where the combination corresponding to (2) or (4) is selected, the following process is performed:

[0149] Using the left knee as the first reference point for the left foot, the right knee as the second reference point for the foot, the left elbow as the first reference point for the left hand, and the right elbow as the second reference point for the right hand, a single occlusion interval in the temporal sequence of a single type of end point is used. The preceding and subsequent coordinate sequences are extracted, and a corresponding third state vector set is constructed. Then, the angular velocity and rotation radius parameters in the third state vector set are used to determine the motion type of the end point, including restricted rotational motion and free motion. Based on the motion type and the third state vector set, motion trajectories of various types of end points are generated. Finally, the coordinate positions of various types of end points in each frame within the occlusion interval are calculated based on the corresponding motion trajectories. After obtaining the predicted coordinates of each type of end point in each frame within the current occlusion interval, these coordinates are used to replace the original coordinates within the occlusion interval in the current temporal sequence, thus completing the correction and reconstruction of the temporal sequence of this type of end point. This calculation method is the same as step 103 and will not be elaborated here.

[0150] The present embodiment describes how, in acquiring the core skeletal point set, based on the dependencies of each joint point in human dynamics, layered motion constraints and physical trajectory compensation are applied to the point coordinates within the occluded area. First, each core skeletal point is divided into base points, parent joints, child joints, and end points, and their kinematic constraints are set layer by layer, constructing corresponding state vector sets. Then, using the angular velocity and rotation radius within these vector sets, two types of motion modes—unconstrained free motion and constrained rotational motion—are accurately identified and distinguished. Next, trajectory evolution modeling is performed specifically for these two types of motion modes. For free motion, the temporal coordinates within the occluded area are quickly reconstructed through polynomial fitting; for constrained rotational motion… The centripetal acceleration term calculated from the corresponding reference point is dynamically introduced into the trajectory evolution equation, so that the instantaneous angular velocity, rotation radius (actual bone length) and centripetal acceleration are dynamically coupled. The centripetal force constraint can correct the trajectory curvature based on the physical constraints of human skeletal features, so that the predicted point still conforms to the limits of human anatomy during occlusion. This solves the problem that the predicted coordinates of traditional linear algorithms are prone to diverging along the tangent or deviating from the bone length constraint when dealing with curvilinear motion (a large number of rotational movements such as turning and circling in aerobics and yoga). This mechanism can effectively eliminate trajectory drift under long-distance time-series extrapolation and improve the coordinate restoration accuracy of key movements that are highly dynamic and easily occluded, such as arm swings, limb twists, and rotational jumps.

[0151] Step 2: For each frame of image under a single camera position, a unified local coordinate system is constructed and the core skeletal points in each frame of image are translated and normalized. Then, a multi-skeletal rigid joint constraint model of the target test person is constructed under the local coordinate system. An adaptive body shape correction factor is introduced to adaptively reconstruct the coordinates of each core skeletal point after translation and normalization, in order to eliminate the three-dimensional projection distortion caused by different target test persons due to differences in height, body shape (BMI difference) and non-horizontal shooting angle.

[0152] Specifically, after the correction step, the t-th frame image in single-camera mode has acquired a set of pixel coordinates containing F core skeleton points, represented as P = {P1, P2,..., P...} F}, where the two-dimensional coordinates of the f-th core skeleton point in the original image coordinate system (a coordinate system with the top left corner of the image as the origin) are represented as P. f = (x f , y f ), f To eliminate absolute coordinate deviations caused by different target test subjects standing in the image (e.g., to the left, right, forward, or backward), a local coordinate system with a specific center point of the human body as the origin needs to be established for translational alignment. Based on the obtained set of pixel coordinates of F core skeletal points, the midpoint P of the left and right hips of the target test subject is selected. hip =(x hip , y hip ) as the reference origin O r =(x o , y o Establish a local coordinate system, where the midpoint P of the hip is... hip The coordinates of the left and right hip points are used for calculation, with the selected reference origin O. r For all core skeleton points P in the t-th frame image f = (x f , y f Perform translation normalization to obtain the translated relative coordinates P'. f = (x' f , y' f ), x' f =x f -x o y' f =y f -y o At this point, the relative coordinates of the reference origin itself become (0, 0), and the relative coordinates of all other skeleton points represent the translation-normalized coordinates in the local coordinate system.

[0153] This scheme does not use a single linear trunk length for human body division scaling. Instead, it constructs a multi-skeletal segment rigid joint constraint model. A single segment distance (such as from the neck to the entire hip) is highly susceptible to two-dimensional projection shortening caused by movements such as leaning forward, backward, or hunching. To improve anti-interference capabilities, this scheme uses a joint geometric average of three independent quasi-rigid skeletal segments from human anatomy as a benchmark reference scale. The length L of each trunk skeletal segment is calculated separately. trunk Length L of the left rigid skeletal segment (left spinal side) left and the length L of the right rigid skeletal segment (right spinal side) right , represented as:

[0154] ;

[0155] ;

[0156] ;

[0157] In the formula, The neck site is after translation and normalization. The midpoint of the hip after translation and normalization. The point is the left shoulder area after translation and normalization. The left hip area is the normalized point after translation. The point is the right shoulder area after translation and normalization. The point is the right hip area after translation and normalization. Represents the L2 norm; based on the length L of the trunk skeletal segment. trunk Length L of the rigid bone segment on the left side left and the length L of the right rigid bone segment right Calculate the joint reference scale S of the multi-skeletal segments corresponding to the t-th frame image. ref This is used to eliminate projection errors caused by unilateral occlusion or body torso rotation, and is expressed as:

[0158] ;

[0159] In the formula, The weights corresponding to the trunk skeletal segments. The weights are the corresponding weights for the rigid skeletal segments on the left and right sides.

[0160] Because differences in body mass (BMI) can cause non-motor shifts in the limb key points located by the neural network (e.g., in overweight individuals, the detected elbow and knee points are wider relative to the trunk center due to fat accumulation), this scheme introduces a body shape adaptive correction factor for adjustment; the mean of the lateral distances from the left shoulder point to the right shoulder point and from the left hip point to the right hip point is calculated as the lateral body shape representation W. body :

[0161] ;

[0162] In the formula, W body The lateral body width feature value of the target test subject; based on the multi-skeletal joint reference scale S ref and lateral body width characteristic value W body Calculate the length-to-width ratio of the body. , represented as Then calculate the aspect ratio. Compared with the standard human anatomy golden ratio template (Preset constants, such as) = 0.45) is compared to construct a nonlinear mapping function to obtain the nonlinear body shape adaptive correction factor. :

[0163] ;

[0164] In the formula, The sensitivity adjustment coefficient has a value range of [0.1, 0.5], preferably 0.25.

[0165] Using multi-skeletal joint reference scale S ref Body size adaptive correction factor For the translation-normalized relative coordinates P' of all core skeleton points in the t-th frame image f = (x' f , y' f Nonlinear adaptive scaling is then performed to obtain the final normalized coordinates P. * f = (x * f , y * f ), represented as: , .

[0166] During the adaptive nonlinear scaling reconstruction process, when the target test subject conforms to the standard body size... ,at this time The system performs standard scaling; when the target test subject is overweight or has an abnormally wide lateral frame, , The value will adaptively decrease, serving as both a penalty and a correction term, dynamically converging the outward offset deviation of key points in the limbs caused by fat thickness; when the target test subject is extremely slender and elongated... , Adaptively increase to compensate for visual bone contraction; in nonlinear body shape adaptive correction factor Under the regulation, the decoupling and separation of fat and thin body types were achieved.

[0167] Step 3, cross-body geometric joint angle calculation; set up a joint angle extraction instruction set, and in each frame image under single camera position, based on the joint angle extraction instruction set, use the geometric topological relationship constructed by the coordinates of each core bone point after scale reconstruction to calculate the geometric joint angles of the target test person, forming a set of motion feature states that are not affected by body shape contour.

[0168] Specifically, a set of joint angle extraction instructions is pre-set for each camera position based on the type of movement to be measured (such as specific movements in aerobics, yoga, or rehabilitation training). The set of joint angle extraction instructions for a single camera position is K={k1,k2,...,k r ,...,k R}, R is the total number of joint angles to be calculated for the current motion type, r is the index of the joint angle calculation instruction, and k is the index of each joint angle calculation instruction. r Each of these corresponds to a topological triplet consisting of three specific core skeletal points, represented as follows: ,in, The center vertex of the joint being measured. and The distal endpoint connected to the joint being measured is denoted as k1. For example, if the current joint angle calculation instruction k1 is to calculate the "left elbow joint angle", then the topological triplet automatically mapped by this instruction is: left shoulder point A1, left elbow point B1, and left wrist point C1.

[0169] Iterate through the N images captured by a single camera at time t in the current frame. For each image captured by a single camera, perform geometric joint angle calculations based on the corresponding joint angle extraction instruction set. Specifically, iterate through each instruction in the current joint angle extraction instruction set, where the r-th instruction... The mapped triples are Retrieve the normalized two-dimensional coordinates of these three points in the t-th frame image from the normalized coordinate set after scale reconstruction (corresponding to step 2): , , The center vertex of the joint being tested Starting from the origin, proceed to the two distant endpoints respectively. and Construct two outward-facing spatial geometric feature vectors for the limb segments, denoted as vectors. sum vector , represented as:

[0170] ;

[0171] ;

[0172] Then calculate the eigenvectors. and cosine value of the angle between Then, the relative geometric angle value of the joint being measured is calculated using the inverse cosine function. (The cosine value is truncated to the interval [-1, 1] before the inverse cosine is calculated). The range of values ​​is [0, The geometric angle value corresponding to each instruction in the current joint angle extraction instruction set is calculated using the dot product (inner product) principle of the space vector of the cosine value of the angle. After traversing the images from N single-camera positions corresponding to the current frame t, the calculated geometric angle values ​​from all camera positions are arranged in a predetermined order and cascaded in multiple dimensions to assemble a set of motion feature states representing the completed action state of the target test subject at the current frame t. .

[0173] Step 4: Compare the set of action feature states with the pre-built set of standard action features to calculate the matching degree of the target test character's actions under different instructions.

[0174] Specifically, model athletes perform standard target movements (such as standard aerobics or yoga movements) beforehand, and multiple sets of standard movement video frames are acquired (each set includes data from N camera positions). The set of movement feature states corresponding to each set of standard movements is calculated according to the methods in steps 1 to 3. The average of each item in the multiple sets of movement feature states is then taken to obtain the standard movement feature set. .

[0175] It should be noted that in this embodiment, it is assumed that the beat of the model athlete performing the standard target action is the same as the beat of the target test subject performing the target action, that is, the actions of the two are synchronized on the time axis, and the corresponding frames t have a mapping relationship on the time sequence. Under this assumption, the action feature state set of the target test subject at frame t on the actual measurement time axis can be directly compared and aligned with the standard expected angle at the same time stamp t in the standard action spatiotemporal feature library.

[0176] Standard action feature set The standard expected angle corresponding to the t-th frame and the r-th instruction in the data is: The set of action feature states obtained in step 3 The actual geometric angle value corresponding to the t-th frame and the r-th instruction in the data is Comparison under the condition of frame alignment and And calculate the angle deviation under the r-th command in the t-th frame. Then, the absolute deviation is normalized, and the individual action matching degree S of the r-th instruction in the t-th frame is calculated. mat (t), represented as:

[0177] ;

[0178] In the formula, The maximum permissible deviation threshold preset for the r-th instruction (e.g., preset to 15°-30°); when the measured deviation... Reaching or exceeding the threshold When the matching degree of the instruction is zero, the system directly determines that the single action instruction has been executed incorrectly or failed.

[0179] The single action matching degree S was calculated. mat After (t), it is determined whether the matching degree of the single action is lower than the preset qualified threshold; if it is lower than the qualified threshold, the positive and negative attributes of the difference between the measured geometric joint angle of the target test person at the current moment and the standard expected angle are further extracted, and based on the physical mapping relationship between the positive and negative attributes of the difference and the current command, corresponding corrective feedback opinions such as "angle too large / please tighten" or "angle too small / please stretch" are given in subsequent evaluation.

[0180] Example 1:

[0181] Video frames of the target test subject's movements during aerobics were collected. Taking the subject's left wrist as the observation point, a set of images containing the occluded area of ​​this observation point was extracted, such as... Figure 2 As shown, the figure's left wrist swings behind and is obscured. The position of the left wrist is constrained by the left elbow (its reference point), resulting in a reciprocating motion within a restricted rotational movement. The trajectory of the left wrist within the obscured area is reconstructed using both the method of this invention and a traditional linear prediction algorithm. The position prediction of the left wrist within the obscured area is completed, and a set of 12 images is extracted at preset time intervals for visual comparison and display, yielding the following results: Figure 2 and Figure 3 The comparison chart shown.

[0182] like Figure 2 This is a predicted trajectory diagram of the left wrist region corresponding to the method of the present invention, such as... Figure 3 The image shows the predicted trajectory of the left wrist point corresponding to the traditional linear prediction algorithm. It is clear that the traditional linear prediction algorithm cannot accurately predict the movement trajectory of the occluded point, while the method of the present invention can accurately predict the movement trajectory of the occluded point.

[0183] Because traditional algorithms lack understanding of human biomechanics and rigid topological constraints, the temporal coordinates of the predicted left wrist location are easily deviated from the physical limitations of the human skeleton. As the number of occluded frames increases, the cumulative error continues to amplify, causing the predicted coordinates to diverge directly outward along the tangent direction. At the same time, the algorithm cannot model reciprocating motions of highly dynamic back-and-forth movements, and can only mechanically move forward along the original inertial trajectory before being occluded. This results in severe discontinuities and instantaneous coordinate jumps between the predicted frame at the end of the occluded section and the subsequent reappearing frame. If such predicted coordinates carrying huge distortion noise are input into the subsequent action matching process, it will inevitably lead to misjudgments by the action recognition algorithm and high-frequency errors in the system. This invention employs a layered dynamic constraint mechanism. Under the constraint of the rigid length of the human skeleton, the reconstructed trajectory of the left wrist strictly conforms to the anatomical features and biomechanical laws of the human body. For this type of reciprocating motion, this invention accurately calculates the motion transition frames in the time domain, dynamically evolves the force trajectories of the deceleration and acceleration phases, and uses the bidirectional state vectors of the preceding and subsequent recurring sequences to anchor and correct the trajectory based on force. The reconstructed temporal trajectory is smooth and continuous, achieving seamless closure with the subsequently recurring real recurring frames, eliminating coordinate jumps and trajectory divergence. Experiments demonstrate that the position coordinate space reconstructed using this method has extremely high fidelity and, when applied to subsequent motion matching and evaluation systems, can significantly suppress algorithmic false alarms caused by missing data.

[0184] Example 2:

[0185] From a frontal camera position, video frames of the target test subject's movements during aerobics exercises are captured, and two sets of typical movement images of the target test subject during the training process are extracted and labeled as the first set of movement images and the second set of movement images, respectively. Figure 4 and Figure 5 As shown in the figure. In this experiment, the target test subjects differed significantly from the model athletes in the standard library in terms of body type, height, and BMI.

[0186] The two sets of action images were subjected to feature extraction and action standardization evaluation using the method of this invention and the traditional action matching method, respectively. The traditional action matching method adopts a video comparison method based on computer vision. The specific process is as follows: extract the global human body contour image of the trainee through edge detection or background modeling algorithm, and the pixel absolute coordinate topological framework. Then, the contour region is compared with the standard video frame pixel by pixel, absolute spatial pose or contour overlap difference is calculated to determine whether the action meets the standard.

[0187] The results of the comparative evaluation of the two sets of movements are as follows:

[0188] For the first set of motion images: Traditional methods, which observe the external contours of the human body, cannot effectively decouple body shape features from motion features. The visual configuration differences caused by variations in body shape of the target test subject are directly misjudged by traditional algorithms as indicating non-standard movements, resulting in an erroneous judgment that all movements are non-standard, leading to an extremely high false alarm rate. In contrast, the method of this invention focuses on the essential motion state of the core motion skeleton. Utilizing a non-linear scale reconstruction mechanism that introduces a body shape adaptive correction factor, it completely eliminates spatial projection noise caused by body shape differences. Based on this, the invention abstracts multiple sets of joint angles of the target test subject (including bilateral shoulder joint angles, bilateral elbow joint angles, and bilateral hip joint angles) through geometric topological relationships, assembles and generates a set of motion feature states, and compares them frame-by-frame with a standard database. The results accurately indicate that the test subject's right-side limb movements are completely standard, with only the left-side limb movements showing deviations. This provides data support for the subsequent system output of precise corrective feedback such as "left-side stretching / tightening."

[0189] Regarding the second set of motion images: Traditional motion matching methods are also severely affected by the test subject's body shape. Traditional methods cannot capture the essential movement state of the core joints, and still give a vague and incorrect assessment result of "whole body posture is not standard". However, the method of this invention eliminates the interference of body shape, and accurately locates the specific misaligned joint points by solving the geometric joint angles across body shape. The final assessment result shows that only the angle of the left elbow joint is not standard, and the movements of other core joints are completely within the standard range.

[0190] Experimental results show that traditional motion matching methods are prone to high-frequency false alarms due to their inability to eliminate differences in body shape and shooting angle, and can only provide a vague overall negative evaluation. In contrast, the method of this invention can effectively remove shape interference, accurately locate and extract the essential motion state of the core points that are not affected by body shape, which not only greatly reduces the false alarm rate of the system, but also achieves accurate identification, matching and quantitative evaluation of specific non-standard skeletal sites.

[0191] The steps in this invention can be adjusted, combined, or deleted according to actual needs.

[0192] The units in the device of the present invention can be merged, divided, or reduced according to actual needs.

[0193] In this invention, the terms "installation," "connection," "linking," and "fixing" should be interpreted broadly. For example, "connection" can be a fixed connection, a detachable connection, or an integral connection; "linking" can be a direct connection or an indirect connection through an intermediate medium. Those skilled in the art can understand the specific meaning of these terms in this invention according to the specific circumstances.

[0194] The shapes of the components in the accompanying drawings are schematic and may differ from their actual shapes. The drawings are only used to illustrate the principles of the present invention and are not intended to limit the present invention.

[0195] Although the invention has been disclosed in detail with reference to the accompanying drawings, it should be understood that these descriptions are merely exemplary and not intended to limit the application of the invention. The scope of protection of the invention is defined by the appended claims and may include various modifications, alterations, and equivalents made to the invention without departing from the scope and spirit of the invention.

Claims

1. A method for action matching based on sensor images using a convolutional neural network, characterized in that, The method includes: Step 1: Collect motion video frames of the target test subject from N camera positions, use a pre-trained convolutional neural network to identify the motion video frames, and obtain the temporal sequence corresponding to each core skeletal point from the N camera positions. Each camera position corresponds to a set of core skeletal points to be extracted. Step 2: For each frame image under a single camera position, a local coordinate system is uniformly constructed and the core bone points in each frame image are translated and normalized. Then, a multi-bone rigid joint constraint model of the target test person is constructed under the local coordinate system, and a body shape adaptive correction factor is introduced to adaptively reconstruct the coordinates of each core bone point after translation and normalization. Wherein, the joint reference scale S trunk of the multi-skeleton segments corresponding to the t-th frame image is calculated based on the trunk skeleton segment length L left , the left side rigid skeleton segment length L right and the right side rigid skeleton segment length L ref : ; In the formula, The weights corresponding to the trunk skeletal segments. The weights corresponding to the rigid skeletal segments on the left and right sides; The mean of the lateral distance of the left shoulder site to the right shoulder site and the lateral distance of the left hip site to the right hip site is calculated as the lateral posture representation W body : ; In the formula, W body The horizontal body width feature value of the target test subject is used. The point is the left shoulder area after translation and normalization. The left hip area is the normalized point after translation. The point is the right shoulder area after translation and normalization. The points are located on the right hip after translation and normalization; based on the multi-skeletal joint reference scale S. ref and lateral body width characteristic value W body Calculate the length-to-width ratio of the body. , represented as Then calculate the aspect ratio. Compared with the standard human anatomy golden ratio template By comparing the results, the nonlinear body shape adaptive correction factor was obtained. : ; In the formula, This is the sensitivity adjustment coefficient; Using multi-skeletal joint reference scale S ref Body size adaptive correction factor For the relative coordinates P' of all core skeleton points in the t-th frame image f = (x' f , y' f Nonlinear adaptive scaling is performed to obtain the final normalized coordinates P. * f =(x * f , y * f ), represented as: , ; Step 3: Set up the joint angle extraction instruction set. In each frame image under single camera position, based on the joint angle extraction instruction set, use the geometric topological relationship constructed by the coordinates of each core bone point after scale reconstruction to calculate the geometric joint angle of the target test person and form a set of motion feature states that are not affected by the body shape contour. Step 4: Compare the set of action feature states with the pre-built set of standard action features to calculate the matching degree of the target test character's actions under different instructions.

2. The method for action matching based on sensor images using a convolutional neural network as described in claim 1, characterized in that, Step 2 specifically includes: Calculate the length L of the trunk skeletal segment trunk Length L of the rigid bone segment on the left side left and the length L of the right rigid bone segment right , represented as: ; ; ; In the formula, The neck site is after translation and normalization. The midpoint of the hip after translation and normalization. It represents the L2 norm.

3. The method for action matching based on sensor images using a convolutional neural network as described in claim 1, characterized in that, Step 3 specifically includes: Pre-set a corresponding joint angle extraction instruction set for each camera position based on the current action type to be measured. The joint angle extraction instruction set for a single camera position is K={k1,k2,...,k r ,...,k R }, R is the total number of joint angles to be calculated for the current motion type, r is the index of the joint angle calculation instruction, and k is the index of each joint angle calculation instruction. r Each of these corresponds to a topological triplet consisting of three specific core skeletal points, represented as follows: ,in, The center vertex of the joint being measured. and This refers to the distal endpoint connected to the joint currently being tested.

4. The method for action matching based on sensor images using a convolutional neural network as described in claim 3, characterized in that, Step 3 also includes: Iterate through the N images captured from a single camera position at time t in the current frame. For each image captured from a single camera position, iterate through each instruction in the current joint angle extraction instruction set, where the r-th instruction... The mapped triples are Retrieve the normalized two-dimensional coordinates of these three points in the t-th frame image from the normalized coordinate set after scale reconstruction: , , The center vertex of the joint being tested Starting from the origin, proceed to the two distant endpoints respectively. and Construct two outward-facing spatial geometric feature vectors for the limb segments, denoted as vectors. sum vector , represented as: ; ; calculate and cosine value of the angle between Then, the relative geometric angle value of the joint being measured is calculated using the inverse cosine function. This yields the geometric angle value corresponding to each instruction in the current joint angle extraction instruction set. After traversing the images from N single-camera positions corresponding to the current frame t, the calculated geometric angle values ​​from all camera positions are arranged in a predetermined order and cascaded in multiple dimensions to assemble a set of motion feature states representing the completed action state of the target test subject at the current frame t. .

5. The method for action matching based on sensor images using a convolutional neural network as described in claim 1, characterized in that, Step 4 specifically includes: Standard action feature set The standard expected angle corresponding to the t-th frame and the r-th instruction in the data is: The actual set of action feature states acquired The actual geometric angle value corresponding to the t-th frame and the r-th instruction in the data is Comparison under the condition of frame alignment and And calculate the angle deviation under the r-th command in the t-th frame. Then, the absolute deviation is normalized, and the individual action matching degree S of the r-th instruction in the t-th frame is calculated. mat (t), represented as: ; In the formula, This is the preset maximum allowable deviation threshold for the r-th instruction; when the measured deviation... Reaching or exceeding the threshold If the matching degree of the instruction is zero, the single action instruction is determined to have been executed incorrectly.

6. The method for action matching based on sensor images using a convolutional neural network as described in claim 1, characterized in that, In step 1, the set of core skeletal points to be extracted configured under a single shooting position includes head points and waist points, and selectively includes at least one of the following combinations according to the camera position perspective: left and right shoulder points and left and right elbow points; left and right shoulder points, left and right elbow points and left and right wrist points; left and right hip points and left and right knee points; left and right hip points, left and right knee points and left and right ankle points.

Citation Information

Patent Citations

  • Single-view-angle Tai Chi action analysis and assessment system based on artificial intelligence

    CN112016497A

  • Intelligent assessment method and system for motion skills, actions and postures

    CN122157370A