TTFDNet: Precise Depth Estimation from Single-Frame Fringe Patterns

Yi Cai, Mingyu Guo, Congying Wang, Xiaowei Lu, Xuanke Zeng, Yiling Sun, Yuexia Ai, Shixiang Xu, Jingzhen Li2024

TL;DR

This paper introduces TTFDNet, a novel deep learning architecture for highly accurate 3D depth estimation from single fringe patterns. By leveraging a pre-trained Vision Transformer and a custom loss function, TTFDNet achieves state-of-the-art performance, outperforming existing methods and demonstrating robustness in dynamic and challenging imaging conditions.

What Problem Does This Paper Address?

Fringe Projection Profilometry (FPP) is a powerful non-contact technique for 3D shape reconstruction. Traditionally, FPP relies on capturing multiple fringe patterns with phase shifts to accurately determine depth. However, this multi-frame approach can be cumbersome and impractical for dynamic scenes or systems with limited synchronization capabilities. While single-frame methods exist, they often struggle with accuracy, especially in capturing fine details and complex structures. Existing deep learning approaches, while promising, often require large datasets to effectively utilize powerful transformer architectures, which are not always available in FPP. This paper aims to bridge this gap by developing a single-frame depth estimation method that is both accurate and efficient, even with limited training data.

Methods

The core of TTFDNet is a novel architecture built upon a pre-trained Vision Transformer (ViT). The network comprises three key modules:

  • Precise Contour and Coarse Depth (PCCD) Pre-processor: This module leverages a fine-tuned ViT model to extract precise contour and coarse depth features from the input fringe pattern. This initial step is crucial for robustly identifying object boundaries and general shape.
  • Global Multi-Dimensional Fusion (GMDF) Module: This module fuses the features extracted by the PCCD pre-processor with the original input image. This creates a richer representation that combines low-level image information with high-level structural features.
  • Progressive Depth Extractor (PDE): This module, featuring a U-shaped architecture enhanced by a ResNet-18 encoder, further refines the fused features to produce the final, precise depth map. It employs residual connections and progressive upsampling to maintain detail and accuracy.

A key innovation is the Fringe Structure Consistency Evaluation (FSCE) loss function. This custom loss function, integrated during training, helps transfer general knowledge from the pre-trained ViT to the specific domain of FPP. It encourages consistency between the predicted depth's reconstructed fringe pattern and the original input, improving fine-tuning and accuracy, especially on smaller datasets.

Datasets

The authors created a new dataset for training and evaluation. This dataset consists of 1062 samples, each containing a 384x384 PNG fringe pattern image and its corresponding ground truth depth map in MAT format. The dataset was systematically divided into training (646 samples), validation (208 samples), and testing (208 samples) subsets. The ground truth depth maps were generated using a four-step phase-shifting algorithm followed by phase unwrapping and phase-to-depth mapping, fitting a second-order polynomial to establish the relationship.

Key Insights and Ideas

  • Leveraging Pre-trained Transformers for FPP: The paper demonstrates that pre-trained Vision Transformers, typically used for general image recognition, can be effectively fine-tuned for the specialized task of FPP depth estimation, even with limited domain-specific data.
  • The Power of a Custom Loss Function: The FSCE loss function is critical for bridging the gap between general image features and the specific requirements of fringe pattern analysis, significantly improving accuracy and robustness.
  • Progressive Refinement for Detail: The multi-stage architecture, particularly the PDE with its U-Net-like structure and ResNet backbone, allows for progressive refinement of depth estimates, leading to the accurate capture of fine details.
  • Single-Frame Efficiency: The success of TTFDNet in achieving high accuracy from a single frame highlights its potential for real-time applications where multi-frame capture is not feasible.

Key Results

  • State-of-the-Art Accuracy: TTFDNet achieved a Mean Absolute Error (MAE) of 0.00372 mm on a test set of 208 scenes, significantly outperforming Unet (0.03458 mm), PDE (0.01063 mm), and PCTNet (0.00518 mm). This is nearly 10 times better than Unet.
  • Precise Measurements: The model demonstrated high precision on standard parts, with deviations of approximately 90 µm for a 25.4 mm radius sphere and 6 µm for a 20 mm thick metal part.
  • Robustness and Generalization: TTFDNet showed excellent robustness and generalization capabilities when system parameters (projection/imaging system position, focus) were varied. It consistently outperformed other methods in maintaining detail and avoiding artifacts like residual deformation fringes and uneven patches.
  • Dynamic Scene Performance: The model successfully tracked depth changes of a rotating fan, demonstrating its effectiveness in dynamic scenarios and its ability to capture subtle vibrations.

Limitations and Future Work

  • Computational Resources: The authors acknowledge that the transformer-based architecture and multi-dimensional fusion require significant computational resources for training and inference.
  • Extreme Conditions: While robust to moderate parameter variations, performance might degrade under extreme conditions (e.g., significant displacements, large aperture changes).

Future work suggested includes:

  • Optimizing Architecture for Efficiency: Exploring techniques like knowledge distillation to create lightweight student models from the teacher TTFDNet, reducing computational demands.
  • Adaptive Algorithms: Developing adaptive algorithms to dynamically adjust model parameters for enhanced performance under extreme imaging conditions.

Summary updated

BibTeX
@misc{cai2024ttfdnet,
  author = {Yi Cai and Mingyu Guo and Congying Wang and Xiaowei Lu and Xuanke Zeng and Yiling Sun and Yuexia Ai and Shixiang Xu and Jingzhen Li},
  title = {{TTFDNet: Precise Depth Estimation from Single-Frame Fringe Patterns}},
  year = {2024},
  doi = {10.3390/s24144733},
}
Figure