Spaces:
Running
Running
Commit
·
7430bfa
1
Parent(s):
546fcbe
Remove debug logging
Browse files- src/app.py +2 -2
- src/wandb_data.py +0 -14
src/app.py
CHANGED
@@ -28,7 +28,7 @@ def main():
|
|
28 |
validator_states_tab.select(lambda: create_validator_states(), [], [validator_states_dataframe])
|
29 |
|
30 |
with gr.Tab("Validator Weights") as validator_weights_tab:
|
31 |
-
include_inactive_checkbox = gr.Checkbox(False, label="Include Inactive", container=False
|
32 |
|
33 |
validator_weights_dataframe = gr.Dataframe()
|
34 |
validator_weights_dataframe.attach_load_event(lambda include_inactive: create_weights(include_inactive), None, [include_inactive_checkbox])
|
@@ -37,7 +37,7 @@ def main():
|
|
37 |
include_inactive_checkbox.change(lambda include_inactive: create_weights(include_inactive), [include_inactive_checkbox], [validator_weights_dataframe])
|
38 |
|
39 |
with gr.Tab("Submissions") as submissions_tab:
|
40 |
-
include_blacklisted_checkbox = gr.Checkbox(False, label="Include Blacklisted", container=False
|
41 |
|
42 |
submissions_dataframe = gr.Dataframe()
|
43 |
submissions_dataframe.attach_load_event(lambda include_blacklisted: create_submissions(include_blacklisted), None, [include_blacklisted_checkbox])
|
|
|
28 |
validator_states_tab.select(lambda: create_validator_states(), [], [validator_states_dataframe])
|
29 |
|
30 |
with gr.Tab("Validator Weights") as validator_weights_tab:
|
31 |
+
include_inactive_checkbox = gr.Checkbox(False, label="Include Inactive", container=False)
|
32 |
|
33 |
validator_weights_dataframe = gr.Dataframe()
|
34 |
validator_weights_dataframe.attach_load_event(lambda include_inactive: create_weights(include_inactive), None, [include_inactive_checkbox])
|
|
|
37 |
include_inactive_checkbox.change(lambda include_inactive: create_weights(include_inactive), [include_inactive_checkbox], [validator_weights_dataframe])
|
38 |
|
39 |
with gr.Tab("Submissions") as submissions_tab:
|
40 |
+
include_blacklisted_checkbox = gr.Checkbox(False, label="Include Blacklisted", container=False)
|
41 |
|
42 |
submissions_dataframe = gr.Dataframe()
|
43 |
submissions_dataframe.attach_load_event(lambda include_blacklisted: create_submissions(include_blacklisted), None, [include_blacklisted_checkbox])
|
src/wandb_data.py
CHANGED
@@ -306,18 +306,4 @@ def get_current_runs() -> list[Run]:
|
|
306 |
for run in runs:
|
307 |
if run.start_date >= today:
|
308 |
current_runs.append(run)
|
309 |
-
print_results_json(current_runs)
|
310 |
return current_runs
|
311 |
-
|
312 |
-
def print_results_json(runs: list[Run]):
|
313 |
-
validators_to_scores: dict[Uid, dict[Key, str]] = {}
|
314 |
-
for run in runs:
|
315 |
-
scores: dict[Key, str] = {}
|
316 |
-
for hotkey, submission in run.submissions.items():
|
317 |
-
scores[hotkey] = f"({submission.score}, {submission.info.block})"
|
318 |
-
|
319 |
-
validators_to_scores[run.uid] = scores
|
320 |
-
|
321 |
-
validators_to_scores = dict(sorted(validators_to_scores.items(), key=lambda item: item[0]))
|
322 |
-
from json import dumps
|
323 |
-
print(dumps(validators_to_scores, indent=4))
|
|
|
306 |
for run in runs:
|
307 |
if run.start_date >= today:
|
308 |
current_runs.append(run)
|
|
|
309 |
return current_runs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|