hongsukchoi / 3DCrowdNet_RELEASE

Official Pytorch implementation of "Learning to Estimate Robust 3D Human Mesh from In-the-Wild Crowded Scenes", CVPR 2022
MIT License
155 stars 15 forks source link

Question about calculation of smpl_trans in Human36M #26

Closed YxZhxn closed 1 year ago

YxZhxn commented 1 year ago

Hi! Firstly, thanks for your excellent work! I was learning your data processing procedure and had confusions about the following code: https://github.com/hongsukchoi/3DCrowdNet_RELEASE/blob/fde86df0fb8799873cd19c683b8251b16640acb3/data/Human36M/Human36M.py#L216 Could you kindly explain to me that what the physical meaning of 'smpl_trans - root_joint_coord + np.dot(R, root_joint_coord.transpose(1,0)).transpose(1,0)' is? As far as i understand that 'smpl_trans - root_joint_coord' represents the translation in the coordinate system that takes root joint as origin. My question is how to explain np.dot(R, root_joint_coord.transpose(1,0)).transpose(1,0)?

hongsukchoi commented 1 year ago

Hi!

The get_smpl_coord function is transforming the mesh in the world coordinate system (frame) to the camera coordinate system. Line 191 and line 216 are performing that. Line 191 is rotating the mesh around the root_joint_coord (pelvis) without any translation change. Line 216 is adding the appropriate translation.

See the equation I wrote below.

IMG_7907

YxZhxn commented 1 year ago

I see. Thanks for your quick response!