Abstract
Absolute camera pose estimation is usually addressed by sequentially solving two distinct subproblems: First a feature matching problem that seeks to establish putative 2D-3D correspondences, and then a Perspective-n-Point problem that minimizes, w.r.t. the camera pose, the sum of so-called Reprojection Errors (RE). We argue that generating putative 2D-3D correspondences 1) leads to an important loss of information that needs to be compensated as far as possible, within RE, through the choice of a robust loss and the tuning of its hyperparameters and 2) may lead to an RE that conveys erroneous data to the pose estimator. In this paper, we introduce the Neural Reprojection Error (NRE) as a substitute for RE. NRE allows to rethink the camera pose estimation problem by merging it with the feature learning problem, hence leveraging richer information than 2D-3D correspondences and eliminating the need for choosing a robust loss and its hyperparameters. Thus NRE can be used as training loss to learn image descriptors tailored for pose estimation. We also propose a coarse-to-fine optimization method able to very efficiently minimize a sum of NRE terms w.r.t. the camera pose. We experimentally demonstrate that NRE is a good substitute for RE as it significantly improves both the robustness and the accuracy of the camera pose estimate while being computationally and memory highly efficient.
Introduction: The Limitations of Traditional Reprojection Error
Estimating the absolute pose of a camera—its position and orientation—is a cornerstone of computer vision, essential for applications in augmented reality, robotics, and Structure-from-Motion (SfM). Traditionally, this is a two-step process. First, feature matching establishes "putative" 2D-3D correspondences between image points and a 3D model. Second, a Perspective-n-Point (PnP) solver minimizes the Reprojection Error (RE), which is the geometric distance between a reprojected 3D point and its corresponding 2D detection.
The authors argue that this decoupling is fundamentally flawed. Summarizing an entire image region into a single 2D coordinate discards vital information about ambiguity, texture, and multimodal matches, such as those found in repetitive architectural patterns. Furthermore, traditional RE requires hand-tuned robust loss functions (e.g., Huber or Geman-McClure) to mitigate the impact of outliers, which are difficult to optimize across diverse scenes.
Methodology: Neural Reprojection Error (NRE)
The core innovation presented is the Neural Reprojection Error (NRE). Instead of measuring point-to-point distance, NRE measures the discrepancy between two probability distributions using Cross-Entropy:
- Matching PMF: A probability mass function derived from dense descriptor cross-correlations, indicating the likelihood of a 3D point corresponding to any pixel in the image.
- Reprojection PMF: A distribution centered on the current estimate of the reprojected 3D point.
Technical Implementation
- Dense Loss Maps: The network outputs a grid where each value represents the "cost" of a 3D point being at that pixel, preserving the full context of the match.
- Differentiability: NRE is differentiable with respect to both camera pose and image descriptors, enabling the joint training of a CNN to learn features specifically optimized for pose estimation.
- Coarse-to-Fine Optimization: To maintain efficiency, the authors employ a multi-scale approach. Low-resolution loss maps provide an initial rough pose, followed by high-resolution refinement on local patches.
- Graduated Non-Convexity (GNC): A smoothing strategy is used to gradually sharpen the loss function during optimization, aiding the solver in reaching the global minimum.
Key Insights: Information Preservation
A critical advantage of NRE is its ability to handle uncertainty. By utilizing the entire loss map, the estimator "sees" the full distribution of potential matches. If a feature matches multiple similar windows on a building, NRE maintains these peaks, whereas traditional methods would be forced to select a single (potentially incorrect) point or discard the feature entirely.
Mathematically, traditional RE is a special case of NRE where the correspondence map is a "one-hot" encoding. NRE generalizes this, eliminating the need for manual inlier threshold tuning as robustness is inherently part of the dense loss map.
Experimental Results
The method was evaluated on the MegaDepth dataset using a benchmark of 3,000 image pairs.
- Accuracy: NRE significantly outperformed state-of-the-art RE-based estimators like MAGSAC++. In the "Hard" category, NRE improved pose accuracy by up to 200%.
- Robustness: The pipeline demonstrated superior resilience to outliers and ambiguous textures.
- Efficiency: Despite the dense approach, the coarse-to-fine strategy ensures high efficiency, requiring 16x less memory for correspondence maps than previous dense methods like S2DNet.
Conclusion and Future Work
While NRE shows great promise, the authors note that the current implementation uses a relatively simple matching architecture. Future work could involve integrating more sophisticated "learning-to-match" architectures, such as SuperGlue-style transformers. The authors believe this paradigm of merging deep learning with 3D geometry could be extended to other domains like multi-view stereo or SLAM, where point-based residuals are currently a bottleneck.
Summary updated