lysandre HF staff Liqs commited on
Commit
714eb0f
1 Parent(s): 4643665

Change loaded mode to correct on that this model card refers to (#26)

Browse files

- Change loaded mode to correct on that this model card refers to (6a50985739210b7567055a1414bf2449cc241c1b)


Co-authored-by: Tobias Lindenbauer <Liqs@users.noreply.huggingface.co>

Files changed (1) hide show
  1. README.md +2 -2
README.md CHANGED
@@ -141,8 +141,8 @@ Example of single-label classification:
141
  import torch
142
  from transformers import DistilBertTokenizer, DistilBertForSequenceClassification
143
 
144
- tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased")
145
- model = DistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased")
146
 
147
  inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
148
  with torch.no_grad():
141
  import torch
142
  from transformers import DistilBertTokenizer, DistilBertForSequenceClassification
143
 
144
+ tokenizer = DistilBertTokenizer.from_pretrained("distilbert-base-uncased-finetuned-sst-2-english")
145
+ model = DistilBertForSequenceClassification.from_pretrained("distilbert-base-uncased-finetuned-sst-2-english")
146
 
147
  inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
148
  with torch.no_grad():