Skip to content

Commit 3304ea7

Browse files
committed
fix the example scripts in parallel_inference_xdit.py
1 parent dcb6795 commit 3304ea7

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

tools/parallel_inference/parallel_inference_xdit.py

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,20 @@
77
By using this code, the inference process is parallelized on multiple GPUs,
88
and thus speeded up.
99
10-
You can also use the run.sh file in the same folder to automate running this
11-
code for batch generation of videos.
12-
1310
Usage:
1411
1. pip install xfuser
15-
2. run the following command to generate video
16-
torchrun --nproc_per_node=4 cogvideox_xdit.py --model <cogvideox-model-path> \
17-
--ring_degree 2 --use_cfg_parallel --height 480 --width 720 --num_frames 9 \
12+
2. mkdir results
13+
3. run the following command to generate video
14+
torchrun --nproc_per_node=4 parallel_inference_xdit.py \
15+
--model <cogvideox-model-path> --ulysses_degree 1 --ring_degree 2 \
16+
--use_cfg_parallel --height 480 --width 720 --num_frames 9 \
1817
--prompt 'A small dog.'
1918
19+
You can also use the run.sh file in the same folder to automate running this
20+
code for batch generation of videos, by running:
21+
22+
sh ./run.sh
23+
2024
"""
2125

2226
import time

0 commit comments

Comments
 (0)