MA-FSAR: Multimodal Adaptation of CLIP for few-shot action recognition

Jiazheng Xing, Jian Zhao, Chao Xu, Mengmeng Wang, Guang Dai, Yong Liu, Jingdong Wang, Xuelong Li

TL;DR

This paper introduces MA-FSAR, a novel framework that efficiently adapts the powerful CLIP model for few-shot action recognition (FSAR). By employing parameter-efficient fine-tuning (PEFT) and a fine-grained multimodal adaptation strategy, MA-FSAR significantly boosts performance while drastically reducing computational costs compared to full fine-tuning methods.

What Problem Does This Paper Address?

Few-shot action recognition (FSAR) is a challenging task that requires models to quickly learn new action categories from very limited labeled data. Traditional approaches often rely on metric-based meta-learning, which can be computationally expensive and time-consuming. While large vision-language models like CLIP have shown promise, adapting them for FSAR typically involves full-parameter fine-tuning of their visual encoders. This is computationally demanding and overlooks the potential to leverage CLIP's multimodal capabilities for better temporal modeling and semantic understanding directly within the encoder. The paper aims to bridge this gap by proposing an efficient adaptation method that enhances CLIP's visual encoder for FSAR without extensive parameter updates.

Methods

MA-FSAR builds upon CLIP's pre-trained visual and text encoders. The core innovation lies in its Fine-grained Multimodal Adaptation (FgMA), which uses Parameter-Efficient Fine-Tuning (PEFT) techniques. FgMA introduces lightweight adapters into CLIP's Vision Transformer (ViT) blocks, freezing the original weights. It comprises three key components:

  • Global Temporal Adaptation: This module focuses solely on the class token to efficiently capture global motion cues across frames, reducing computational overhead.
  • Local Spatiotemporal/Multimodal Adaptation: This component injects the global temporal cues into local visual tokens. For the query branch, it performs local spatiotemporal modeling. For the support branch, it integrates text features specific to the FSAR support set, enabling multimodal modeling to highlight action semantics.
  • Joint Adaptation: This final step tunes the representations by adding adapters parallel to the MLP layer in the ViT blocks, ensuring consistency across layers.

Additionally, a Text-guided Prototype Construction Module (TPCM) is introduced to enrich video prototypes by leveraging cross-attention between adapted visual features and text features, improving class prototype matching.

Datasets

The paper evaluates MA-FSAR on five widely used datasets:

  • Spatial-related: Kinetics, HMDB51, UCF101
  • Temporal-related: SSv2-Full, SSv2-Small

Key Insights and Ideas

  • PEFT is sufficient for FSAR: The paper demonstrates that parameter-efficient fine-tuning, rather than full fine-tuning, is highly effective for adapting large models like CLIP to FSAR, significantly reducing computational burden.
  • Multimodal fusion at the token level: Integrating text features directly into the visual encoder's token processing (FgMA) is crucial for enhancing both temporal and semantic understanding, leading to more discriminative features.
  • Global-to-local temporal modeling: The hierarchical approach of first capturing global motion cues and then refining them with local spatiotemporal and multimodal information proves effective.
  • Text-guided prototypes matter: Leveraging text descriptions to guide the construction of class prototypes (TPCM) significantly improves the quality of prototypes and subsequent matching.
  • MA-FSAR is versatile: The framework is shown to be plug-and-play, performing well with various temporal alignment metrics.

Key Results

  • MA-FSAR achieves state-of-the-art performance on multiple datasets, including SSv2-Small and Kinetics, often outperforming methods with full fine-tuning or other PEFT approaches.
  • On SSv2-Small, MA-FSAR with CLIP-ViT-B/16 (PEFT) achieves 83.4% accuracy in 1-shot and 87.9% in 5-shot settings, significantly outperforming previous methods.
  • The proposed FgMA module alone provides substantial accuracy improvements (e.g., 13.5% on SSv2-Small), and TPCM further boosts performance.
  • MA-FSAR uses a fraction of the trainable parameters compared to full fine-tuning methods (e.g., 18.5M vs. 90.99M for ViT-B/32), leading to faster training times and reduced memory usage.
  • The method also shows strong zero-shot performance, outperforming baselines like CLIP-FSAR and AIM.

Limitations and Future Work

  • Data-driven approach: The current method is data-driven, and the authors suggest exploring improved utilization of Large Language Models (LLMs) to develop knowledge-driven FSAR methods for enhanced generalization.
  • Hyperparameter tuning: While optimal values are found for scaling factor r (0.5) and loss factor a (0.75 for spatial, 0.25 for temporal), further exploration of these could yield marginal improvements.
  • Prompt template impact: While a "mixture" approach for prompt templates is proposed to balance dataset preferences, specific prompt engineering might still offer further gains.

Summary updated

BibTeX
@article{xing2024ma,
  author = {Jiazheng Xing and Jian Zhao and Chao Xu and Mengmeng Wang and Guang Dai and Yong Liu and Jingdong Wang and Xuelong Li},
  title = {{MA-FSAR: Multimodal Adaptation of CLIP for few-shot action recognition}},
  journal = {Pattern Recognition},
  year = {2024},
}
Figure