F2Depth: Self-supervised Indoor Monocular Depth Estimation via Optical Flow Consistency and Feature Map Synthesis

Xiaotong Guo, Huijie Zhao, Shuwei Shao, Xudong Li, Baochang Zhang · DOI

Abstract

Self-supervised monocular depth estimation has achieved significant success in outdoor environments, yet indoor scenes remain a challenge due to the prevalence of textureless surfaces like blank walls and polished floors. These regions provide insufficient photometric gradients for standard view-synthesis-based supervision. We present $F^2Depth$, a novel framework that addresses these limitations by leveraging a fine-tuned optical flow network to provide stable geometric priors. By incorporating patch-based photometric loss, optical flow consistency, and high-dimensional feature map synthesis, $F^2Depth$ significantly improves depth accuracy and edge preservation in complex indoor environments.

1. Introduction

Estimating 3D structure from a single 2D image is a fundamental task in computer vision with applications ranging from robotics to augmented reality. While supervised methods yield high accuracy, they require massive amounts of ground-truth data (e.g., LiDAR or structured light), which are difficult to collect indoors. Self-supervised learning offers an alternative by using temporal consistency in video sequences as a supervisory signal. However, the core mechanism of self-supervision—warping frames to minimize photometric error—fails when pixels are indistinguishable, a common occurrence in indoor settings with beige walls and uniform lighting. $F^2Depth$ is designed to overcome this "blank wall" problem by moving beyond raw pixel matching toward feature-level and flow-based consistency.

2. Methodology

The $F^2Depth$ framework introduces three primary technical innovations to stabilize the training signal in low-texture environments.

2.1 Patch-based Photometric Loss for Optical Flow

Standard optical flow networks often struggle with indoor scenes because they are typically pre-trained on synthetic datasets (like MPI Sintel) that do not match indoor statistics. To fine-tune the flow network, $F^2Depth$ employs Direct Sparse Odometry (DSO) to identify "key points" with high gradient variance. Instead of calculating loss across the entire image, the model focuses on $3 \times 3$ patches around these discriminative points. This selective learning ensures the flow network masters reliable features before attempting to generalize to more ambiguous regions.

2.2 Optical Flow Consistency Loss

To bridge the gap between depth estimation and motion, the system enforces consistency between two types of flow:

  1. Rigid Flow: The pixel displacement predicted based on the current depth estimate and the calculated camera pose.
  2. Optical Flow: The displacement predicted by the fine-tuned flow network.

By minimizing the discrepancy between these two signals, the depth network receives a stable geometric prior that is less sensitive to local photometric ambiguities than standard pixel-warping losses.

2.3 Multi-scale Feature Map Synthesis

Perhaps the most significant departure from traditional methods is the use of feature map synthesis. While RGB images only provide three channels of information, the flow network generates high-dimensional feature maps (up to 192 channels). $F^2Depth$ warps these feature maps to calculate a synthesis loss. Because these features encode structural and contextual information, they maintain variance even in areas where the raw RGB pixels appear flat, providing a much richer gradient for the depth optimizer.

3. Experimental Setup

The model was evaluated across three distinct datasets to test both accuracy and generalization:

  • NYU Depth V2: The primary benchmark for indoor depth estimation.
  • 7-Scenes: Used for zero-shot generalization testing to evaluate performance on unseen environments.
  • Campus Indoor Dataset: A custom dataset collected by the authors using a laser rangefinder. This dataset provides high-precision ground truth for specific points, offering a more rigorous validation than the relatively noisy Kinect data found in NYU Depth V2.

4. Results and Discussion

$F^2Depth$ demonstrates a clear performance advantage over existing self-supervised baselines such as $P^2Net$.

4.1 Quantitative Performance

On the NYU Depth V2 dataset, $F^2Depth$ achieved an RMS error reduction of 2.67% to 3.88% compared to previous state-of-the-art models. In zero-shot generalization tests, the model maintained high precision, achieving a $\delta_1$ accuracy (pixels within 1.25 of the ground truth) of 75.8% on 7-Scenes and 76.0% on the Campus Indoor dataset.

4.2 Qualitative Analysis

Visual results indicate that $F^2Depth$ excels at recovering sharp structural boundaries. While earlier models often produce "blobby" artifacts or blurred edges around objects like bookshelves and doorways, $F^2Depth$ maintains the planarity of walls and the sharpness of corners. This is attributed to the feature-level supervision, which is more sensitive to structural transitions than raw color values.

5. Limitations and Future Work

Despite its successes, the model exhibits sensitivity to extreme illumination changes. In scenarios with significant shadows or dark hallways, the model occasionally defaults to a "darkness equals distance" bias, incorrectly predicting deeper values for poorly lit areas. Future research will explore the integration of Transformer architectures to capture more global context and the potential for end-to-end joint training of optical flow and depth networks to further refine the geometric consistency.

6. Conclusion

$F^2Depth$ represents a significant step forward for indoor spatial perception. By shifting the supervisory focus from raw pixels to high-dimensional feature maps and leveraging selective patch-based learning, the framework effectively mitigates the challenges posed by textureless surfaces. This approach provides a more robust foundation for self-supervised depth estimation in the complex, often ambiguous environments of the human world.

Summary updated

BibTeX
@article{guo2024f,
  author = {Xiaotong Guo and Huijie Zhao and Shuwei Shao and Xudong Li and Baochang Zhang},
  title = {{F2Depth: Self-supervised Indoor Monocular Depth Estimation via Optical Flow Consistency and Feature Map Synthesis}},
  journal = {Engineering Applications of AI},
  year = {2024},
  doi = {10.1016/j.engappai.2024.108391},
}
Figure