Skip to content

about camera extrinsic #244

@duruing

Description

@duruing

Hi! I'm reading your code recently and I'm confused why don't you reverse the y-axis and z-axis here when converting extrinsic from opencv coordinate system to open3d coordinate system

extrinsic=np.asarray((viewpoint_cam.world_view_transform.T).cpu().numpy())
camera = o3d.camera.PinholeCameraParameters()
camera.extrinsic = extrinsic

I notice that you implement this in estimate_bounding_sphere function

def estimate_bounding_sphere(self):
"""
Estimate the bounding sphere given camera pose
"""
from utils.render_utils import transform_poses_pca, focus_point_fn
torch.cuda.empty_cache()
c2ws = np.array([np.linalg.inv(np.asarray((cam.world_view_transform.T).cpu().numpy())) for cam in self.viewpoint_stack])
poses = c2ws[:,:3,:] @ np.diag([1, -1, -1, 1])

I'm confused about the difference. Could you help explain? Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions