Contextual Flow Matching: Adaptive Step Selection in Flow Models for Efficient Visual Generation
Abstract
Flow Matching enables high-quality visual generation via continuous-time dynamics, but inference remains costly due to multiple sequential function evaluations. Existing acceleration methods reduce the number of function evaluations but often introduce additional training overhead, degrade quality, or fail to account for input-dependent variability. We propose COFLOW, an inference-time method that adaptively selects the step counts each generation based on the prompt features. Our context-aware COFLOW is trained online with an unsupervised reward that balances inference efficiency and generation fidelity. Our method is plug-and-play, requiring no retraining of the underlying generative model. It generalizes to image and video generation, achieving over 2.5x speedup while preserving perceptual and semantic quality. We further provide a theoretical analysis establishing an O(1/K) forward-Euler discretization error bound under standard regularity conditions.
Create a lesson
Metadata
- Categories
- cs.CV, cs.AI
- Comments
- Accepted in NeurIPS 2026
Related papers
FoMNet: Adaptive Kernels Meet Contextual Matching for Cross-Modal Homography Estimation
Shared title terminologycs.CVZhuoran Yang, Zhenyu Yi, Runmin Zhang et al.
X-Matte: VAE-Free Pixel-Space Flow Matching for Single-Step Image Matting
Shared title terminologycs.CVZanyi Wang, Jiaang Li, Dengyang Jiang et al.
DuoMatching: Joint-Marginal Distribution Matching for Few-Step Video Generation
Shared title terminologycs.CVJiahao Zhan, Yan Wang, Yongrui Ma et al.
TRAC: Trajectory-aware Reuse and Adaptive Correction for Efficient Autoregressive Video Generation
Shared title terminologycs.CVJiaxing Song, Weiqi Yan, You Huang et al.
WebVibe: Multimodal Interactive Website Generation via Reverse Synthesis and Visual Self-Distillation
Shared title terminologycs.CVTianxiang Jiang, Sheng Xia, Yilin Long et al.
HSTTA: Hierarchical Selective Test-Time Adaptation for Label-Free Cross-Subject EEG-to-Image Retrieval
Shared title terminologycs.CVHongzhou Chen, Yuhao Wei, Lianghua He et al.