Introduction
Controlling the specific trajectory and style of motion in text-to-video (T2V) generation remains a significant challenge. While current models excel at generating high-quality frames from text, describing complex movement patterns through language is inherently ambiguous. Motion transfer—the process of applying the movement from a reference video to a new subject or scene—offers a solution. However, most existing tools are designed for UNet architectures, which process spatial and temporal data separately. As the field shifts toward Diffusion Transformers (DiTs), which utilize global attention for joint spatiotemporal processing, new methods are required. This paper introduces DiTFlow, the first training-free motion transfer pipeline specifically optimized for the transformer architecture.
Methodology
DiTFlow leverages the internal mechanisms of pre-trained DiTs to achieve motion control without additional training or fine-tuning. The pipeline consists of three primary components:
- Attention Motion Flow (AMF) Extraction: By analyzing cross-frame attention maps within a DiT, researchers can identify how patches in one frame relate to those in subsequent frames. Applying an
argmaxoperation to these maps generates a patch-wise displacement matrix, termed Attention Motion Flow (AMF), which serves as a high-level representation of the reference motion. - Optimization-Based Guidance: During the denoising process of a new video, the AMF of the current generation is compared against the reference AMF. Backpropagation is then used to adjust the latent representations, steering the model toward the desired motion path.
- Zero-Shot Transfer via Positional Embeddings: A key innovation of DiTFlow is the optimization of spatiotemporal positional embeddings rather than latents. Because these embeddings define the coordinate system of the video content, "warping" them effectively warps the motion. These optimized embeddings can then be applied to entirely different text prompts in a zero-shot manner.
Key Insights
The researchers discovered that the internal self-attention of DiTs naturally captures token dependencies across frames, acting as a proxy for motion without the need for external optical flow models. Furthermore, they identified that early blocks in the transformer (specifically around the 20th block in a 40-block model like CogVideoX-5B) are the most critical for defining motion structure.
Experimental Setup and Results
The method was evaluated using the DAVIS dataset, testing 150 motion-prompt pairs across categories such as subject changes and full scene swaps. DiTFlow was benchmarked against state-of-the-art models like SMM, MOFT, and MotionClone using the CogVideoX-5B architecture.
Quantitative Performance
DiTFlow achieved a Motion Fidelity (MF) score of 0.785, outperforming the leading baseline, SMM (0.766). Human evaluation studies also confirmed a strong preference for DiTFlow in terms of both motion adherence and textual alignment.
Qualitative Analysis
Visual results demonstrate that DiTFlow successfully preserves the structural integrity of new subjects while following the reference trajectory precisely.
Conclusion and Future Work
DiTFlow represents a significant step forward in providing native motion control for Diffusion Transformers. While the current optimization-based approach increases inference time (approximately 1.6x to 2x), it eliminates the need for costly retraining. Future research will focus on distilling these optimized embeddings into feed-forward networks to enable real-time, zero-shot motion control.
Summary updated