multimodalart HF Staff commited on
Commit
38835a1
·
verified ·
1 Parent(s): 4163f2f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -310,7 +310,7 @@ def run_diptych_prompting(
310
  final_image = final_image.crop((pixel_offset, pixel_offset, padded_width - pixel_offset, padded_height - pixel_offset))
311
 
312
  # 7. Return all outputs
313
- return final_image, processed_image, full_diptych_result, full_prompt
314
 
315
 
316
  # --- Gradio UI Definition ---
@@ -403,7 +403,7 @@ with gr.Blocks(theme=gr.themes.Soft(), css=css) as demo:
403
  ctrl_scale, width, height, pixel_offset, num_steps, guidance,
404
  real_guidance, seed, randomize_seed
405
  ],
406
- outputs=[output_image, processed_ref_image, full_diptych_image, final_prompt_used]
407
  )
408
  def run_subject_driven_example(input_image, subject_name, target_prompt):
409
  # Construct the full prompt for subject-driven mode
@@ -433,7 +433,7 @@ with gr.Blocks(theme=gr.themes.Soft(), css=css) as demo:
433
  ["./assets/bear_plushie.jpg", "a bear plushie", "a bear plushie drinking bubble tea"]
434
  ],
435
  inputs=[input_image, subject_name, target_prompt],
436
- outputs=[output_image, processed_ref_image, full_diptych_image, final_prompt_used],
437
  fn=run_subject_driven_example,
438
  cache_examples="lazy"
439
  )
 
310
  final_image = final_image.crop((pixel_offset, pixel_offset, padded_width - pixel_offset, padded_height - pixel_offset))
311
 
312
  # 7. Return all outputs
313
+ return final_image, processed_image, full_diptych_result, full_prompt, actual_seed
314
 
315
 
316
  # --- Gradio UI Definition ---
 
403
  ctrl_scale, width, height, pixel_offset, num_steps, guidance,
404
  real_guidance, seed, randomize_seed
405
  ],
406
+ outputs=[output_image, processed_ref_image, full_diptych_image, final_prompt_used, actual_seed]
407
  )
408
  def run_subject_driven_example(input_image, subject_name, target_prompt):
409
  # Construct the full prompt for subject-driven mode
 
433
  ["./assets/bear_plushie.jpg", "a bear plushie", "a bear plushie drinking bubble tea"]
434
  ],
435
  inputs=[input_image, subject_name, target_prompt],
436
+ outputs=[output_image, processed_ref_image, full_diptych_image, final_prompt_used, actual_seed],
437
  fn=run_subject_driven_example,
438
  cache_examples="lazy"
439
  )