DigiP-AI commited on
Commit
2b92370
·
verified ·
1 Parent(s): 00c94d4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -52,7 +52,7 @@ headers = {"Authorization": f"Bearer {API_TOKEN}"}
52
  timeout = 100
53
 
54
 
55
- def query(lora_id, prompt, is_negative=False, steps=28, cfg_scale=3.5, sampler="DPM++ 2M Karras", seed=-1, num_images_per_prompt=1, strength=0.7, width=1024, height=1024):
56
  if prompt == "" or prompt == None:
57
  return None
58
 
@@ -86,7 +86,6 @@ def query(lora_id, prompt, is_negative=False, steps=28, cfg_scale=3.5, sampler=
86
  "cfg_scale": cfg_scale,
87
  "seed": seed if seed != -1 else random.randint(1, 1000000000),
88
  "strength": strength,
89
- "num_images_per_prompt": num_images_per_prompt,
90
  "parameters": {
91
  "width": width, # Pass the width to the API
92
  "height": height # Pass the height to the API
@@ -171,7 +170,6 @@ with gr.Blocks(theme=theme, css=css, elem_id="app-container") as app:
171
  strength = gr.Slider(label="Strength", value=0.7, minimum=0, maximum=1, step=0.001)
172
  seed = gr.Slider(label="Seed", value=-1, minimum=-1, maximum=1000000000, step=1)
173
 
174
- num_images_per_prompt = gr.Slider(label="Images", minimum=1, maximum=5, step=1, value=2, interactive=True, visible=True)
175
  with gr.Row():
176
  with gr.Accordion("🫘Seed", open=False):
177
  seed_output = gr.Textbox(label="Seed Used", show_copy_button = True, elem_id="seed-output")
 
52
  timeout = 100
53
 
54
 
55
+ def query(lora_id, prompt, is_negative=False, steps=28, cfg_scale=3.5, sampler="DPM++ 2M Karras", seed=-1, strength=0.7, width=1024, height=1024):
56
  if prompt == "" or prompt == None:
57
  return None
58
 
 
86
  "cfg_scale": cfg_scale,
87
  "seed": seed if seed != -1 else random.randint(1, 1000000000),
88
  "strength": strength,
 
89
  "parameters": {
90
  "width": width, # Pass the width to the API
91
  "height": height # Pass the height to the API
 
170
  strength = gr.Slider(label="Strength", value=0.7, minimum=0, maximum=1, step=0.001)
171
  seed = gr.Slider(label="Seed", value=-1, minimum=-1, maximum=1000000000, step=1)
172
 
 
173
  with gr.Row():
174
  with gr.Accordion("🫘Seed", open=False):
175
  seed_output = gr.Textbox(label="Seed Used", show_copy_button = True, elem_id="seed-output")