Awesome
TimeMarker: A Versatile Video-LLM for Long and Short Video Understanding with Superior Temporal Localization Ability
<img width="900" src="https://github.com/TimeMarker-LLM/TimeMarker/blob/main/assets/logo_w_name.jpg">Introduction
Recent advancements in the realm of video-language models have predominantly focused on visual perception and reasoning, leading to less emphasis on temporal localization and detection capabilities. Current models, while trained extensively on video captioning and QA datasets, struggle with placing precise temporal references within video content. Although many Video-LLMs incorporate temporal embedding into video features, this approach still has significant drawbacks. Specifically, these models can only perceive relative time—such as the sequence of events rather than absolute time points, like the exact second an event occurs. This lack of precise temporal grounding leads to less interpretable and verifiable responses, and poses challenges for subsequent temporal reasoning and inference. To address these limitations, we present TimeMarker, a versatile Video-LLM designed for high-quality dialogue based on video content, featuring robust temporal localization abilities.
Key Innovations:
-
Temporal Separator Tokens Integration: TimeMarker uses Temporal Separator Tokens Integration to enhance temporal awareness in videos. By interleaving textual temporal separator tokens (e.g., sec{20}) with video frame tokens, this method encodes the absolute temporal positions of video frames. These tokens serve as precise time markers, allowing the model to identify and reference specific moments within the video.
-
AnyLength Mechanism: To process videos of varying lengths efficiently, TimeMarker employs the AnyLength mechanism, which uses dynamic frame sampling and adaptive token resizing/merging. This mechanism adjusts the frames per second (FPS) when sample video frames and modify token compression ratio when adaptively merge tokens in a single video frame based on the video's length, ensuring comprehensive coverage of various-length videos.
-
Advanced Data Utilization: Beyond conventional video captioning and QA datasets, TimeMarker converts annotations from various temporal-related datasets into video QA formats, facilitating comprehensive model training on temporal understanding tasks. Despite using only approximately 5M video-text pairs in training, the video data is diverse in duration, from less than one minute to 120 minutes. Additionally, extensive image training data (around 90M) and interleaved multi-image data (around 12M) enhance the model's semantic perception and cognitive abilities.
-
Benchmark Excellence Across Various Video Lengths: TimeMarker achieves state-of-the-art performance across multiple public video benchmarks, excelling in both short and long video categories. It surpasses traditional models in tasks such as temporal sentence grounding, demonstrating superior temporal localization and understanding capabilities. This underscores the model's robustness and versatility in handling videos of varying lengths with exceptional accuracy in time-based tasks.
News
[2024/10/30] 🔥 We release our TimeMarker model. TimeMarker is based on Llama3-8B LLM, and achieves 🌟Rank 1 on LVBench, 🌟Rank 2 on VideoVista (Rank 1 on VideoVista is Human Performance), 🌟Rank 2 on MVBench, and 🌟Rank 3 on MLVU test set! The results of our TimeMarker also rank highly in other video benchmarks. Our paper is coming soon.
Model Architecture
<img width="1260" src="https://github.com/TimeMarker-LLM/TimeMarker/blob/main/assets/timemarker_framework.png">Performance
Results on Video Benchmarks
Model Name | LLM | VideoMME (w/o subs) | VideoVista | LVbench | LongVideoBench (dev) | MLVU (dev) | MVBench | MMBench-Video | TempCompass |
---|---|---|---|---|---|---|---|---|---|
Gemini-1.5-pro | - | 75.0 | 76.4 | 33.1 | 66.4 | - | - | 1.30 | 67.1 |
GPT-4V | - | 59.9 | - | - | 60.7 | 49.2 | 43.7 | 1.53 | - |
GPT-4o | - | 71.9 | 78.3 | 27.0 | 66.7 | 64.6 | - | 1.64 | - |
LLaVA-Next-Video-7B | Vicuna-7b-v1.5 | 33.7 | 56.7 | - | 43.5 | - | 53.1 | - | - |
PLLaVA-7B | Vicuna-7b-v1.5 | - | 60.4 | - | 39.2 | - | 46.6 | 1.03 | - |
VideoChat2-HD | Mistral-7B | - | 61.6 | - | - | 47.9 | 62.3 | 1.22 | - |
VideoLLaMA2-7B | Mistral-7B | 47.9 | 60.5 | - | - | 48.5 | 54.6 | - | - |
LongVA | Qwen2-7B | 52.6 | 67.4 | - | - | 56.3 | - | - | 56.9 |
Video-XL | Qwen2-7B | 55.5 | - | - | 49.5 | 64.9 | 55.3 | - | - |
Qwen2-VL-7B-Instruct | Qwen2-7B | 63.3 | - | - | - | - | 67.0 | - | 67.8 |
Kangaroo | Llama3-8B | 56.0 | 69.5 | 39.4 | 54.8 | 61.0 | 61.1 | 1.44 | - |
TimeMarker (Ours) | Llama3-8B | 57.3 | 78.4 | 41.3 | 56.3 | 63.9 | 67.4 | 1.53 | 60.4 |