From b40c7639f8820b71035dcb000785c0f170de9fb8 Mon Sep 17 00:00:00 2001 From: Wauplin Date: Thu, 6 Jun 2024 12:23:01 +0200 Subject: [PATCH] Switch from cached_download to hf_hub_download in tests --- bindings/python/tests/test_serialization.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bindings/python/tests/test_serialization.py b/bindings/python/tests/test_serialization.py index a56c6bb33..4434e6304 100644 --- a/bindings/python/tests/test_serialization.py +++ b/bindings/python/tests/test_serialization.py @@ -3,9 +3,9 @@ import unittest import tqdm - -from huggingface_hub import HfApi, cached_download, hf_hub_url +from huggingface_hub import hf_hub_download from tokenizers import Tokenizer + from .utils import albert_base, data_dir @@ -63,7 +63,7 @@ def test_full_deserialization_hub(self): all_models = [("HueyNemud/das22-10-camembert_pretrained", "tokenizer.json")] for model_id, filename in tqdm.tqdm(all_models): - tokenizer_file = cached_download(hf_hub_url(model_id, filename=filename)) + tokenizer_file = hf_hub_download(model_id, filename=filename) is_ok = check(tokenizer_file) if not is_ok: