Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -966,7 +966,7 @@ def update_results(selected_models):
|
|
966 |
visibility = [False] * 9
|
967 |
|
968 |
# Update visibility based on the selected models
|
969 |
-
if "
|
970 |
visibility[0] = True # ko_deplot_generated_table
|
971 |
visibility[1] = True # ko_deplot_score_table
|
972 |
visibility[6] = True # ko_deplot_label_table
|
@@ -976,7 +976,7 @@ def update_results(selected_models):
|
|
976 |
visibility[3] = True # aihub_deplot_score_table
|
977 |
visibility[7] = True # aihub_deplot_label_table
|
978 |
'''
|
979 |
-
if "
|
980 |
visibility[4] = True # unichart_generated_table
|
981 |
visibility[5] = True # unichart_score_table
|
982 |
visibility[8] = True # unichart_label_table
|
@@ -1067,7 +1067,7 @@ with gr.Blocks(css=css) as iface:
|
|
1067 |
file_uploader= gr.File(file_count="single", file_types=[".txt"], visible=False)
|
1068 |
file_upload_option=gr.Radio(choices=["low score ์ฐจํธ","high score ์ฐจํธ"],label="ํ์ผ ์
๋ก๋ ์ต์
",visible=False)
|
1069 |
chart_type = gr.Dropdown(["์ผ๋ฐ ๊ฐ๋ก ๋ง๋ํ","๋์ ๊ฐ๋ก ๋ง๋ํ","100% ๊ธฐ์ค ๋์ ๊ฐ๋ก ๋ง๋ํ", "์ผ๋ฐ ์ธ๋ก ๋ง๋ํ","๋์ ์ธ๋ก ๋ง๋ํ","100% ๊ธฐ์ค ๋์ ์ธ๋ก ๋ง๋ํ","์ ํ", "์ํ", "๊ธฐํ ๋ฐฉ์ฌํ", "๊ธฐํ ํผํฉํ", "์ ์ฒด"], label="Chart Type", value="all")
|
1070 |
-
model_type=gr.Dropdown(["
|
1071 |
image_displayer=gr.Image(visible=True)
|
1072 |
with gr.Row():
|
1073 |
pre_button=gr.Button("์ด์ ",interactive="False")
|
@@ -1077,17 +1077,17 @@ with gr.Blocks(css=css) as iface:
|
|
1077 |
#file_button.click(interface_selector, inputs=gr.State("ํ์ผ ์
๋ก๋"), outputs=[image_uploader, file_uploader,mode,mode_label,image_name])
|
1078 |
inference_button=gr.Button("์ถ๋ก ")
|
1079 |
with gr.Column():
|
1080 |
-
ko_deplot_generated_table=gr.DataFrame(visible=False,label="
|
1081 |
aihub_deplot_generated_table=gr.DataFrame(visible=False,label="aihub-deplot ์ถ๋ก ๊ฒฐ๊ณผ",elem_classes="dataframe-class")
|
1082 |
-
unichart_generated_table=gr.DataFrame(visible=False,label="
|
1083 |
with gr.Column():
|
1084 |
-
ko_deplot_label_table=gr.DataFrame(visible=False,label="
|
1085 |
aihub_deplot_label_table=gr.DataFrame(visible=False,label="aihub-deplot ์ ๋ตํ
์ด๋ธ",elem_classes="dataframe-class")
|
1086 |
-
unichart_label_table=gr.DataFrame(visible=False,label="
|
1087 |
with gr.Column():
|
1088 |
-
ko_deplot_score_table=gr.DataFrame(visible=False,label="
|
1089 |
aihub_deplot_score_table=gr.DataFrame(visible=False,label="aihub_deplot ์ ์",elem_classes="dataframe-class")
|
1090 |
-
unichart_score_table=gr.DataFrame(visible=False,label="
|
1091 |
model_type.change(
|
1092 |
update_results,
|
1093 |
inputs=[model_type],
|
|
|
966 |
visibility = [False] * 9
|
967 |
|
968 |
# Update visibility based on the selected models
|
969 |
+
if "VAIV_DePlot" in selected_models:
|
970 |
visibility[0] = True # ko_deplot_generated_table
|
971 |
visibility[1] = True # ko_deplot_score_table
|
972 |
visibility[6] = True # ko_deplot_label_table
|
|
|
976 |
visibility[3] = True # aihub_deplot_score_table
|
977 |
visibility[7] = True # aihub_deplot_label_table
|
978 |
'''
|
979 |
+
if "VAIV_UniChart" in selected_models:
|
980 |
visibility[4] = True # unichart_generated_table
|
981 |
visibility[5] = True # unichart_score_table
|
982 |
visibility[8] = True # unichart_label_table
|
|
|
1067 |
file_uploader= gr.File(file_count="single", file_types=[".txt"], visible=False)
|
1068 |
file_upload_option=gr.Radio(choices=["low score ์ฐจํธ","high score ์ฐจํธ"],label="ํ์ผ ์
๋ก๋ ์ต์
",visible=False)
|
1069 |
chart_type = gr.Dropdown(["์ผ๋ฐ ๊ฐ๋ก ๋ง๋ํ","๋์ ๊ฐ๋ก ๋ง๋ํ","100% ๊ธฐ์ค ๋์ ๊ฐ๋ก ๋ง๋ํ", "์ผ๋ฐ ์ธ๋ก ๋ง๋ํ","๋์ ์ธ๋ก ๋ง๋ํ","100% ๊ธฐ์ค ๋์ ์ธ๋ก ๋ง๋ํ","์ ํ", "์ํ", "๊ธฐํ ๋ฐฉ์ฌํ", "๊ธฐํ ํผํฉํ", "์ ์ฒด"], label="Chart Type", value="all")
|
1070 |
+
model_type=gr.Dropdown(["VAIV_DePlot","VAIV_UniChart","all"],label="model",multiselect=True)
|
1071 |
image_displayer=gr.Image(visible=True)
|
1072 |
with gr.Row():
|
1073 |
pre_button=gr.Button("์ด์ ",interactive="False")
|
|
|
1077 |
#file_button.click(interface_selector, inputs=gr.State("ํ์ผ ์
๋ก๋"), outputs=[image_uploader, file_uploader,mode,mode_label,image_name])
|
1078 |
inference_button=gr.Button("์ถ๋ก ")
|
1079 |
with gr.Column():
|
1080 |
+
ko_deplot_generated_table=gr.DataFrame(visible=False,label="VAIV_DePlot ์ถ๋ก ๊ฒฐ๊ณผ",elem_classes="dataframe-class")
|
1081 |
aihub_deplot_generated_table=gr.DataFrame(visible=False,label="aihub-deplot ์ถ๋ก ๊ฒฐ๊ณผ",elem_classes="dataframe-class")
|
1082 |
+
unichart_generated_table=gr.DataFrame(visible=False,label="VAIV_UniChart ์ถ๋ก ๊ฒฐ๊ณผ",elem_classes="dataframe-class")
|
1083 |
with gr.Column():
|
1084 |
+
ko_deplot_label_table=gr.DataFrame(visible=False,label="VAIV_DePlot ์ ๋ตํ
์ด๋ธ",elem_classes="dataframe-class")
|
1085 |
aihub_deplot_label_table=gr.DataFrame(visible=False,label="aihub-deplot ์ ๋ตํ
์ด๋ธ",elem_classes="dataframe-class")
|
1086 |
+
unichart_label_table=gr.DataFrame(visible=False,label="VAIV_UniChart ์ ๋ตํ
์ด๋ธ",elem_classes="dataframe-class")
|
1087 |
with gr.Column():
|
1088 |
+
ko_deplot_score_table=gr.DataFrame(visible=False,label="VAIV_DePlot ์ ์",elem_classes="dataframe-class")
|
1089 |
aihub_deplot_score_table=gr.DataFrame(visible=False,label="aihub_deplot ์ ์",elem_classes="dataframe-class")
|
1090 |
+
unichart_score_table=gr.DataFrame(visible=False,label="VAIV_UniChart ์ ์",elem_classes="dataframe-class")
|
1091 |
model_type.change(
|
1092 |
update_results,
|
1093 |
inputs=[model_type],
|