Long Context Transfer from Language to Vision

Peiyuan Zhang, Kaichen Zhang, Bo Li, Guangtao Zeng, Jingkang Yang +5 more
6/24/2024
cs.CV

Official code: EvolvingLMMs-Lab/LongVA (413 stars, last commit 2025-03-18).

Abstract

Video sequences offer valuable temporal information, but existing large multimodal models (LMMs) fall short in understanding extremely long videos. Many works address this by reducing the number of visual tokens using visual resamplers. Alternatively, in this paper, we approach this problem from the perspective of the language model. By simply extrapolating the context length of the language backbone, we enable LMMs to comprehend orders of magnitude more visual tokens without any video training. We call this phenomenon long context transfer and carefully ablate its properties. To effectively measure LMMs' ability to generalize to long contexts in the vision modality, we develop V-NIAH (Visual Needle-In-A-Haystack), a purely synthetic long vision benchmark inspired by the language model's NIAH test. Our proposed Long Video Assistant (LongVA) can process 2000 frames or over 200K visual tokens without additional complexities. With its extended context length, LongVA achieves state-of-the-art performance on Video-MME among 7B-scale models by densely sampling more input frames. Our work is open-sourced at https://github.com/EvolvingLMMs-Lab/LongVA.

View on arXivView PDF

Code Implementations(1)

Long Context Transfer from Language to Vision

41318Shell, PythonJun 21, 20241 years agoNOASSERTION

Similar Papers

Cite this paper

@article{zhang2024long,
  title  = {Long Context Transfer from Language to Vision},
  author = {Peiyuan Zhang and Kaichen Zhang and Bo Li and Guangtao Zeng and Jingkang Yang and Yuanhan Zhang and Ziyue Wang and Haoran Tan and Chunyuan Li and Ziwei Liu},
  year   = {2024},
  eprint = {2406.16852},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2406.16852v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2406.16852.svg)](https://codeofpaper.com/paper/2406.16852)

Discussion