Eran Fainman
commited on
Commit
·
eaf6c27
1
Parent(s):
fd29657
Add application file
Browse files
app.py
CHANGED
@@ -104,9 +104,11 @@ def upload_results(group_email, group_name, model_name, revision, mrr10, precisi
|
|
104 |
df_temp_results = pd.DataFrame({'email': [group_email], 'group_name': [group_name], model_name: [model_name],
|
105 |
"submission_date": [submission_date], "revision": [revision], "MRR10": [mrr10],
|
106 |
"PRECISION10": [precision10]})
|
107 |
-
|
|
|
108 |
df_temp_results.to_csv(temp_path, index=False)
|
109 |
-
hh.upload_file(path_or_fileobj=temp_path, repo_id=RESULTS_REPO, token=TOKEN, repo_type="dataset"
|
|
|
110 |
|
111 |
|
112 |
def render():
|
|
|
104 |
df_temp_results = pd.DataFrame({'email': [group_email], 'group_name': [group_name], model_name: [model_name],
|
105 |
"submission_date": [submission_date], "revision": [revision], "MRR10": [mrr10],
|
106 |
"PRECISION10": [precision10]})
|
107 |
+
temp_results_fn = str(uuid.uuid4()) + '.csv'
|
108 |
+
temp_path = os.path.join(TEMP_RESULTS_PATH, temp_results_fn)
|
109 |
df_temp_results.to_csv(temp_path, index=False)
|
110 |
+
hh.upload_file(path_or_fileobj=temp_path, repo_id=RESULTS_REPO, token=TOKEN, repo_type="dataset",
|
111 |
+
path_in_repo=temp_results_fn)
|
112 |
|
113 |
|
114 |
def render():
|