This commit is contained in:
hiyouga
2024-04-01 21:35:18 +08:00
parent eb259cc573
commit aee634cd20
7 changed files with 37 additions and 16 deletions

View File

@@ -331,7 +331,7 @@ def patch_model(
):
gen_config.do_sample = True
if model_args.resize_vocab:
if is_trainable and model_args.resize_vocab:
_resize_embedding_layer(model, tokenizer)
if is_trainable: