Papers
Topics
Authors
Recent
Search
2000 character limit reached

CMLReID: CLIP-Based Lifelong ReID

Updated 11 July 2026
  • The paper introduces CMLReID, a novel CLIP-based framework that jointly addresses same-clothing and clothing-change scenarios under lifelong learning.
  • It employs Context-Aware Semantic Prompt and Adaptive Knowledge Fusion modules to adapt visual-text representations and mitigate catastrophic forgetting.
  • Experimental results show significant improvements in mAP and Rank-1 accuracy across multiple ReID datasets, demonstrating robust intra- and inter-domain generalization.

CMLReID is a CLIP-based framework for lifelong person re-identification under hybrid clothing conditions, introduced for the LReID-Hybrid task, where a model must handle both same-clothing (SC) and clothing-change (CC) cases while learning sequentially across tasks without catastrophic forgetting (Long et al., 14 Sep 2025). The formulation addresses a gap in prior practice: previous existing methods either develop models specifically for one application, which is mostly a same-cloth setting, or treat CCReID as its own separate sub-problem. CMLReID targets mismatched representations and forgetting through two modules, Context-Aware Semantic Prompt (CASP) and Adaptive Knowledge Fusion and Projection (AKFP), with the stated goal of robust performance on seen domains and generalization to unseen SC/CC datasets (Long et al., 14 Sep 2025).

1. LReID-Hybrid task formulation

The LReID-Hybrid setting is defined over a continual stream of ReID tasks indexed by t=1,,Tt=1,\dots,T. At step tt, the model observes a labeled dataset

D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},

where Ii(t)I_i^{(t)} is the ii-th person image, yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\} is its identity label, and si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\} indicates clothing state (Long et al., 14 Sep 2025). In this formulation, SC means the identity has not changed outfit versus its gallery images, whereas CC means the person is in different attire.

The lifelong objective is to learn sequentially on D(1),,D(T)\mathcal{D}^{(1)},\dots,\mathcal{D}^{(T)} and then perform ReID robustly on all seen domains while also generalizing to unseen SC/CC datasets, without catastrophic forgetting (Long et al., 14 Sep 2025). This definition is significant because it turns SC and CC from isolated evaluation regimes into a joint continual-learning problem. A plausible implication is that hybrid clothing-state ReID is treated not merely as a robustness issue, but as a domain-sequential representation learning problem.

2. Core architecture

CMLReID builds upon CLIP, using a Vision Transformer EVE_V (ViT-B/16) for images and a text encoder ETE_T (Long et al., 14 Sep 2025). The architecture is organized as a two-stage pipeline.

In Stage A, the Context-Aware Semantic Prompt module first computes a visual embedding

tt0

A context encoder tt1, described as a small MLP with self-attention, maps tt2 to a context vector

tt3

Base semantic tokens tt4 and dynamic tokens

tt5

are concatenated to form

tt6

and the text encoder produces

tt7

for cross-modal alignment (Long et al., 14 Sep 2025).

In Stage B, the Adaptive Knowledge Fusion and Projection module maintains slow-updated text prototypes for each clothing state tt8: tt9 The model also predicts a clothing-state distribution from the visual feature,

D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},0

and applies two projection heads D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},1 and D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},2. The fused projection is

D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},3

which is then aligned to the corresponding slow prototype D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},4 (Long et al., 14 Sep 2025).

Architecturally, the framework is multimodal in a strict sense: visual features are not merely paired with fixed text templates, but are used to generate adaptive prompts and state-specific projections. This suggests that CMLReID treats clothing-state variation as both a semantic alignment problem and a continual memory problem.

3. Context-Aware Semantic Prompt

CASP is designed to address multi-grained representation mismatches by conditioning the text prompt on visual context (Long et al., 14 Sep 2025). Its computations are

D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},5

followed by

D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},6

The role of CASP is not only to generate adaptive prompts, but also to incorporate context so as to align richly multi-grained visual cues with semantic text space (Long et al., 14 Sep 2025). Cross-modal alignment is encouraged by standard contrastive or classification losses between D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},7 and D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},8. The paper specifies that this allows D(t)={(Ii(t),yi(t),si(t))}i=1Nt,\mathcal{D}^{(t)}=\bigl\{(I_i^{(t)},y_i^{(t)},s_i^{(t)})\bigr\}_{i=1}^{N_t},9 to adapt its semantic granularity, for example by focusing on clothing details for SC or on body-shape cues for CC (Long et al., 14 Sep 2025).

This design is important because SC and CC emphasize different discriminative signals. In SC, garment-specific information is often informative; in CC, such cues become unstable, making body-shape and other intrinsic identity traits more salient. CASP operationalizes this distinction at the prompt level rather than through separate models.

4. Adaptive Knowledge Fusion and Projection

AKFP comprises a dual-path slow learner, a state-conditioned fusion mechanism, and the Clothing-State-Aware Projection Loss (Long et al., 14 Sep 2025). For each state Ii(t)I_i^{(t)}0, the framework maintains a long-term prototype Ii(t)I_i^{(t)}1. At task iteration Ii(t)I_i^{(t)}2,

Ii(t)I_i^{(t)}3

where Ii(t)I_i^{(t)}4 is a small momentum, with an example value Ii(t)I_i^{(t)}5, and Ii(t)I_i^{(t)}6 is the subset of the batch with state Ii(t)I_i^{(t)}7 (Long et al., 14 Sep 2025).

The state-aware fusion is followed by the projection loss

Ii(t)I_i^{(t)}8

which is the average cosine-distance to the correct state prototype (Long et al., 14 Sep 2025). By slowly updating Ii(t)I_i^{(t)}9 across tasks and aligning each incoming fused projection ii0 to the corresponding prototype, the network retains long-term, state-specific knowledge and resists overwriting earlier representations.

A recurrent misconception in continual learning is that robustness necessarily requires an explicit replay buffer. CMLReID explicitly states that no explicit replay buffer is needed; the slow-learner prototypes serve as implicit memory, and the small momentum ii1 ensures stability against forgetting (Long et al., 14 Sep 2025). Within the framework’s own logic, the prototypes are therefore both semantic anchors and continual-learning memory states.

5. Optimization procedure and empirical results

Training follows an alternating optimization strategy (Long et al., 14 Sep 2025). The CASP stage, given as an example of 120 epochs, optimizes ii2, ii3, and ii4 to produce high-quality ii5. The AKFP stage, given as an example of 60 epochs, updates ii6, ii7, ii8, and ii9 using the refined yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}0 and prototypes yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}1.

The AKFP stage uses the joint loss

yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}2

where yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}3 is cross-entropy on identity, yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}4 is a standard triplet loss with margin yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}5, and yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}6 balances the projection term (Long et al., 14 Sep 2025).

The evaluation protocol spans seen and unseen SC/CC domains, with mean Average Precision (mAP) and Rank-1 (R-1) as metrics, and six lifelong orders such as Market→LTCC→MSMT→PRCC (Long et al., 14 Sep 2025).

Split Datasets
Seen (training) SC Market-1501, MSMT17
Seen (training) CC LTCC, PRCC
Unseen SC CUHK01/02, GRID, SenseReID, PRID
Unseen CC VC-Clothes, Celeb-ReID

On Order 1, for the seen domains average, CMLReID achieves Total-Avg mAP yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}7 and R-1 yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}8, outperforming the next best CLIP-ReID by about yi(t){1,,Ct}y_i^{(t)}\in\{1,\dots,C_t\}9 percentage points in mAP and si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}0 percentage points in R-1 (Long et al., 14 Sep 2025). The framework is also reported to remain stable across all six learning orders, always exceeding baselines by about si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}1–si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}2 percentage points in mAP, and on unseen SC/CC datasets it consistently exceeds baselines by si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}3–si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}4 percentage points in mAP (Long et al., 14 Sep 2025).

Ablation results on Order 1 isolate the contribution of each major component.

Variant Tot-Avg mAP / R-1
si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}5CASP (fixed prompts) si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}6
si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}7dynamic context in CASP si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}8
si(t){SC,CC}s_i^{(t)}\in\{\mathrm{SC},\mathrm{CC}\}9AKFP (single projection, no D(1),,D(T)\mathcal{D}^{(1)},\dots,\mathcal{D}^{(T)}0, no slow-learner) D(1),,D(T)\mathcal{D}^{(1)},\dots,\mathcal{D}^{(T)}1
%%%%6Ii(t)I_i^{(t)}6%%%%3 only D(1),,D(T)\mathcal{D}^{(1)},\dots,\mathcal{D}^{(T)}4
D(1),,D(T)\mathcal{D}^{(1)},\dots,\mathcal{D}^{(T)}5single prototype (no dual-path) D(1),,D(T)\mathcal{D}^{(1)},\dots,\mathcal{D}^{(T)}6

These drops confirm each component’s necessity (Long et al., 14 Sep 2025). In interpretive terms, the ablation pattern indicates that prompt adaptation, state-aware projection, and slow prototype updates contribute complementary forms of robustness rather than redundant ones.

6. Position within ReID research and open directions

CMLReID belongs to a broader family of ReID methods that use memory structures, multimodal alignment, or contrastive objectives, but its defining contribution is the joint treatment of SC and CC in a continual setting. This can be clarified by comparison with adjacent lines of work represented in the contemporary literature.

Prototype-based memory has appeared in large-scale unsupervised ReID through Meta Clustering Learning, where a subset of unlabeled data is clustered, the resulting cluster centroids are treated as meta-prototypes, and the remaining data are softly annotated for further polishing (Jin et al., 2021). Multi-memory design has also been explored in unsupervised visible-infrared ReID: the MMM framework uses Cross-Modality Clustering, Multi-Memory Learning and Matching, and Soft Cluster-level Alignment, subdividing each identity into multiple sub-memories to establish cross-modality correspondences (Shi et al., 2024). Weakly supervised ReID has pursued a different route: CMIL learns from noisy bag-level labels with a single model, bag embeddings, and contrastive bag-level triplet losses, then discards the aggregator at test time and ranks crops via instance embeddings (Tyo et al., 2024). At the system level, spatio-temporal structuring has been used in multi-camera vehicle tracking through a trajectory-based Camera Link Model and temporal-attention ReID, where transition-time windows prune impossible cross-camera matches (Hsu et al., 2020).

Against this background, CMLReID’s distinctive formulation is not merely “multimodal” or “prototype-based.” It combines CLIP-derived visual-text alignment, context-conditioned prompt generation, clothing-state-aware projection, and implicit continual memory for hybrid SC/CC learning (Long et al., 14 Sep 2025). This suggests that its novelty lies in the coupling of semantic prompting and state-specific continual retention, rather than in any single component viewed in isolation.

The limitations and future directions stated for CMLReID are also specific. The context encoder’s accuracy in marginal cases, particularly ambiguous attire change, can be further improved (Long et al., 14 Sep 2025). Extending the framework to video sequences or adding other modalities such as pose and depth could enhance fine-grained discrimination, and reducing prompt-generation overhead or exploring prompt-efficiency through prompt expert mixtures may speed up inference (Long et al., 14 Sep 2025). These points indicate that the current formulation is best understood as a principled baseline for lifelong hybrid-clothing ReID rather than a closed solution to all clothing-variation and continual-learning scenarios.

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to CMLReID.