facebookresearch / co3d

Tooling for the Common Objects In 3D dataset.
Other
963 stars 75 forks source link

CO3D Depth Unit #76

Closed TropicalPenguinn closed 1 year ago

TropicalPenguinn commented 1 year ago

hello I am using your wonderful dataset for Bundle Adjustment Experiment.

This is the part of my code to make point cloud from Pytorch 3D and I used CO3D dataset.

sequence_dataset = torch.utils.data.Subset(dataset, sequence_entries)
# load the required part of the dataset
loader = torch.utils.data.DataLoader(
    sequence_dataset,
    batch_size=1,
    shuffle=False,
    num_workers=10,
    collate_fn=dataset.frame_data_type.collate,
)

image_path=[]
depth_path=[]
R_T_lst=[]
K_lst=[]
for frame_data in loader:
    image_path.append(frame_data.image_path[0])
    depth_path.append(frame_data.depth_path[0])
    R,T,K=opencv_from_cameras_projection(frame_data.camera, frame_data.image_size_hw)
    point_cloud=get_rgbd_point_cloud(frame_data.camera,frame_data.image_rgb,frame_data.depth_map)

After I make Point cloud I measure the mean value of Z (the depth) But I got 4 or 5 so on. Is that real depth distance (m?) If the depth is not correct, I can't use your dataset for research.

davnov134 commented 1 year ago

Hi. The depth maps are outputs of SfM reconstruction and, as such, cannot be in metric units ( meters). Regardless they are perfectly correct but not in human units.