Commit ·
eb898c5
1
Parent(s): a3de4e4
Upload causallm-to-hub.py
Browse files- causallm-to-hub.py +3 -3
causallm-to-hub.py
CHANGED
|
@@ -35,12 +35,12 @@ def main():
|
|
| 35 |
from huggingface_hub import HfApi
|
| 36 |
|
| 37 |
api = HfApi()
|
| 38 |
-
for file in ["all_results.json", "eval_results.json"]:
|
| 39 |
try:
|
| 40 |
api.upload_file(
|
| 41 |
-
path_or_fileobj=f"{args.
|
| 42 |
path_in_repo=file,
|
| 43 |
-
repo_id=args.
|
| 44 |
repo_type="model",
|
| 45 |
)
|
| 46 |
except Exception as e:
|
|
|
|
| 35 |
from huggingface_hub import HfApi
|
| 36 |
|
| 37 |
api = HfApi()
|
| 38 |
+
for file in ["training_args.bin", "all_results.json", "eval_results.json"]:
|
| 39 |
try:
|
| 40 |
api.upload_file(
|
| 41 |
+
path_or_fileobj=f"{args.path}/{file}",
|
| 42 |
path_in_repo=file,
|
| 43 |
+
repo_id=args.hub_name,
|
| 44 |
repo_type="model",
|
| 45 |
)
|
| 46 |
except Exception as e:
|