comdoleger commited on
Commit
007e243
1 Parent(s): 53886e3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -252,7 +252,7 @@ def resize_to_fit(max_size, original_size):
252
  return new_width, new_height
253
 
254
 
255
- def process_generate(fore, prompt, intensity, mode, refprompt, isrmbg, model_type, steps, control_strength):
256
 
257
  max_size = (1500,1500)
258
  if prompt in prompt_list:
@@ -543,6 +543,7 @@ with block:
543
  gr.Markdown("### FAI Fuzer medium: Composite Photography in various styles in less than 2 minutes!")
544
  with gr.Row():
545
  fore = gr.Image(image_mode='RGBA', type="pil", label="Foreground Image", height=400, width=400, min_width=400)
 
546
  # with gr.Column():
547
  result_gallery = gr.Image(label='Output', min_width=400) #gr.Gallery(height=400, object_fit='contain', label='Outputs')
548
  with gr.Row():
@@ -618,7 +619,7 @@ with block:
618
 
619
 
620
 
621
- ins = [fore, prompt, intensity, mode, refprompt, isrmbg, model_type, steps, control_strength]
622
  generate_button.click(fn=process_generate, inputs=ins, outputs=[result_gallery])
623
 
624
 
 
252
  return new_width, new_height
253
 
254
 
255
+ def process_generate(fore, back, prompt, intensity, mode, refprompt, isrmbg, model_type, steps, control_strength):
256
 
257
  max_size = (1500,1500)
258
  if prompt in prompt_list:
 
543
  gr.Markdown("### FAI Fuzer medium: Composite Photography in various styles in less than 2 minutes!")
544
  with gr.Row():
545
  fore = gr.Image(image_mode='RGBA', type="pil", label="Foreground Image", height=400, width=400, min_width=400)
546
+ back = gr.Image(image_mode='RGBA', type="pil", label="Background Image", height=400, width=400, min_width=400)
547
  # with gr.Column():
548
  result_gallery = gr.Image(label='Output', min_width=400) #gr.Gallery(height=400, object_fit='contain', label='Outputs')
549
  with gr.Row():
 
619
 
620
 
621
 
622
+ ins = [fore, back, prompt, intensity, mode, refprompt, isrmbg, model_type, steps, control_strength]
623
  generate_button.click(fn=process_generate, inputs=ins, outputs=[result_gallery])
624
 
625