julian-schelb
commited on
Commit
•
1733f36
1
Parent(s):
f550e29
Update README.md
Browse files
README.md
CHANGED
@@ -111,7 +111,7 @@ predicted_token_class_ids = logits.argmax(-1)
|
|
111 |
# Note that tokens are classified rather then input words which means that
|
112 |
# there might be more predicted token classes than words.
|
113 |
# Multiple token classes might account for the same word
|
114 |
-
predicted_tokens_classes = [
|
115 |
predicted_tokens_classes
|
116 |
```
|
117 |
|
|
|
111 |
# Note that tokens are classified rather then input words which means that
|
112 |
# there might be more predicted token classes than words.
|
113 |
# Multiple token classes might account for the same word
|
114 |
+
predicted_tokens_classes = [model.config.id2label[t.item()] for t in predicted_token_class_ids[0]]
|
115 |
predicted_tokens_classes
|
116 |
```
|
117 |
|