Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -84,7 +84,7 @@ def generate_output(file, column1, column2, choice, bins):
|
|
84 |
return df.head(), gr.update(visible=True), image_path, gr.update(visible=True)
|
85 |
|
86 |
with gr.Blocks() as demo:
|
87 |
-
with gr.Row():
|
88 |
with gr.Column():
|
89 |
file_input = gr.File(label="上传表格文件(支持CSV、XLS、XLSX等格式", file_types=["csv", "xls", "xlsx"])
|
90 |
col1_dropdown = gr.Dropdown(label="请选择特征列", visible=False)
|
@@ -92,7 +92,7 @@ with gr.Blocks() as demo:
|
|
92 |
choice_radio = gr.Radio(["是", "否"], label="特征列是否为连续值", visible=False) # , value="否"
|
93 |
slider = gr.Slider(minimum=3, maximum=7, step=1, label="选择将特征列分组的分组数", visible=False, value=4)
|
94 |
submit_button = gr.Button("查看结果", visible=False)
|
95 |
-
with gr.Column(
|
96 |
df_display = gr.Dataframe(visible=False)
|
97 |
output_image = gr.Image(visible=False)
|
98 |
|
|
|
84 |
return df.head(), gr.update(visible=True), image_path, gr.update(visible=True)
|
85 |
|
86 |
with gr.Blocks() as demo:
|
87 |
+
with gr.Row(cols=[1, 2]):
|
88 |
with gr.Column():
|
89 |
file_input = gr.File(label="上传表格文件(支持CSV、XLS、XLSX等格式", file_types=["csv", "xls", "xlsx"])
|
90 |
col1_dropdown = gr.Dropdown(label="请选择特征列", visible=False)
|
|
|
92 |
choice_radio = gr.Radio(["是", "否"], label="特征列是否为连续值", visible=False) # , value="否"
|
93 |
slider = gr.Slider(minimum=3, maximum=7, step=1, label="选择将特征列分组的分组数", visible=False, value=4)
|
94 |
submit_button = gr.Button("查看结果", visible=False)
|
95 |
+
with gr.Column():
|
96 |
df_display = gr.Dataframe(visible=False)
|
97 |
output_image = gr.Image(visible=False)
|
98 |
|