Skip to content

Commit

Permalink
Update bindings/python/src/tokenizer.rs
Browse files Browse the repository at this point in the history
Co-authored-by: Nicolas Patry <[email protected]>
  • Loading branch information
ArthurZucker and Narsil authored Nov 5, 2024
1 parent 8c96f47 commit e1169ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bindings/python/src/tokenizer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1036,7 +1036,7 @@ impl PyTokenizer {
is_pretokenized: bool,
add_special_tokens: bool,
) -> PyResult<Vec<PyEncoding>> {
let mut items = Vec::<tk::EncodeInput>::new();
let mut items = Vec::<tk::EncodeInput>::with_capacity(input.len());
for i in 0..input.len()? {
let item = input.get_item(i)?;
let item: tk::EncodeInput = if is_pretokenized {
Expand Down

0 comments on commit e1169ee

Please sign in to comment.