# BoQ: A Place is Worth a Bag of Learnable Queries

arXiv: https://arxiv.org/abs/2405.07364 · HTML: https://mlsanity.com/paper/2405.07364/

## Key facts

- Cited by 64 papers in the map (data through 14 Oct 2026).
- Builds on 31 of its 63 references that are in the map.
- First posted on arXiv 12 May 2024.

## Builds on (most cited first, 30 of 31)

- [Attention Is All You Need](https://mlsanity.com/paper/1706.03762/) (2017)
- [Deep Residual Learning for Image Recognition](https://mlsanity.com/paper/1512.03385/) (2015)
- [An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale](https://mlsanity.com/paper/2010.11929/) (2020)
- [PyTorch: An Imperative Style, High-Performance Deep Learning Library](https://mlsanity.com/paper/1912.01703/) (2019)
- [Swin Transformer: Hierarchical Vision Transformer using Shifted Windows](https://mlsanity.com/paper/2103.14030/) (2021)
- [DINOv2: Learning Robust Visual Features without Supervision](https://mlsanity.com/paper/2304.07193/) (2023)
- [End-to-End Object Detection with Transformers](https://mlsanity.com/paper/2005.12872/) (2020)
- [RandAugment: Practical automated data augmentation with a reduced search space](https://mlsanity.com/paper/1909.13719/) (2019)
- [Rethinking Semantic Segmentation from a Sequence-to-Sequence Perspective with Transformers](https://mlsanity.com/paper/2012.15840/) (2020)
- [SuperPoint: Self-Supervised Interest Point Detection and Description](https://mlsanity.com/paper/1712.07629/) (2017)
- [NetVLAD: CNN architecture for weakly supervised place recognition](https://mlsanity.com/paper/1511.07247/) (2015)
- [CrossViT: Cross-Attention Multi-Scale Vision Transformer for Image Classification](https://mlsanity.com/paper/2103.14899/) (2021)
- [Fine-tuning CNN Image Retrieval with No Human Annotation](https://mlsanity.com/paper/1711.02512/) (2017)
- [Multi-Similarity Loss with General Pair Weighting for Deep Metric Learning](https://mlsanity.com/paper/1904.06627/) (2019)
- [Patch-NetVLAD: Multi-Scale Fusion of Locally-Global Descriptors for Place Recognition](https://mlsanity.com/paper/2103.01486/) (2021)
- [AnyLoc: Towards Universal Visual Place Recognition](https://mlsanity.com/paper/2308.00688/) (2023)
- [Particular object retrieval with integral max-pooling of CNN activations](https://mlsanity.com/paper/1511.05879/) (2015)
- [MixVPR: Feature Mixing for Visual Place Recognition](https://mlsanity.com/paper/2303.02190/) (2023)
- [EigenPlaces: Training Viewpoint Robust Models for Visual Place Recognition](https://mlsanity.com/paper/2308.10832/) (2023)
- [Self-supervising Fine-grained Region Similarities for Large-scale Image Localization](https://mlsanity.com/paper/2006.03926/) (2020)
- [TransVPR: Transformer-based place recognition with multi-level attention aggregation](https://mlsanity.com/paper/2201.02001/) (2022)
- [R2Former: Unified Retrieval and Reranking Transformer for Place Recognition](https://mlsanity.com/paper/2304.03410/) (2023)
- [VPR-Bench: An Open-Source Visual Place Recognition Evaluation Framework with Quantifiable Viewpoint and Appearance Change](https://mlsanity.com/paper/2005.08135/) (2020)
- [What do Vision Transformers Learn? A Visual Exploration](https://mlsanity.com/paper/2212.06727/) (2022)
- [Aggregating Deep Convolutional Features for Image Retrieval](https://mlsanity.com/paper/1510.07493/) (2015)
- [Data-efficient Large Scale Place Recognition with Graded Similarity Supervision](https://mlsanity.com/paper/2303.11739/) (2023)
- [Adaptive-Attentive Geolocalization from few queries: a hybrid approach](https://mlsanity.com/paper/2010.06897/) (2020)
- [AmsterTime: A Visual Place Recognition Benchmark Dataset for Severe Domain Shift](https://mlsanity.com/paper/2203.16291/) (2022)
- [Are Local Features All You Need for Cross-Domain Visual Place Recognition?](https://mlsanity.com/paper/2304.05887/) (2023)
- [Global Proxy-based Hard Mining for Visual Place Recognition](https://mlsanity.com/paper/2302.14217/) (2023)

## Built on by (most cited first, 30 of 64)

- [OpenING: A Comprehensive Benchmark for Judging Open-ended Interleaved Image-Text Generation](https://mlsanity.com/paper/2411.18499/) (2024)
- [Recognition through Reasoning: Reinforcing Image Geo-localization with Large Vision-Language Models](https://mlsanity.com/paper/2506.14674/) (2025)
- [Focus on Local: Finding Reliable Discriminative Regions for Visual Place Recognition](https://mlsanity.com/paper/2504.09881/) (2025)
- [EffoVPR: Effective Foundation Model Utilization for Visual Place Recognition](https://mlsanity.com/paper/2405.18065/) (2024)
- [Pair-VPR: Place-Aware Pre-training and Contrastive Pair Classification for Visual Place Recognition with Vision Transformers](https://mlsanity.com/paper/2410.06614/) (2024)
- [SelaVPR++: Towards Seamless Adaptation of Foundation Models for Efficient Place Recognition](https://mlsanity.com/paper/2502.16601/) (2025)
- [EDTformer: An Efficient Decoder Transformer for Visual Place Recognition](https://mlsanity.com/paper/2412.00784/) (2024)
- [UniPR-3D: Towards Universal Visual Place Recognition with Visual Geometry Grounded Transformer](https://mlsanity.com/paper/2512.21078/) (2025)
- [Towards Implicit Aggregation: Robust Image Representation for Place Recognition in the Transformer Era](https://mlsanity.com/paper/2511.06024/) (2025)
- [MutualVPR: A Mutual Learning Framework for Resolving Supervision Inconsistencies via Adaptive Clustering](https://mlsanity.com/paper/2412.09199/) (2024)
- [WildCross: A Cross-Modal Large Scale Benchmark for Place Recognition and Metric Depth Estimation in Natural Environments](https://mlsanity.com/paper/2603.01475/) (2026)
- [Feature Complementation Architecture for Visual Place Recognition](https://mlsanity.com/paper/2506.12401/) (2025)
- [SuperPlace: The Renaissance of Classical Feature Aggregation for Visual Place Recognition in the Era of Foundation Models](https://mlsanity.com/paper/2506.13073/) (2025)
- [A2GC: Asymmetric Aggregation with Geometric Constraints for Locally Aggregated Descriptors](https://mlsanity.com/paper/2511.14109/) (2025)
- [R2M-Bench: Evaluating Revisit Memory via Relative Consistency in Interactive Video World Models](https://mlsanity.com/paper/2608.27328/) (2026)
- [Structured Pruning for Efficient Visual Place Recognition](https://mlsanity.com/paper/2409.07834/) (2024)
- [To Match or Not to Match: Revisiting Image Matching for Reliable Visual Place Recognition](https://mlsanity.com/paper/2504.06116/) (2025)
- [MMS-VPR: A Fine-Grained Multimodal Street-Level Visual Place Recognition Dataset and Evaluation Benchmark for Dense Pedestrian Environments](https://mlsanity.com/paper/2505.12254/) (2025)
- [Scale, Don't Fine-tune: Guiding Multimodal LLMs for Efficient Visual Place Recognition at Test-Time](https://mlsanity.com/paper/2509.02129/) (2025)
- [Range and Bird's Eye View Fused Cross-Modal Visual Place Recognition](https://mlsanity.com/paper/2502.11742/) (2025)
- [TextInPlace: Indoor Visual Place Recognition in Repetitive Structures with Scene Text Spotting and Verification](https://mlsanity.com/paper/2503.06501/) (2025)
- [EmbodiedPlace: Learning Mixture-of-Features with Embodied Constraints for Visual Place Recognition](https://mlsanity.com/paper/2506.13133/) (2025)
- [VLM-Guided Visual Place Recognition for Planet-Scale Geo-Localization](https://mlsanity.com/paper/2507.17455/) (2025)
- [SAGE: Spatial-visual Adaptive Graph Exploration for Efficient Visual Place Recognition](https://mlsanity.com/paper/2509.25723/) (2025)
- [Learnable Query Aggregation with KV Routing for Cross-view Geo-localisation](https://mlsanity.com/paper/2512.23938/) (2025)
- [Quantile Transfer for Reliable Operating Point Selection in Visual Place Recognition](https://mlsanity.com/paper/2602.04401/) (2026)
- [Region Matters: Efficient and Reliable Region-Aware Visual Place Recognition](https://mlsanity.com/paper/2604.22390/) (2026)
- [A Hyperdimensional One Place Signature to Represent Them All: Stackable Descriptors For Visual Place Recognition](https://mlsanity.com/paper/2412.06153/) (2024)
- [TeTRA-VPR: A Ternary Transformer Approach for Compact Visual Place Recognition](https://mlsanity.com/paper/2503.02511/) (2025)
- [Environmental Change Detection for Real-World Change Analysis](https://mlsanity.com/paper/2506.11481/) (2025)

## Abstract (arXiv)

In visual place recognition, accurately identifying and matching images of locations under varying environmental conditions and viewpoints remains a significant challenge. In this paper, we introduce a new technique, called Bag-of-Queries (BoQ), which learns a set of global queries designed to capture universal place-specific attributes. Unlike existing methods that employ self-attention and generate the queries directly from the input features, BoQ employs distinct learnable global queries, which probe the input features via cross-attention, ensuring consistent information aggregation. In addition, our technique provides an interpretable attention mechanism and integrates with both CNN and Vision Transformer backbones. The performance of BoQ is demonstrated through extensive experiments on 14 large-scale benchmarks. It consistently outperforms current state-of-the-art techniques including NetVLAD, MixVPR and EigenPlaces. Moreover, as a global retrieval technique (one-stage), BoQ surpasses two-stage retrieval methods, such as Patch-NetVLAD, TransVPR and R2Former, all while being orders of magnitude faster and more efficient. The code and model weights are publicly available at https://github.com/amaralibey/Bag-of-Queries.
