-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix camera conversion between opencv and pytorch3d
Summary: For non square image, the NDC space in pytorch3d is not square [-1, 1]. Instead, it is [-1, 1] for the smallest side, and [-u, u] for the largest side, where u > 1. This behavior is followed by the pytorch3d renderer. See the function `get_ndc_to_screen_transform` for a example. Without this fix, the rendering result is not correct using the converted pytorch3d-camera from a opencv-camera on non square images. This fix also helps the `transform_points_screen` function delivers consistent results with opencv projection for the converted pytorch3d-camera. Reviewed By: classner Differential Revision: D31366775 fbshipit-source-id: 8858ae7b5cf5c0a4af5a2af40a1358b2fe4cf74b
- Loading branch information
1 parent
815a93c
commit 8fa438c
Showing
2 changed files
with
24 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8fa438c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi,
Did this commit make it into the latest release (v0.6.0)?
8fa438c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No.
8fa438c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The version number change is the last commit in each release.