multimodalart HF staff commited on
Commit
3d680e0
1 Parent(s): eef5fc9

No queue for dropdown

Browse files
Files changed (1) hide show
  1. app.py +6 -4
app.py CHANGED
@@ -662,7 +662,9 @@ with gr.Blocks(css="style.css") as demo:
662
  #neg_guidance_1.change(fn = update_label, inputs=[neg_guidance_1], outputs=[add_1])
663
  #neg_guidance_2.change(fn = update_label, inputs=[neg_guidance_2], outputs=[add_2])
664
  #neg_guidance_3.change(fn = update_label, inputs=[neg_guidance_3], outputs=[add_3])
665
- add_1.click(fn=update_counter,inputs=[sega_concepts_counter,edit_concept_1,edit_concept_2,edit_concept_3], outputs=sega_concepts_counter,queue=False).then(fn = update_display_concept, inputs=[add_1, edit_concept_1, neg_guidance_1, sega_concepts_counter], outputs=[box1, concept_1, guidnace_scale_1,neg_guidance_1,row1, row2, sega_concepts_counter],queue=False)
 
 
666
  add_2.click(fn=update_counter,inputs=[sega_concepts_counter,edit_concept_1,edit_concept_2,edit_concept_3], outputs=sega_concepts_counter,queue=False).then(fn = update_display_concept, inputs=[add_2, edit_concept_2, neg_guidance_2, sega_concepts_counter], outputs=[box2, concept_2, guidnace_scale_2,neg_guidance_2,row2, row3, sega_concepts_counter],queue=False)
667
  add_3.click(fn=update_counter,inputs=[sega_concepts_counter,edit_concept_1,edit_concept_2,edit_concept_3], outputs=sega_concepts_counter,queue=False).then(fn = update_display_concept, inputs=[add_3, edit_concept_3, neg_guidance_3, sega_concepts_counter], outputs=[box3, concept_3, guidnace_scale_3,neg_guidance_3,row3, row4, sega_concepts_counter],queue=False)
668
 
@@ -778,9 +780,9 @@ with gr.Blocks(css="style.css") as demo:
778
  fn = reset_do_reconstruction,
779
  outputs = [do_reconstruction], queue = False)
780
 
781
- dropdown1.change(fn=update_dropdown_parms, inputs = [dropdown1], outputs = [guidnace_scale_1,warmup_1, threshold_1])
782
- dropdown2.change(fn=update_dropdown_parms, inputs = [dropdown2], outputs = [guidnace_scale_2,warmup_2, threshold_2])
783
- dropdown3.change(fn=update_dropdown_parms, inputs = [dropdown3], outputs = [guidnace_scale_3,warmup_3, threshold_3])
784
 
785
  clear_components = [input_image,ddpm_edited_image,ddpm_edited_image,sega_edited_image, do_inversion,
786
  src_prompt, steps, src_cfg_scale, seed,
 
662
  #neg_guidance_1.change(fn = update_label, inputs=[neg_guidance_1], outputs=[add_1])
663
  #neg_guidance_2.change(fn = update_label, inputs=[neg_guidance_2], outputs=[add_2])
664
  #neg_guidance_3.change(fn = update_label, inputs=[neg_guidance_3], outputs=[add_3])
665
+ add_1.click(fn=update_counter,
666
+ inputs=[sega_concepts_counter,edit_concept_1,edit_concept_2,edit_concept_3],
667
+ outputs=sega_concepts_counter,queue=False).then(fn = update_display_concept, inputs=[add_1, edit_concept_1, neg_guidance_1, sega_concepts_counter], outputs=[box1, concept_1, guidnace_scale_1,neg_guidance_1,row1, row2, sega_concepts_counter],queue=False)
668
  add_2.click(fn=update_counter,inputs=[sega_concepts_counter,edit_concept_1,edit_concept_2,edit_concept_3], outputs=sega_concepts_counter,queue=False).then(fn = update_display_concept, inputs=[add_2, edit_concept_2, neg_guidance_2, sega_concepts_counter], outputs=[box2, concept_2, guidnace_scale_2,neg_guidance_2,row2, row3, sega_concepts_counter],queue=False)
669
  add_3.click(fn=update_counter,inputs=[sega_concepts_counter,edit_concept_1,edit_concept_2,edit_concept_3], outputs=sega_concepts_counter,queue=False).then(fn = update_display_concept, inputs=[add_3, edit_concept_3, neg_guidance_3, sega_concepts_counter], outputs=[box3, concept_3, guidnace_scale_3,neg_guidance_3,row3, row4, sega_concepts_counter],queue=False)
670
 
 
780
  fn = reset_do_reconstruction,
781
  outputs = [do_reconstruction], queue = False)
782
 
783
+ dropdown1.change(fn=update_dropdown_parms, inputs = [dropdown1], outputs = [guidnace_scale_1,warmup_1, threshold_1], queue=False)
784
+ dropdown2.change(fn=update_dropdown_parms, inputs = [dropdown2], outputs = [guidnace_scale_2,warmup_2, threshold_2], queue=False)
785
+ dropdown3.change(fn=update_dropdown_parms, inputs = [dropdown3], outputs = [guidnace_scale_3,warmup_3, threshold_3], queue=False)
786
 
787
  clear_components = [input_image,ddpm_edited_image,ddpm_edited_image,sega_edited_image, do_inversion,
788
  src_prompt, steps, src_cfg_scale, seed,