1

I am trying to use the OSD dataset link: http://www.acin.tuwien.ac.at/forschung/v4r/software-tools/osd/ which uses kinect v1 for generating the Depth map images. I have read that the values should range from 0-2048 in the depth map images and the unit for these values are in mm. However, when i try using the depth map images from the dataset mentioned above, i get values more than 2048 (I get in the region of 0-5200, i am using opencv for reading these images)

original_image

enter image description here

Depth Image

enter image description here

minimum disparity value: 0

maximum disparity value: 3475

code that i have used to normlized this image so that i can see some meaningful gray depth image

img_depth = cv2.imread("depth_map.png",-1)
depth_array = np.array(img_depth, dtype=np.float32)
frame = cv2.normalize(depth_array, depth_array, 0, 1, cv2.NORM_MINMAX)
cv2.imwrite('capture_depth.png',frame*255)

Result after normalization enter image description here

I have a set of questions:

  • Why do we have values above 2048?

  • Why do we have a black region at the sides of the image (My guess was that the RGB camera and the laser sensor are at different angle so this translation was required so that are mapped properly, however, i am not sure as i have tried with different RGBD datasets and these black regions at the edges occurs differently)

  • What are the best ways to fill these black holes in the center of the image? (My understanding with these black holes is that they occur due to depth been not measured at those points)

  • I wanted to generate stereo pairs using RGB and depth image, how best i can do it?(currently i am using Triaxes StereoTracer for generating stereo images)

kkk
  • 1,850
  • 1
  • 25
  • 45
  • 1
    where did you read that max value von kinect depth map should be 2048? Be aware that there is a difference between disparity values and depth values! – Micka Aug 01 '17 at 10:41
  • @Micka I have read in stackoverflow and other web sources, they say that 11 bits are used for the values and hence 2048. – kkk Aug 01 '17 at 12:52
  • 1
    This is what I have found: `For the kinect v1, the raw depth values range between 0 and 2048, for the kinect v2 the range is between 0 and 4500.` http://shiffman.net/p5/kinect/ BUT it also says that the raw-depth values have to be transformed to get Depth-In-Meters, which opencv probably does internally: `The raw depth values from the kinect are not directly proportional to physical depth. Rather, they scale with the inverse of the depth according to this formula: depthInMeters = 1.0 / (rawDepth * -0.0030711016 + 3.3309495161);` so probably openCV already provides depth in millimeters or sth. – Micka Aug 01 '17 at 12:57

0 Answers0