marsggbo commited on
Commit
11f5c06
1 Parent(s): bd20f23

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1 -1
README.md CHANGED
@@ -15,7 +15,7 @@ Lora weights after finetuning Switch-base-32 on WMT16 datasets.
15
  from peft import PeftModel
16
  from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
17
 
18
- base_model = AutoModelForSeq2SeqLM.from_pretrained('google/switch-base-32')
19
  lora_model = PeftModel.from_pretrained(base_model, 'marsggbo/wmt-switch-base-32-lora-ckpt140000')
20
  merged_model = lora_model.merge_and_unload()
21
  merged_model.save_pretrained('./switch-base-32-wmt', state_dict=merged_model.state_dict(), safe_serialization=False)
 
15
  from peft import PeftModel
16
  from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
17
 
18
+ base_model = AutoModelForSeq2SeqLM.from_pretrained('google/switch-base-32', use_safetensors=False)
19
  lora_model = PeftModel.from_pretrained(base_model, 'marsggbo/wmt-switch-base-32-lora-ckpt140000')
20
  merged_model = lora_model.merge_and_unload()
21
  merged_model.save_pretrained('./switch-base-32-wmt', state_dict=merged_model.state_dict(), safe_serialization=False)