Skip to content

Commit 2ac31ba

Browse files
committed
Fixing the python side with the ahash public api removal.
1 parent 9234c4d commit 2ac31ba

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

bindings/python/src/models.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,6 @@ impl Model for PyModel {
7575
self.model.read().unwrap().get_vocab()
7676
}
7777

78-
fn get_vocab_ahash(&self) -> AHashMap<String, u32> {
79-
self.model.read().unwrap().get_vocab_ahash()
80-
}
81-
8278
fn get_vocab_size(&self) -> usize {
8379
self.model.read().unwrap().get_vocab_size()
8480
}
@@ -678,7 +674,7 @@ impl PyWordPiece {
678674
if let Some(vocab) = vocab {
679675
match vocab {
680676
PyVocab::Vocab(vocab) => {
681-
let vocab = vocab.into_iter().collect();
677+
let vocab: AHashMap<_, _> = vocab.into_iter().collect();
682678
builder = builder.vocab(vocab);
683679
}
684680
PyVocab::Filename(vocab_filename) => {

0 commit comments

Comments
 (0)