1inkusFace commited on
Commit
38ea7b1
·
verified ·
1 Parent(s): 9c98320

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -145,8 +145,8 @@ def infer_60(
145
  pyx.upload_to_ftp(sd35_path)
146
  upscaler_2.to(torch.device('cuda'))
147
  with torch.no_grad():
148
- upscale = upscaler_2(sd_image, tiling=True, tile_width=512, tile_height=512)
149
- upscale2 = upscaler_2(upscale, tiling=True, tile_width=512, tile_height=512)
150
  print('-- got upscaled image --')
151
  downscale = upscale2.resize((upscale2.width // 4, upscale2.height // 4),Image.LANCZOS)
152
  downscale2 = downscale.resize((downscale.width // 4, downscale.height // 4),Image.LANCZOS)
@@ -199,8 +199,8 @@ def infer_90(
199
  pyx.upload_to_ftp(sd35_path)
200
  upscaler_2.to(torch.device('cuda'))
201
  with torch.no_grad():
202
- upscale = upscaler_2(sd_image, tiling=True, tile_width=512, tile_height=512)
203
- upscale2 = upscaler_2(upscale, tiling=True, tile_width=512, tile_height=512)
204
  print('-- got upscaled image --')
205
  downscale = upscale2.resize((upscale2.width // 4, upscale2.height // 4),Image.LANCZOS)
206
  downscale2 = downscale.resize((downscale.width // 4, downscale.height // 4),Image.LANCZOS)
@@ -253,8 +253,8 @@ def infer_110(
253
  pyx.upload_to_ftp(sd35_path)
254
  upscaler_2.to(torch.device('cuda'))
255
  with torch.no_grad():
256
- upscale = upscaler_2(sd_image, tiling=True, tile_width=512, tile_height=512)
257
- upscale2 = upscaler_2(upscale, tiling=True, tile_width=512, tile_height=512)
258
  print('-- got upscaled image --')
259
  downscale = upscale2.resize((upscale2.width // 4, upscale2.height // 4),Image.LANCZOS)
260
  downscale2 = downscale.resize((downscale.width // 4, downscale.height // 4),Image.LANCZOS)
 
145
  pyx.upload_to_ftp(sd35_path)
146
  upscaler_2.to(torch.device('cuda'))
147
  with torch.no_grad():
148
+ upscale = upscaler_2(sd_image, tiling=True, tile_width=256, tile_height=256)
149
+ upscale2 = upscaler_2(upscale, tiling=True, tile_width=256, tile_height=256)
150
  print('-- got upscaled image --')
151
  downscale = upscale2.resize((upscale2.width // 4, upscale2.height // 4),Image.LANCZOS)
152
  downscale2 = downscale.resize((downscale.width // 4, downscale.height // 4),Image.LANCZOS)
 
199
  pyx.upload_to_ftp(sd35_path)
200
  upscaler_2.to(torch.device('cuda'))
201
  with torch.no_grad():
202
+ upscale = upscaler_2(sd_image, tiling=True, tile_width=256, tile_height=256)
203
+ upscale2 = upscaler_2(upscale, tiling=True, tile_width=256, tile_height=256)
204
  print('-- got upscaled image --')
205
  downscale = upscale2.resize((upscale2.width // 4, upscale2.height // 4),Image.LANCZOS)
206
  downscale2 = downscale.resize((downscale.width // 4, downscale.height // 4),Image.LANCZOS)
 
253
  pyx.upload_to_ftp(sd35_path)
254
  upscaler_2.to(torch.device('cuda'))
255
  with torch.no_grad():
256
+ upscale = upscaler_2(sd_image, tiling=True, tile_width=256, tile_height=256)
257
+ upscale2 = upscaler_2(upscale, tiling=True, tile_width=256, tile_height=256)
258
  print('-- got upscaled image --')
259
  downscale = upscale2.resize((upscale2.width // 4, upscale2.height // 4),Image.LANCZOS)
260
  downscale2 = downscale.resize((downscale.width // 4, downscale.height // 4),Image.LANCZOS)