prithivMLmods commited on
Commit
7cb4b35
·
verified ·
1 Parent(s): 5023417

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -5
app.py CHANGED
@@ -166,7 +166,7 @@ def preview_image_and_mask(image, width, height, overlap_percentage, resize_opti
166
 
167
  return preview
168
 
169
- @spaces.GPU(duration=24)
170
  def infer(image, width, height, overlap_percentage, num_inference_steps, resize_option, custom_resize_percentage, prompt_input, alignment, overlap_left, overlap_right, overlap_top, overlap_bottom):
171
  background, mask = prepare_image_and_mask(image, width, height, overlap_percentage, resize_option, custom_resize_percentage, alignment, overlap_left, overlap_right, overlap_top, overlap_bottom)
172
 
@@ -245,11 +245,24 @@ def update_history(new_image, history):
245
 
246
  css = """
247
  .gradio-container {
248
- width: 1200px !important;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
249
  }
250
- h1 { text-align: center; }
251
- footer { visibility: hidden; }
252
- """
253
 
254
  title = """<h1 align="center">Diffusers Image Outpaint Lightning</h1>
255
  """
 
166
 
167
  return preview
168
 
169
+ @spaces.GPU(duration=20)
170
  def infer(image, width, height, overlap_percentage, num_inference_steps, resize_option, custom_resize_percentage, prompt_input, alignment, overlap_left, overlap_right, overlap_top, overlap_bottom):
171
  background, mask = prepare_image_and_mask(image, width, height, overlap_percentage, resize_option, custom_resize_percentage, alignment, overlap_left, overlap_right, overlap_top, overlap_bottom)
172
 
 
245
 
246
  css = """
247
  .gradio-container {
248
+ max-width: 1200px !important;
249
+ margin: auto !important;
250
+ }
251
+ /* Add some spacing */
252
+ .gr-form > * {
253
+ margin-bottom: 10px;
254
+ }
255
+ .gr-button {
256
+ min-width: 100px; /* Ensure buttons have a minimum width */
257
+ }
258
+ /* Style the history gallery */
259
+ #history_gallery .gr-gallery {
260
+ min-height: 150px; /* Give gallery some minimum height */
261
+ }
262
+ #history_gallery .gr-gallery > .gr-image {
263
+ border: 1px solid #ddd; /* Add subtle border to gallery images */
264
+ border-radius: 4px;
265
  }
 
 
 
266
 
267
  title = """<h1 align="center">Diffusers Image Outpaint Lightning</h1>
268
  """