alexnasa commited on
Commit
01f75e7
·
verified ·
1 Parent(s): b8314ed

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -5
app.py CHANGED
@@ -270,7 +270,7 @@ def process(
270
  print(e)
271
  image = Image.new(mode="RGB", size=(512, 512))
272
  images.append(np.array(image))
273
- return images
274
 
275
 
276
  #
@@ -310,7 +310,10 @@ with block:
310
  latent_tiled_overlap = gr.Slider(label="Diffusion Tile Overlap", minimum=4, maximum=16, value=4, step=1)
311
  scale_factor = gr.Number(label="SR Scale", value=4)
312
  with gr.Column():
313
- result_gallery = gr.Gallery(label="Output", show_label=False, elem_id="gallery")
 
 
 
314
  examples = gr.Examples(
315
  examples=[
316
  [
@@ -323,7 +326,7 @@ with block:
323
  "clean, high-resolution, 8k, best quality, masterpiece",
324
  "dotted, noise, blur, lowres, oversmooth, longbody, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality",
325
  50,
326
- 2,
327
  7.5,
328
  123,
329
  320,
@@ -340,7 +343,7 @@ with block:
340
  "clean, high-resolution, 8k, best quality, masterpiece",
341
  "dotted, noise, blur, lowres, oversmooth, longbody, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality",
342
  50,
343
- 2,
344
  7.5,
345
  123,
346
  320,
@@ -357,7 +360,7 @@ with block:
357
  "clean, high-resolution, 8k, best quality, masterpiece",
358
  "dotted, noise, blur, lowres, oversmooth, longbody, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality",
359
  50,
360
- 2,
361
  7.5,
362
  123,
363
  320,
 
270
  print(e)
271
  image = Image.new(mode="RGB", size=(512, 512))
272
  images.append(np.array(image))
273
+ return input_image, images[0]
274
 
275
 
276
  #
 
310
  latent_tiled_overlap = gr.Slider(label="Diffusion Tile Overlap", minimum=4, maximum=16, value=4, step=1)
311
  scale_factor = gr.Number(label="SR Scale", value=4)
312
  with gr.Column():
313
+ result_gallery = ImageSlider(
314
+ interactive=False,
315
+ label="Generated Image",
316
+ )
317
  examples = gr.Examples(
318
  examples=[
319
  [
 
326
  "clean, high-resolution, 8k, best quality, masterpiece",
327
  "dotted, noise, blur, lowres, oversmooth, longbody, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality",
328
  50,
329
+ 4,
330
  7.5,
331
  123,
332
  320,
 
343
  "clean, high-resolution, 8k, best quality, masterpiece",
344
  "dotted, noise, blur, lowres, oversmooth, longbody, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality",
345
  50,
346
+ 4,
347
  7.5,
348
  123,
349
  320,
 
360
  "clean, high-resolution, 8k, best quality, masterpiece",
361
  "dotted, noise, blur, lowres, oversmooth, longbody, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality",
362
  50,
363
+ 4,
364
  7.5,
365
  123,
366
  320,