John6666 commited on
Commit
2956d04
β€’
1 Parent(s): f3584e1

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -111,11 +111,11 @@ with gr.Blocks(theme="NoCrypt/miku@>=1.2.2", fill_width=True, css=css) as demo:
111
  gen_event = gr.on(triggers=[run_button.click, prompt.submit],
112
  fn=lambda i, n, m, t1, t2, l1, l2, l3, l4: infer_fn(m, t1, t2, l1, l2, l3, l4) if (i < n) else None,
113
  inputs=[img_i, image_num, model_name, prompt, neg_prompt, positive_prefix, positive_suffix, negative_prefix, negative_suffix],
114
- outputs=[o], queue=True, show_api=True)
115
  gen_event2 = gr.on(triggers=[random_button.click],
116
  fn=lambda i, n, m, t1, t2, l1, l2, l3, l4: infer_rand_fn(m, t1, t2, l1, l2, l3, l4) if (i < n) else None,
117
  inputs=[img_i, image_num, model_name, prompt, neg_prompt, positive_prefix, positive_suffix, negative_prefix, negative_suffix],
118
- outputs=[o], queue=True, show_api=True)
119
  o.change(save_gallery, [o, results], [results, image_files], show_api=False)
120
  stop_button.click(lambda: gr.update(interactive=False), None, stop_button, cancels=[gen_event, gen_event2], show_api=False)
121
 
 
111
  gen_event = gr.on(triggers=[run_button.click, prompt.submit],
112
  fn=lambda i, n, m, t1, t2, l1, l2, l3, l4: infer_fn(m, t1, t2, l1, l2, l3, l4) if (i < n) else None,
113
  inputs=[img_i, image_num, model_name, prompt, neg_prompt, positive_prefix, positive_suffix, negative_prefix, negative_suffix],
114
+ outputs=[o], queue=True, show_api=False)
115
  gen_event2 = gr.on(triggers=[random_button.click],
116
  fn=lambda i, n, m, t1, t2, l1, l2, l3, l4: infer_rand_fn(m, t1, t2, l1, l2, l3, l4) if (i < n) else None,
117
  inputs=[img_i, image_num, model_name, prompt, neg_prompt, positive_prefix, positive_suffix, negative_prefix, negative_suffix],
118
+ outputs=[o], queue=True, show_api=False)
119
  o.change(save_gallery, [o, results], [results, image_files], show_api=False)
120
  stop_button.click(lambda: gr.update(interactive=False), None, stop_button, cancels=[gen_event, gen_event2], show_api=False)
121