Improved Hard Example Mining by Discovering Attribute-based Hard Person Identity

Xiao Wang, Ziliang Chen, Rui Yang, Bin Luo, Jin TangarXiv 2019 · arXiv

Introduction

Person Re-identification (re-ID) is the task of recognizing the same individual across non-overlapping camera views. A common training paradigm involves the triplet loss, which aims to minimize the distance between an anchor and a positive sample (same identity) while maximizing the distance between the anchor and a negative sample (different identity). To optimize this, researchers typically employ "hard example mining," selecting the most difficult samples to challenge the model.

The Problem with Local Mining

Standard hard example mining is often "local," meaning it only searches for difficult examples within a small mini-batch. As datasets scale to thousands of identities, the probability of a random mini-batch containing a truly challenging "global" look-alike—someone who shares many physical attributes with the anchor—becomes very low. This leads to inefficient training and models that struggle to distinguish between visually similar individuals in real-world scenarios.

Proposed Method: Hard Person Identity Mining (HPIM)

The authors propose a two-stage framework, Hard Person Identity Mining (HPIM), to address this limitation by leveraging shared physical attributes to identify global hard negatives.

Comparison of local vs. global hard negative mining in mini-batches.

1. Attribute Describer Encoding

The model first learns to represent individuals through a set of semantic attributes (e.g., clothing type, hair color). To handle noisy or unlabeled data, the authors use a Self-Paced Learning (SPL) curriculum, starting with high-confidence samples. Attributes are grouped into semantically exclusive categories to manage complexity.

2. Global Identity Mining

Instead of treating identities as single points, HPIM treats each person as a distribution of attribute codes. The Central Moment Discrepancy (CMD) is used to measure the statistical distance between these distributions. Identities with low CMD scores are considered "globally" hard to distinguish.

3. Stochastic Batch Sampling

Rather than random sampling, mini-batches are constructed by purposefully selecting these "hard identities" based on their attribute similarity. This ensures the model consistently encounters challenging negative pairs during training, moving beyond the limitations of local batch constraints.

4. Improved Triplet Loss

A regularization term is added to the triplet loss, encouraging individual image embeddings to remain close to the average representation of their respective identity, which stabilizes the embedding space.

Experimental Results

The HPIM framework was evaluated on standard benchmarks including Market-1501 and CUHK03. The method demonstrated significant performance gains:

  • Market-1501: Achieved a Rank-1 accuracy of 79.6% and a Mean Average Precision (mAP) of 62.2%.
  • CUHK03: Achieved a Rank-1 accuracy of 65.5%.
  • Attribute Recognition: Their semi-supervised approach on the PETA dataset reached 84.9% accuracy, outperforming several dedicated baselines.

Ablation studies confirmed that constructing mini-batches using global identity mining (HPIM) is substantially more effective than standard local mining.

Conclusion and Future Work

HPIM demonstrates that visual attributes serve as a stable and effective proxy for identity difficulty. By moving from local to global hard example mining, the model can better navigate the complexities of large-scale person re-identification. Future research may focus on incorporating spatial correlations of attributes and exploring more robust sample selection methods, such as Deep Reinforcement Learning, to further mitigate noise in semi-supervised learning.

Summary updated

Abstract

In this paper, we propose Hard Person Identity Mining (HPIM) that attempts to refine the hard example mining to improve the exploration efficacy in person re-identification. It is motivated by following observation: the more attributes some people share, the more difficult to separate their identities. Based on this observation, we develop HPIM via a transferred attribute describer, a deep multi-attribute classifier trained from the source noisy person attribute datasets. We encode each image into the attribute probabilistic description in the target person re-ID dataset. Afterwards in the attribute code space, we consider each person as a distribution to generate his view-specific attribute codes in different practical scenarios. Hence we estimate the person-specific statistical moments from zeroth to higher order, which are further used to calculate the central moment discrepancies between persons. Such discrepancy is a ground to choose hard identity to organize proper mini-batches, without concerning the person representation changing in metric learning. It presents as a complementary tool of hard example mining, which helps to explore the global instead of the local hard example constraint in the mini-batch built by randomly sampled identities. Extensive experiments on two person re-identification benchmarks validated the effectiveness of our proposed algorithm.
BibTeX
@misc{wang2019improved,
  author = {Xiao Wang and Ziliang Chen and Rui Yang and Bin Luo and Jin Tang},
  title = {{Improved Hard Example Mining by Discovering Attribute-based Hard Person Identity}},
  year = {2019},
  eprint = {1905.02102},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1905.02102},
}
Figure