TencentARC / MotionCtrl

MotionCtrl: A Unified and Flexible Motion Controller for Video Generation

Home Page:https://wzhouxiff.github.io/projects/MotionCtrl/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MotionCtrl: A Unified and Flexible Motion Controller for Video Generation

πŸ‘‰ MotionCtrl for [SVD], for [VideoCrafter]

Paper   arXiv   Project Page

πŸ€— HF Demo   πŸ€— HF Demo


motionctrl_small.mp4

πŸ”₯πŸ”₯ We release the codes, models and demos for MotionCtrl on Stable Video Diffusion (SVD).

Official implementation of MotionCtrl: A Unified and Flexible Motion Controller for Video Generation.

MotionCtrl can Independently control complex camera motion and object motion of generated videos, with only a unified model.

Results of MotionCtrl+SVD

More results are in showcase_svd and our Project Page.

Results of MotionCtrl+VideoCrafter

More results are in our Project Page.


πŸ“ Changelog

  • 20231225: Release MotionCtrl deployed on LVDM/VideoCrafter.
  • 20231225: Gradio demo available. πŸ€— HF Demo
  • 20231228: Provide local gradio demo for convenience.
  • 20240115 More camera poses used for testing are provided in dataset/camera_poses
  • 20240115 Release MotionCtrl deployed on SVD. Codes are in the brach svd and Gradio Demo is available in πŸ€— HF Demo.
  • Release MotionCtrl deployed on AnimateDiff.

βš™οΈ Environment

conda create -n motionctrl python=3.10.6
conda activate motionctrl
pip install -r requirements.txt

πŸ’« Inference

  • Run local inference script

  1. Download the weights of MotionCtrl motionctrl.pth and put it to ./checkpoints.
  2. Go into configs/inference/run.sh and set condtype as 'camera_motion', 'object_motion', or 'both'.
  • condtype=camera_motion means only control the camera motion in the generated video.
  • condtype=object_motion means only control the object motion in the generated video.
  • condtype=both means control the camera motion and object motion in the generated video simultaneously.
  1. Running scripts: sh configs/inference/run.sh
  • Run local gradio demo

    python -m app --share
    

πŸ“š Citation

If you make use of our work, please cite our paper.

@inproceedings{wang2023motionctrl,
  title={MotionCtrl: A Unified and Flexible Motion Controller for Video Generation},
  author={Wang, Zhouxia and Yuan, Ziyang and Wang, Xintao and Chen, Tianshui and Xia, Menghan and Luo, Ping and Shan, Yin},
  booktitle={arXiv preprint arXiv:2312.03641},
  year={2023}
}

πŸ€— Acknowledgment

The current version of MotionCtrl is built on VideoCrafter. We appreciate the authors for sharing their awesome codebase.

❓ Contact

For any question, feel free to email wzhoux@connect.hku.hk or zhouzi1212@gmail.com.

About

MotionCtrl: A Unified and Flexible Motion Controller for Video Generation

https://wzhouxiff.github.io/projects/MotionCtrl/

License:Apache License 2.0


Languages

Language:Python 99.7%Language:Shell 0.3%