Skip to content

Commit 3349931

Browse files
committed
chore: update wan i2v/t2v configs and eval defaults
Made-with: Cursor
1 parent 0cdfa67 commit 3349931

4 files changed

Lines changed: 40 additions & 65 deletions

File tree

configs/quantization/video_gen/wan_i2v/awq_w_a.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ base:
22
seed: &seed 42
33
model:
44
type: WanI2V
5-
path: /mnt/lm_data_afs/wangzining/charles/lab/llmc/models/Wan2.2-T2V-A14B/
5+
path: /path/to/model
66
torch_dtype: auto
77
calib:
88
name: i2v
@@ -31,12 +31,12 @@ quant:
3131
video_gen:
3232
method: Awq
3333
weight:
34-
bit: 4
34+
bit: 8
3535
symmetric: True
3636
granularity: per_channel
3737
group_size: -1
3838
act:
39-
bit: 4
39+
bit: 8
4040
symmetric: True
4141
granularity: per_token
4242
special:
@@ -46,4 +46,4 @@ quant:
4646
clip_sym: True
4747
save:
4848
save_lightx2v: True
49-
save_path: ../lightx2v/wan_i2v_awq_w_a/x2v/
49+
save_path: /path/to/x2v/

configs/quantization/video_gen/wan_i2v/smoothquant_w_a_fp8_example.yaml

Lines changed: 0 additions & 57 deletions
This file was deleted.
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: WanT2V
5+
path: /path/to/wan_t2v
6+
torch_dtype: auto
7+
eval:
8+
eval_pos: [transformed, fake_quant]
9+
type: video_gen
10+
name: t2v
11+
download: False
12+
path: ../assets/wan_t2v/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: 6
24+
symmetric: True
25+
granularity: per_channel
26+
act:
27+
bit: 6
28+
symmetric: True
29+
granularity: per_token
30+
save:
31+
save_lightx2v: True
32+
save_path: /path/to/x2v/

llmc/__main__.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def main(config):
3232
logger.info(f'tokenizer: {model.get_tokenizer()}')
3333

3434
eval_list = get_eval_list(model, config)
35-
# eval_model(model, None, eval_list, eval_pos='pretrain')
35+
eval_model(model, None, eval_list, eval_pos='pretrain')
3636

3737
blockwise_opts = []
3838
modalities, modality_configs = get_modality(config)
@@ -70,7 +70,7 @@ def main(config):
7070
blockwise_opts.append(blockwise_opt)
7171
dist.barrier()
7272

73-
# eval_model(model, blockwise_opts, eval_list, eval_pos='transformed')
73+
eval_model(model, blockwise_opts, eval_list, eval_pos='transformed')
7474
if int(os.environ['RANK']) == 0:
7575
if 'save' in config and config.save.get('save_trans', False):
7676
blockwise_opt.save_model(save_trans_path)
@@ -85,8 +85,8 @@ def main(config):
8585
config.save.get('trtllm_cfg'),
8686
)
8787

88-
# eval_model(model, blockwise_opts, eval_list, eval_pos='fake_quant')
89-
# eval_model(model, blockwise_opts, eval_list, eval_pos='fake_quant_wo_kv')
88+
eval_model(model, blockwise_opts, eval_list, eval_pos='fake_quant')
89+
eval_model(model, blockwise_opts, eval_list, eval_pos='fake_quant_wo_kv')
9090

9191
if 'save' in config and config.save.get('save_fake', False):
9292
deploy_all_modality(blockwise_opts, 'fake_quant')

0 commit comments

Comments
 (0)