Video and Temporal Reasoning › From frames to tokens: the video encoder pipeline

Michael BrenndoerferDecember 1, 20262 min read
Language AI HandbookAll chapters
Part 52 of 67Omni-Modal and Embodied Language Systems
Chapter 399Video and Temporal Reasoning › From frames to tokens: the video encoder pipeline
Reading section 4 of 12 · From frames to tokens: the video encoder pipeline · 2 minSection 4 of 12 · 2 min

Section 4 of 12 · 2 min read

Reading settings

Definitions

Choose how many terms have tooltips.

Article links

Make inline references clickable

Notes & comments

Once frames are chosen, each frame is encoded, and the encoded frames are stitched into the language model's input. This is the video version of the LLaVA pipeline from Part L, Ch 5: LLaVA Architecture, with the addition of time. There are three main architectural choices.

Frame-as-image, concatenated. Encode selected frames separately and concatenate their visual representations in order. The sequence preserves order. To represent irregular spacing, supply timestamps or time-based positions alongside the frame representations.

Temporal pooling and aggregation. Merge information within a time window. If that operation outputs fewer tokens, the language model receives a shorter sequence. A mean over the whole window can lose fine order unless the feature representation separately encodes it.

Explicit temporal encoding. Add a time feature to the visual representation. An embedding parameterized by elapsed time can distinguish equal frame-index gaps with different durations. Whether the model uses that feature correctly is an evaluation question.

The LLaVA-OneVision paper gives a concrete token-budget example. Its documented video path encodes frames individually and uses spatial interpolation to reduce their visual token count. That compression within each frame is independent of pooling across time. Both choices affect the evidence available further downstream.

The worked example compares the two samplers on the same feature sequence.

Comments

Add to the conversation

A question, a correction, or an example from your own work.

No comments yet. Be the first to share your thoughts!

Newsletter

Stay up to date

Get new articles, book updates, and notes on AI and technology.

Unsubscribe at any time. Privacy policy