Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,5 +1,3 @@
|
|
| 1 |
-
import os
|
| 2 |
-
|
| 3 |
import gradio as gr
|
| 4 |
|
| 5 |
from src.about import (
|
|
@@ -18,7 +16,7 @@ grouped = get_grouped_dfs(RESULTS_PATH)
|
|
| 18 |
model_info_df = get_model_info_df(RESULTS_PATH)
|
| 19 |
|
| 20 |
|
| 21 |
-
def build_table(result_df, info_df, sort_col
|
| 22 |
merged = get_merged_df(result_df, info_df)
|
| 23 |
if "T" in merged.columns:
|
| 24 |
merged = merged[["T"] + [col for col in merged.columns if col != "T"]]
|
|
@@ -59,7 +57,8 @@ frequency_table = build_table(
|
|
| 59 |
metric_only=True,
|
| 60 |
)
|
| 61 |
|
| 62 |
-
|
|
|
|
| 63 |
gr.HTML(TITLE)
|
| 64 |
gr.Markdown(INTRODUCTION_TEXT, elem_classes="markdown-text")
|
| 65 |
|
|
@@ -100,8 +99,4 @@ with gr.Blocks(css=custom_css, title="TSFM Realworld Bench") as demo:
|
|
| 100 |
show_copy_button=True,
|
| 101 |
)
|
| 102 |
|
| 103 |
-
|
| 104 |
-
demo.queue(default_concurrency_limit=20).launch(
|
| 105 |
-
server_name="0.0.0.0",
|
| 106 |
-
server_port=int(os.getenv("PORT", "7860")),
|
| 107 |
-
)
|
|
|
|
|
|
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
|
| 3 |
from src.about import (
|
|
|
|
| 16 |
model_info_df = get_model_info_df(RESULTS_PATH)
|
| 17 |
|
| 18 |
|
| 19 |
+
def build_table(result_df, info_df, sort_col=None, metric_only=False):
|
| 20 |
merged = get_merged_df(result_df, info_df)
|
| 21 |
if "T" in merged.columns:
|
| 22 |
merged = merged[["T"] + [col for col in merged.columns if col != "T"]]
|
|
|
|
| 57 |
metric_only=True,
|
| 58 |
)
|
| 59 |
|
| 60 |
+
demo = gr.Blocks(css=custom_css)
|
| 61 |
+
with demo:
|
| 62 |
gr.HTML(TITLE)
|
| 63 |
gr.Markdown(INTRODUCTION_TEXT, elem_classes="markdown-text")
|
| 64 |
|
|
|
|
| 99 |
show_copy_button=True,
|
| 100 |
)
|
| 101 |
|
| 102 |
+
demo.queue(default_concurrency_limit=20).launch()
|
|
|
|
|
|
|
|
|
|
|
|