Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -120,6 +120,7 @@ with gr.Blocks() as app:
|
|
120 |
height="auto")
|
121 |
form_start_btn = gr.Button("Start Harmonization", interactive=False)
|
122 |
form_reset_btn = gr.Button("Reset", interactive=True)
|
|
|
123 |
|
124 |
|
125 |
def on_change_form_composite_image(form_composite_image):
|
@@ -254,6 +255,12 @@ with gr.Blocks() as app:
|
|
254 |
form_reset_btn.click(on_click_form_reset_btn,
|
255 |
inputs=None, outputs=[form_log, form_composite_image, form_mask_image, form_start_btn])
|
256 |
|
|
|
|
|
|
|
|
|
|
|
|
|
257 |
gr.Markdown("""
|
258 |
## Quick Start
|
259 |
1. Select desired `Pretrained Model`.
|
|
|
120 |
height="auto")
|
121 |
form_start_btn = gr.Button("Start Harmonization", interactive=False)
|
122 |
form_reset_btn = gr.Button("Reset", interactive=True)
|
123 |
+
form_stop_btn = gr.Button("Stop", interactive=True)
|
124 |
|
125 |
|
126 |
def on_change_form_composite_image(form_composite_image):
|
|
|
255 |
form_reset_btn.click(on_click_form_reset_btn,
|
256 |
inputs=None, outputs=[form_log, form_composite_image, form_mask_image, form_start_btn])
|
257 |
|
258 |
+
def on_click_form_stop():
|
259 |
+
gr.close_all()
|
260 |
+
|
261 |
+
form_stop_btn.click(on_click_form_stop,
|
262 |
+
inputs=None, outputs=None)
|
263 |
+
|
264 |
gr.Markdown("""
|
265 |
## Quick Start
|
266 |
1. Select desired `Pretrained Model`.
|