TL;DR
RoSAMDepth improves self-supervised monocular depth estimation in adverse conditions (like rain and night) by incorporating object-level priors from the Segment Anything Model (SAM). By introducing object-aware feature contrastive learning, adaptive regional smoothness, and object-level reliability filtering during training, it achieves sharper boundaries and state-of-the-art accuracy without adding any inference-time computational overhead.
What Problem Does This Paper Address?
Monocular depth estimation—predicting 3D depth from a single 2D image—is a cornerstone of autonomous driving, robotics, and AR/VR. Self-supervised methods are highly attractive because they learn depth purely from raw video sequences using geometric and photometric consistency constraints, bypassing the need for expensive LiDAR or human annotations.
However, these methods suffer from a major flaw: they assume that a point's appearance remains constant across video frames (photometric consistency). In adverse conditions like nighttime, heavy rain, or glare, this assumption completely breaks down. Furthermore, standard self-supervised frameworks treat images as uniform grids of pixels, ignoring semantic or object-level boundaries. This causes depth predictions to "bleed" across object edges, resulting in blurred boundaries and unstable depth maps in complex environments.
Methods
To inject structural and object-level awareness into depth estimation, the authors introduce RoSAMDepth. Crucially, the Segment Anything Model (SAM) is used entirely offline to pre-generate non-overlapping object masks before training begins, meaning the final model remains lightweight and fast during deployment.
The framework builds upon a teacher-student distillation paradigm and introduces three novel components:
- Segment-Guided Representation Contrasting (SRC): Instead of forcing depth outputs to rigidly match SAM boundaries (which fails when SAM over-segments an object), SRC operates in the latent feature space. It uses a contrastive loss function to pull pixel features belonging to the same object closer together while pushing features from different objects apart.
- Adaptive Regional Outlier Masking (AROM) & Regional Gaussian Likelihood Loss: Traditional smoothness losses fail when depth is smoothly but incorrectly estimated across an object boundary. AROM dynamically computes an outlier mask based on the depth variance within each SAM segment. This mask guides a regional Gaussian likelihood loss to enforce smoothness strictly within continuous object regions while preserving sharp edges.
- Object-Level Reliability Estimation (ORE): Standard pixel-level error metrics can be easily fooled by uniform textures (e.g., a misscaled car can still yield low pixel-level error). ORE aggregates photometric errors across entire SAM segments to evaluate depth reliability at the object level, down-weighting untrustworthy regions during knowledge distillation.
Datasets
The authors evaluated RoSAMDepth on two challenging real-world driving benchmarks:
- nuScenes: A massive dataset containing diverse environmental conditions. The training split included 15,129 daytime, 3,796 rainy, and 2,551 nighttime frames.
- Oxford RobotCar: Used specifically to benchmark daytime vs. nighttime performance, utilizing 17,790 daytime and 19,162 nighttime images for training.
Key Insights and Ideas
- Latent Space vs. Output Space Constraints: Forcing depth maps to strictly align with segmentation masks introduces noise due to mask fragmentation. Constraining the feature representations instead allows the network to implicitly learn object geometry without suffering from over-segmentation artifacts.
- The Illusion of Pixel-Level Accuracy: Pixels within the same object share similar appearances, which can lead to accidental alignments and low photometric errors even if the object's scale is completely wrong. Evaluating reliability at the object level provides a much truer supervision signal.
Key Results
RoSAMDepth consistently outperformed state-of-the-art unsupervised and real-data-trained methods across both datasets:
- nuScenes Benchmark: Compared to the real-data baseline (Syn2Real-Depth), RoSAMDepth achieved average relative gains of 2.8% on Absolute Relative Error (AbsRel) and 2.7% on Squared Relative Error (SqRel) across all weather conditions and frame settings.
- Oxford RobotCar Benchmark: Under single-frame evaluation, the model demonstrated substantial improvements, reducing AbsRel by 4.4% and SqRel by 7.6%.
- Qualitative Improvements: Visually, the model excels at preserving the fine structures of poles, street signs, and distant vehicles, while successfully suppressing reflection-induced artifacts on rainy roads and night glare.
Limitations and Future Work
While RoSAMDepth successfully avoids inference-time overhead by using SAM offline, its training performance is inherently bounded by the quality of the pre-generated SAM masks. In cases of extreme degradation where even SAM fails to segment key objects, the object-level priors could introduce noise.
The authors suggest that future work could explore integrating online, lightweight segmentation models or jointly optimizing depth and segmentation tasks under adverse conditions.
Summary updated