NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Deforming Videos to Masks: Flow Matching for Referring Video Segmentation

Zanyi Wang, Dengyang Jiang, Liuzhuozheng Li, Sizhe Dang, Chengzu Li, Harry Yang, Guang Dai, Mengmeng Wang, Jingdong Wang · DOI

Abstract

Referring Video Object Segmentation (RVOS) requires identifying and tracking specific objects in a video based on natural language queries. Traditional methods follow a "locate-then-segment" paradigm, which often collapses rich visual information into narrow geometric prompts, leading to temporal inconsistencies. We introduce FlowRVS, a new paradigm that treats RVOS as a continuous flow matching problem. By leveraging a pretrained Text-to-Video (T2V) foundation model, FlowRVS learns to "deform" video pixels into segmentation masks through a language-guided velocity field. Our approach achieves state-of-the-art performance on MeViS and Ref-DAVIS17, demonstrating exceptional zero-shot generalization and robustness to complex motion.

Introduction: Beyond Locate-then-Segment

The standard approach to RVOS typically involves two decoupled stages: first, a grounding model locates the target object (e.g., via a bounding box), and second, a segmentation model generates the mask. This "locate-then-segment" strategy creates significant information bottlenecks. By reducing a complex video scene to a single point or box, the model loses the fine-grained semantic context necessary to resolve ambiguous queries or maintain consistency during occlusions.

Comparison of the traditional 'Locate then Segment' paradigm versus the proposed FlowRVS approach, including qualitative and quantitative results.

FlowRVS reimagines this task. Instead of discrete labeling, it views segmentation as a continuous transformation of visual information. By treating the video as a starting point and the mask as a destination, the model learns a deterministic path—a "flow"—that maps pixels to masks.

Methodology: Flow Matching for Video Understanding

The core of FlowRVS is a conditional continuous flow model built upon Wan 2.1, a 1.3B parameter Diffusion Transformer (DiT). While standard T2V models are designed for divergent generation (one prompt to many possible videos), RVOS is a convergent task where a specific video and prompt must map to a unique mask.

Technical Innovations

To adapt generative priors for this discriminative task, we introduced three key components:

  1. Boundary-Biased Sampling (BBS): In a convergent flow, the initial direction is critical. BBS focuses training on the start of the trajectory ($t=0$), where the model must disambiguate which object to follow based on the text prompt.
  2. Start-Point Augmentation (SPA): We inject slight stochastic noise into the initial video latents. This forces the model to learn a more robust velocity field that can recover from minor visual perturbations.
  3. Direct Video Injection (DVI): To prevent the model from "forgetting" the visual context during the multi-step flow process, original video features are concatenated to the input at every step.
The FlowRVS training pipeline, highlighting the interpolation between video and mask latents and the use of boundary-biased time sampling.

Experimental Results

FlowRVS was evaluated across several challenging benchmarks, focusing on motion-centric queries and zero-shot generalization.

State-of-the-Art Performance

  • MeViS: On this motion-focused dataset, FlowRVS achieved a $\mathcal{J}\&\mathcal{F}$ score of 51.1, surpassing the previous leader (SAMWISE) by 1.6 points.
  • Zero-Shot Ref-DAVIS17: Perhaps most impressively, FlowRVS reached a score of 73.3 on Ref-DAVIS17 without any fine-tuning on that specific dataset. This outperforms many supervised models by a margin of +2.7, highlighting the power of the T2V foundation model's internal representations.

Qualitative Advantages

Visual analysis confirms that FlowRVS maintains superior temporal stability. Unlike previous methods that might "flicker" or lose the object during fast motion, the continuous flow ensures that the mask evolves smoothly alongside the video pixels. It also shows a heightened ability to parse long-range linguistic dependencies, correctly identifying objects in complex multi-object scenes.

Conclusion and Future Work

FlowRVS demonstrates that the generative capabilities of large-scale video models can be effectively repurposed for high-precision understanding tasks. By shifting from discrete detection to continuous deformation, we overcome the bottlenecks of previous paradigms. While challenges remain in handling extremely intricate multi-part interactions or specific counting queries, the success of FlowRVS suggests that "deformation-based" understanding is a promising frontier as video foundation models continue to scale.

Summary updated

BibTeX
@inproceedings{wang2026deforming,
  author = {Zanyi Wang and Dengyang Jiang and Liuzhuozheng Li and Sizhe Dang and Chengzu Li and Harry Yang and Guang Dai and Mengmeng Wang and Jingdong Wang},
  title = {{Deforming Videos to Masks: Flow Matching for Referring Video Segmentation}},
  booktitle = {International Conference on Learning Representations},
  year = {2026},
  url = {https://openreview.net/forum?id=3KaIcArMAB},
}
Figure