Spaces:
Runtime error
Runtime error
Update create_results.py
Browse files- create_results.py +1 -14
create_results.py
CHANGED
@@ -21,20 +21,7 @@ api.upload_folder(
|
|
21 |
requests = load_dataset("EnergyStarAI/requests_debug", split="test", token=TOKEN)
|
22 |
requests_dset = requests.to_pandas()
|
23 |
|
24 |
-
models_ran=[]
|
25 |
-
for dir, path, files in os.walk(out_dir):
|
26 |
-
print("Dir is: ")
|
27 |
-
print(dir)
|
28 |
-
print("Path is:")
|
29 |
-
print(path)
|
30 |
-
print("Files are:")
|
31 |
-
print(files)
|
32 |
-
for fid in files:
|
33 |
-
print("fid is:")
|
34 |
-
print(fid)
|
35 |
-
model = os.path.join(dir, fid)
|
36 |
-
models_ran.append(model)
|
37 |
-
|
38 |
print("Models ran are: " + str(models_ran))
|
39 |
|
40 |
requests_dset.loc[requests_dset["model"].isin(models_ran), ['status']] = "COMPLETED"
|
|
|
21 |
requests = load_dataset("EnergyStarAI/requests_debug", split="test", token=TOKEN)
|
22 |
requests_dset = requests.to_pandas()
|
23 |
|
24 |
+
models_ran=[ f.path for f in os.scandir(out_dir) if f.is_dir() ]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
print("Models ran are: " + str(models_ran))
|
26 |
|
27 |
requests_dset.loc[requests_dset["model"].isin(models_ran), ['status']] = "COMPLETED"
|