CadenzaBaron commited on
Commit
ce09713
1 Parent(s): 148ff33

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +2 -2
README.md CHANGED
@@ -35,10 +35,10 @@ That being said, it has upsides for first MT pass in a game translation context
35
  Sample generation script :
36
 
37
  ```python
38
- from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
39
  import torch
40
  device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu")
41
- tokenizer = transformers.AutoTokenizer.from_pretrained("CadenzaBaron/M2M100-418M-for-GameTranslation-Finetuned-Zh-En")
42
  model = AutoModelForSeq2SeqLM.from_pretrained("CadenzaBaron/M2M100-418M-for-GameTranslation-Finetuned-Zh-En")
43
  model.to(device)
44
  tokenizer.src_lang = "zh"
 
35
  Sample generation script :
36
 
37
  ```python
38
+ from transformers import AutoModelForSeq2SeqLM, M2M100Tokenizer
39
  import torch
40
  device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu")
41
+ tokenizer = transformers.M2M100Tokenizer.from_pretrained("CadenzaBaron/M2M100-418M-for-GameTranslation-Finetuned-Zh-En")
42
  model = AutoModelForSeq2SeqLM.from_pretrained("CadenzaBaron/M2M100-418M-for-GameTranslation-Finetuned-Zh-En")
43
  model.to(device)
44
  tokenizer.src_lang = "zh"