|
Download README.md from htdong/Loopy: direct link, hf CLI and curl.
- Browser
- Download file 6.59 kB
-
https://huggingface.co/htdong/Loopy/resolve/main/README.md
- Command line
-
hf download hf://htdong/Loopy/README.md
-
curl -L -o README.md https://huggingface.co/htdong/Loopy/resolve/main/README.md
6.59 kB
| license: apache-2.0 | |
| base_model: | |
| - Wan-AI/Wan2.2-T2V-A14B | |
| pipeline_tag: text-to-video | |
| tags: | |
| - looping | |
| - RGB | |
| - RGBA | |
| - video | |
| - generation | |
| <div align="center"> | |
| <h1 style="font-size:2.5em; font-weight:700; line-height:1.25; margin:0 0 16px; padding-bottom:.3em; border-bottom:1px solid rgba(128,128,128,.35);"> | |
| <img src="assets/loopy-logo.apng" alt="Loopy logo" height="42" style="height:1.2em; width:auto; display:inline-block; vertical-align:middle; margin-right:10px;"/> | |
| Loopy | |
| </h1> | |
| <h3 style="font-size:1.5em; font-weight:600; line-height:1.3; margin:0 0 16px;">Seamless Video Loop Generation via Anchored Looping Shift of Positional Embedding</h3> | |
| [](http://arxiv.org/abs/2608.23090) | |
| [](https://donghaotian123.github.io/Loopy/) | |
| [](https://github.com/WeChatCV/Loopy) | |
| </div> | |
| <img src="assets/teaser.png" alt="Loopy Qualitative Results" style="max-width: 100%; height: auto;"> | |
| >Our **Loopy** generates high-quality looping videos with seamless transitions at loop boundaries and diverse motion. It also supports RGBA with semi-transparent effects. In the application block, all elements—including game assets and Loopy character stickers—are generated by our **Loopy**. | |
| --- | |
| ### 🔥 News | |
| * **[2026.8.24]** Released Loopy, the Wan2.2-T2V-A14B–adapted weights and inference code are now open-sourced. | |
| * **[2026.8.24]** Our technical report is available on [arXiv](https://arxiv.org/abs/XXXX.XXXXX). | |
| --- | |
| ### 📝 To-Do List | |
| - [x] **Paper**: Release the technical report on arXiv. | |
| - [x] **Inference Code**: Released the looping inference pipeline for Loopy. | |
| - [x] **Model Weights**: Release the high-noise / low-noise LoRA checkpoints. | |
| --- | |
| ### 🌟 Showcase | |
| ##### Seamless Looping Video Generation | |
| <!-- | Prompt | Preview Video | Alpha Video | | |
| | :---: | :---: | :---: | | |
| | "Medium shot. A little girl holds a bubble wand and blows out colorful bubbles that float and pop in the air. The background of this video is transparent. Realistic style." | | |
| <div style="display: flex; gap: 10px;"> | |
| <img src="girl.gif" alt="..." style="flex: 1; min-width: 200px;"> | |
| </div> | | |
| <div style="display: flex; gap: 10px;"> | |
| <img src="girl_pha.gif" alt="..." style="flex: 1; min-width: 200px;"> | |
| </div> | --> | |
| | Preview Video | Preview Video | | |
| | :---: | :---: | | |
| | <img src="assets/human.apng" width="320" height="180" style="object-fit:contain; display:block; margin:auto;"/> | <img src="assets/loopy-6.apng" width="320" height="180" style="object-fit:contain; display:block; margin:auto;"/> | | |
| ##### For more results, please visit [Our Website](https://donghaotian123.github.io/Loopy/) | |
| ### 🚀 Quick Start | |
| ##### 1. Environment Setup | |
| ```bash | |
| # Clone the project repository | |
| git clone https://github.com/WeChatCV/Loopy.git | |
| cd Loopy | |
| # Create and activate Conda environment | |
| conda create -n Loopy python=3.11 -y | |
| conda activate Loopy | |
| # Install dependencies | |
| pip install -r requirements.txt | |
| ``` | |
| ##### 2. Model Download | |
| Download [Wan2.2-T2V-A14B](https://huggingface.co/Wan-AI/Wan2.2-T2V-A14B) | |
| Download the LightX2V 4-step distillation LoRAs for both experts: | |
| [high noise](https://huggingface.co/lightx2v/Wan2.2-Distill-Loras/blob/main/wan2.2_t2v_A14b_high_noise_lora_rank64_lightx2v_4step_1217.safetensors) / | |
| [low noise](https://huggingface.co/lightx2v/Wan2.2-Distill-Loras/blob/main/wan2.2_t2v_A14b_low_noise_lora_rank64_lightx2v_4step_1217.safetensors) | |
| Download [Loopy](https://huggingface.co/htdong/Loopy) (`high_noise.safetensors` and | |
| `low_noise.safetensors`) | |
| --- | |
| ### 🧪 Usage | |
| Write one prompt per line in a plain UTF-8 text file, then launch the batch inference: | |
| ```bash | |
| output_path="./checkpoints" | |
| mkdir -p $output_path | |
| torchrun --nproc_per_node=8 generate_2.2_new.py --task t2v-A14B --size 832*480 \ | |
| --ckpt_dir Wan-AI/Wan2.2-T2V-A14B \ | |
| --dit_fsdp --t5_fsdp --ulysses_size 8 \ | |
| --frame_num 53 \ | |
| --sample_steps 4 \ | |
| --high_lightx2v_path "wan2.2_lora/wan2.2_t2v_A14b_high_noise_lora_rank64_lightx2v_4step_1217.safetensors" \ | |
| --low_lightx2v_path "wan2.2_lora/wan2.2_t2v_A14b_low_noise_lora_rank64_lightx2v_4step_1217.safetensors" \ | |
| --high_lora_path high_noise.safetensors \ | |
| --low_lora_path low_noise.safetensors \ | |
| --prompt_file prompt.txt \ | |
| --output_dir $output_path/results 2>&1 | tee -a $output_path/results.log | |
| ``` | |
| Or simply run the packaged script after editing the paths inside it: | |
| ```bash | |
| bash test.sh | |
| ``` | |
| You can specify the weights of `Wan2.2-T2V-A14B` with `--ckpt_dir`, the LightX2V distillation | |
| LoRAs with `--high_lightx2v_path` / `--low_lightx2v_path`, and the Loopy LoRAs with | |
| `--high_lora_path` / `--low_lora_path`. Wan2.2-T2V-A14B is a two-expert MoE model, so the | |
| high-noise and low-noise branches each need their own pair of LoRAs. | |
| Generated videos are written to `--output_dir`, one subdirectory per prompt, each containing | |
| `fgr.mp4`. | |
| **Prompt Writing Tip:** Describe a subject whose motion is naturally periodic or continuous — | |
| falling snow, drifting clouds, flowing water, a walking animal, a rotating object. State the | |
| visual style and the shot type (close-up, medium shot, wide shot) as well. Prompts support | |
| both Chinese and English input. | |
| ```bash | |
| # An example of prompt. | |
| An Arctic fox leaps nimbly through the snow while hunting, its white fur blending seamlessly with the snowflakes. Realistic style; a scene of winter wildlife. | |
| ``` | |
| --- | |
| ### 🤝 Acknowledgements | |
| This project is built upon the following excellent open-source projects: | |
| * [Wan2.2](https://github.com/Wan-Video/Wan2.2) (base video generation model) | |
| * [LightX2V](https://github.com/ModelTC/LightX2V) (inference acceleration) | |
| * [DiffSynth-Studio](https://github.com/modelscope/DiffSynth-Studio) (training/inference framework) | |
| We sincerely thank the authors and contributors of these projects. | |
| --- | |
| ### ✏️ Citation | |
| If you find our work helpful for your research, please consider citing our paper: | |
| ```bibtex | |
| @article{haotiandong2026loopy, | |
| title = {Loopy: Seamless Video Loop Generation via Anchored Looping Shift of Positional Embedding}, | |
| author = {Haotian Dong, Wenjing Wang, Chen Li, Jing Lyu, Xin Wang, Di Lin}, | |
| journal = {arXiv preprint}, | |
| year = {2026} | |
| } | |
| ``` | |
| --- | |
| ### 📬 Contact Us | |
| If you have any questions or suggestions, feel free to reach out via | |
| [GitHub Issues](https://github.com/WeChatCV/Loopy/issues). We look forward to your feedback! | |