manydepth
manydepth copied to clipboard
About cityscapes disparity to depth_gt
Hello, you mentioned in your README "We provide ground truth depth files HERE, which were converted from pixel disparities using intrinsics and the known baseline. Download this and unzip into splits/cityscapes.", how do you deal with the original disparity data and generate the .npy, I'm having some issues trying. If so, is it possible to make the code public?
like this
To convert a disparity map to a depth map you need the focal length in pixels (call this f
, taken as the top left element of the intrinsics matrix, i.e. fx
) and the baseline between the 2 stereo cameras (call this b
).
Given these you can obtain depth via depth = f * b / disparity
Hope this helps!