arXiv:2609.01778cs.CVSep 2026

Manuscript Offprint

arXiv:2609.01778

Allocate Before You Embed: Adaptive Visual Input Allocation for Video Embeddings

Song Jin, Zhongtao Jiang, Chenglei Shen, Huanxuan Liao, Haozhe Chi, Zhiwei Wang, Kun Xu, Yong Liu

Abstract

Large-scale video retrieval requires embedding models to encode long and diverse videos under tight visual-input and inference budgets. Existing methods typically sample a small, fixed set of frames at their original resolution, limiting temporal coverage and ignoring frame importance. Our empirical analysis shows that expanding temporal coverage improves retrieval even under a fixed visual-input budget. Gains are larger when the original per-frame resolution is preserved, highlighting the complementary roles of temporal coverage and spatial fidelity. Motivated by this finding, we propose AllocEmbed, an allocate-then-embed framework that reallocates a fixed visual-input budget across more frames. A lightweight allocator uses low-cost previews to assign frame-wise resolutions before the embedding backbone, preserving more detail where it most benefits retrieval while reducing visual cost elsewhere. We further introduce Retrieval-Driven Policy Optimization (RDPO), which learns the allocator directly from retrieval feedback using a rank-validated similarity gap and a confidence-guided efficiency incentive. Operating entirely before the backbone, AllocEmbed integrates with existing retrieval systems without modifying the embedding model or downstream pipeline. Experiments on the MMEB-V2 V-QA and V-RET tasks and our LongRet benchmark show that AllocEmbed achieves the best overall retrieval performance among the evaluated budget-matched methods and transfers across embedding backbones. Our code is publicly available at https://github.com/jinsong8/AllocEmbed.

1 Introduction

Video embeddings provide a common interface for large-scale video retrieval, cross-modal search, and retrieval-augmented video understanding. By

Figure

Figure 1: Fixed-frame inputs limit temporal coverage. Adding full-resolution frames increases inference cost, whereas uniform downscaling loses spatial detail. AllocEmbed preserves broad temporal coverage and key spatial detail under the same visual-input budget. H/L denote high/low resolution.

compressing a variable-length video into a fixed-dimensional vector, they make it possible to compare video content efficiently at corpus scale. In practice, however, video embedding models operate under limited visual context, and running large models over massive video collections is expensive. Existing systems therefore commonly control cost by uniformly sampling a small, fixed number of frames from each video (Luo et al., 2022; Ma et al., 2022; Meng et al., 2025). This strategy is simple and cost-effective, but it also assumes that different videos, time positions, and visual evidence carry the same value for retrieval.

Figure 1 illustrates our motivation. We first examine how temporal coverage affects video retrieval. Across four embedding backbones, sampling more frames improves retrieval when per-frame resolution is preserved. Under a fixed visual-input budget, denser sampling remains beneficial despite the resulting lower per-frame resolution, but

  • Corresponding author.

yields smaller gains. Together, these results show that temporal coverage and spatial fidelity provide complementary benefits and motivate a central question: how should a fixed visual-input budget be allocated across a denser frame sequence?

We therefore propose AllocEmbed, an allocate-then-embed framework that redistributes a target visual-input budget across a denser frame sequence. Given low-cost previews of the sampled frames and the task text, a lightweight allocator predicts a continuous resolution scale for each frame and constructs a mixed-resolution video input. All sampled frames remain in their original temporal order, while their resolutions are adjusted to preserve more detail where it most benefits retrieval and reduce visual cost elsewhere. The allocated input is then processed by a frozen embedding backbone. Because allocation occurs entirely before embedding, AllocEmbed requires no changes to the backbone weights, embedding dimensionality, similarity function, or downstream retrieval pipeline.

Learning such an allocator is challenging because existing datasets provide no frame-level supervision for resolution, and an allocation can be evaluated only after preprocessing, embedding, and retrieval. We address this problem with Retrieval-Driven Policy Optimization (RDPO), which learns directly from end-to-end retrieval outcomes. RDPO samples multiple allocations for the same input and evaluates them against an augmented candidate set with in-batch and global negatives. It then constructs a group-relative learning signal from a rank-validated similarity gap, which grades only allocations that rank the positive target first. A success-gated, confidence-guided efficiency incentive further favors lower-cost allocations without rewarding cheap but incorrect decisions. This formulation trains the allocator through the actual visual preprocessing and tokenization pipeline while keeping the embedding backbone frozen.

We evaluate AllocEmbed on ten MMEB-V2 video QA and retrieval tasks and on LongRet, a new benchmark for long videos with sparse and unevenly distributed evidence. The allocator is trained with VLM2Vec-V2-2B and evaluated without retraining on three additional embedding backbones, covering model sizes from 2B to 8B parameters. Averaged across the ten MMEB-V2 tasks, AllocEmbed improves Hit@1 by 1.34–1.69 points over the corresponding fixed-frame baselines. Averaged across the four LongRet subsets, the gains increase to 5.69–9.09 points. These aggregate improvements are achieved without exceeding the visual-input cost of each backbone's fixed-frame baseline.

Our contributions are threefold:

  • We introduce AllocEmbed, an allocate-then-embed framework motivated by our finding that temporal coverage and spatial fidelity provide complementary benefits for video retrieval. To our knowledge, AllocEmbed is the first framework to study visual input allocation for VLM-based video embedding models.

  • We develop RDPO, a retrieval-driven policy optimization method that learns the allocation policy directly from ranking feedback using a rank-validated similarity gap and a confidence-guided efficiency incentive.

  • We conduct extensive experiments on MMEB-V2 and our newly constructed LongRet benchmark. AllocEmbed improves aggregate retrieval performance under matched visual-input budgets and transfers from its training backbone to three additional embedding backbones without retraining.

References (31)