adding model names
Browse files
app.py
CHANGED
@@ -10,7 +10,10 @@ def get_plots(task_data):
|
|
10 |
task_df = px.scatter(task_df, x="model", y="total_gpu_energy (Wh)", height= 500, width= 800, color = 'energy_star', color_discrete_map={"β": 'red', "ββ": "yellow", "βββ": "green"})
|
11 |
return task_df
|
12 |
|
13 |
-
|
|
|
|
|
|
|
14 |
demo = gr.Blocks()
|
15 |
|
16 |
with demo:
|
@@ -32,7 +35,11 @@ with demo:
|
|
32 |
)
|
33 |
with gr.TabItem("Text Classification π"):
|
34 |
with gr.Row():
|
35 |
-
|
|
|
|
|
|
|
|
|
36 |
with gr.TabItem("Image Classification πΌοΈ"):
|
37 |
with gr.Row():
|
38 |
landscape_data = gr.components.Dataframe(
|
|
|
10 |
task_df = px.scatter(task_df, x="model", y="total_gpu_energy (Wh)", height= 500, width= 800, color = 'energy_star', color_discrete_map={"β": 'red', "ββ": "yellow", "βββ": "green"})
|
11 |
return task_df
|
12 |
|
13 |
+
def get_model_names(task_data):
|
14 |
+
task_df= pd.read_csv(task_data)
|
15 |
+
return task_df['model']
|
16 |
+
|
17 |
demo = gr.Blocks()
|
18 |
|
19 |
with demo:
|
|
|
35 |
)
|
36 |
with gr.TabItem("Text Classification π"):
|
37 |
with gr.Row():
|
38 |
+
with gr.Column():
|
39 |
+
plot = gr.Plot(get_plots('data/text_classification.csv'))
|
40 |
+
with gr.Column():
|
41 |
+
table = gr.Dataframe(get_model_names'('data/text_classification.csv'))
|
42 |
+
|
43 |
with gr.TabItem("Image Classification πΌοΈ"):
|
44 |
with gr.Row():
|
45 |
landscape_data = gr.components.Dataframe(
|