alexnasa commited on
Commit
b94e3a2
·
verified ·
1 Parent(s): 922ce8c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -7
app.py CHANGED
@@ -217,7 +217,7 @@ def generate_image(
217
  target_width = 768,
218
  seed = 42,
219
  vae_skip_iter = "0-0.05:1,0.8-1:1",
220
- control_weight_lambda = "0-1:1/3/5",
221
  double_attention = False,
222
  single_attention = True,
223
  ip_scale = "0-1:0.85",
@@ -390,8 +390,10 @@ def create_min_image_input(index, open=True, indices_state=None):
390
  with gr.Column(min_width=256):
391
  image = gr.Image(type="filepath", label=f"Image {index + 1}")
392
  caption = gr.Textbox(label=f"ENT{index + 1} Prompt", value="")
393
- det_btn = gr.Button("Crop to Prompt")
394
  face_btn = gr.Button("Crop to Face")
 
 
395
  id_ip_checkbox = gr.Checkbox(value=True, label=f"ID or not {index + 1}", visible=False)
396
  with gr.Row():
397
  vlm_btn = gr.Button("Generate Caption", visible=False)
@@ -606,13 +608,13 @@ if __name__ == "__main__":
606
  examples = gr.Examples(
607
  examples=[
608
  [
609
- "ENT1 wearing a tiny hat",
610
- "sample/hamster.jpg", "a hamster",
611
- None, None,
612
  ],
613
  [
614
- "ENT1 in a red dress is smiling",
615
- "sample/woman.jpg", "a woman",
616
  None, None,
617
  ],
618
  [
 
217
  target_width = 768,
218
  seed = 42,
219
  vae_skip_iter = "0-0.05:1,0.8-1:1",
220
+ control_weight_lambda = "0-1:1/3.5/5",
221
  double_attention = False,
222
  single_attention = True,
223
  ip_scale = "0-1:0.85",
 
390
  with gr.Column(min_width=256):
391
  image = gr.Image(type="filepath", label=f"Image {index + 1}")
392
  caption = gr.Textbox(label=f"ENT{index + 1} Prompt", value="")
393
+
394
  face_btn = gr.Button("Crop to Face")
395
+ det_btn = gr.Button("Crop to Prompt")
396
+
397
  id_ip_checkbox = gr.Checkbox(value=True, label=f"ID or not {index + 1}", visible=False)
398
  with gr.Row():
399
  vlm_btn = gr.Button("Generate Caption", visible=False)
 
608
  examples = gr.Examples(
609
  examples=[
610
  [
611
+ "ENT1 wearing ENT2",
612
+ "sample/woman2.jpg", "a woman",
613
+ "sample/dress.jpg", "a dress",
614
  ],
615
  [
616
+ "ENT1 wearing a tiny hat",
617
+ "sample/hamster.jpg", "a hamster",
618
  None, None,
619
  ],
620
  [