Created
January 18, 2020 15:22
-
-
Save schio/16109d80280cca87112050ba00de8899 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bert_tokens = [] | |
bert_tokens.append("[CLS]") | |
for token in tokens: | |
bert_tokens.append(token) | |
bert_tokens.append("[SEP]") | |
bert_tokens | |
>>> ['[CLS]', 'this', 'here', "'", 's', 'an', 'example', 'of', 'using', 'the', 'bert', 'token', '##izer', '[SEP]'] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment