Kvikontent commited on
Commit
e55ec3c
1 Parent(s): bc7cf63

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -9,7 +9,7 @@ def generate_image(prompt, negative_prompt="Low quality", width=512, height=512)
9
  # Run pipeline in inference (sample random noise and denoise)
10
  images = ldm([prompt], num_inference_steps=50, eta=0.3, guidance_scale=6, negative_prompts=[negative_prompt]).images
11
  # Resize image to desired width and height
12
- resized_images = [image.resize((width, height)) for image in images]
13
  # Save images
14
  for idx, image in enumerate(resized_images):
15
  image.save(f"squirrel-{idx}.png")
 
9
  # Run pipeline in inference (sample random noise and denoise)
10
  images = ldm([prompt], num_inference_steps=50, eta=0.3, guidance_scale=6, negative_prompts=[negative_prompt]).images
11
  # Resize image to desired width and height
12
+ resized_images = [image.resize((int(width), int(height))) for image in images]
13
  # Save images
14
  for idx, image in enumerate(resized_images):
15
  image.save(f"squirrel-{idx}.png")