A human motion imitation method and device based on an adaptive selection framework
By employing an adaptive selection framework-based human motion imitation method, which utilizes reference motion clustering, pre-trained controllers, and dynamic programming, the method addresses the physical inconsistencies and high computational costs associated with existing human motion recovery techniques. This enables the rapid generation of high-quality 3D human motion, making it suitable for virtual reality and animation production.
Patent Information
- Application Number
- CN202510326174.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-19
- Publication Date
- 2025-11-28
- Estimated Expiration
- 2045-03-19
AI Technical Summary
Existing technologies for recovering 3D human motion from 2D videos suffer from depth blur, self-occlusion, and lack of camera parameters, resulting in physically unreasonable artifacts in the generated motion data. At the same time, the computational cost is high, making it difficult to meet the needs of practical applications.
We employ an adaptive selection framework-based human motion imitation method. By using reference motion clustering, a pre-trained human motion controller, a dynamic programming-assigned controller, and joint fine-tuning of the controller, we can quickly generate high-quality and physically accurate human motion using deep reinforcement learning and dynamic programming algorithms.
It significantly improves the quality and speed of motion imitation, solves the problem of imitating complex motion, reduces physical inconsistencies, and is suitable for applications such as virtual reality and animation production.
Smart Images

Figure CN120163910B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of human animation and human motion restoration, and particularly relates to a human motion imitation method based on an adaptive selection framework, which is used for quickly generating high-quality and physically correct human motion in a physics engine. BACKGROUND
[0002] Human motion restoration is an important research direction in the fields of computer graphics and human animation, aiming to restore the motion information of human bodies in three-dimensional space from videos or other inputs. This technology has wide application prospects in virtual reality, animation production, motion analysis, etc. In recent years, with the rapid development of deep learning and sensor technology, human motion restoration methods have made significant progress, but still face many challenges.
[0003] Restoring 3D motion from 2D videos is an ill-posed problem, and existing methods are often limited by depth blur, self-occlusion, and lack of camera parameters, resulting in physically unreasonable artifacts such as foot sliding, body penetrating the ground, and floating in the restored motion data. On the other hand, some research attempts to introduce physical constraints into the motion restoration process. For example, methods based on physical simulation can effectively reduce physically unreasonable phenomena by driving virtual characters in a physics engine to imitate the motion extracted from videos. However, such methods usually have high computational cost, and it takes hours or even longer to generate a single motion clip, making it difficult to meet the needs of practical applications. SUMMARY
[0004] The purpose of the present application is to overcome the shortcomings of the prior art and provide a human motion imitation method based on an adaptive selection framework, which can quickly imitate reference motion while ensuring the high quality and physical correctness of the imitation results.
[0005] The purpose of the present application is achieved by the following technical solutions: In a first aspect, the present application provides a human motion imitation method based on an adaptive selection framework, which includes the following steps:
[0006] (1) Reference motion clustering: Extract feature vectors from each reference motion and perform hierarchical clustering on the feature vectors, so that the class radius of each class is less than a preset threshold, thereby limiting the complexity of the motion in each class.
[0007] (2) Pre-training human motion controller: Use a deep reinforcement learning algorithm to pre-train multiple motion controllers, each of which is used to imitate the reference motion in a cluster.
[0008] (3) Dynamic programming assignment controller: according to the imitation results of all pre-trained motion controllers on the reference motion, an optimal motion controller is assigned to each segment of the reference motion, specifically: using all pre-trained motion controllers to imitate the reference motion, generating an imitation reward trajectory corresponding to each controller; based on the imitation reward trajectory, a dynamic programming algorithm is used to maximize the total reward and minimize the controller switching frequency as the optimization goal, and the optimal human motion controller assignment scheme is solved.
[0009] (4) Controller joint fine-tuning: during the data collection process of reinforcement learning, the reference motion is imitated using the assigned human motion controller; when switching motion controllers is needed during different stage motion imitation, the posture imitated by the last motion controller is continued to control imitation, and the assigned human motion controller is fine-tuned according to the collected data.
[0010] Further, the feature vector group of the reference motion extraction includes: the average height of the root node from the ground in the reference motion; the mean square angular velocity of the root node rotating around the axis perpendicular to the ground in the reference motion; the mean square speed of all nodes parallel to the ground and the mean square speed perpendicular to the ground in the reference motion; the mean square acceleration of all nodes in the reference motion.
[0011] Further, the class radius calculation process is to traverse all feature vector pairs in the class, calculate the Euclidean distance between each pair of feature vectors, and take the maximum distance as the class radius.
[0012] Further, the motion controller inference process is to input the next frame of the reference motion and the difference between it and the current imitation posture, together with the body shape parameters, into the autoencoder for encoding to obtain 128-dimensional encoding features; input the encoding features and the current imitation posture into the policy network to generate the target posture; input the target posture into the proportional differential controller (PDController) to generate the torque acting on each human joint in the physics engine.
[0013] Further, in the motion controller training process, the 128-dimensional encoding features are input into a decoder trained at the same time, and the input of the autoencoder is used to supervise the output of the decoder to ensure that the original input information of the autoencoder is not lost in the encoding features.
[0014] In a second aspect, the present application also provides a human motion imitation device based on an adaptive selection framework, comprising a memory and one or more processors, the memory storing executable code, and the processor executing the executable code to implement the human motion imitation method based on the adaptive selection framework.
[0015] In a third aspect, the present application further provides a computer readable storage medium, having a program stored thereon, which, when executed by a processor, implements the human motion imitation method based on the adaptive selection framework.
[0016] In a fourth aspect, the present application further provides a computer program product comprising a computer program, which, when executed by a processor, implements the human motion imitation method based on the adaptive selection framework.
[0017] The present application has the following beneficial effects:
[0018] 1. By using multiple motion controllers to imitate different clusters of reference motions, the imitation ability of complex and diverse motions is improved, and the imitation quality is significantly improved.
[0019] 2. By introducing an auto-encoder into the motion controller, the next frame of the reference motion and the difference between the current posture and the next frame are encoded together with the body shape parameters, which is proved to effectively speed up the training and improve the imitation quality.
[0020] 3. By using a dynamic programming algorithm to quickly assign the optimal motion controller to each motion segment of the reference motion, the problem of complex and diverse actions within a reference motion that is difficult to imitate is solved.
[0021] 4. After assigning the motion controllers, a joint fine-tuning mechanism is introduced to solve the smoothness problem during the transition between different motion controllers, further improving the imitation quality.
[0022] In summary, the present application provides a human motion imitation method based on an adaptive selection framework, which can effectively improve the quality of imitated motion and speed up the imitation process. It is suitable for research fields such as high-quality human motion big data set construction, and various application scenarios such as virtual reality and animation production, and has a wide application prospect. BRIEF DESCRIPTION OF DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiment or prior art description:
[0024] Figure 1 The overall algorithm flowchart of the present application.
[0025] Figure 2 The overall structure diagram of the human motion controller in the present application.
[0026] Figure 3 The data collection schematic diagram of joint fine-tuning in the present application.
[0027] Figure 4This is a schematic diagram of a human motion mimicry device based on an adaptive selection framework, provided by the present invention. Detailed Implementation
[0028] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings.
[0029] Figure 1 The flowchart of the method of this invention is shown, namely a human motion imitation method based on an adaptive selection framework. First, all reference motions are clustered to obtain multiple reference motion classes; then, a motion controller is pre-trained on each reference motion class to imitate the reference motions in that class; finally, a dynamic programming algorithm is used to assign a motion controller to each motion segment of the reference motion to be imitated. Figure 1 An example of allocation is shown; finally, the allocated motion controller is jointly fine-tuned to obtain high-quality simulation results. The method of this invention specifically includes the following four steps:
[0030] (1) Reference Motion Clustering: Reference motion can be recovered from video using existing human motion recovery methods. It is composed of body shape parameters and human poses from consecutive frames, where the human pose includes the rotation of J nodes of the human joints and the translation of the root node. The J human nodes include the pelvis, hip, knee, ankle, foot, spine, scapula, shoulder, elbow, wrist, hand, neck, and head. First, feature vectors are extracted from the reference motion. The feature vectors include the average height of the root node from the ground in 1D reference motion, the mean square angular velocity of the root node rotating about an axis perpendicular to the ground in 1D reference motion, the mean square velocities of all human nodes parallel to and perpendicular to the ground in 2JD reference motion, and the mean square acceleration of all human nodes in JD reference motion, for a total of 3J+2 dimensions. To avoid redundant calculation of root node information, the velocities and accelerations of all human nodes except the root node are calculated based on their positions in the root node coordinates. Then, hierarchical clustering is performed on the extracted feature vectors. After each clustering, all feature vector pairs in the newly generated class are traversed, the Euclidean distance between feature vector pairs is calculated, and the maximum distance is used as the class radius of that class. If the class radius of the newly generated class is greater than a preset threshold and the number of elements within the class is greater than a preset threshold, then clustering of that class continues until no new classes need further clustering. By limiting the class radius, the complexity of the reference motion within each class can be effectively reduced, thereby simplifying the subsequent training process of the controller.
[0031] (2) Pre-trained human motion controller: trained using the Proximal Policy Optimization (PPO) algorithm from reinforcement learning. For example... Figure 2As shown, the human motion controller includes an autoencoder, a decoder, a policy network, and a value network. The autoencoder and the decoder have the same structure, which is composed of three hidden layers (1024, 512, 512) and one output layer of a multilayer perception mechanism; the policy network and the value network are composed of three hidden layers (1024, 1024, 512) and one output layer of a multilayer perception mechanism. During the training process, the next frame of the reference motion is sampled as the reference pose, and the reference pose and the difference between the reference pose and the current imitation pose are input into the autoencoder together with the body parameter to obtain the encoded feature. The current frame of the imitation pose input into the policy network includes the root node height, the rotation angle, the speed, the rotation angle and the rotation speed of the nodes other than the root node under the root node coordinates, and the positions of the hands and feet under the root node coordinates. The encoded feature and the current frame of the imitation pose are sent into the policy network together to generate the target pose, and then the target pose is input into the proportional-differential controller to calculate the torque of each joint of the human body in the physics engine, so as to simulate the next moment of the imitation pose. The feedback function in the training process includes the similarity of the imitation pose and the reference pose, and the similarity of the projection of the joint nodes of the imitation pose back to the image and the detected two-dimensional key points. At the same time, the encoded feature is sent into the decoder to obtain the decoding result, and the input of the autoencoder is used to supervise the decoding result to ensure that too much information is not lost in the encoded feature.
[0032] (3) Dynamic programming allocation controller: using all pre-trained motion controllers to imitate the pose sequence of the reference motion to generate the imitation reward trajectory corresponding to each controller where c represents the serial number of the motion controller, and N represents the number of motion frames, represents the imitation reward of the cth controller at the tth frame. During the generation process, if the imitation reward of a certain motion controller is less than a given threshold, the imitation pose controlled by the controller is reinitialized as the imitation pose of the controller with the highest current imitation reward. Based on the imitation reward trajectory, a dynamic programming algorithm is used to maximize the total reward and minimize the controller switching frequency as the optimization objective to solve the optimal human motion controller allocation scheme where, o t represents the serial number of the selected controller at the tth frame, w p represents the penalty term of switching the controller, and δ {·,·} represents the Dirac function. The state transition equation of the dynamic programming in this step is where the state function dp(t, c) represents the highest cumulative reward from the 1st frame to the tth frame when the cth controller is selected at the tth frame, which is initialized as c' has the same meaning as c, which is used here to denote an intermediate variable for finding the maximum value. The results of all state functions can be calculated through the state transition equation, for example, dp(2, ·) can be derived from the initialized dp(1, ·), and so on to dp(N, ·). The optimal allocation scheme is obtained by recursively propagating from max x [dp(N, c)] to the starting frame, for example, o N = argmax c [dp(N, c)], Similarly, if there are multiple o N-1 satisfy the equation requirement, a random one is selected. This allocation method not only allocates appropriate motion controllers for each motion segment of the reference motion, but also limits the frequent switching of motion controllers when imitating a segment of reference motion, so as to avoid excessive transition problems.
[0033] (4) Controller joint fine-tuning: training using the proximal policy optimization algorithm, similar to step (2), but using the motion controllers allocated in step (3) for data collection and imitation training of the corresponding motion segment. As shown in Figure 3 for simplicity, the figure omits the body shape parameters), in the data collection process, the corresponding motion controller allocated to the reference pose is called to interact with the environment to obtain the next frame of imitation pose. The first frame of imitation pose is directly initialized as the first frame of reference pose. When the motion controller of the next frame of reference pose is different from the motion controller of the current frame, the motion controller of the next frame of reference pose is used to continue interacting with the environment, rather than resetting the imitation pose or interrupting the imitation. In this way, the imitation poses in the transition phase of different motion controllers can be collected for subsequent policy optimization. In the policy optimization phase, the allocated motion controllers are optimized together, but the data collected in the data collection phase is only used to optimize the corresponding motion controller. In order to improve the stability of the policy optimization process, the gradient calculated in the motion controller backpropagation phase is pruned to limit it to -1 to 1.
[0034] The comparative experiment proves the advantages of the present application over the prior art solutions. Table 1 shows the index comparison of the present application and other prior art solutions on the Human3.6M dataset which is widely used for testing. The compared indexes include: root node error (Mean root position error, MRPE), node error (Mean per-joint position error, MPJPE), velocity error and acceleration error, which measure the imitation accuracy, the lower the better; foot sliding (Foot sliding, FS), ground penetration (Ground penetration, GP), and floating (Floating), which measure the physical rationality of the imitated motion, the smaller the better. The data of VIBE, GVHMR and MaskedMimic in Table 1 come from the respective open source code and model, and the data of other technical solutions come from the data published by each technical solution. In Table 1, "-" represents that the technical solution does not publish the corresponding data index. From Table 1, compared with the prior art solutions, the present application realizes the smallest root node error and node error in the imitation error, and has obvious advantages over most prior art solutions in the velocity error and acceleration error; in the physical rationality index, the result of the present application is also excellent and at the leading level. Especially compared with VIBE and GVHMR, which are non-physical driven human motion recovery methods, the present application has a significant advantage in the physical rationality index.
[0035] Table 1, quantitative comparison of the present application and prior art solutions on the Human3.6M dataset
[0036]
[0037] Meanwhile, the ablation experiment proves the necessity of the core steps in the present application. Table 2 lists the performance of the system on the Human3.6M dataset after stripping off different key steps in the present application or replacing key parameters, for explaining the role of the key steps in the present application in the whole system, wherein the complete method of the present application is in bold. It can be seen that the benchmark scheme directly imitates each reference motion from scratch, with large imitation error and long training time; without fine-tuning, the imitation quality is significantly reduced; adding the autoencoder in the motion controller can improve the overall imitation quality and reduce the fine-tuning time required; after introducing the dynamic programming allocation controller, the reference motion with rich action changes can be imitated, thereby improving the imitation quality and reducing the fine-tuning time required; the size of the class radius also has a greater impact on the result, when the class radius threshold is 40, the imitation error can be better reduced, and the fine-tuning time is also reduced, while too large or too small class radius will lead to reduced imitation quality and increased fine-tuning time; in addition, without clustering and increasing the parameter amount of the controller, the imitation quality will be reduced, and the fine-tuning time required will be greatly increased, which proves the effectiveness of the multi-controller scheme.
[0038] Table 2, influence of main steps in the present application on the whole system, wherein the complete method of the present application is in bold.
[0039]
[0040] Corresponding to the foregoing embodiment of the human motion imitation method based on the adaptive selection framework, the present application also provides an embodiment of a human motion imitation device based on the adaptive selection framework.
[0041] Referring to Figure 4 The human motion imitation device based on the adaptive selection framework provided in the embodiment of the present application comprises a memory and one or more processors, the memory stores executable code, and the processor executes the executable code to implement the human motion imitation method based on the adaptive selection framework in the foregoing embodiment.
[0042] The embodiment of the human motion imitation device based on the adaptive selection framework provided in the present application can be applied to any device with data processing capability, which can be a device or apparatus such as a computer. The device embodiment can be realized by software, or by hardware or a combination of software and hardware. Taking software realization as an example, as a logically meaningful device, it is formed by reading the corresponding computer program instructions in the non-volatile memory into the memory for execution by the processor of the any device with data processing capability where the device is located. From the hardware level, for example, the device can be a chip mainly composed of a processor. When the processor executes the corresponding computer program instructions in the non-volatile memory, the chip realizes the functions of the device. Figure 4As shown in the figure, a hardware structure diagram of an arbitrary data processing capable device where the human motion imitation apparatus based on the adaptive selection framework provided by the present application is located, in addition to the processor, the memory, the network interface, and the non-volatile memory Figure 4 In addition to the processor, the memory, the network interface, and the non-volatile memory, the arbitrary data processing capable device where the apparatus in the embodiment is located can also include other hardware according to the actual functions of the arbitrary data processing capable device, and details are not described herein.
[0043] The implementation process of the functions and roles of each unit in the apparatus is specifically described in the implementation process of the corresponding steps in the above method, and details are not described herein.
[0044] For the apparatus embodiment, since it basically corresponds to the method embodiment, the related parts can be referred to the part of the method embodiment. The apparatus embodiment described above is only schematic, and the units described as separate components can or can not be physically separate, and the components displayed as units can or can not be physical units, that is, they can be located in one place, or distributed on multiple network units. Part or all of the modules can be selected to achieve the purpose of the present application according to actual needs. Those skilled in the art can understand and implement without creative labor.
[0045] The embodiment of the present application also provides a computer readable storage medium, which stores a program, and the program is executed by a processor to realize the human motion imitation method based on the adaptive selection framework in the above embodiment.
[0046] The computer readable storage medium can be an internal storage unit of the arbitrary data processing capable device, such as a hard disk or a memory. The computer readable storage medium can also be an external storage device of the arbitrary data processing capable device, such as a plug-in hard disk, a smart media card (SMC), an SD card, a flash card, etc. Further, the computer readable storage medium can include both the internal storage unit and the external storage device of the arbitrary data processing capable device. The computer readable storage medium is used to store the computer program and other programs and data required by the arbitrary data processing capable device, and can also be used to temporarily store data that has been output or will be output.
[0047] The present application also provides a computer program product, which includes a computer program, and the computer program is executed by a processor to realize the human motion imitation method based on the adaptive selection framework.
[0048] In summary, the application provides a human motion imitation method using an adaptive selection framework, which can quickly imitate a reference motion and generate high-quality imitated motion. The above embodiments are used to explain and illustrate the application, but not to limit the application, and any modifications and changes made to the application within the spirit of the application and the protection scope of the claims fall within the protection scope of the application.
Claims
1. A method for imitating human motion based on an adaptive selection framework, characterized in that, The method includes the following steps: (1) Reference motion clustering: extract feature vectors from each reference motion and perform hierarchical clustering on the feature vectors so that the class radius of each class is less than a preset threshold. (2) Pre-trained motion controllers: Multiple motion controllers are pre-trained using deep reinforcement learning algorithms to mimic the reference motion in each cluster. (3) Dynamic programming to assign controllers: Based on the imitation results of the reference motion, an optimal motion controller is assigned to each motion segment of the reference motion. Specifically, all pre-trained human motion controllers are used to imitate the reference motion to generate the imitation reward trajectory corresponding to each motion controller. Based on the imitation reward trajectory, a dynamic programming algorithm is used to solve the optimal human motion controller allocation scheme with the optimization objective of maximizing the total reward and minimizing the controller switching frequency. (4) Joint fine-tuning of controllers: During the data acquisition process of reinforcement learning, the assigned motion controller is used to imitate the reference motion; when it is necessary to switch motion controllers for different stages of motion imitation, the posture imitated by the previous motion controller is continued to be controlled, and the assigned motion controller is fine-tuned according to the acquired data.
2. The human motion imitation method based on an adaptive selection framework according to claim 1, characterized in that, The extraction of the feature vector includes: calculating the average height of the root node from the ground during the reference motion, the mean square angular velocity of the root node rotating about an axis perpendicular to the ground, the mean square velocities of all nodes parallel to the ground and perpendicular to the ground, and the mean square acceleration of all nodes; and combining the above calculation results to form the feature vector.
3. The human motion imitation method based on an adaptive selection framework according to claim 1, characterized in that, The calculation process of the class radius includes: traversing all feature vector pairs within the class, calculating the Euclidean distance between each pair of feature vectors, and taking the maximum distance as the class radius.
4. The human motion imitation method based on an adaptive selection framework according to claim 3, characterized in that, If the radius of the newly generated class is greater than the first preset threshold and the number of elements in the class is greater than the second preset threshold, then the newly generated class will continue to be clustered until there are no new generated classes that need to be further clustered.
5. The human motion imitation method based on an adaptive selection framework according to claim 1, characterized in that, The reasoning process of the motion controller includes: inputting the next frame pose of the reference motion and its difference from the current imitation pose, along with human body shape parameters, into an autoencoder for encoding to obtain multi-dimensional encoded features; feeding the encoded features and the current imitation pose into the policy network of a deep reinforcement learning algorithm to generate a target pose; and inputting the target pose into a proportional-derivative controller to obtain the torque acting on each human joint in the physics engine.
6. The human motion imitation method based on an adaptive selection framework according to claim 5, characterized in that, The previous imitation pose includes the root node height, rotation angle, and velocity; the rotation angle and rotation velocity of other nodes in the root node coordinate system; and the positions of the hands and feet in the root node coordinate system.
7. The human motion imitation method based on an adaptive selection framework according to claim 1, characterized in that, During the generation of the imitation reward trajectory, if the imitation reward of a certain motion controller is less than a given threshold, the imitation posture controlled by that controller is reinitialized to the imitation posture of the controller with the highest current imitation reward.
8. A human motion mimicry device based on an adaptive selection framework, comprising a memory and one or more processors, wherein the memory stores executable code, characterized in that, When the processor executes the executable code, it implements a human motion imitation method based on an adaptive selection framework as described in any one of claims 1-7.
9. A computer-readable storage medium having a program stored thereon, characterized in that, When the program is executed by the processor, it implements a human motion imitation method based on an adaptive selection framework as described in any one of claims 1-7.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements a human motion imitation method based on an adaptive selection framework as described in any one of claims 1-7.
Citation Information
Patent Citations
Motion synthesis framework based on deep neural network
CN114972441A
Data efficient imitation of diverse behaviors
WO2018211140A1