Posture deformation method and system for mapping human body posture to robot posture
By constructing the same three-dimensional coordinate system in the human body and robot and calculating spatial angle information, the problems of natural fluency and accuracy in robot posture imitation are solved, and more realistic action imitation is achieved.
Patent Information
- Application Number
- CN202411055382.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-01
- Publication Date
- 2024-11-15
AI Technical Summary
In the existing robot posture imitation technology, the mapping between human posture to robot posture has problems with low natural fluency and accuracy, resulting in discontinuous robot imitation movements.
By building the same three-dimensional coordinate system in the human body and the robot, identifying the key points and bone information of the human body, calculating the spatial angle information between the key points, and adjusting the robot's posture based on this information until all key points determine their spatial position.
It improves the natural fluency and accuracy of the robot's movements, allowing the robot to imitate human body movements more realistically.
Smart Images

Figure CN118952168A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of robotics technology, and in particular to a posture deformation method and system for mapping a human posture to a robot posture. Background Art
[0002] The robot posture imitation function is an important application in robotics technology, which enables robots to perform similar tasks by observing and learning human movements. This technology has broad application potential in many fields. For example, robots can imitate the movements of teachers or coaches, provide standard movement demonstrations, and help learners master the correct posture and skills; in rehabilitation medicine, robots can imitate the guidance of doctors or physical therapists to help patients with recovery training. In industry and services: In industrial automation and service industries, robots can imitate the movements of workers for precise operations and task execution. In rescue and search: In emergency rescue and disaster search, robots can imitate the movements of rescuers and perform high-risk rescue tasks, etc.
[0003] Existing robot posture imitation technology mainly relies on image recognition and posture classification methods. Specifically, the robot recognizes the human posture through the image captured by the camera, and then executes the corresponding control instructions according to the pre-set posture category. Existing technology usually discretizes the continuous human posture space, which limits the natural fluency and accuracy of the robot's imitation action. Summary of the invention
[0004] Based on this, in order to solve the above technical problems, a posture deformation method and system for mapping human posture to robot posture are provided to solve the problems of low natural fluency and accuracy of robot imitation movements in the prior art.
[0005] In a first aspect, a posture deformation method for mapping a human posture to a robot posture, the method comprising:
[0006] Step S1: acquiring a human posture image, identifying human key points in the human posture image, and constructing a three-dimensional human coordinate system in the human posture image according to the human key points according to a set rule; the set rule is that the right hip is taken as the origin, the line connecting the two hips is taken as the y-axis, and the positive direction of the y-axis is toward the left side of the human posture image; the z-axis is taken as the z-axis perpendicular to the horizontal plane, and the positive direction of the z-axis is toward the top of the human posture image; the x-axis is perpendicular to the yz plane and faces forward;
[0007] Step S2: construct a coordinate system in the robot according to the same setting rules;
[0008] Step S3: identifying human skeleton information through the human posture image; and obtaining spatial angle information between key points of the human body according to the human skeleton information;
[0009] Step S4: Select key points of the robot with determined spatial positions and key points of the undetermined spatial positions, obtain key points of the parts corresponding to the key points of the robot with determined spatial positions in the human posture image, record them as first key points, obtain key points of the parts corresponding to the key points of the undetermined spatial positions in the robot in the human posture image, record them as second key points; take the key points of the robot with determined spatial positions as vector starting points, and determine the spatial positions of the key points of the undetermined spatial positions of the robot according to the spatial angle information of the first key point relative to the second key point in the human posture image, and the lengths of the key points of the robot with determined spatial positions and the key points of the undetermined spatial positions;
[0010] Step S5: Repeat step S4 until all key points in the robot are positioned in space;
[0011] Step S6: adjusting the robot posture according to the spatial position of the key point;
[0012] Step S7: Repeat steps S1-S6.
[0013] In the above scheme, optionally, the key points include: left hip, left shoulder, left elbow, left hand, left knee, left foot, right hip, right shoulder, right elbow, right hand, right knee, and right foot.
[0014] In the above scheme, further optionally, step S4 includes: taking the left hip of the robot as the vector starting point, determining the spatial position of the left shoulder of the robot according to the spatial angle information of the left shoulder relative to the left hip in the human posture image and the lengths of the left shoulder and the left hip of the robot;
[0015] According to the robot's left shoulder as the vector starting point, the spatial position of the robot's left elbow is determined according to the spatial angle information of the left elbow relative to the left shoulder in the human posture image and the length of the robot's left elbow and left shoulder;
[0016] According to the robot's left elbow as the vector starting point, the spatial position of the robot's left hand is determined according to the spatial angle information of the left hand relative to the left elbow in the posture image and the length between the robot's left hand and the left elbow;
[0017] According to the left hip of the robot as the vector starting point, the spatial position of the left knee of the robot is determined according to the spatial angle information of the left knee relative to the left hip in the posture image and the length between the left knee and the left hip of the robot;
[0018] The left knee of the robot is taken as the vector starting point, the spatial position of the robot's left foot is determined according to the spatial angle information of the left foot relative to the left knee in the posture image and the length between the robot's left foot and the left knee.
[0019] In the above scheme, further optionally, step S4 further includes: taking the right hip of the robot as the vector starting point, determining the spatial position of the right shoulder of the robot according to the spatial angle information of the right shoulder relative to the right hip in the human posture image and the lengths of the right shoulder and the right hip of the robot;
[0020] The right shoulder of the robot is taken as the starting point of the vector, the spatial position of the right elbow of the robot is determined according to the spatial angle information of the right elbow relative to the right shoulder in the human posture image and the length of the right elbow and the right shoulder of the robot;
[0021] According to the right elbow of the robot as the starting point of the vector, the spatial position of the robot's right hand is determined according to the spatial angle information of the right hand relative to the right elbow in the posture image and the length between the right hand and the right elbow of the robot;
[0022] According to the right hip of the robot as the vector starting point, the spatial position of the right knee of the robot is determined according to the spatial angle information of the right knee relative to the right hip in the posture image and the length between the right knee and the right hip of the robot;
[0023] With the right knee of the robot as the vector starting point, the spatial position of the robot's right foot is determined according to the spatial angle information of the right foot relative to the right knee in the posture image and the length between the right foot and the right knee of the robot.
[0024] In a second aspect, a posture deformation system for mapping a human posture to a robot posture, the system comprising:
[0025] A human body coordinate system construction module is used to obtain a human body posture image, identify human body key points in the human body posture image, and construct a three-dimensional human body coordinate system in the human body posture image according to the human body key points according to the set rules; the set rules are as follows: the right hip is the origin, the line connecting the two hips is the y-axis, and the positive direction of the y-axis is toward the left side of the human body posture image; the z-axis is perpendicular to the horizontal plane and upward, and the positive direction of the z-axis is toward the top of the human body posture image; the x-axis is perpendicular to the yz plane and forward;
[0026] Robot coordinate system construction module: used to construct the coordinate system in the robot according to the same setting rules;
[0027] The module for acquiring spatial angle information between key points is used to identify human skeleton information through human posture images; and acquire spatial angle information between key points of the human body according to the human skeleton information;
[0028] Key point spatial position determination module: used to select key points of determined spatial positions and key points of undetermined spatial positions in the robot, obtain key points of the parts corresponding to the key points of the determined spatial positions in the robot in the human posture image, record them as first key points, obtain key points of the parts corresponding to the key points of the undetermined spatial positions in the robot in the human posture image, record them as second key points; use the key points of the determined spatial positions in the robot as vector starting points, determine the spatial positions of the key points of the undetermined spatial positions of the robot according to the spatial angle information of the first key point relative to the second key point in the human posture image, and the lengths of the key points of the determined spatial positions and the key points of the undetermined spatial positions in the robot;
[0029] Judgment module: used to repeat the key point spatial position determination module until the spatial positions of all key points have been determined;
[0030] Robot adjustment module: used to adjust the robot posture according to the spatial position of the key point.
[0031] In the above scheme, optionally, the key points include: left hip, left shoulder, left elbow, left hand, left knee, left foot, right hip, right shoulder, right elbow, right hand, right knee, and right foot.
[0032] In the above scheme, further optionally, the key point spatial position determination module is specifically used to determine the spatial position of the robot's left shoulder based on the spatial angle information of the left shoulder relative to the left hip in the human posture image and the length of the robot's left shoulder and left hip, taking the robot's left hip as the vector starting point;
[0033] According to the robot's left shoulder as the vector starting point, the spatial position of the robot's left elbow is determined according to the spatial angle information of the left elbow relative to the left shoulder in the human posture image and the length of the robot's left elbow and left shoulder;
[0034] According to the robot's left elbow as the vector starting point, the spatial position of the robot's left hand is determined according to the spatial angle information of the left hand relative to the left elbow in the posture image and the length between the robot's left hand and the left elbow;
[0035] According to the left hip of the robot as the vector starting point, the spatial position of the left knee of the robot is determined according to the spatial angle information of the left knee relative to the left hip in the posture image and the length between the left knee and the left hip of the robot;
[0036] The left knee of the robot is taken as the vector starting point, the spatial position of the robot's left foot is determined according to the spatial angle information of the left foot relative to the left knee in the posture image and the length between the robot's left foot and the left knee.
[0037] In the above scheme, further optionally, the key point spatial position determination module is specifically used to determine the spatial position of the robot's right shoulder based on the spatial angle information of the right shoulder relative to the right hip in the human posture image and the lengths of the robot's right shoulder and right hip, taking the robot's right hip as the vector starting point;
[0038] The right shoulder of the robot is taken as the starting point of the vector, the spatial position of the right elbow of the robot is determined according to the spatial angle information of the right elbow relative to the right shoulder in the human posture image and the length of the right elbow and the right shoulder of the robot;
[0039] According to the right elbow of the robot as the starting point of the vector, the spatial position of the robot's right hand is determined according to the spatial angle information of the right hand relative to the right elbow in the posture image and the length between the right hand and the right elbow of the robot;
[0040] According to the right hip of the robot as the vector starting point, the spatial position of the right knee of the robot is determined according to the spatial angle information of the right knee relative to the right hip in the posture image and the length between the right knee and the right hip of the robot;
[0041] With the right knee of the robot as the vector starting point, the spatial position of the robot's right foot is determined according to the spatial angle information of the right foot relative to the right knee in the posture image and the length between the right foot and the right knee of the robot.
[0042] In a third aspect, a computer device comprises a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the posture deformation method for mapping a human body posture to a robot posture described in the first aspect are implemented.
[0043] In a fourth aspect, a computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the posture deformation method for mapping a human body posture to a robot posture described in the first aspect are performed.
[0044] This application has at least the following beneficial effects:
[0045] The present application constructs a three-dimensional coordinate system according to the same rules based on key points in the robot and in the human posture image, thereby obtaining the spatial angle information between the key points of the human body in the human posture image, obtaining the key points of the human posture image corresponding to the key points of the robot with determined spatial positions and undetermined spatial positions, respectively recorded as the first key point and the second key point, and determining the spatial position of the key point of the robot with undetermined spatial position according to the spatial angle information of the first key point relative to the second key point in the human posture image and the length of the key points of the robot with determined spatial positions and undetermined spatial positions. In this way, the spatial coordinates of each end of the robot are determined from the posture, and the coordinates of each end of the robot are respectively obtained according to multiple human posture images during the human body movement, so that the robot's movements are continuous, and the natural fluency and accuracy of the robot's imitation movements are improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] Figure 1 A flowchart of a posture deformation method for mapping a human posture to a robot posture is provided in accordance with an embodiment of the present application. DETAILED DESCRIPTION
[0047] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0048] In one embodiment, Figure 1 As shown, a posture deformation method for mapping a human posture to a robot posture is provided, the method comprising:
[0049] Step S1: acquiring a human posture image, identifying human key points in the human posture image, and constructing a three-dimensional human coordinate system in the human posture image according to the human key points according to a set rule; the set rule is that the right hip is taken as the origin, the line connecting the two hips is taken as the y-axis, and the positive direction of the y-axis is toward the left side of the human posture image; the z-axis is taken as the z-axis perpendicular to the horizontal plane, and the positive direction of the z-axis is toward the top of the human posture image; the x-axis is perpendicular to the yz plane and faces forward;
[0050] Step S2: construct a coordinate system in the robot according to the same setting rules;
[0051] Step S3: identifying human skeleton information through the human posture image; and obtaining spatial angle information between key points of the human body according to the human skeleton information;
[0052] Step S4: Select key points of the robot with determined spatial positions and key points of the undetermined spatial positions, obtain key points of the parts corresponding to the key points of the robot with determined spatial positions in the human posture image, record them as first key points, obtain key points of the parts corresponding to the key points of the undetermined spatial positions in the robot in the human posture image, record them as second key points; take the key points of the robot with determined spatial positions as vector starting points, and determine the spatial positions of the key points of the undetermined spatial positions of the robot according to the spatial angle information of the first key point relative to the second key point in the human posture image, and the lengths of the key points of the robot with determined spatial positions and the key points of the undetermined spatial positions;
[0053] Step S5: Repeat step S4 until all key points in the robot are positioned in space;
[0054] Step S6: adjusting the robot posture according to the spatial position of the key point;
[0055] Step S7: Repeat steps S1-S6.
[0056] Specifically, when constructing the coordinate system, the ground where the human body stands is taken as the horizontal plane. When the human body is doing an action, the line connecting the two hips is always parallel to the horizontal plane, the y-axis is parallel to the line connecting the two hips to the left, the z-axis is perpendicular to the horizontal plane and upward, and the x-axis is perpendicular to the yz plane and forward. The robot coordinate system is established in the same way.
[0057] When obtaining the orientation (spatial angle information) of the limbs and shoulder joints, calculate the unit direction vectors of the left shoulder relative to the left hip, the left elbow relative to the left shoulder, the left hand relative to the left elbow, the left knee relative to the left hip, the left foot relative to the left knee, the right shoulder relative to the right hip, the right elbow relative to the right shoulder, the right hand relative to the right elbow, the right knee relative to the right hip, and the right foot relative to the right knee.
[0058] In the above-mentioned posture deformation method for mapping human posture to robot posture, a three-dimensional coordinate system is constructed according to the same rules based on key points in the robot and in the human posture image, thereby obtaining the spatial angle information between the key points of the human body in the human posture image, obtaining the key points of the human posture image corresponding to the key points of the robot with determined spatial positions and undetermined spatial positions, and recording them as the first key point and the second key point respectively, and determining the spatial position of the key point of the robot with undetermined spatial position according to the spatial angle information of the first key point relative to the second key point in the human posture image and the length of the key points of the robot with determined spatial positions and undetermined spatial positions. Thus, the spatial coordinates of each end of the robot are determined from the posture, and thus the coordinates of each end of the robot are respectively obtained according to multiple human posture images during the movement of the human body, so that the robot's movements are continuous, and the natural fluency and accuracy of the robot's imitation movements are improved.
[0059] In one embodiment, the key points include: left hip, left shoulder, left elbow, left hand, left knee, left foot, right hip, right shoulder, right elbow, right hand, right knee, and right foot.
[0060] In one embodiment, step S4 includes: taking the left hip of the robot as the vector starting point, determining the spatial position of the left shoulder of the robot according to the spatial angle information of the left shoulder relative to the left hip in the human posture image and the length of the left shoulder and the left hip of the robot;
[0061] According to the robot's left shoulder as the vector starting point, the spatial position of the robot's left elbow is determined according to the spatial angle information of the left elbow relative to the left shoulder in the human posture image and the length of the robot's left elbow and left shoulder;
[0062] According to the robot's left elbow as the vector starting point, the spatial position of the robot's left hand is determined according to the spatial angle information of the left hand relative to the left elbow in the posture image and the length between the robot's left hand and the left elbow;
[0063] According to the left hip of the robot as the vector starting point, the spatial position of the left knee of the robot is determined according to the spatial angle information of the left knee relative to the left hip in the posture image and the length between the left knee and the left hip of the robot;
[0064] The left knee of the robot is taken as the vector starting point, the spatial position of the robot's left foot is determined according to the spatial angle information of the left foot relative to the left knee in the posture image and the length between the robot's left foot and the left knee.
[0065] In this embodiment, the upper body is considered first. The spatial position of the left hip is determined. Therefore, the spatial position of the left shoulder is obtained based on the left hip, and the position of the left elbow is obtained using the left shoulder; the spatial position of the left hand is obtained using the left elbow of the robot. Then the lower body is considered, and the position of the left knee is obtained based on the left hip, and the position of the left foot is obtained based on the left knee.
[0066] In one embodiment, step S4 further includes: taking the right hip of the robot as the vector starting point, determining the spatial position of the right shoulder of the robot according to the spatial angle information of the right shoulder relative to the right hip in the human posture image and the lengths of the right shoulder and the right hip of the robot;
[0067] The right shoulder of the robot is taken as the starting point of the vector, the spatial position of the right elbow of the robot is determined according to the spatial angle information of the right elbow relative to the right shoulder in the human posture image and the length of the right elbow and the right shoulder of the robot;
[0068] According to the right elbow of the robot as the starting point of the vector, the spatial position of the robot's right hand is determined according to the spatial angle information of the right hand relative to the right elbow in the posture image and the length between the right hand and the right elbow of the robot;
[0069] According to the right hip of the robot as the vector starting point, the spatial position of the right knee of the robot is determined according to the spatial angle information of the right knee relative to the right hip in the posture image and the length between the right knee and the right hip of the robot;
[0070] With the right knee of the robot as the vector starting point, the spatial position of the robot's right foot is determined according to the spatial angle information of the right foot relative to the right knee in the posture image and the length between the right foot and the right knee of the robot.
[0071] In this embodiment, similarly, the upper body is considered first. The spatial position of the right hip is determined, so the spatial position of the right shoulder is first obtained based on the right hip, and then the position of the right elbow is obtained using the right shoulder; the spatial position of the right hand is obtained using the right elbow of the robot. Then the lower body is considered, and the position of the right knee is obtained based on the right hip, and the position of the right foot is obtained based on the right knee.
[0072] In one embodiment, a posture deformation system for mapping a human posture to a robot posture is provided, the system comprising:
[0073] A human body coordinate system construction module is used to obtain a human body posture image, identify human body key points in the human body posture image, and construct a three-dimensional human body coordinate system in the human body posture image according to the human body key points according to the set rules; the set rules are as follows: the right hip is the origin, the line connecting the two hips is the y-axis, and the positive direction of the y-axis is toward the left side of the human body posture image; the z-axis is perpendicular to the horizontal plane and upward, and the positive direction of the z-axis is toward the top of the human body posture image; the x-axis is perpendicular to the yz plane and forward;
[0074] Robot coordinate system construction module: used to construct the coordinate system in the robot according to the same setting rules;
[0075] The module for acquiring spatial angle information between key points is used to identify human skeleton information through human posture images; and acquire spatial angle information between key points of the human body according to the human skeleton information;
[0076] Key point spatial position determination module: used to select key points of determined spatial positions and key points of undetermined spatial positions in the robot, obtain key points of the parts corresponding to the key points of the determined spatial positions in the robot in the human posture image, record them as first key points, obtain key points of the parts corresponding to the key points of the undetermined spatial positions in the robot in the human posture image, record them as second key points; use the key points of the determined spatial positions in the robot as vector starting points, determine the spatial positions of the key points of the undetermined spatial positions of the robot according to the spatial angle information of the first key point relative to the second key point in the human posture image, and the lengths of the key points of the determined spatial positions and the key points of the undetermined spatial positions in the robot;
[0077] Judgment module: used to repeat the key point spatial position determination module until the spatial positions of all key points have been determined;
[0078] Robot adjustment module: used to adjust the robot posture according to the spatial position of the key point.
[0079] In one embodiment, the key point spatial position determination module is specifically used to determine the spatial position of the robot's left shoulder based on the spatial angle information of the left shoulder relative to the left hip in the human posture image and the length of the robot's left shoulder and left hip, taking the robot's left hip as the vector starting point;
[0080] According to the robot's left shoulder as the vector starting point, the spatial position of the robot's left elbow is determined according to the spatial angle information of the left elbow relative to the left shoulder in the human posture image and the length of the robot's left elbow and left shoulder;
[0081] According to the robot's left elbow as the vector starting point, the spatial position of the robot's left hand is determined according to the spatial angle information of the left hand relative to the left elbow in the posture image and the length between the robot's left hand and the left elbow;
[0082] According to the left hip of the robot as the vector starting point, the spatial position of the left knee of the robot is determined according to the spatial angle information of the left knee relative to the left hip in the posture image and the length between the left knee and the left hip of the robot;
[0083] The left knee of the robot is taken as the vector starting point, the spatial position of the robot's left foot is determined according to the spatial angle information of the left foot relative to the left knee in the posture image and the length between the robot's left foot and the left knee.
[0084] In one embodiment, the key point spatial position determination module is further used to determine the spatial position of the robot's right shoulder based on the spatial angle information of the right shoulder relative to the right hip in the human posture image and the lengths of the robot's right shoulder and right hip, taking the robot's right hip as the vector starting point;
[0085] The right shoulder of the robot is taken as the starting point of the vector, the spatial position of the right elbow of the robot is determined according to the spatial angle information of the right elbow relative to the right shoulder in the human posture image and the length of the right elbow and the right shoulder of the robot;
[0086] According to the right elbow of the robot as the starting point of the vector, the spatial position of the robot's right hand is determined according to the spatial angle information of the right hand relative to the right elbow in the posture image and the length between the right hand and the right elbow of the robot;
[0087] According to the right hip of the robot as the vector starting point, the spatial position of the right knee of the robot is determined according to the spatial angle information of the right knee relative to the right hip in the posture image and the length between the right knee and the right hip of the robot;
[0088] With the right knee of the robot as the vector starting point, the spatial position of the robot's right foot is determined according to the spatial angle information of the right foot relative to the right knee in the posture image and the length between the right foot and the right knee of the robot.
[0089] The specific definition of a posture deformation system for mapping a human posture to a robot posture can be found in the above definition of a posture deformation method for mapping a human posture to a robot posture, which will not be repeated here. Each module in the above-mentioned posture deformation system for mapping a human posture to a robot posture can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to the above-mentioned modules.
[0090] In one embodiment, a computer device is provided, which may be a server. The computer device includes a processor, a memory, and a network interface connected via a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, the posture deformation method of mapping a human posture to a robot posture is implemented.
[0091] In one embodiment, a computer program product is also provided, including a computer program / instruction, which involves all or part of the process in the above-mentioned embodiment method.
[0092] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0093] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0094] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A posture deformation method for mapping a human posture to a robot posture, characterized in that: The method comprises: Step S1: acquiring a human posture image, identifying human key points in the human posture image, and constructing a three-dimensional human coordinate system in the human posture image according to the human key points according to a set rule; the set rule is that the right hip is taken as the origin, the line connecting the two hips is taken as the y-axis, and the positive direction of the y-axis is toward the left side of the human posture image; the z-axis is taken as the z-axis perpendicular to the horizontal plane, and the positive direction of the z-axis is toward the top of the human posture image; the x-axis is perpendicular to the yz plane and faces forward; Step S2: construct a coordinate system in the robot according to the same setting rules; Step S3: identifying human skeleton information through the human posture image; and obtaining spatial angle information between key points of the human body according to the human skeleton information; Step S4: Select key points of the robot with determined spatial positions and key points of the undetermined spatial positions, obtain key points of the parts corresponding to the key points of the robot with determined spatial positions in the human posture image, record them as first key points, obtain key points of the parts corresponding to the key points of the undetermined spatial positions in the robot in the human posture image, record them as second key points; take the key points of the robot with determined spatial positions as vector starting points, and determine the spatial positions of the key points of the undetermined spatial positions of the robot according to the spatial angle information of the first key point relative to the second key point in the human posture image, and the lengths of the key points of the robot with determined spatial positions and the key points of the undetermined spatial positions; Step S5: Repeat step S4 until all key points in the robot are positioned in space; Step S6: adjusting the robot posture according to the spatial position of the key point; Step S7: Repeat steps S1-S6.
2. The posture deformation method for mapping human posture to robot posture according to claim 1, characterized in that: The key points include: left hip, left shoulder, left elbow, left hand, left knee, left foot, right hip, right shoulder, right elbow, right hand, right knee, and right foot.
3. The posture deformation method for mapping human posture to robot posture according to claim 2, characterized in that: The step S4 comprises: taking the left hip of the robot as the vector starting point, determining the spatial position of the left shoulder of the robot according to the spatial angle information of the left shoulder relative to the left hip in the human posture image and the length of the left shoulder and the left hip of the robot; According to the robot's left shoulder as the vector starting point, the spatial position of the robot's left elbow is determined according to the spatial angle information of the left elbow relative to the left shoulder in the human posture image and the length of the robot's left elbow and left shoulder; According to the robot's left elbow as the vector starting point, the spatial position of the robot's left hand is determined according to the spatial angle information of the left hand relative to the left elbow in the posture image and the length between the robot's left hand and the left elbow; According to the left hip of the robot as the vector starting point, the spatial position of the left knee of the robot is determined according to the spatial angle information of the left knee relative to the left hip in the posture image and the length between the left knee and the left hip of the robot; The left knee of the robot is taken as the vector starting point, the spatial position of the robot's left foot is determined according to the spatial angle information of the left foot relative to the left knee in the posture image and the length between the robot's left foot and the left knee.
4. The posture deformation method for mapping human posture to robot posture according to claim 3, characterized in that: The step S4 further comprises: taking the right hip of the robot as the vector starting point, determining the spatial position of the right shoulder of the robot according to the spatial angle information of the right shoulder relative to the right hip in the human posture image and the lengths of the right shoulder and the right hip of the robot; The right shoulder of the robot is taken as the starting point of the vector, the spatial position of the right elbow of the robot is determined according to the spatial angle information of the right elbow relative to the right shoulder in the human posture image and the length of the right elbow and the right shoulder of the robot; According to the right elbow of the robot as the starting point of the vector, the spatial position of the robot's right hand is determined according to the spatial angle information of the right hand relative to the right elbow in the posture image and the length between the robot's right hand and the right elbow; The right hip of the robot is taken as the vector starting point, the spatial position of the right knee of the robot is determined according to the spatial angle information of the right knee relative to the right hip in the posture image and the length between the right knee and the right hip of the robot; The right knee of the robot is taken as the vector starting point, the spatial position of the right foot of the robot is determined according to the spatial angle information of the right foot relative to the right knee in the posture image and the length between the right foot and the right knee of the robot.
5. A posture deformation system for mapping human posture to robot posture, characterized in that: The system comprises: A human body coordinate system construction module is used to obtain a human body posture image, identify human body key points in the human body posture image, and construct a three-dimensional human body coordinate system in the human body posture image according to the human body key points according to the set rules; the set rules are as follows: the right hip is the origin, the line connecting the two hips is the y-axis, and the positive direction of the y-axis is toward the left side of the human body posture image; the z-axis is perpendicular to the horizontal plane and upward, and the positive direction of the z-axis is toward the top of the human body posture image; the x-axis is perpendicular to the yz plane and forward; Robot coordinate system construction module: used to construct the coordinate system in the robot according to the same setting rules; The module for acquiring spatial angle information between key points is used to identify human skeleton information through human posture images; and acquire spatial angle information between key points of the human body according to the human skeleton information; Key point spatial position determination module: used to select key points of determined spatial positions and key points of undetermined spatial positions in the robot, obtain key points of the parts corresponding to the key points of the determined spatial positions in the robot in the human posture image, record them as first key points, obtain key points of the parts corresponding to the key points of the undetermined spatial positions in the robot in the human posture image, record them as second key points; use the key points of the determined spatial positions in the robot as vector starting points, determine the spatial positions of the key points of the undetermined spatial positions of the robot according to the spatial angle information of the first key point relative to the second key point in the human posture image, and the lengths of the key points of the determined spatial positions and the key points of the undetermined spatial positions in the robot; Judgment module: used to repeat the key point spatial position determination module until the spatial positions of all key points have been determined; Robot adjustment module: used to adjust the robot posture according to the spatial position of the key point.
6. The posture deformation system for mapping human posture to robot posture according to claim 5, characterized in that: The key points include: left hip, left shoulder, left elbow, left hand, left knee, left foot, right hip, right shoulder, right elbow, right hand, right knee, and right foot.
7. The posture deformation system for mapping human posture to robot posture according to claim 5, characterized in that: The key point spatial position determination module is specifically used to determine the spatial position of the robot's left shoulder based on the spatial angle information of the left shoulder relative to the left hip in the human posture image and the lengths of the robot's left shoulder and left hip, taking the robot's left hip as the vector starting point; According to the robot's left shoulder as the vector starting point, the spatial position of the robot's left elbow is determined according to the spatial angle information of the left elbow relative to the left shoulder in the human posture image and the length of the robot's left elbow and left shoulder; According to the robot's left elbow as the vector starting point, the spatial position of the robot's left hand is determined according to the spatial angle information of the left hand relative to the left elbow in the posture image and the length between the robot's left hand and the left elbow; According to the left hip of the robot as the vector starting point, the spatial position of the left knee of the robot is determined according to the spatial angle information of the left knee relative to the left hip in the posture image and the length between the left knee and the left hip of the robot; The left knee of the robot is taken as the vector starting point, the spatial position of the robot's left foot is determined according to the spatial angle information of the left foot relative to the left knee in the posture image and the length between the robot's left foot and the left knee.
8. The posture deformation system for mapping human posture to robot posture according to claim 5, characterized in that: The key point spatial position determination module is also specifically used to determine the spatial position of the robot's right shoulder based on the spatial angle information of the right shoulder relative to the right hip in the human posture image and the lengths of the robot's right shoulder and right hip, taking the robot's right hip as the vector starting point; The right shoulder of the robot is taken as the starting point of the vector, the spatial position of the right elbow of the robot is determined according to the spatial angle information of the right elbow relative to the right shoulder in the human posture image and the length of the right elbow and the right shoulder of the robot; According to the right elbow of the robot as the starting point of the vector, the spatial position of the robot's right hand is determined according to the spatial angle information of the right hand relative to the right elbow in the posture image and the length between the robot's right hand and the right elbow; The right hip of the robot is taken as the vector starting point, the spatial position of the right knee of the robot is determined according to the spatial angle information of the right knee relative to the right hip in the posture image and the length between the right knee and the right hip of the robot; The right knee of the robot is taken as the vector starting point, the spatial position of the right foot of the robot is determined according to the spatial angle information of the right foot relative to the right knee in the posture image and the length between the right foot and the right knee of the robot.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 4 are implemented.
10. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.
