solemn-leader
commited on
Commit
•
9f849fa
1
Parent(s):
9a4ac4b
Update README.md
Browse files
README.md
CHANGED
@@ -46,7 +46,7 @@ model = AutoModelForSequenceClassification.from_pretrained('tinkoff-ai/response-
|
|
46 |
inputs = tokenizer('[CLS]привет[SEP]привет![SEP]как дела?[RESPONSE_TOKEN]норм, у тя как?', max_length=128, add_special_tokens=False, return_tensors='pt')
|
47 |
with torch.inference_mode():
|
48 |
logits = model(**inputs).logits
|
49 |
-
probas = torch.softmax(logits)[0].cpu().detach().numpy()
|
50 |
```
|
51 |
|
52 |
|
|
|
46 |
inputs = tokenizer('[CLS]привет[SEP]привет![SEP]как дела?[RESPONSE_TOKEN]норм, у тя как?', max_length=128, add_special_tokens=False, return_tensors='pt')
|
47 |
with torch.inference_mode():
|
48 |
logits = model(**inputs).logits
|
49 |
+
probas = torch.softmax(logits, dim=-1)[0].cpu().detach().numpy()
|
50 |
```
|
51 |
|
52 |
|