Skip to content

Commit

Permalink
use get_vocab method
Browse files Browse the repository at this point in the history
Signed-off-by: Shun Kiyono <shun.kiyono@sbintuitions.co.jp>
  • Loading branch information
butsugiri committed May 23, 2024
1 parent 0f2874b commit 846ff08
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ def ids_to_text(self, ids):

@property
def vocab(self):
id2vocab = {v: k for k, v in self.tokenizer.vocab.items()}
id2vocab = {v: k for k, v in self.tokenizer.get_vocab().items()}
return [id2vocab[i] for i in range(len(id2vocab))]

@property
Expand Down

0 comments on commit 846ff08

Please sign in to comment.