Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -402,7 +402,6 @@ def merge_loop():
|
|
| 402 |
# Sample two models
|
| 403 |
dir_path = "/home/"
|
| 404 |
print(f"pwd: {os.getcwd()}")
|
| 405 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 406 |
sample = df.sample(n=2)
|
| 407 |
models = [sample.iloc[i] for i in range(2)]
|
| 408 |
|
|
@@ -418,30 +417,32 @@ def merge_loop():
|
|
| 418 |
# Merge configs
|
| 419 |
yaml_config = create_config(models)
|
| 420 |
print(f"YAML config:{yaml_config}")
|
| 421 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 422 |
|
| 423 |
# Merge models
|
| 424 |
merge_models()
|
| 425 |
print("Model merged!")
|
| 426 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 427 |
|
| 428 |
# Create model card
|
| 429 |
print("Create model card")
|
| 430 |
create_model_card(yaml_config, model_name, USERNAME, license)
|
| 431 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 432 |
|
| 433 |
# Upload model
|
| 434 |
print("Upload model")
|
| 435 |
upload_model(api, USERNAME, model_name)
|
| 436 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 437 |
|
| 438 |
# Clear data
|
|
|
|
| 439 |
clear_data()
|
| 440 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 441 |
|
| 442 |
# Evaluate model on Runpod
|
|
|
|
| 443 |
create_pod(model_name, USERNAME)
|
| 444 |
-
print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 445 |
|
| 446 |
|
| 447 |
# Install scrape-open-llm-leaderboard and mergekit
|
|
|
|
| 402 |
# Sample two models
|
| 403 |
dir_path = "/home/"
|
| 404 |
print(f"pwd: {os.getcwd()}")
|
|
|
|
| 405 |
sample = df.sample(n=2)
|
| 406 |
models = [sample.iloc[i] for i in range(2)]
|
| 407 |
|
|
|
|
| 417 |
# Merge configs
|
| 418 |
yaml_config = create_config(models)
|
| 419 |
print(f"YAML config:{yaml_config}")
|
| 420 |
+
# print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 421 |
|
| 422 |
# Merge models
|
| 423 |
merge_models()
|
| 424 |
print("Model merged!")
|
| 425 |
+
# print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 426 |
|
| 427 |
# Create model card
|
| 428 |
print("Create model card")
|
| 429 |
create_model_card(yaml_config, model_name, USERNAME, license)
|
| 430 |
+
# print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 431 |
|
| 432 |
# Upload model
|
| 433 |
print("Upload model")
|
| 434 |
upload_model(api, USERNAME, model_name)
|
| 435 |
+
# print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 436 |
|
| 437 |
# Clear data
|
| 438 |
+
print("Clear data")
|
| 439 |
clear_data()
|
| 440 |
+
# print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 441 |
|
| 442 |
# Evaluate model on Runpod
|
| 443 |
+
print("Start evaluation")
|
| 444 |
create_pod(model_name, USERNAME)
|
| 445 |
+
# print(f"Total size: {human_readable_size(get_size(dir_path))}")
|
| 446 |
|
| 447 |
|
| 448 |
# Install scrape-open-llm-leaderboard and mergekit
|