We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hey @mks0601, hope you doing well.
I actually came across your issue regarding the smpl body projection to image #classner/up#17 (comment)
I used the following projection function but unsure if the points are correct.
def perspective_projection_custom(points, rotation, translation, focal_length, camera_center): """ This function computes the perspective projection of a set of points. Input: points (bs, N, 3): 3D points rotation (bs, 3, 3): Camera rotation translation (bs, 3): Camera translation focal_length (bs,) or scalar: Focal length camera_center (bs, 2): Camera center """ batch_size = points.shape[0] K = torch.zeros([batch_size, 3, 3], device=points.device) K[:, 0, 0] = focal_length K[:, 1, 1] = focal_length K[:, 2, 2] = 1.0 K[:, :-1, -1] = camera_center # Transform points points = torch.einsum("bij,bkj->bki", rotation, points) points = points + translation.unsqueeze(1) # Apply perspective distortion projected_points = points / points[:, :, -1].unsqueeze(-1) # Apply camera intrinsics projected_points = torch.einsum("bij,bkj->bki", K, projected_points) return projected_points[:, :, :-1]
Can you share the check the function once or maybe share your sample code which you used for smpl body projection to image If possible?
I need to convert the smpl points into several other format for a custom dataset, so this conversion and projection is crucial for me.
I hope you can help out. Thank you once again.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hey @mks0601, hope you doing well.
I actually came across your issue regarding the smpl body projection to image #classner/up#17 (comment)
I used the following projection function but unsure if the points are correct.
Can you share the check the function once or maybe share your sample code which you used for smpl body projection to image If possible?
I need to convert the smpl points into several other format for a custom dataset, so this conversion and projection is crucial for me.
I hope you can help out. Thank you once again.
The text was updated successfully, but these errors were encountered: