Views
No views yet





| 480P Resolution | 720P Resolution |
|---|---|
📋 Show promptTwo shirtless men with short dark hair are sparring in a dimly lit room. They are both wearing boxing gloves, one red and one black. One man is wearing white shorts while the other is wearing black shorts. There are several screens on the wall displaying images of buildings and people. | 📋 Show promptA woman with fair skin, dark hair tied back, and wearing a light green t-shirt is visible against a gray background. She uses both hands to apply a white substance from below her eyes upward onto her face. Her mouth is slightly open as she spreads the cream. |
📋 Show promptThe woman has dark eyes and is holding a black smartphone to her ear with her right hand. She is typing on the keyboard of an open silver laptop computer with her left hand. Her fingers have blue nail polish. She is sitting in front of a window covered by sheer white curtains. | 📋 Show promptA light-skinned man with short hair wearing a yellow baseball cap, plaid shirt, and blue overalls stands in a field of sunflowers. He holds a cut sunflower head in his left hand and touches it with his right index finger. Several other sunflowers are visible in the background, some facing away from the camera. |
| 480P Resolution | 720P Resolution |
|---|---|
![]() | ![]() |
📋 Show promptA monochromatic video capturing a cat's gaze into the camera | 📋 Show promptA young boy is jumping in the mud |
![]() | ![]() |
📋 Show promptA family of four eats fast food at a table. | 📋 Show promptNormal speed, Medium shot, Eye level angle, Third person viewpoint, Static camera movement, Frame-within-frame composition, Shallow depth of field, Natural light, Cinematic style, Desaturated palette with slate blue, dusty rose, and dark wood tones color palette, Dramatic atmosphere. The scene is set on a patio or veranda, framed by a stone archway. In the back, there is a large, weathered wooden gate set into a stone wall. Six people are gathered on a stone patio in front of a large wooden gate. On the right, two men are seated at a dark wooden table. An older man in a grey traditional jacket holds a cane and gestures with his right hand while speaking. A younger man in a light grey suit sits beside him, listening. On the left side of the frame, a man in a dark suit stands with his back to the camera. Next to him, a woman in a pink patterned cheongsam and a woman in a grey skirt suit are standing close together, whispering. The women then turn and smile towards the men at the table. The man in the dark suit turns to face the group, revealing a newborn baby cradled in his arms, wrapped in a pink blanket. He takes a few steps forward, holding the baby. The women look at him and the infant. The older man at the table continues to talk, now gesturing towards the man with the baby. The man holding the baby looks down at the infant as he continues to walk slowly. The table is set with white cups, plates, fruit, and a dark wooden box. |
1git clone https://github.com/Tencent-Hunyuan/HY-Video-PRFL.git
2cd HY-Video-PRFL1# Create conda environment
2conda create -n HY-Video-PRFL python==3.10
3
4# Activate environment
5conda activate HY-Video-PRFL
6
7# Install PyTorch and dependencies (CUDA 12.4)
8pip3 install torch==2.5.0 torchvision==0.20.0 torchaudio==2.5.0 --index-url https://download.pytorch.org/whl/cu121
9
10# Install additional dependencies
11pip3 install git+https://github.com/huggingface/transformers qwen-vl-utils[decord]
12pip3 install git+https://github.com/huggingface/diffusers
13pip3 install xfuser -i https://pypi.org/simple
14pip3 install flash-attn==2.5.0 --no-build-isolation
15pip3 install -e .
16pip3 install nvidia-cublas-cu12==12.4.5.8
17
18export PYTHONPATH=./| Model | Resolution | Download Links | Notes |
|---|---|---|---|
| Wan2.1-T2V-14B | 480P & 720P | 🤗 Huggingface 🤖 ModelScope | Text-to-Video model |
| Wan2.1-I2V-14B-720P | 720P | 🤗 Huggingface 🤖 ModelScope | Image-to-Video (High-res) |
| Wan2.1-I2V-14B-480P | 480P | 🤗 Huggingface 🤖 ModelScope | Image-to-Video (Standard) |
pip install -U "huggingface_hub[cli]"
pip install modelscope./weights by default.hf download Wan-AI/Wan2.1-I2V-14B-720P --local-dir ./weights/Wan2.1-I2V-14B-720Ppython3 scripts/preprocess/gen_wanx_latent.py --config configs/pre_480.yamltemp_data/videos as template training data and an input json file temp_data/temp_input_data.jsontemplate for preprocess. configs/pre_480.yaml is for 480P latent extraction and configs/pre_720.yaml is for 720P. The json_path and save_dir in config file can be customized with your own training data."physics_quality": 1, "human_quality": 1) should be added in the data meta files (e.g. temp_data/480/meta_v1/0004e625d5bcb80130e1ea3d204e2488_meta_v1.json). Thus we get meta file list temp_data/temp_data_480.list and temp_data/temp_data_720.list which can be used in PAVRM and PRFL training.torchrun --nnodes=1 --nproc_per_node=8 --master_port 29500 scripts/pavrm/train_pavrm.py --config configs/train_pavrm_i2v_720.yamlmeta_file_list and val_meta_file_list in config file can be customized with your own training and validation data. We provide several config files for different settings t2v or i2v, 480P or 720P. To be noted that, we train PAVRM with ce loss. To train PAVRM with bt loss, you can use the config file of configs/train_pavrm_bt_i2v_720.yaml.torchrun --nnodes=1 --nproc_per_node=8 --master_port 29500 scripts/prfl/train_prfl.py --config configs/train_prfl_i2v_720.yamlmeta_file_list in config file can be customized with your own training data, lrm_transformer_path, lrm_mlp_path and lrm_query_attention_path in config file are for your reward model obtained from the previous step. We provide several config files for different settings t2v or i2v, 480P or 720P.torchrun --nnodes=1 --nproc_per_node=8 --master_port 29500 scripts/pavrm/inference_pavrm.py --config configs/infer_pavrm_i2v_720.yamlval_meta_file_list in config file can be customized with your own inference data, resume_transformer_path, resume_mlp_path and resume_query_attention_path in config file are for your reward model to be tested.1export negative_prompt="色调艳丽,过曝,静态,细节模糊不清,字幕,风格,作品,画作,画面,静止,整体发灰,最差质量,低质量,JPEG压缩残留,丑陋的,残缺的,多余的手指,画得不好的手部,画得不好的脸部,畸形的,毁容的,形态畸形的肢体,手指融合,静止不动的画面,杂乱的背景,三条腿,背景人很多,倒着走"
2torchrun --nnodes=1 --nproc_per_node=8 --master_port 29500 scripts/prfl/inference_prfl.py \
3 --dit_fsdp \
4 --t5_fsdp \
5 --ulysses_size 1 \
6 --task "i2v-14B"\
7 --ckpt_dir "weights/Wan2.1-I2V-14B-720P" \
8 --lora_path "" \
9 --lora_alpha 0 \
10 --dataset_path "temp_data/temp_prfl_infer_data.json" \
11 --negative_prompt "$negative_prompt" \
12 --size "1280*720" \
13 --frame_num 81 \
14 --sample_steps 40 \
15 --sample_guide_scale 5.0 \
16 --sample_shift 5.0 \
17 --teacache_thresh 0 \
18 --save_folder outputs/infer/prfl_i2v_720 \
19 --transformer_path <YOUR_CKPT_PATH> \
20 --offload_model False--dit_fsdp --t5_fsdp: Enable FSDP for memory efficiency--task: "t2v-14B" or "i2v-14B"--ckpt_dir: Path to pretrained checkpoint file--lora_path --lora_alpha: Path and load weight ratio for LoRA checkpoint file--dataset_path: Path to inference dataset file--size: Output resolution ("1280*720" or "832*480")--frame_num: Number of frames to generate (default: 81)--sample_steps: Number of inference steps (default: 40)--sample_guide_scale: Classifier-free guidance scale (default: 5.0)--sample_shift: Flow shift (default: 5.0)--save_folder: Path to save generated videos--teacache_thresh: Enable teacache--transformer_path: Path to your PRFL checkpoint file--offload_model: Offload to CPU to save GPU memory1@article{mi2025video,
2 title={Video Generation Models are Good Latent Reward Models},
3 author={Mi, Xiaoyue and Yu, Wenqing and Lian, Jiesong and Jie, Shibo and Zhong, Ruizhe and Liu, Zijun and Zhang, Guozhen and Zhou, Zixiang and Xu, Zhiyong and Zhou, Yuan and Lu, Qinglin and Tang, Fan},
4 journal={arXiv preprint arXiv:2511.21541},
5 year={2025}
6}