DigiP-AI commited on
Commit
081e864
·
verified ·
1 Parent(s): 4f6e0b5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -14
app.py CHANGED
@@ -197,22 +197,23 @@ with gr.Blocks(theme=theme, css=css) as app:
197
  clear_prompt =gr.Button("Clear Prompt 🗑️",variant="primary", elem_id="clear_button")
198
  clear_prompt.click(lambda: (None), None, [text_prompt], queue=False, show_api=False)
199
 
200
- with gr.Group():
201
- # Image output area to display the generated image
 
 
 
 
 
 
 
 
 
202
  with gr.Row():
203
- image_output = gr.Image(type="pil", label="Image Output", format="png", show_share_button=False, elem_id="gallery")
 
204
 
205
- gr.Examples(
206
- examples = examples,
207
- inputs = [text_prompt],
208
- )
209
-
210
- with gr.Row():
211
- clear_results = gr.Button(value="Clear Image 🗑️", variant="primary", elem_id="clear_button")
212
- clear_results.click(lambda: (None), None, [image_output], queue=False, show_api=False)
213
-
214
- # Bind the button to the query function with the added width and height inputs
215
- text_button.click(query, inputs=[text_prompt, negative_prompt, steps, cfg, method, seed, strength, width, height], outputs=image_output)
216
 
217
 
218
  app.queue(default_concurrency_limit=200, max_size=200) # <-- Sets up a queue with default parameters
 
197
  clear_prompt =gr.Button("Clear Prompt 🗑️",variant="primary", elem_id="clear_button")
198
  clear_prompt.click(lambda: (None), None, [text_prompt], queue=False, show_api=False)
199
 
200
+ with gr.Column(elem_id="app-container"):
201
+ with gr.Group():
202
+ # Image output area to display the generated image
203
+ with gr.Row():
204
+ image_output = gr.Image(type="pil", label="Image Output", format="png", show_share_button=False, elem_id="gallery")
205
+
206
+ gr.Examples(
207
+ examples = examples,
208
+ inputs = [text_prompt],
209
+ )
210
+
211
  with gr.Row():
212
+ clear_results = gr.Button(value="Clear Image 🗑️", variant="primary", elem_id="clear_button")
213
+ clear_results.click(lambda: (None), None, [image_output], queue=False, show_api=False)
214
 
215
+ # Bind the button to the query function with the added width and height inputs
216
+ text_button.click(query, inputs=[text_prompt, negative_prompt, steps, cfg, method, seed, strength, width, height], outputs=image_output)
 
 
 
 
 
 
 
 
 
217
 
218
 
219
  app.queue(default_concurrency_limit=200, max_size=200) # <-- Sets up a queue with default parameters