Analysis of NaN Divergence in Training Monocular Depth Estimation Model
Not on the map. Why?
Abstract (arXiv)
The latest advances in deep learning have facilitated the development of highly accurate monocular depth estimation models. However, when training a monocular depth estimation network, practitioners and researchers have observed not a number (NaN) loss, which disrupts gradient descent optimization. Although several practitioners have reported the stochastic and mysterious occurrence of NaN loss that bothers training, its root cause is not discussed in the literature. This study conducted an in-depth analysis of NaN loss during training a monocular depth estimation network and identified three types of vulnerabilities that cause NaN loss: 1) the use of square root loss, which leads to an unstable gradient; 2) the log-sigmoid function, which exhibits numerical stability issues; and 3) certain variance implementations, which yield incorrect computations. Furthermore, for each vulnerability, the occurrence of NaN loss was demonstrated and practical guidelines to prevent NaN loss were presented. Experiments showed that both optimization stability and performance on monocular depth estimation could be improved by following our guidelines.
Key facts. No citing papers in the map yet (data through 14 Oct 2026). Builds on 37 of its 51 references that are in the map. First posted on arXiv 7 Nov 2023.
Builds on
37 of 51 references.
References · 37
- 2015Deep Residual Learning for Image Recognitioncited by 52,096
- 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 30,186
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,305
- 2023DINOv2: Learning Robust Visual Features without Supervisioncited by 7,974
- 2015Batch Normalization: Accelerating Deep Network Training by Reducing Internal Covariate Shiftcited by 7,005
- 2015Delving Deep into Rectifiers: Surpassing Human-Level Performance on ImageNet Classificationcited by 3,611
- 2018Encoder-Decoder with Atrous Separable Convolution for Semantic Image Segmentationcited by 3,223
- 2021Vision Transformers for Dense Predictioncited by 1,803
- 2014Depth Map Prediction from a Single Image using a Multi-Scale Deep Networkcited by 1,274
- 2021Swin Transformer V2: Scaling Up Capacity and Resolutioncited by 1,228
- 2017Visualizing the Loss Landscape of Neural Netscited by 1,130
- 2019Argoverse: 3D Tracking and Forecasting with Rich Mapscited by 732
25 more
- 2023ZoeDepth: Zero-shot Transfer by Combining Relative and Metric Depthcited by 657
- 2020AdaBins: Depth Estimation using Adaptive Binscited by 601
- 2018Loss Surfaces, Mode Connectivity, and Fast Ensembling of DNNscited by 588
- 20193D Packing for Self-Supervised Monocular Depth Estimationcited by 439
- 2019From Big to Small: Multi-Scale Local Planar Guidance for Monocular Depth Estimationcited by 382
- 2016Unsupervised CNN for Single View Depth Estimation: Geometry to the Rescuecited by 368
- 2019Why gradient clipping accelerates training: A theoretical justification for adaptivitycited by 341
- 2017Sparsity Invariant CNNscited by 326
- 2023Unleashing Text-to-Image Diffusion Models for Visual Perceptioncited by 269
- 2022NeW CRFs: Neural Window Fully-connected CRFs for Monocular Depth Estimationcited by 153
- 2023DDP: Diffusion Model for Dense Visual Predictioncited by 148
- 2017L2 Regularization versus Batch and Weight Normalizationcited by 124
- 2022DepthFormer: Exploiting Long-Range Correlation and Local Information for Accurate Monocular Depth Estimationcited by 118
- 2022Revealing the Dark Secrets of Masked Image Modelingcited by 117
- 2022P3Depth: Monocular Depth Estimation with a Piecewise Planarity Priorcited by 107
- 2022LocalBins: Improving Depth Estimation by Learning Local Distributionscited by 94
- 2022Attention Attention Everywhere: Monocular Depth Prediction with Skip Attentioncited by 93
- 2023iDisc: Internal Discretization for Monocular Depth Estimationcited by 73
- 2022Global-Local Path Networks for Monocular Depth Estimation with Vertical CutDepthcited by 58
- 2023VA-DepthNet: A Variational Approach to Single Image Depth Predictioncited by 54
- 2023IEBins: Iterative Elastic Bins for Monocular Depth Estimationcited by 54
- 2023All in Tokens: Unifying Output Space of Visual Tasks via Soft Tokencited by 52
- 2020On the training dynamics of deep networks with L2 regularizationcited by 39
- 2022Depthformer : Multiscale Vision Transformer For Monocular Depth Estimation With Local Global Information Fusioncited by 21
- 2023URCDC-Depth: Uncertainty Rectified Cross-Distillation with CutFlip for Monocular Depth Estimationcited by 16
Built on by
Not cited yet.