File tree Expand file tree Collapse file tree 6 files changed +10
-12
lines changed Expand file tree Collapse file tree 6 files changed +10
-12
lines changed Original file line number Diff line number Diff line change 60
60
model .generation_config .max_length = int (30 * model .audio_encoder .config .frame_rate )
61
61
model .generation_config .do_sample = True # True
62
62
model .generation_config .guidance_scale = 1 # 3.0
63
+
64
+ model .config .pad_token_id = encodec_vocab_size
65
+ model .config .decoder_start_token_id = encodec_vocab_size + 1
63
66
64
67
model .save_pretrained (os .path .join (args .save_directory , "tiny-model" ))
Original file line number Diff line number Diff line change 60
60
model .generation_config .max_length = int (30 * model .audio_encoder .config .frame_rate )
61
61
model .generation_config .do_sample = True # True
62
62
model .generation_config .guidance_scale = 1 # 3.0
63
+
64
+ model .config .pad_token_id = encodec_vocab_size
65
+ model .config .decoder_start_token_id = encodec_vocab_size + 1
63
66
64
67
model .save_pretrained (os .path .join (args .save_directory , "parler-tts-untrained-300M/" ))
Original file line number Diff line number Diff line change 37
37
38
38
"preprocessing_num_workers" : 8 ,
39
39
40
- "pad_token_id" : 1024 ,
41
- "decoder_start_token_id" : 1025 ,
42
-
43
40
"do_train" : true ,
44
41
"num_train_epochs" : 50 ,
45
42
"gradient_accumulation_steps" : 1 ,
Original file line number Diff line number Diff line change 39
39
40
40
"preprocessing_num_workers" : 8 ,
41
41
42
- "pad_token_id" : 1024 ,
43
- "decoder_start_token_id" : 1025 ,
44
-
45
42
"do_train" : true ,
46
43
"num_train_epochs" : 40 ,
47
44
"gradient_accumulation_steps" : 1 ,
Original file line number Diff line number Diff line change @@ -124,8 +124,6 @@ accelerate launch ./training/run_parler_tts_training.py \
124
124
--add_audio_samples_to_wandb true \
125
125
--id_column_name " id" \
126
126
--preprocessing_num_workers 8 \
127
- --pad_token_id 1024 \
128
- --decoder_start_token_id 1025 \
129
127
--do_train true \
130
128
--num_train_epochs 50 \
131
129
--gradient_accumulation_steps 1 \
Original file line number Diff line number Diff line change @@ -235,11 +235,11 @@ class ModelArguments:
235
235
metadata = {"help" : "Whether to freeze the text encoder." },
236
236
)
237
237
do_sample : bool = field (
238
- default = False ,
238
+ default = True ,
239
239
metadata = {"help" : "Whether to do sampling or greedy decoding." },
240
240
)
241
241
temperature : float = field (
242
- default = 0.4 ,
242
+ default = 1.0 ,
243
243
metadata = {"help" : "Temperature if sampling." },
244
244
)
245
245
max_length : int = field (
@@ -1018,10 +1018,10 @@ def main():
1018
1018
{
1019
1019
"pad_token_id" : model_args .pad_token_id
1020
1020
if model_args .pad_token_id is not None
1021
- else model . config .pad_token_id ,
1021
+ else config .pad_token_id ,
1022
1022
"decoder_start_token_id" : model_args .decoder_start_token_id
1023
1023
if model_args .decoder_start_token_id is not None
1024
- else model . config .decoder_start_token_id ,
1024
+ else config .decoder_start_token_id ,
1025
1025
}
1026
1026
)
1027
1027
You can’t perform that action at this time.
0 commit comments