Skip to main content
QUICK REVIEW

[Paper Review] CLIP-ReID: Exploiting Vision-Language Model for Image Re-Identification without Concrete Text Labels

Siyuan Li, Sun Li|arXiv (Cornell University)|Nov 25, 2022
Multimodal Machine Learning ApplicationsComputer Science9 citations
TL;DR

This paper proposes CLIP-ReID, a two-stage method that leverages CLIP's vision-language pre-training for image re-identification without concrete text labels. By introducing learnable text tokens per ID and optimizing them in a contrastive manner before fine-tuning the image encoder with cross-modal supervision, the approach achieves state-of-the-art performance on person and vehicle ReID benchmarks, outperforming existing methods by up to 2.4% mAP gain.

ABSTRACT

Pre-trained vision-language models like CLIP have recently shown superior performances on various downstream tasks, including image classification and segmentation. However, in fine-grained image re-identification (ReID), the labels are indexes, lacking concrete text descriptions. Therefore, it remains to be determined how such models could be applied to these tasks. This paper first finds out that simply fine-tuning the visual model initialized by the image encoder in CLIP, has already obtained competitive performances in various ReID tasks. Then we propose a two-stage strategy to facilitate a better visual representation. The key idea is to fully exploit the cross-modal description ability in CLIP through a set of learnable text tokens for each ID and give them to the text encoder to form ambiguous descriptions. In the first training stage, image and text encoders from CLIP keep fixed, and only the text tokens are optimized from scratch by the contrastive loss computed within a batch. In the second stage, the ID-specific text tokens and their encoder become static, providing constraints for fine-tuning the image encoder. With the help of the designed loss in the downstream task, the image encoder is able to represent data as vectors in the feature embedding accurately. The effectiveness of the proposed strategy is validated on several datasets for the person or vehicle ReID tasks. Code is available at https://github.com/Syliz517/CLIP-ReID.

Motivation & Objective

  • To address the challenge of applying pre-trained vision-language models like CLIP to image re-identification, where labels are identity indices without descriptive text.
  • To explore how CLIP's cross-modal understanding can be harnessed in ReID despite the absence of concrete textual descriptions for identities.
  • To develop a method that enables effective feature learning in ReID by generating ambiguous, ID-specific textual descriptions through learnable tokens.
  • To validate the effectiveness of the proposed two-stage training strategy on both CNN and Vision Transformer backbones across multiple ReID datasets.

Proposed method

  • Introduces a set of learnable text tokens per identity to form ambiguous textual descriptions, replacing concrete labels.
  • In the first stage, the image and text encoders from CLIP are fixed, and only the learnable text tokens are optimized using contrastive loss within a batch.
  • In the second stage, the optimized text tokens and CLIP's text encoder are frozen, and they provide cross-modal supervision to fine-tune the image encoder.
  • Uses a combined loss function including identity loss ($\mathcal{L}_{id}$), triplet loss ($\mathcal{L}_{tri}$), and image-to-text contrastive loss ($\mathcal{L}_{i2tce}$) to refine the image encoder.
  • Employs SIE (Spatial-Enhanced Prompt) and OLP (Occlusion-robust Prompt) techniques to improve feature robustness and generalization in the ViT-based model.
  • Supports both ResNet-50 and ViT-B/16 backbones, with ablation studies on token count (M=4), loss components, and prompt engineering.

Experimental results

Research questions

  • RQ1Can CLIP's vision-language pre-training be effectively leveraged in image re-identification when no concrete text descriptions are available for identities?
  • RQ2Does a two-stage training strategy—first optimizing learnable text tokens and then using them to supervise image encoder fine-tuning—yield better performance than joint optimization?
  • RQ3How does the use of ambiguous, ID-specific learnable text tokens compare to using fixed or prompt-based text descriptions in ReID?
  • RQ4What is the optimal configuration of learnable text tokens (e.g., number M) and loss components for maximizing ReID performance?
  • RQ5Can the proposed method improve feature discriminativeness and robustness compared to standard ReID baselines?

Key findings

  • The two-stage training strategy significantly outperforms one-stage training, achieving 73.4% mAP and 88.7% Rank-1 on MSMT17 with ViT-B/16, compared to 68.9% mAP and 85.9% Rank-1 in the one-stage variant.
  • Using all IDs in the training set for the image-to-text contrastive loss ($\mathcal{L}_{i2tce}$) yields better performance than using only the current batch, with a 2.4% mAP improvement when combining $\mathcal{L}_{id}$, $\mathcal{L}_{tri}$, and $\mathcal{L}_{i2tce}$.
  • The combination of SIE-cls and OLP techniques improves mAP by 2.4% and Rank-1 by 1.0% on MSMT17, demonstrating their effectiveness in enhancing feature quality.
  • Setting the number of learnable text tokens (M) to 4 achieves the best performance, as M=1 is insufficient and M=8 becomes redundant.
  • The method achieves state-of-the-art performance on multiple person and vehicle ReID datasets, with the ViT-based model outperforming the ResNet-50 version on all benchmarks.
  • Visualization shows that CLIP-ReID attends to more holistic body regions compared to baseline models that focus on local, discriminative patches.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.