A Low Memory Footprint Quantized Neural Network for Depth Completion of Very Sparse Time-of-Flight Depth Maps

Xiaowen Jiang, Valerio Cambareri, Gianluca Agresti, Cynthia Ifeyinwa Ugwu, Adriano Simonetto, Fabien Cardinaux, Pietro Zanuttigh

TL;DR

This paper introduces a highly efficient, quantized encoder-decoder convolutional neural network (CNN) designed for depth completion using extremely sparse Time-of-Flight (ToF) data and a single RGB image. By leveraging mixed-precision quantization-aware training (QAT) and a geometry-preserving loss function, the authors achieve up to a 14-fold reduction in weight memory size with negligible loss in depth accuracy, making high-quality 3D perception viable for low-power mobile devices.

What Problem Does This Paper Address?

Active Time-of-Flight (ToF) sensors are increasingly common in mobile devices for 3D perception, but their active illumination systems consume substantial power. To extend battery life, sensors can project a highly sparse dot pattern (e.g., only 500 to 1500 dots per frame), drastically reducing power consumption. However, this leaves the system with an incomplete depth map containing less than 1.5% of the scene's depth data.

To reconstruct a dense depth map, "depth completion" algorithms combine this sparse data with a standard RGB image. While deep learning approaches excel at this, existing state-of-the-art models are often too computationally heavy or memory-intensive for real-time deployment on edge devices. This paper tackles the challenge of designing a network that is robust against extreme sparsity while maintaining a minimal memory footprint and fast inference times.

Figure 1. RGB-annotation overlay of (a) KITTI (LiDAR; range: [0, 85]m), (b) NYU-Depth v2 (processed; range: [0, 10]m), (c) SDS-ST1k (sparse ToF; range: [0, 15]m). Annotations (red) at available sparse depth coordinates. Figure best viewed in color.

Methods

The authors propose a lightweight, end-to-end framework consisting of three main components:

  1. Input Pre-Processing: Instead of feeding raw sparse data directly to the network, they apply a fast CPU-based Nearest Neighbors Interpolation (NNI) to create an initial depth guess, alongside a Euclidean Distance Transform (EDT) that acts as an uncertainty map.
  2. Core Architecture: A streamlined, UNet-like encoder-decoder network (UNetθ,nf,ns) processes the concatenated RGB image, NNI depth, and EDT map to predict a residual depth map.
  3. Normals Estimation Block: To enforce geometric consistency without adding a heavy secondary decoder branch, the authors introduce a lightweight block that approximates surface normals directly from the predicted depth map using simple 1D centered-difference convolutions.
Figure 2. Summary of our network design for depth completion: (a) Network architecture. We highlight pre-processing blocks (gray); tensor operators (orange, square); training supervision operators (teal) and connections (dashed); concatenation (yellow, circle); the UNetθ,nf ,ns module (blue); the normals estimation block (purple). (b) UNetθ,nf ,ns Module. M2×2 indicates a MaxPooling2D layer with stride 2. U2×2 indicates an Upsample2D layer using nearest neighbors upsampling with factor 2. (c) Basic convolutional building blocks of the UNetθ,nf ,ns Module. (d) Normals Estimation Block, as implemented by 1-D convolution (∗) in the respective directions.

The network is trained using a joint loss function balancing an $\ell_1$ depth loss and a cosine-similarity surface normals loss ($\mathcal{L}_n$).

To minimize memory usage, the authors apply Mixed-Precision Quantization-Aware Training (MP QAT). Unlike uniform quantization, which enforces the same bit-width across all layers, their mixed-precision strategy uses a Straight-Through Estimator (STE) to learn the optimal bit-width for the weights and activations of each individual layer based on a target memory budget.

Datasets

The model was evaluated on two indoor datasets under challenging sparsity constraints:

  • NYU-Depth v2: A widely used public indoor dataset. The authors subsampled the dense ground truth using a simulated commercial VCSEL triangular tiling dot pattern, resulting in a sparsity level of $K \approx 1.4\%$.
  • SDS-ST1k: A contributed dataset providing physically accurate raytracing simulations of a low-power ToF sensor and RGB camera setup, yielding an even more extreme sparsity level of $K \approx 0.4\%$.

Key Insights and Ideas

  • Mixed-Precision for Regression: While mixed-precision QAT has seen success in classification tasks, this work demonstrates its efficacy for regression tasks like depth completion. The optimization naturally allocates higher bit-widths to the outer layers and lower bit-widths to the inner layers.
  • Lightweight Geometric Supervision: Incorporating surface normal supervision typically requires complex multi-branch decoders. The authors prove that a simple 1D convolution approximation block provides sufficient geometric guidance to eliminate structural artifacts at depth boundaries.
  • Initialization Matters: Simple NNI and EDT pre-processing provides a strong spatial prior, allowing a much lighter CNN architecture to achieve competitive results compared to heavy iterative spatial propagation networks (like NLSPN).

Key Results

  • Massive Memory Savings: The weights-only mixed-precision model ($W_\star$) achieved a 14-fold memory reduction (from 198.5 MB down to 13.9 MB) on the SDS-ST1k dataset, with a Root Mean Square Error (RMSE) of 94.5 mm, actually outperforming its float32 baseline (98.7 mm) due to QAT refinement.
  • Activation Compression: The $W_4A_8$ model (averaging 4-bit weights and 8-bit activations) compressed activation memory on NYU-Depth v2 from 145.5 MB to 36.2 MB, with an RMSE penalty of only 0.7 mm compared to the float32 model.
  • High Speed: The proposed network achieved a median GPU inference time of 5.11 ms on NYU-Depth v2, significantly outperforming the state-of-the-art NLSPN (42.50 ms) while maintaining comparable depth quality.

Limitations and Future Work

While the results on simulated ToF data (SDS-ST1k) and subsampled real data (NYU-Depth v2) are promising, the method has not yet been validated on physical, real-world low-power RGB-ToF hardware setups where sensor noise and calibration errors might introduce additional complications.

For future work, the authors plan to investigate combining knowledge distillation with mixed-precision QAT to compress the network even further, alongside domain adaptation techniques to bridge the gap between simulated and real-world ToF data.

Summary updated

BibTeX
@misc{jiang2022low,
  author = {Xiaowen Jiang and Valerio Cambareri and Gianluca Agresti and Cynthia Ifeyinwa Ugwu and Adriano Simonetto and Fabien Cardinaux and Pietro Zanuttigh},
  title = {{A Low Memory Footprint Quantized Neural Network for Depth Completion of Very Sparse Time-of-Flight Depth Maps}},
  year = {2022},
  eprint = {2205.12918},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2205.12918},
}
Figure