"vscode:/vscode.git/clone" did not exist on "94eb68d74202f4c8ed90a0f7a74a9dffa1487a0a"
Unverified Commit 3951c2c1 authored by Thomas Wolf's avatar Thomas Wolf Committed by GitHub
Browse files

Merge pull request #60 from davidefiocco/patch-1

Updated quick-start example with `BertForMaskedLM`
parents 21f01964 ec2c339b
......@@ -142,7 +142,7 @@ predictions = model(tokens_tensor, segments_tensors)
# confirm we were able to predict 'henson'
predicted_index = torch.argmax(predictions[0, masked_index]).item()
predicted_token = tokenizer.convert_ids_to_tokens([predicted_index])
predicted_token = tokenizer.convert_ids_to_tokens([predicted_index])[0]
assert predicted_token == 'henson'
```
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment