Manjushri commited on
Commit
0602d73
·
1 Parent(s): f83b8ac

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -35,7 +35,7 @@ else:
35
  refiner.unet = torch.compile(refiner.unet, mode="reduce-overhead", fullgraph=True)
36
 
37
  def genie (prompt, negative_prompt, height, width, scale, steps, seed, upscaling, prompt_2, negative_prompt_2, high_noise_frac):
38
- n_steps = 40
39
  generator = np.random.seed(0) if seed == 0 else torch.manual_seed(seed)
40
  int_image = pipe(prompt, prompt_2=prompt_2, negative_prompt=negative_prompt, negative_prompt_2=negative_prompt_2, num_inference_steps=steps, height=height, width=width, guidance_scale=scale, num_images_per_prompt=1, generator=generator, output_type="latent").images
41
  if upscaling == 'Yes':
@@ -58,7 +58,7 @@ gr.Interface(fn=genie, inputs=[gr.Textbox(label='What you want the AI to generat
58
  gr.Radio(['Yes', 'No'], value='No', label='Upscale?'),
59
  gr.Textbox(label='Embedded Prompt'),
60
  gr.Textbox(label='Embedded Negative Prompt'),
61
- gr.Slider(minimum=.7, maximum=.99, value=.8, step=.01, label='Refiner Denoise %')],
62
  outputs=['image', 'image'],
63
  title="Stable Diffusion XL 1.0 GPU",
64
  description="SDXL 1.0 GPU. <br><br><b>WARNING: Capable of producing NSFW (Softcore) images.</b>",
 
35
  refiner.unet = torch.compile(refiner.unet, mode="reduce-overhead", fullgraph=True)
36
 
37
  def genie (prompt, negative_prompt, height, width, scale, steps, seed, upscaling, prompt_2, negative_prompt_2, high_noise_frac):
38
+ #n_steps = 40
39
  generator = np.random.seed(0) if seed == 0 else torch.manual_seed(seed)
40
  int_image = pipe(prompt, prompt_2=prompt_2, negative_prompt=negative_prompt, negative_prompt_2=negative_prompt_2, num_inference_steps=steps, height=height, width=width, guidance_scale=scale, num_images_per_prompt=1, generator=generator, output_type="latent").images
41
  if upscaling == 'Yes':
 
58
  gr.Radio(['Yes', 'No'], value='No', label='Upscale?'),
59
  gr.Textbox(label='Embedded Prompt'),
60
  gr.Textbox(label='Embedded Negative Prompt'),
61
+ gr.Slider(minimum=.7, maximum=.99, value=.95, step=.01, label='Refiner Denoise %')],
62
  outputs=['image', 'image'],
63
  title="Stable Diffusion XL 1.0 GPU",
64
  description="SDXL 1.0 GPU. <br><br><b>WARNING: Capable of producing NSFW (Softcore) images.</b>",