dataset-api icon indicating copy to clipboard operation
dataset-api copied to clipboard

Caculate depth from disparity map

Open Huyhust13 opened this issue 6 years ago • 11 comments

As I know, we can calculate depth from disparity follow: depth = baseline * focal / disparity. I'm using stereo_train_01.zip (4.4GB) to calculate depth map from disparity. I can find focal from intrinsic.txt but cannot find baseline of camera. Can you guides help me:

  • Where can i find baseline parameter of stereo camera? or
  • How to calculate depth from disparity map using Apoloscapes Dataset? Many thanks!

Huyhust13 avatar Jul 18 '19 10:07 Huyhust13

As I know, we can calculate depth from disparity follow: depth = baseline * focal / disparity. I'm using stereo_train_01.zip (4.4GB) to calculate depth map from disparity. I can find focal from intrinsic.txt but cannot find baseline of camera. Can you guides help me:

  • Where can i find baseline parameter of stereo camera? or
  • How to calculate depth from disparity map using Apoloscapes Dataset? Many thanks!

Hi, I have the same problem with you. Do you find the baseline parameter? Many thanks in advance for your reply!

NovaMind-Z avatar Oct 16 '19 12:10 NovaMind-Z

As I know, we can calculate depth from disparity follow: depth = baseline * focal / disparity. I'm using stereo_train_01.zip (4.4GB) to calculate depth map from disparity. I can find focal from intrinsic.txt but cannot find baseline of camera. Can you guides help me:

  • Where can i find baseline parameter of stereo camera? or
  • How to calculate depth from disparity map using Apoloscapes Dataset? Many thanks!

Hi, I have the same problem with you. Do you find the baseline parameter? Many thanks in advance for your reply!

focal = 2301.3147 (pixel) But now i can't find document that mentioned it. I will find later

Huyhust13 avatar Oct 17 '19 05:10 Huyhust13

Hi, Many thanks for your reply! I also try to ask the writer of the paper published on CVPR. Yet I receive no feedback. Let's keep in contact!

NovaMind-Z avatar Oct 17 '19 05:10 NovaMind-Z

As I know, we can calculate depth from disparity follow: depth = baseline * focal / disparity. I'm using stereo_train_01.zip (4.4GB) to calculate depth map from disparity. I can find focal from intrinsic.txt but cannot find baseline of camera. Can you guides help me:

  • Where can i find baseline parameter of stereo camera? or
  • How to calculate depth from disparity map using Apoloscapes Dataset? Many thanks!

Hi, I have the same problem with you. Do you find the baseline parameter? Many thanks in advance for your reply!

focal = 2301.3147 (pixel) But now i can't find document that mentioned it. I will find later

Hi, It seems that I have found it in their Chinese operation manual (url: http://data.apollo.auto/static/pdf/lidar_obstacle_label.pdf ). According to values on the picture, the baseline should be 0.36m

image

NovaMind-Z avatar Oct 17 '19 05:10 NovaMind-Z

oh, so sorry, i have a mistake.

On Thu, Oct 17, 2019 at 12:53 PM Zhu-Jinkuan [email protected] wrote:

As I know, we can calculate depth from disparity follow: depth = baseline

  • focal / disparity. I'm using stereo_train_01.zip (4.4GB) to calculate depth map from disparity. I can find focal from intrinsic.txt but cannot find baseline of camera. Can you guides help me:

    • Where can i find baseline parameter of stereo camera? or
    • How to calculate depth from disparity map using Apoloscapes Dataset? Many thanks!

Hi, I have the same problem with you. Do you find the baseline parameter? Many thanks in advance for your reply!

focal = 2301.3147 (pixel) But now i can't find document that mentioned it. I will find later

Hi, It seems that I have found it in their Chinese operation manual (url: http://data.apollo.auto/static/pdf/lidar_obstacle_label.pdf ). According to values on the picture, the baseline should be 0.36m

[image: image] https://user-images.githubusercontent.com/42997811/66981131-76a1c100-f0e5-11e9-8cb0-9e46c82f910d.png

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ApolloScapeAuto/dataset-api/issues/25?email_source=notifications&email_token=AIFPE4PETDDYITF3TGATFHDQO74VFA5CNFSM4IEZPLRKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBO4CKA#issuecomment-543015208, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFPE4JNJ2OHCPFZWMDSJ2LQO74VFANCNFSM4IEZPLRA .

-- Nguyen Van Huy T: (+84) 972 973 146 (zalo) | Skype: [email protected] | M: [email protected] Mechatronics Engineer

Huyhust13 avatar Oct 17 '19 06:10 Huyhust13

As I know, we can calculate depth from disparity follow: depth = baseline * focal / disparity. I'm using stereo_train_01.zip (4.4GB) to calculate depth map from disparity. I can find focal from intrinsic.txt but cannot find baseline of camera. Can you guides help me:

  • Where can i find baseline parameter of stereo camera? or
  • How to calculate depth from disparity map using Apoloscapes Dataset? Many thanks!

Hi, I have the same problem with you. Do you find the baseline parameter? Many thanks in advance for your reply!

focal = 2301.3147 (pixel) But now i can't find document that mentioned it. I will find later

Hi, It seems that I have found it in their Chinese operation manual (url: http://data.apollo.auto/static/pdf/lidar_obstacle_label.pdf ). According to values on the picture, the baseline should be 0.36m

image

I am afraid it's not correct. The vehicle used in Apollo dataset paper is a Toyata SUV, but your image looks like a sedan. I won't use this dataset anymore.

Underquant avatar Nov 16 '20 05:11 Underquant

Does anyone know what the baseline is now?

dontLoveBugs avatar Mar 23 '21 13:03 dontLoveBugs

@dontLoveBugs It seems that 0.36m is the correct metric baseline.

CaptainEven avatar Apr 15 '21 03:04 CaptainEven

Hi. Please check my method to calculate the baseline for Apolloscape dataset:

  • I got the Extrinsic parameters of the two cameras from the pose.txt files in road02_ins.
  • Then, the baseline is the distance between these two cameras.
  • I calculated the distances as normal distances formula for all pairs and got the average result of the baseline around 0.622m.

Apolloscape_baseline

tungngovn avatar Jan 05 '22 02:01 tungngovn

Guys, does anyone know how to convert disparity to metric depth? I first use disp = disp / 200 as the readme.txt says the disparity value is 200 times larger than groundtruth, then I use depth = 0.622 * 2301.3147 / (disp + 1e-8) to get depth, but the results seem incorrect, because I found that the minimum depth value is over 2000. Is it because the focal length or disparity is formatted at the pixel level and not at the metric (meter) level?

whyygug avatar May 21 '23 13:05 whyygug

Guys, does anyone know how to convert disparity to metric depth? I first use disp = disp / 200 as the readme.txt says the disparity value is 200 times larger than groundtruth, then I use depth = 0.622 * 2301.3147 / (disp + 1e-8) to get depth, but the results seem incorrect, because I found that the minimum depth value is over 2000. Is it because the focal length or disparity is formatted at the pixel level and not at the metric (meter) level?

Hi, did you ever resolve this issue?

tony-chew avatar Dec 01 '23 13:12 tony-chew