Matching Query Image Against Selected NeRF Feature for Efficient and Scalable Localization

Huaiji Zhou, Bing Wang, Changhao ChenarXiv 2024

Abstract

Neural implicit representations such as NeRF have revolutionized 3D scene representation with photo-realistic quality. However, existing methods for visual localization within NeRF representations suffer from inefficiency and scalability issues, particularly in large-scale environments. This work proposes MatLoc-NeRF, a novel matching-based localization framework using selected NeRF features. It addresses efficiency by employing a learnable feature selection mechanism that identifies informative NeRF features for matching with query images. This eliminates the need for all NeRF features or additional descriptors, leading to faster and more accurate pose estimation. To tackle large-scale scenes, MatLoc-NeRF utilizes a pose-aware scene partitioning strategy. It ensures that only the most relevant NeRF sub-block generates key features for a specific pose. Additionally, scene segmentation and a place predictor provide fast coarse initial pose estimation. Evaluations on public large-scale datasets demonstrate that MatLoc-NeRF achieves superior efficiency and accuracy compared to existing NeRF-based localization methods.

Introduction

Visual localization—the task of determining a camera's precise 6-DoF pose in a 3D environment—is fundamental to autonomous systems. While Neural Radiance Fields (NeRF) provide high-fidelity scene representations, their application to localization has been hindered by computational bottlenecks. Traditional approaches like iNeRF rely on slow iterative optimization, while others require memory-intensive external descriptors. MatLoc-NeRF addresses these challenges by leveraging the inherent features of the NeRF model itself, optimized through a learnable selection process.

Overview of the MatLoc-NeRF pipeline, showing the coarse-to-fine localization process from query image to refined pose estimation.

Methodology

1. Learnable Feature Selection

A key innovation of MatLoc-NeRF is that the intermediate layers of a standard NeRF MLP already contain discriminative geometric and appearance information. Instead of adding a separate "localization head," the framework uses a learnable binary selection matrix. This matrix identifies the most informative dimensions of the internal features for matching. By reducing the feature dimension (e.g., from 47 to 5 or 10), the system achieves significant speedups in matching without compromising accuracy.

2. Pose-Aware Scene Partitioning

Scalability in large-scale environments often requires partitioning the scene into sub-NeRFs. Unlike spatial partitioning, which can require a single view to load multiple sub-networks, MatLoc-NeRF employs a pose-centric strategy. By clustering the map based on camera poses, the system ensures a one-to-one mapping between a query image and a specific sub-NeRF, maximizing efficiency during both training and inference.

3. Coarse-to-Fine Pipeline

The localization process occurs in two stages:

  • Coarse Estimation: A lightweight CNN-based place predictor classifies the query image into a pre-defined "place" or cluster.
  • Fine Localization: The identified sub-NeRF generates 3D features that are matched against 2D features extracted from the query image. The final pose is then refined using PnP and RANSAC.

Experimental Results

The framework was evaluated on the Mill-19 dataset, featuring complex outdoor scenes like "Rubble" and "Building."

Efficiency and Speed

MatLoc-NeRF significantly outperforms existing methods in terms of localization time. It achieves a total localization time of 1.4 seconds, an order of magnitude faster than the 18 seconds required by iNeRF.

Efficiency comparison of MatLoc-NeRF against other methods, showing state-of-the-art speed.

Accuracy

On the "Rubble" dataset, MatLoc-NeRF achieved a median translation error of 1.7m and a rotation error of 0.8°, outperforming iNeRF (5.6m, 10.3°) and matching-based methods using SIFT (4.1m, 1.4°). This demonstrates that internal NeRF features, when properly selected, are highly effective for precise localization.

Conclusion

MatLoc-NeRF demonstrates that neural implicit maps can be used for efficient, real-time visual localization. By selecting informative internal features and employing pose-aware partitioning, the framework overcomes the scalability and speed limitations of previous NeRF-based methods, paving the way for its use in large-scale autonomous navigation.

Summary updated

BibTeX
@misc{zhou2024matching,
  author = {Huaiji Zhou and Bing Wang and Changhao Chen},
  title = {{Matching Query Image Against Selected NeRF Feature for Efficient and Scalable Localization}},
  year = {2024},
  eprint = {2406.11766},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2406.11766},
}
Figure