Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -202,13 +202,15 @@ def infer(
|
|
| 202 |
print("-- using image file --")
|
| 203 |
print('-- generating image --')
|
| 204 |
#with torch.no_grad():
|
| 205 |
-
|
| 206 |
-
|
| 207 |
-
|
| 208 |
-
|
|
|
|
| 209 |
width=width,
|
| 210 |
height=height,
|
| 211 |
-
|
|
|
|
| 212 |
).images[0]
|
| 213 |
rv_path = f"sd35_{seed}.png"
|
| 214 |
sd_image[0].save(rv_path,optimize=False,compress_level=0)
|
|
|
|
| 202 |
print("-- using image file --")
|
| 203 |
print('-- generating image --')
|
| 204 |
#with torch.no_grad():
|
| 205 |
+
sd_image = pipe(
|
| 206 |
+
prompt=enhanced_prompt, # This conversion is fine
|
| 207 |
+
negative_prompt=negative_prompt,
|
| 208 |
+
guidance_scale=guidance_scale,
|
| 209 |
+
num_inference_steps=num_inference_steps,
|
| 210 |
width=width,
|
| 211 |
height=height,
|
| 212 |
+
latents=sd_image_a,
|
| 213 |
+
generator=generator
|
| 214 |
).images[0]
|
| 215 |
rv_path = f"sd35_{seed}.png"
|
| 216 |
sd_image[0].save(rv_path,optimize=False,compress_level=0)
|