Image-Guided Shape-from-Template Using Mesh Inextensibility Constraints

Thuy Tran, Ruochen Chen, Shaifali Parashar

TL;DR

This paper introduces a novel, unsupervised method for reconstructing 3D shapes from images using a deformable template. By leveraging only visual cues like color, gradients, and silhouettes, and enforcing mesh inextensibility, their approach achieves a significant speedup (400x faster) and outperforms existing methods, especially in challenging scenarios with fine details and severe occlusions.

What Problem Does This Paper Address?

Recovering the 3D shape of objects from images is a fundamental problem in computer vision. "Shape-from-Template" (SfT) methods tackle this by deforming a known 3D template to match input images. Traditional SfT methods rely on finding point correspondences between the image and the template's texture. However, these methods struggle significantly when faced with occlusions, sharp motions, or extreme perspectives, as correspondences become unreliable or impossible to find. While recent deep learning approaches can reconstruct 3D shapes without explicit correspondences, they often require vast amounts of labeled data for supervision and can still falter in complex scenarios. Physics-based simulation methods offer an unsupervised alternative but are notoriously slow. This paper aims to bridge this gap by providing an unsupervised, fast, and robust SfT method that handles challenging visual conditions effectively.

Methods

The core of this work is an unsupervised, image-guided Shape-from-Template (SfT) approach. Instead of relying on physics-based simulations or explicit point correspondences, the method uses a deformation network to predict vertex offsets for the 3D template mesh. This network learns to deform the template to match input images by minimizing a combination of vision-based losses and a mesh regularization term.

Key methodological components include:

  • Deformation Model: A neural network predicts a continuous displacement field for the template mesh vertices, allowing for flexible deformations. This is formulated as $\mathbf{x}_{t}=\mathbf{x}_{0}+f_{\theta }(\mathbf{x}_0,t)$, where $\mathbf{x}_0$ is the initial template shape, $\mathbf{x}_t$ is the deformed shape at frame $t$, and $f_{\theta}$ is the deformation network.
  • Differentiable Rendering: Off-the-shelf differentiable renderers are used to project the deformed 3D mesh into a 2D image and silhouette, enabling gradient-based optimization.
  • Adaptive Data Loss Structure: A novel loss function is introduced that amplifies element-wise errors exponentially, allowing the optimizer to focus on significant discrepancies. This is crucial for handling variations in lighting and shading.
  • Vision Losses: The method utilizes RGB loss (pixel-wise difference between rendered and input image), Silhouette Loss (comparing rendered and ground-truth object masks), and Image Gradient Loss (comparing image gradients to capture edges and texture). For scenarios without ground-truth silhouettes, they employ the Segment Anything Model 2 (SAM 2).
  • Mesh Inextensibility Regularization: To ensure stable optimization and prevent unrealistic stretching, a mesh inextensibility constraint is enforced. This constraint is adapted to the mesh scale.
  • Frame-wise Optimization: The optimization is performed independently for each frame, with the parameters from the previous frame used to initialize the current frame's optimization. This leverages temporal coherence in videos for faster convergence and improved results.

Datasets

The paper evaluates its method on two datasets:

  • Kinect-paper dataset: This dataset consists of 193 images and depth maps captured using a Kinect sensor.
  • ϕ-SfT dataset: This dataset includes both synthetic sequences of cloth deformations (simulated using ArcSim) and real-world sequences captured from an Azure Kinect v2 camera.

Key Insights and Ideas

  • Vision Cues are Sufficient: The paper demonstrates that by carefully combining image color, gradients, and silhouettes with a mesh inextensibility constraint, it's possible to achieve high-quality 3D reconstruction without relying on explicit physics simulations or point correspondences.
  • Adaptive Loss for Robustness: The adaptive data loss structure is a key innovation that allows the method to be more robust to variations in lighting and shading, which are common in real-world images and can significantly degrade performance in other methods.
  • Frame-wise Optimization for Speed: By initializing each frame's optimization with the results from the previous frame, the method significantly reduces computation time without sacrificing accuracy, achieving a substantial speedup over previous unsupervised methods.
  • Mesh Inextensibility as a Versatile Constraint: Using mesh inextensibility (rather than strict isometry) allows the method to handle a broader range of materials, from rigid objects to elastic ones like cloth.

Key Results

  • Speed: The proposed method achieves a 400x speedup compared to previous unsupervised methods like ϕ-SfT.
  • Accuracy:
    • On the Kinect-paper dataset, the method achieves competitive RMSE values, outperforming traditional SfT and DeepSfT.
  • On the ϕ-SfT synthetic dataset, it shows significantly lower average errors compared to ϕ-SfT and PGSfT.
  • On the ϕ-SfT real dataset, the method outperforms ϕ-SfT and PGSfT by large margins in terms of average chamfer distance.
  • Qualitative Performance: The method demonstrates superior performance in reconstructing finer details, handling severe occlusions, and dealing with strong perspectivities, as visually shown in comparisons with state-of-the-art methods. It captures subtle surface variations and folds more accurately.

Limitations and Future Work

  • Limitations:
    • The method's performance on the Kinect Paper dataset is slightly worse than TD-SfT due to challenges with reconstructing frames exhibiting high inter-image motion, requiring more iterations.
  • The current formulation cannot reconstruct textureless or specular surfaces, as it lacks explicit modeling of light sources and reflectance.
  • Future Work:
    • Extend the framework to other 3D representations beyond triangle meshes, such as parametric surfaces, implicit fields, or point-based structures.
  • Adapt the frame-wise optimization to a window-wise approach to incorporate temporal consistency losses more explicitly, potentially further improving timing and accuracy.
  • Explore other object categories, particularly those with severe self-occlusions.

Summary updated

BibTeX
@inproceedings{tran2025image,
  author = {Thuy Tran and Ruochen Chen and Shaifali Parashar},
  title = {{Image-Guided Shape-from-Template Using Mesh Inextensibility Constraints}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2025},
}
Figure