Upload directory
Browse files
README.md
CHANGED
@@ -41,6 +41,7 @@ import sys
|
|
41 |
|
42 |
# helpfer function to download huggingface repo and use model
|
43 |
def download(repo_id, path, HF_TOKEN=None):
|
|
|
44 |
files_path = os.path.join(path, 'files.txt')
|
45 |
if not os.path.exists(files_path):
|
46 |
hf_hub_download(repo_id, 'files.txt', token=HF_TOKEN, local_dir=path, local_dir_use_symlinks=False)
|
|
|
41 |
|
42 |
# helpfer function to download huggingface repo and use model
|
43 |
def download(repo_id, path, HF_TOKEN=None):
|
44 |
+
os.makedirs(path, exist_ok=True)
|
45 |
files_path = os.path.join(path, 'files.txt')
|
46 |
if not os.path.exists(files_path):
|
47 |
hf_hub_download(repo_id, 'files.txt', token=HF_TOKEN, local_dir=path, local_dir_use_symlinks=False)
|