facebookresearch / ContactPose

Large dataset of hand-object contact, hand- and object-pose, and 2.9 M RGB-D grasp images.
http://contactpose.cc.gatech.edu/
MIT License
338 stars 33 forks source link

projecting 3D points to images #13

Closed samarth-robo closed 2 years ago

samarth-robo commented 2 years ago

[from an email query]

Basically, I am trying to project the 3D vertices of objects on to provided 2D images. I use the following transformations: ​ projected2d_verts = (cam_intrinsics @ (cp.obj_poses[:3, :3] @ obj3d_verts.T) + cp.obj_poses[:3, 3].reshape(3,1))

But I am getting below(wrong) projection(object projection is at the top left which should have been overlapping the mug in the hand) ​ wrong_projection ​ I am not able to find what's wrong here. Would you have any suggestions to rectify this? ​ Thanks a lot in Advance for your time on this issue.

samarth-robo commented 2 years ago

Please use the project() function from utilities/misc.py.

An example is shown in the Utilities section of the demo iPython notebook.

anilesec commented 2 years ago

Thank you!