Skip to content

Commit 12fa9f8

Browse files
gushiqiaogushiqiao
andauthored
Support wan i2v and lora. (#375)
Co-authored-by: gushiqiao <[email protected]>
1 parent 21beba3 commit 12fa9f8

35 files changed

+499
-100
lines changed

assets/wan_i2v/calib/astronaut.jpg

936 KB
Loading

assets/wan_i2v/calib/samples.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[
2+
{
3+
"image": "astronaut.jpg",
4+
"prompt": "An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space realised in the background. High quality, ultrarealistic detail and breath-taking movie-like camera shot.",
5+
"negative_prompt": "Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality, low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured, misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards"
6+
}
7+
]

assets/wan_i2v/eval/astronaut.jpg

936 KB
Loading

assets/wan_i2v/eval/samples.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[
2+
{
3+
"image": "astronaut.jpg",
4+
"prompt": "An astronaut hatching from an egg, on the surface of the moon, the darkness and depth of space realised in the background. High quality, ultrarealistic detail and breath-taking movie-like camera shot.",
5+
"negative_prompt": "Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality, low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured, misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards"
6+
}
7+
]

assets/wan_t2v/calib/samples.json

100644100755
File mode changed.

assets/wan_t2v/eval/samples.json

100644100755
File mode changed.
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
base:
2+
seed: &seed 42
3+
model:
4+
type: WanI2V
5+
path: /path/to/model
6+
torch_dtype: auto
7+
calib:
8+
name: i2v
9+
download: False
10+
path: ../assets/wan_i2v/calib/
11+
sample_steps: 40
12+
bs: 1
13+
target_height: 480
14+
target_width: 832
15+
num_frames: 81
16+
guidance_scale: 5.0
17+
seed: *seed
18+
eval:
19+
eval_pos: [fake_quant]
20+
type: video_gen
21+
name: i2v
22+
download: False
23+
path: ../assets/wan_i2v/eval/
24+
bs: 1
25+
target_height: 480
26+
target_width: 832
27+
num_frames: 81
28+
guidance_scale: 5.0
29+
output_video_path: ./output_videos_awq/
30+
quant:
31+
video_gen:
32+
method: Awq
33+
weight:
34+
bit: 8
35+
symmetric: True
36+
granularity: per_channel
37+
group_size: -1
38+
act:
39+
bit: 8
40+
symmetric: True
41+
granularity: per_token
42+
special:
43+
trans: True
44+
trans_version: v2
45+
weight_clip: False
46+
clip_sym: True
47+
save:
48+
save_lightx2v: True
49+
save_path: /path/to/x2v/
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
base:
2+
seed: &seed 42
3+
model:
4+
type: WanI2V
5+
path: /path/to/model
6+
torch_dtype: auto
7+
eval:
8+
eval_pos: [fake_quant]
9+
type: video_gen
10+
name: i2v
11+
download: False
12+
path: ../assets/wan_i2v/eval/
13+
bs: 1
14+
target_height: 480
15+
target_width: 832
16+
num_frames: 81
17+
guidance_scale: 5.0
18+
output_video_path: ./output_videos_rtn/
19+
quant:
20+
video_gen:
21+
method: RTN
22+
weight:
23+
bit: 8
24+
symmetric: True
25+
granularity: per_channel
26+
act:
27+
bit: 8
28+
symmetric: True
29+
granularity: per_token
30+
save:
31+
save_lightx2v: True
32+
save_path: /path/to/x2v/
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
base:
2+
seed: &seed 42
3+
model:
4+
type: WanI2V
5+
path: /path/to/model
6+
lora_path: /path/to/lora_weights
7+
torch_dtype: auto
8+
eval:
9+
eval_pos: [fake_quant]
10+
type: video_gen
11+
name: i2v
12+
download: False
13+
path: ../assets/wan_i2v/eval/
14+
bs: 1
15+
target_height: 480
16+
target_width: 832
17+
num_frames: 81
18+
guidance_scale: 5.0
19+
output_video_path: ./output_videos_rtn_lora/
20+
quant:
21+
video_gen:
22+
method: RTN
23+
weight:
24+
bit: 8
25+
symmetric: True
26+
granularity: per_channel
27+
act:
28+
bit: 8
29+
symmetric: True
30+
granularity: per_token
31+
save:
32+
save_lightx2v: True
33+
save_path: /path/to/x2v/
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
base:
2+
seed: &seed 42
3+
model:
4+
type: WanI2V
5+
path: /path/to/model
6+
torch_dtype: auto
7+
calib:
8+
name: i2v
9+
download: False
10+
path: ../assets/wan_i2v/calib/
11+
sample_steps: 40
12+
bs: 1
13+
target_height: 480
14+
target_width: 832
15+
num_frames: 81
16+
guidance_scale: 5.0
17+
seed: *seed
18+
eval:
19+
eval_pos: [fake_quant]
20+
type: video_gen
21+
name: i2v
22+
download: False
23+
path: ../assets/wan_i2v/eval/
24+
bs: 1
25+
target_height: 480
26+
target_width: 832
27+
num_frames: 81
28+
guidance_scale: 5.0
29+
output_video_path: ./output_videos_sq/
30+
quant:
31+
video_gen:
32+
method: SmoothQuant
33+
weight:
34+
bit: 8
35+
symmetric: True
36+
granularity: per_channel
37+
act:
38+
bit: 8
39+
symmetric: True
40+
granularity: per_token
41+
special:
42+
alpha: 0.75
43+
save:
44+
save_lightx2v: True
45+
save_path: /path/to/x2v/

0 commit comments

Comments
 (0)