We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c8f36d1 commit 99b88b1Copy full SHA for 99b88b1
medcat-v2/tests/components/addons/meta_cat/test_bert_meta_cat.py
@@ -56,9 +56,12 @@ def _force_hf_download(temp_dir_path: str):
56
57
def replacement_method(*args, **kwargs):
58
method_calls.append((len(args), len(kwargs)))
59
- return orig_from_pretrained(
+ print(f"=== DEBUG: Cache dir contents BEFORE: {os.listdir(temp_dir_path)} ===")
60
+ result = orig_from_pretrained(
61
*args, force_download=True,
62
cache_dir=temp_dir_path, **kwargs)
63
+ print(f"=== DEBUG: Cache dir contents AFTER: {os.listdir(temp_dir_path)} ===")
64
+ return result
65
transformers.BertModel.from_pretrained = replacement_method
66
try:
67
yield
0 commit comments