Depth Data Visualization
Left: Depth from NYU Database with inserted 3D face from Dissertation. Right: Colorized Depth Visualization

Depth Data Visualization

Depth images are beautiful but also problematic. Visualization is key to seeing what is in the scene, and certain methods can make the process faster. If you can try your eyes to understand depth images with extra information, failure analysis could be done more efficiently. This data is from the NYU Depth V1 Dataset (Silberman, N., Fergus, R.: Indoor scene segmentation using a structured light sensor. In: ICCV Workshop on 3D Representation and Recognition. (2011) 

Left: RGB Gray , Right: Depth Image

I inserted a more complex 3D object, which is a face from my dissertation work. The quality of the depth of the face is quite bad (can't recognize the person), but it still is useful to show how the complexity of that depth image could be shown as well with a depth image with a large variance of depth measurements. In this case, the gray representation of depth shows the face as a flat object.

Left: RGB , Right: Gray Depth Image with highlighted low quality 3D face

Let's go to Jet because the blue to red color scheme makes some of the data easier to see

Left: Gray Depth , Right: Jet colormap (courtesy to Matlab)

Let's take a look at shifting the different pieces of information. It looks like the data in the back is unreliable because it it showing the data is close up, but in the RGB image, we know the depth is far away. A bit more detail can be seen on the chairs and the face.

Left: Focus on the foreground , Right: Focus on the background

How about an HSV color mapping instead of Jet, just to see.

Left: Jet colormap , Right:HSV colormap

Why not use the same colormap for multiple depth boxes? This can be done by using a mod colormap. Color mod is done in the lines below. It causes the colormap to be used multiple times in the N interval of points. This allows more depth information to be shown in the same image.

N = 30000; %Max is uint16 (65,535)

depthMod = mod(depth,N)/N;

Left: Jet , Right: Mod Jet

The main issue with this is that at the transition points, the color jumps from blue to red, which is not appealing to the eye. If we modify the colormap to go from blue to red to blue (Jet+), that problem is solved (below):

Left: Mod Jet , Right: Mod Jet+

Let's change N form 30,000 to 20,000 for a little more clarity:

Left: Mod Jet+ at N=30,000 , Right: Mod Jet+ N=20,000

Still, there are some background pixels that aren't helpful. These are either too close (<1500 in this case) or too far away (== 65,535). If we set these to black, it gives it another view:

Left: Mod Jet+ at N=20,000 , Right: Mod Jet+ N=20,000 dropped useless pixels

We can even scale the colors by the original depth to help make a different between two things that are the same color but different depths.

N1=0.2; Scaled = JetImage.*((original.^N1));

Left: Mod Jet+ at N=20,000 dropped useless pixels , Right: Mod Jet+ N=20,000 dropped useless pixels Scaled

This brings out that added face artifact, and the scene is a little easier to interpret. Here is the final comparison before and after. I love Jet if it wasn't clear already.

Left: Original Gray , Right: Mod Jet+ N=20,000 dropped useless pixels Scaled


To view or add a comment, sign in

More articles by Dr. Robert McKeon Aloe

  • Ph.D. Interviews

    I have interviewed mostly Ph.D.

  • How to break into Data Science the easy way

    Scratch that; there’s not an easy way. Data science has become a hot topic the past few years along side machine…

    5 Comments
  • ML: Examining the Test Set

    I recently saw a post where someone said “Never touch your test set.” The theory was that you (as the algorithm…

    8 Comments
  • Privacy in Machine Learning: PII

    Privacy is not a value explicitly written into the US Constitution, but the essentials are there. As a democratic…

    1 Comment
  • Mastering LinkedIn

    Account Creation I never had a LinkedIn account until I was searching for a job, and then I only paid attention to it…

    1 Comment
  • Withdrawing a Conference Paper

    In graduate school, I tried all sorts of optimizations aimed at making my face matcher work better and faster. I found…

    1 Comment
  • Thoughts on Leaving

    Relax, I’m not leaving my current job right now. I’ve been writing about many different aspects of my work experience…

  • Crashing the Student Computer Lab

    In my last year of graduate school at Notre Dame, I used over 1,000,000 computer hours or just over 114 years of…

    3 Comments
  • Presentation Essentials

    I have fallen asleep in my fair share of presentations, and I’ve worked hard at making sure my presentations are not…

  • Design of Experiment: Data Collection

    Anyone can collect data; some people can collect good data. The key theme to any good data collection is data…

Others also viewed

Explore content categories