Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -413,7 +413,7 @@ def infer(
|
|
413 |
).images
|
414 |
|
415 |
# Return the first (and only) image
|
416 |
-
return [image,images[0]], seed
|
417 |
|
418 |
except Exception as e:
|
419 |
print(f"Error during inference: {e}")
|
@@ -499,7 +499,7 @@ with gr.Blocks(css=css) as demo:
|
|
499 |
show_label=True,
|
500 |
type="pil"
|
501 |
)
|
502 |
-
final_prompt = gr.Textbox(label="Processed prompt", visible=False)
|
503 |
|
504 |
|
505 |
with gr.Accordion("Advanced Settings", open=False):
|
@@ -550,7 +550,7 @@ with gr.Blocks(css=css) as demo:
|
|
550 |
["./assets/pexels-pixabay-355465.jpg", "daylight, bright sunshine", "custom", "auto" ]
|
551 |
],
|
552 |
inputs=[input_image, prompt, illumination_dropdown, direction_dropdown],
|
553 |
-
outputs=[result, seed
|
554 |
fn=infer,
|
555 |
cache_examples="lazy"
|
556 |
)
|
@@ -575,7 +575,7 @@ with gr.Blocks(css=css) as demo:
|
|
575 |
rewrite_prompt,
|
576 |
# Removed num_images_per_prompt from inputs
|
577 |
],
|
578 |
-
outputs=[result, seed
|
579 |
)
|
580 |
|
581 |
if __name__ == "__main__":
|
|
|
413 |
).images
|
414 |
|
415 |
# Return the first (and only) image
|
416 |
+
return [image,images[0]], seed
|
417 |
|
418 |
except Exception as e:
|
419 |
print(f"Error during inference: {e}")
|
|
|
499 |
show_label=True,
|
500 |
type="pil"
|
501 |
)
|
502 |
+
# final_prompt = gr.Textbox(label="Processed prompt", visible=False)
|
503 |
|
504 |
|
505 |
with gr.Accordion("Advanced Settings", open=False):
|
|
|
550 |
["./assets/pexels-pixabay-355465.jpg", "daylight, bright sunshine", "custom", "auto" ]
|
551 |
],
|
552 |
inputs=[input_image, prompt, illumination_dropdown, direction_dropdown],
|
553 |
+
outputs=[result, seed],
|
554 |
fn=infer,
|
555 |
cache_examples="lazy"
|
556 |
)
|
|
|
575 |
rewrite_prompt,
|
576 |
# Removed num_images_per_prompt from inputs
|
577 |
],
|
578 |
+
outputs=[result, seed],
|
579 |
)
|
580 |
|
581 |
if __name__ == "__main__":
|