Update app.py
Browse files
app.py
CHANGED
@@ -103,7 +103,6 @@ def process_image(image_input, unit):
|
|
103 |
|
104 |
def refresh():
|
105 |
global result
|
106 |
-
time.sleep(30)
|
107 |
return result
|
108 |
|
109 |
def reset_result():
|
@@ -136,8 +135,9 @@ with gr.Blocks(css=css, title="家庭医生AI助手", theme="soft") as iface:
|
|
136 |
gr.Markdown(LICENSE)
|
137 |
|
138 |
# Set up the event listeners
|
139 |
-
submit_btn.click(main, inputs=[text_input, image_input, unit], outputs=output_box)
|
140 |
-
|
|
|
141 |
|
142 |
|
143 |
#gr.close_all()
|
|
|
103 |
|
104 |
def refresh():
|
105 |
global result
|
|
|
106 |
return result
|
107 |
|
108 |
def reset_result():
|
|
|
135 |
gr.Markdown(LICENSE)
|
136 |
|
137 |
# Set up the event listeners
|
138 |
+
submit_btn.click(main, inputs=[text_input, image_input, unit], outputs=output_box).then(output_box.change(refresh, every= 10, outputs=output_box))
|
139 |
+
|
140 |
+
|
141 |
|
142 |
|
143 |
#gr.close_all()
|