Skip to content
New issue

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

Low performance on Monodepth2 generated depth maps #16

Closed
amajee11us opened this issue Apr 4, 2020 · 1 comment
Closed

Low performance on Monodepth2 generated depth maps #16

amajee11us opened this issue Apr 4, 2020 · 1 comment

Comments

@amajee11us
Copy link

Hi, I am trying to use your work with depth maps generated from monodepth2 depth estimation network.

I tried using one of your kitti samples to test the pipeline, with depth configuration as :
conf.depth_mean = [107.0805491, 68.26778312, 133.50751215] conf.depth_std = [38.65614623, 73.59464917, 88.24401221]

Even then, the max score that i get is less than 30 percent.
Depth map and image uploaded for reference.
Is there any configurations I need to change in the monodepth code itself to get this working?

Model used for testing is the pretrained model provided in the repo.
My monodepth post processing code is:
_, scaled_depth = disp_to_depth(disp, 0.1, 100)
depth_resized = torch.nn.functional.interpolate(scaled_depth, (original_height, original_width), mode="bilinear", align_corners=False)
depth_resized_np = depth_resized.squeeze().cpu().numpy()
normalizer_depth = mpl.colors.Normalize(vmin=depth_resized_np.min())
mapper_depth = cm.ScalarMappable(norm=normalizer_depth, cmap='gray')
colormapped_im_depth = (mapper_depth.to_rgba(depth_resized_np)[:, :, :3] * 255).astype(np.uint8)
im_depth = pil.fromarray(colormapped_im_depth)

Depth Map:
000005

Image:
000005_image

Output is :(
Car -1 -1 -0.420610 690.218506 147.377106 1291.588501 441.522003 1.693756 1.490031 3.745631 2.358071 1.346878 1.293291 0.648531 0.281668
Car -1 -1 -0.314688 271.298126 136.579041 803.299255 431.537445 1.713774 1.436281 3.459033 1.215498 1.356887 1.107118 0.517339 0.234700

@dingmyu
Copy link
Owner

dingmyu commented Apr 28, 2020

Hi, do you just inference with monodepth2 depth maps? You should retrain the model with depth maps generated by monodepth2.

@dingmyu dingmyu closed this as completed Apr 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants