mirror of
https://github.com/KoboldAI/KoboldAI-Client.git
synced 2025-01-24 06:08:53 +01:00
Merge branch 'KoboldAI:main' into united
This commit is contained in:
commit
699c2353e7
2
utils.py
2
utils.py
@ -210,7 +210,7 @@ def aria2_hook(pretrained_model_name_or_path: str, force_download=False, cache_d
|
|||||||
def is_cached(url):
|
def is_cached(url):
|
||||||
try:
|
try:
|
||||||
transformers.file_utils.get_from_cache(url, cache_dir=cache_dir, local_files_only=True)
|
transformers.file_utils.get_from_cache(url, cache_dir=cache_dir, local_files_only=True)
|
||||||
except FileNotFoundError:
|
except (FileNotFoundError, transformers.file_utils.EntryNotFoundError):
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
while True: # Try to get the huggingface.co URL of the model's pytorch_model.bin or pytorch_model.bin.index.json file
|
while True: # Try to get the huggingface.co URL of the model's pytorch_model.bin or pytorch_model.bin.index.json file
|
||||||
|
Loading…
Reference in New Issue
Block a user