Efficient In-Context Learning in Vision-Language Models for Egocentric Videos

Keunwoo Peter Yu, Zheyuan Zhang, Fengyuan Hu, Joyce Chai · OpenReview

TL;DR

This paper introduces EILeV, a novel training paradigm for vision-language models (VLMs) that enables in-context learning for egocentric videos without massive, naturalistic datasets. EILeV leverages specific data distribution properties (bursty, skewed, dynamic meaning) and architectural tweaks to significantly outperform larger, off-the-shelf VLMs in few-shot video narration, especially for rare and out-of-distribution actions.

What Problem Does This Paper Address?

Large Language Models (LLMs) have shown remarkable in-context learning (ICL) capabilities, allowing them to adapt to new tasks with just a few examples, bypassing expensive fine-tuning. However, extending this to Vision-Language Models (VLMs) for video understanding, particularly egocentric videos, has been challenging. While large VLMs exist, they often lack effective ICL for video. This is partly due to the difficulty and cost of collecting massive, naturalistic egocentric video datasets that might inherently foster ICL. The authors aim to bridge this gap by developing a training method that elicits ICL in VLMs for egocentric videos, even with smaller, curated datasets.

Methods

The core contribution is the Emergent In-context Learning on Videos (EILeV) training paradigm. EILeV is built upon three key distributional properties of training data identified in prior work for text-only LLMs:

  1. Bursty Distributions: Data where related entities appear in clusters. EILeV implements this by sampling in-context examples that share verb or noun classes with the query, but not both simultaneously, creating "bursts" of related concepts.
  2. Skewed Marginal Distributions: Data with a long tail of infrequent items (like rare actions). EILeV utilizes the inherent skewness of the Ego4D dataset's verb-noun classes, specifically by designating common actions for training and rare actions for evaluation.
  3. Dynamic Meaning: Entities having multiple interpretations or synonyms. EILeV leverages this by using natural language narrations that contain synonyms and homonyms, and by canonicalizing verbs and nouns to their classes.

Beyond data properties, EILeV involves architectural modifications to a BLIP-2 model to handle interleaved video clips and text, enabling it to process contexts with both modalities. The training objective is to maximize the likelihood of the ground-truth narration given the context and query video.

Datasets

  • Ego4D: Used for training and evaluating the EILeV models. This dataset is chosen for its rich annotations of egocentric videos, including human-written narrations, verb classes, and noun classes, which are crucial for implementing and ablating the distributional properties.
  • EPIC-KITCHENS-100: Used for evaluating the generalization capabilities of the trained models to out-of-distribution actions. This dataset presents a distributional shift from Ego4D, making it a good testbed for robustness.

Key Insights and Ideas

  • Data Distribution Matters for Video ICL: The study strongly suggests that the same data distributional properties (bursty, skewed, dynamic meaning) that induce ICL in text-only models are also crucial for VLMs processing video. This is a significant finding, extending prior work to the multimodal domain.
  • Targeted Training Outperforms Scale: EILeV-trained models, despite being smaller and trained on less data than large off-the-shelf VLMs like Kosmos-2 and Otter, significantly outperform them in few-shot video narration. This highlights the power of a focused training approach.
  • Bursty and Skewed Distributions are Key: Ablation studies reveal that bursty and skewed marginal distributions contribute most significantly to the in-context learning capabilities of VLMs for video narration. Dynamic meaning also plays a role, but to a lesser extent.
  • ICL vs. In-Weights Learning Trade-off: The paper provides evidence for the trade-off between in-context learning and in-weights learning, where models optimized for ICL might show weaker performance in zero-shot settings (relying on pre-trained knowledge).

Key Results

  • Superior Few-Shot Performance: EILeV-trained models consistently outperform off-the-shelf VLMs (Kosmos-2, Otter) on rare and out-of-distribution egocentric video narration tasks as the number of in-context examples (shots) increases.
  • Generalization to Novel Actions: The models demonstrate strong generalization to novel, rare actions not seen during training, a key motivation for the work.
  • Ablation Impact: Removing bursty distributions significantly degrades ICL capabilities. Reducing skewness (using fewer common actions) also harms performance, while increasing skewness improves it. Dynamic meaning has a less pronounced but still notable impact, particularly on semantic similarity metrics.
  • Model Size vs. Training Strategy: EILeV-trained BLIP-2 models (188M parameters) outperform larger models like Kosmos-2 (1.6B) and Otter (1.3B) in few-shot scenarios, demonstrating that effective training strategies can compensate for model scale.

Limitations and Future Work

  • Domain Specificity: The current EILeV models are optimized for action narration in egocentric videos. Generalizing to other video understanding tasks or different domains might require further adaptation.
  • Potential for Harmful Content: Like all models trained on large datasets, EILeV models may inherit biases from their frozen language models, potentially generating harmful content. Safety measures like guardrails and data sanitization are recommended before deployment.
  • In-Weights vs. In-Context Balance: The paper notes the trade-off between in-context and in-weights learning and suggests future work on finding the optimal balance.
  • Broader Applications: EILeV is presented as a foundation for building VLMs capable of in-context learning on video and text for a wider range of tasks and domains. The authors release their code and models to facilitate future research.

Summary updated

BibTeX
@inproceedings{yu2024efficient,
  author = {Keunwoo Peter Yu and Zheyuan Zhang and Fengyuan Hu and Joyce Chai},
  title = {{Efficient In-Context Learning in Vision-Language Models for Egocentric Videos}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2024},
  url = {https://openreview.net/forum?id=UhrS65Apq8},
}
Figure