Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -302,7 +302,7 @@ def generate_30(
|
|
| 302 |
sd_image[0].save(filename,optimize=False,compress_level=0)
|
| 303 |
upload_to_ftp(filename)
|
| 304 |
uploadNote(prompt,num_inference_steps,guidance_scale,timestamp)
|
| 305 |
-
torch.setfloat32_matmul_precision("medium")
|
| 306 |
with torch.no_grad():
|
| 307 |
upscale = upscaler(sd_image, tiling=True, tile_width=256, tile_height=256)
|
| 308 |
downscale1 = upscale.resize((upscale.width // 4, upscale.height // 4), Image.LANCZOS)
|
|
@@ -355,7 +355,7 @@ def generate_60(
|
|
| 355 |
sd_image[0].save(filename,optimize=False,compress_level=0)
|
| 356 |
upload_to_ftp(filename)
|
| 357 |
uploadNote(prompt,num_inference_steps,guidance_scale,timestamp)
|
| 358 |
-
torch.setfloat32_matmul_precision("medium")
|
| 359 |
with torch.no_grad():
|
| 360 |
upscale = upscaler(sd_image, tiling=True, tile_width=256, tile_height=256)
|
| 361 |
downscale1 = upscale.resize((upscale.width // 4, upscale.height // 4), Image.LANCZOS)
|
|
@@ -408,7 +408,7 @@ def generate_90(
|
|
| 408 |
sd_image[0].save(filename,optimize=False,compress_level=0)
|
| 409 |
upload_to_ftp(filename)
|
| 410 |
uploadNote(prompt,num_inference_steps,guidance_scale,timestamp)
|
| 411 |
-
torch.setfloat32_matmul_precision("medium")
|
| 412 |
with torch.no_grad():
|
| 413 |
upscale = upscaler(sd_image, tiling=True, tile_width=256, tile_height=256)
|
| 414 |
downscale1 = upscale.resize((upscale.width // 4, upscale.height // 4), Image.LANCZOS)
|
|
|
|
| 302 |
sd_image[0].save(filename,optimize=False,compress_level=0)
|
| 303 |
upload_to_ftp(filename)
|
| 304 |
uploadNote(prompt,num_inference_steps,guidance_scale,timestamp)
|
| 305 |
+
#torch.setfloat32_matmul_precision("medium")
|
| 306 |
with torch.no_grad():
|
| 307 |
upscale = upscaler(sd_image, tiling=True, tile_width=256, tile_height=256)
|
| 308 |
downscale1 = upscale.resize((upscale.width // 4, upscale.height // 4), Image.LANCZOS)
|
|
|
|
| 355 |
sd_image[0].save(filename,optimize=False,compress_level=0)
|
| 356 |
upload_to_ftp(filename)
|
| 357 |
uploadNote(prompt,num_inference_steps,guidance_scale,timestamp)
|
| 358 |
+
#torch.setfloat32_matmul_precision("medium")
|
| 359 |
with torch.no_grad():
|
| 360 |
upscale = upscaler(sd_image, tiling=True, tile_width=256, tile_height=256)
|
| 361 |
downscale1 = upscale.resize((upscale.width // 4, upscale.height // 4), Image.LANCZOS)
|
|
|
|
| 408 |
sd_image[0].save(filename,optimize=False,compress_level=0)
|
| 409 |
upload_to_ftp(filename)
|
| 410 |
uploadNote(prompt,num_inference_steps,guidance_scale,timestamp)
|
| 411 |
+
#torch.setfloat32_matmul_precision("medium")
|
| 412 |
with torch.no_grad():
|
| 413 |
upscale = upscaler(sd_image, tiling=True, tile_width=256, tile_height=256)
|
| 414 |
downscale1 = upscale.resize((upscale.width // 4, upscale.height // 4), Image.LANCZOS)
|