Spaces:
Running
on
Zero
Running
on
Zero
clean flacon image on new fragrance inference
Browse files
app.py
CHANGED
|
@@ -438,7 +438,7 @@ with gr.Blocks(css=css) as demo:
|
|
| 438 |
bottle_res = gr.Image(label="Flacon")
|
| 439 |
|
| 440 |
def disable_flacon_button():
|
| 441 |
-
return gr.update(interactive=False), gr.update(visible=False)
|
| 442 |
|
| 443 |
def allow_flacon_button():
|
| 444 |
return gr.update(interactive=True), gr.update(visible=True)
|
|
@@ -446,7 +446,7 @@ with gr.Blocks(css=css) as demo:
|
|
| 446 |
submit_btn.click(
|
| 447 |
fn=disable_flacon_button,
|
| 448 |
inputs = [],
|
| 449 |
-
outputs = [get_flacon_btn, output_df]
|
| 450 |
).then(
|
| 451 |
fn=infer,
|
| 452 |
inputs=[image_in],
|
|
|
|
| 438 |
bottle_res = gr.Image(label="Flacon")
|
| 439 |
|
| 440 |
def disable_flacon_button():
|
| 441 |
+
return gr.update(interactive=False), gr.update(visible=False), gr.update(value=None)
|
| 442 |
|
| 443 |
def allow_flacon_button():
|
| 444 |
return gr.update(interactive=True), gr.update(visible=True)
|
|
|
|
| 446 |
submit_btn.click(
|
| 447 |
fn=disable_flacon_button,
|
| 448 |
inputs = [],
|
| 449 |
+
outputs = [get_flacon_btn, output_df, bottle_res]
|
| 450 |
).then(
|
| 451 |
fn=infer,
|
| 452 |
inputs=[image_in],
|