arXiv:2412.09919cs.CVcs.AI2024-12ICCV被引 7

平衡视频时空信息,减少视觉令牌数以提升长视频理解能力

B-VLLM: A Vision Large Language Model with Balanced Spatio-Temporal Tokens

  • 根据文本任务动态选择关键帧,结合时空合并技术控制令牌数量
  • 在多个视频理解基准上超越现有模型,保持高精度与低计算开销
  • 适合需要高效处理长视频的场景,如智能监控、视频摘要

近期,融合视觉编码器的视觉大语言模型(VLLM)在视觉理解任务中展现出优异性能。其核心是将视觉内容编码为视觉令牌序列,使模型可同时处理视觉与文本信息。然而,长视频的视觉理解仍是挑战,因视频编码产生的视觉令牌数量急剧增长,易超出VLLM上下文窗口并带来沉重计算负担。现有方法要么对视频均匀下采样至固定帧数,要么减少每帧的视觉令牌数,前者忽略视频中的丰富时序线索,后者忽视帧内空间细节。本文提出平衡型视觉大语言模型(B-VLLM),通过文本条件自适应帧选择模块识别与任务相关的关键帧,并采用时间帧令牌合并技术去重。随后,利用空间令牌采样模块及可选的空间令牌合并策略,精确控制令牌总数。实验表明,B-VLLM能有效平衡帧数与视觉令牌数,在多个视频理解基准上表现更优。代码已开源。

原文摘要 · Abstract (English)

Recently, Vision Large Language Models (VLLMs) integrated with vision encoders have shown promising performance in vision understanding. The key of VLLMs is to encode visual content into sequences of visual tokens, enabling VLLMs to simultaneously process both visual and textual content. However, understanding videos, especially long videos, remain a challenge to VLLMs as the number of visual tokens grows rapidly when encoding videos, resulting in the risk of exceeding the context window of VLLMs and introducing heavy computation burden. To restrict the number of visual tokens, existing VLLMs either: (1) uniformly downsample videos into a fixed number of frames or (2) reducing the number of visual tokens encoded from each frame. We argue the former solution neglects the rich temporal cue in videos and the later overlooks the spatial details in each frame. In this work, we present Balanced-VLLM (B-VLLM): a novel VLLM framework that aims to effectively leverage task relevant spatio-temporal cues while restricting the number of visual tokens under the VLLM context window length. At the core of our method, we devise a text-conditioned adaptive frame selection module to identify frames relevant to the visual understanding task. The selected frames are then de-duplicated using a temporal frame token merging technique. The visual tokens of the selected frames are processed through a spatial token sampling module and an optional spatial token merging strategy to achieve precise control over the token count. Experimental results show that B-VLLM is effective in balancing the number of frames and visual tokens in video understanding, yielding superior performance on various video understanding benchmarks. Our code is available at https://github.com/zhuqiangLu/B-VLLM.

视觉语言模型视频理解令牌控制

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。