alexnasa commited on
Commit
d98a313
·
verified ·
1 Parent(s): b6e3013

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -9
app.py CHANGED
@@ -121,7 +121,7 @@ run_mode = "mod_only"
121
  store_attn_map = False
122
  run_name = time.strftime("%m%d-%H%M")
123
 
124
- num_inputs = 3
125
 
126
  images = []
127
  captions = []
@@ -209,7 +209,6 @@ def generate_image(
209
  prompt,
210
  image_1, caption_1,
211
  image_2 = None, caption_2 = None,
212
- image_3 = None, caption_3 = None,
213
  cond_size = 256,
214
  target_height = 768,
215
  target_width = 768,
@@ -242,11 +241,7 @@ def generate_image(
242
  images.append(image_2)
243
  captions.append(caption_2)
244
  idips_checkboxes.append(True)
245
- elif image_3 != None:
246
- images.append(image_3)
247
- captions.append(caption_3)
248
- idips_checkboxes.append(True)
249
-
250
  print(f"Length of images: {len(images)}")
251
  print(f"Length of captions: {len(captions)}")
252
 
@@ -495,7 +490,7 @@ def cleanup(request: gr.Request):
495
  css = """
496
  #col-container {
497
  margin: 0 auto;
498
- max-width: 1400px;
499
  }
500
  """
501
 
@@ -652,7 +647,6 @@ if __name__ == "__main__":
652
  prompt,
653
  images[0], captions[0],
654
  images[1], captions[1],
655
- images[2], captions[2],
656
  cond_size,
657
  target_height,
658
  target_width,
 
121
  store_attn_map = False
122
  run_name = time.strftime("%m%d-%H%M")
123
 
124
+ num_inputs = 2
125
 
126
  images = []
127
  captions = []
 
209
  prompt,
210
  image_1, caption_1,
211
  image_2 = None, caption_2 = None,
 
212
  cond_size = 256,
213
  target_height = 768,
214
  target_width = 768,
 
241
  images.append(image_2)
242
  captions.append(caption_2)
243
  idips_checkboxes.append(True)
244
+
 
 
 
 
245
  print(f"Length of images: {len(images)}")
246
  print(f"Length of captions: {len(captions)}")
247
 
 
490
  css = """
491
  #col-container {
492
  margin: 0 auto;
493
+ max-width: 1096px;
494
  }
495
  """
496
 
 
647
  prompt,
648
  images[0], captions[0],
649
  images[1], captions[1],
 
650
  cond_size,
651
  target_height,
652
  target_width,