Spaces:
Runtime error
Runtime error
Commenting out Regis' code for error printing (for now) to repurpose the script.
Browse files- failed_run.py +8 -8
failed_run.py
CHANGED
@@ -31,14 +31,14 @@ dataset = load_dataset("EnergyStarAI/requests_debug", split="test", token=TOKEN)
|
|
31 |
# Set benchmark to failed
|
32 |
dataset.loc[dataset["model"].isin(args.model_name), ['status']] = "FAILED"
|
33 |
|
34 |
-
|
35 |
-
with open(f"{args.run_dir}/error.log", 'r') as file:
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
if "error_message" not in dataset.columns:
|
40 |
-
dataset["error_message"] = ""
|
41 |
-
dataset.loc[dataset["model"].isin(args.model_name), ['error_message']] = error_message
|
42 |
|
43 |
updated_dataset = Dataset.from_pandas(dataset)
|
44 |
updated_dataset.push_to_hub("EnergyStarAI/requests_debug", split="test", token=TOKEN)
|
|
|
31 |
# Set benchmark to failed
|
32 |
dataset.loc[dataset["model"].isin(args.model_name), ['status']] = "FAILED"
|
33 |
|
34 |
+
## Read error message
|
35 |
+
# with open(f"{args.run_dir}/error.log", 'r') as file:
|
36 |
+
# error_message = file.read()
|
37 |
+
#
|
38 |
+
## Add a new column for the error message if necessary
|
39 |
+
#if "error_message" not in dataset.columns:
|
40 |
+
# dataset["error_message"] = ""
|
41 |
+
#dataset.loc[dataset["model"].isin(args.model_name), ['error_message']] = error_message
|
42 |
|
43 |
updated_dataset = Dataset.from_pandas(dataset)
|
44 |
updated_dataset.push_to_hub("EnergyStarAI/requests_debug", split="test", token=TOKEN)
|