# AAformer: Auto-Aligned Transformer for Person Re-Identification

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

## Key facts

- Cited by 48 papers in the map (data through 14 Oct 2026).
- Builds on 59 of its 92 references that are in the map.
- First posted on arXiv 2 Apr 2021.

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

- [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)
- [BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding](https://mlsanity.com/paper/1810.04805/) (2018)
- [Adam: A Method for Stochastic Optimization](https://mlsanity.com/paper/1412.6980/) (2014)
- [An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale](https://mlsanity.com/paper/2010.11929/) (2020)
- [End-to-End Object Detection with Transformers](https://mlsanity.com/paper/2005.12872/) (2020)
- [Layer Normalization](https://mlsanity.com/paper/1607.06450/) (2016)
- [Rethinking the Inception Architecture for Computer Vision](https://mlsanity.com/paper/1512.00567/) (2015)
- [Gaussian Error Linear Units (GELUs)](https://mlsanity.com/paper/1606.08415/) (2016)
- [Unsupervised Learning of Visual Features by Contrasting Cluster Assignments](https://mlsanity.com/paper/2006.09882/) (2020)
- [Sinkhorn Distances: Lightspeed Computation of Optimal Transportation Distances](https://mlsanity.com/paper/1306.0895/) (2013)
- [Non-local Neural Networks](https://mlsanity.com/paper/1711.07971/) (2017)
- [Spatial Transformer Networks](https://mlsanity.com/paper/1506.02025/) (2015)
- [Random Erasing Data Augmentation](https://mlsanity.com/paper/1708.04896/) (2017)
- [In Defense of the Triplet Loss for Person Re-Identification](https://mlsanity.com/paper/1703.07737/) (2017)
- [DensePose: Dense Human Pose Estimation In The Wild](https://mlsanity.com/paper/1802.00434/) (2018)
- [Self-labelling via simultaneous clustering and representation learning](https://mlsanity.com/paper/1911.05371/) (2019)
- [Person Transfer GAN to Bridge Domain Gap for Person Re-Identification](https://mlsanity.com/paper/1711.08565/) (2017)
- [Beyond Part Models: Person Retrieval with Refined Part Pooling (and a Strong Convolutional Baseline)](https://mlsanity.com/paper/1711.09349/) (2017)
- [TransReID: Transformer-based Object Re-Identification](https://mlsanity.com/paper/2102.04378/) (2021)
- [Bag of Tricks and A Strong Baseline for Deep Person Re-identification](https://mlsanity.com/paper/1903.07071/) (2019)
- [Visual Transformers: Token-based Image Representation and Processing for Computer Vision](https://mlsanity.com/paper/2006.03677/) (2020)
- [Omni-Scale Feature Learning for Person Re-Identification](https://mlsanity.com/paper/1905.00953/) (2019)
- [Learning Discriminative Features with Multiple Granularities for Person Re-Identification](https://mlsanity.com/paper/1804.01438/) (2018)
- [Unlabeled Samples Generated by GAN Improve the Person Re-identification Baseline in vitro](https://mlsanity.com/paper/1701.07717/) (2017)
- [Re-ranking Person Re-identification with k-reciprocal Encoding](https://mlsanity.com/paper/1701.08398/) (2017)
- [Joint Discriminative and Generative Learning for Person Re-identification](https://mlsanity.com/paper/1904.07223/) (2019)
- [Harmonious Attention Network for Person Re-Identification](https://mlsanity.com/paper/1802.08122/) (2018)
- [Disentangled Non-Local Neural Networks](https://mlsanity.com/paper/2006.06668/) (2020)
- [Identity-Guided Human Semantic Parsing for Person Re-Identification](https://mlsanity.com/paper/2007.13467/) (2020)

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

- [CLIP-ReID: Exploiting Vision-Language Model for Image Re-Identification without Concrete Text Labels](https://mlsanity.com/paper/2211.13977/) (2022)
- [Dual Cross-Attention Learning for Fine-Grained Visual Categorization and Object Re-Identification](https://mlsanity.com/paper/2205.02151/) (2022)
- [Body Part-Based Representation Learning for Occluded Person Re-Identification](https://mlsanity.com/paper/2211.03679/) (2022)
- [Learning Progressive Modality-shared Transformers for Effective Visible-Infrared Person Re-identification](https://mlsanity.com/paper/2212.00226/) (2022)
- [HAT: Hierarchical Aggregation Transformers for Person Re-identification](https://mlsanity.com/paper/2107.05946/) (2021)
- [Self-Supervised Pre-Training for Transformer-Based Person Re-Identification](https://mlsanity.com/paper/2111.12084/) (2021)
- [Magic Tokens: Select Diverse Tokens for Multi-modal Object Re-Identification](https://mlsanity.com/paper/2403.10254/) (2024)
- [HAP: Structure-Aware Masked Image Modeling for Human-Centric Perception](https://mlsanity.com/paper/2310.20695/) (2023)
- [TOP-ReID: Multi-spectral Object Re-Identification with Token Permutation](https://mlsanity.com/paper/2312.09612/) (2023)
- [QSAN: A Near-term Achievable Quantum Self-Attention Network](https://mlsanity.com/paper/2207.07563/) (2022)
- [Transformer for Object Re-Identification: A Survey](https://mlsanity.com/paper/2401.06960/) (2024)
- [Recent Advances in Vision Transformer: A Survey and Outlook of Recent Work](https://mlsanity.com/paper/2203.01536/) (2022)
- [Cross-Platform Video Person ReID: A New Benchmark Dataset and Adaptation Approach](https://mlsanity.com/paper/2408.07500/) (2024)
- [DC-Former: Diverse and Compact Transformer for Person Re-Identification](https://mlsanity.com/paper/2302.14335/) (2023)
- [When Large Vision-Language Models Meet Person Re-Identification](https://mlsanity.com/paper/2411.18111/) (2024)
- [A Versatile Framework for Multi-scene Person Re-identification](https://mlsanity.com/paper/2403.11121/) (2024)
- [Prototypical Contrastive Learning-based CLIP Fine-tuning for Object Re-identification](https://mlsanity.com/paper/2310.17218/) (2023)
- [Rotation Invariant Transformer for Recognizing Object in UAVs](https://mlsanity.com/paper/2311.02559/) (2023)
- [Other Tokens Matter: Exploring Global and Local Features of Vision Transformers for Object Re-Identification](https://mlsanity.com/paper/2404.14985/) (2024)
- [PersonViT: Large-scale Self-supervised Vision Transformer for Person Re-Identification](https://mlsanity.com/paper/2408.05398/) (2024)
- [PASS: Part-Aware Self-Supervised Pre-Training for Person Re-Identification](https://mlsanity.com/paper/2203.03931/) (2022)
- [Unity is Strength: Unifying Convolutional and Transformeral Features for Better Person Re-Identification](https://mlsanity.com/paper/2412.17239/) (2024)
- [LATex: Leveraging Attribute-based Text Knowledge for Aerial-Ground Person Re-Identification](https://mlsanity.com/paper/2503.23722/) (2025)
- [SD-ReID: View-aware Stable Diffusion for Aerial-Ground Person Re-Identification](https://mlsanity.com/paper/2504.09549/) (2025)
- [MDReID: Modality-Decoupled Learning for Any-to-Any Multi-Modal Object Re-Identification](https://mlsanity.com/paper/2510.23301/) (2025)
- [Transformer Based Multi-Grained Features for Unsupervised Person Re-Identification](https://mlsanity.com/paper/2211.12280/) (2022)
- [Attention Disturbance and Dual-Path Constraint Network for Occluded Person Re-identification](https://mlsanity.com/paper/2303.10976/) (2023)
- [PersonMAE: Person Re-Identification Pre-Training with Masked AutoEncoders](https://mlsanity.com/paper/2311.04496/) (2023)
- [Pose-dIVE: Pose-Diversified Augmentation with Diffusion Model for Person Re-Identification](https://mlsanity.com/paper/2406.16042/) (2024)
- [Exploring Part-Informed Visual-Language Learning for Person Re-Identification](https://mlsanity.com/paper/2308.02738/) (2023)

## Abstract (arXiv)

In person re-identification (re-ID), extracting part-level features from person images has been verified to be crucial to offer fine-grained information. Most of the existing CNN-based methods only locate the human parts coarsely, or rely on pretrained human parsing models and fail in locating the identifiable nonhuman parts (e.g., knapsack). In this article, we introduce an alignment scheme in transformer architecture for the first time and propose the auto-aligned transformer (AAformer) to automatically locate both the human parts and nonhuman ones at patch level. We introduce the "Part tokens ([PART]s)", which are learnable vectors, to extract part features in the transformer. A [PART] only interacts with a local subset of patches in self-attention and learns to be the part representation. To adaptively group the image patches into different subsets, we design the auto-alignment. Auto-alignment employs a fast variant of optimal transport (OT) algorithm to online cluster the patch embeddings into several groups with the [PART]s as their prototypes. AAformer integrates the part alignment into the self-attention and the output [PART]s can be directly used as part features for retrieval. Extensive experiments validate the effectiveness of [PART]s and the superiority of AAformer over various state-of-the-art methods.
