AV1 Motion Vector Candidate Ranking and Pruning

In the AV1 video codec, inter-frame prediction relies heavily on motion vector (MV) signaling, where coding efficiency depends on accurately predicting motion with minimal bit overhead. To achieve this, AV1 builds a dynamic motion vector candidate list for each block using spatial and temporal neighbors. The codec evaluates these candidates through a structured sorting hierarchy and aggressively prunes redundant or low-probability vectors to produce a compact, ranked candidate list signaled to the decoder.

Spatial and Temporal Candidate Assembly

Before ranking and pruning can occur, AV1 scans predefined neighboring locations to populate an initial candidate pool.

  1. Spatial Neighbors: The encoder searches causal spatial blocks surrounding the current coding unit, focusing on adjacent blocks directly to the left, above, above-right, and above-left. It also evaluates extended spatial neighbors if primary blocks are unavailable.
  2. Temporal Motion Vector Fields (MFMV): AV1 projects motion vectors from previously decoded reference frames onto a temporal motion field. By mapping these reference trajectories to the current block's position, it gathers collocated temporal motion vectors.

Ranking Methodology

Once candidates are gathered, AV1 sorts them into a priority-driven stack based on geometric proximity and reference frame compatibility:

The dynamic stack ranks candidates so that the most statistically probable motion vector occupies the lowest indices (such as index 0), ensuring that entropy coding uses the fewest bits for the most likely choice.

Pruning and Redundancy Elimination

To prevent wasting bits on signaling duplicate data and to conserve decoder processing time, the candidate list undergoes a strict pruning process:

Fallback and Padding

If the pruning process leaves the dynamic candidate list short of the required capacity, AV1 fills the remaining slots using deterministic fallbacks. It injects global motion parameters associated with the current reference frame, or defaults to zero motion vectors \((0, 0)\). This guarantees that the encoder and decoder always maintain identical list lengths without explicit signaling overhead.