From bcde2c61cb2a9b4b5c2b2234e2e8cee505e695e8 Mon Sep 17 00:00:00 2001 From: thomwolf Date: Wed, 17 Apr 2019 12:35:38 +0200 Subject: [PATCH] fix #497 --- pytorch_pretrained_bert/tokenization_gpt2.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pytorch_pretrained_bert/tokenization_gpt2.py b/pytorch_pretrained_bert/tokenization_gpt2.py index 80be4435df..07777292a3 100644 --- a/pytorch_pretrained_bert/tokenization_gpt2.py +++ b/pytorch_pretrained_bert/tokenization_gpt2.py @@ -97,6 +97,7 @@ class GPT2Tokenizer(object): if pretrained_model_name_or_path in PRETRAINED_VOCAB_ARCHIVE_MAP: vocab_file = PRETRAINED_VOCAB_ARCHIVE_MAP[pretrained_model_name_or_path] merges_file = PRETRAINED_MERGES_ARCHIVE_MAP[pretrained_model_name_or_path] + special_tokens_file = None else: vocab_file = os.path.join(pretrained_model_name_or_path, VOCAB_NAME) merges_file = os.path.join(pretrained_model_name_or_path, MERGES_NAME)