lixiny / manotorch

MANO in pyTORCH (anatomical constraints, anchors, etc)
GNU General Public License v3.0
166 stars 11 forks source link

definition of shape and pose parameter #4

Closed Pyf1234 closed 1 year ago

Pyf1234 commented 1 year ago

I'm trying to convert (rotation angles,size of the rigid body) to mano-hand mesh using the mano-layer you provided. But my definition of hand asset is in mujoco (.xml) format and definition of rotation is in (rotation angles of the joints around local x,y,z axis) So in order to apply the model you provided to my data,I need to figure out the exact definition of shape and pose parameter of manolayer. image Could you please provide me with the exact definition or provide me with some material related to it. Thanks a lot!

lixiny commented 1 year ago

Hi, if you already have the euler angles of each joints/articulation on the hand, you can follow the joint orders described in compose to customize your hand pose.

demo example here

In order to dive deep of the shape and pose parameter defined in original MANO, you can visit paper: Embodied Hands: Modeling and Capturing Hands and Bodies Together.

As for the demo code in your screenshot, it is just a bare demo of how the manolayer was called. We use the use_pca=True to use the low-dimensional 15 PCA pose components to control the total 15 joints (45 DoFs in MANO).

Best, Lixin

Pyf1234 commented 1 year ago

Thanks for your reply. By the way I have another question about this code . image The intermediate tensor close_face is not moved to "cuda",so I guess the manolayer module could not run on GPU if I don't manually modify the code?

lixiny commented 1 year ago

Correct,

This closed_faces is designed for drawing the hand without open hole at wrist. If you want use faces on GPU, I recommend you manually forward the close_faces to target device, or, use the MANO's default faces: th_faces, which is bound on GPU.

DakshDeepakTI commented 4 months ago

Hi, I found this thread somewhat helpful, thank you. However, I'm encountering an issue with my approach. I'm utilizing 21 keypoints (x, y, z) to construct vectors and calculating angles across different axes by projecting onto the XY, YZ, and ZX planes. Then, I use the compose function to generate a mesh using MANO, but the mesh output closely matches only a few datasets from MANO. Currently, I'm only employing the pose parameter for this purpose and not the shape parameters. Just want to check is this approach right?