to-be commited on
Commit
a642a77
1 Parent(s): a043749

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -32,7 +32,7 @@ def inference(img):
32
 
33
  # 'Downsampled Image'
34
  #### Resize the longer edge of the input image
35
- max_res = 512
36
  width, height = img.size
37
  if max(width,height) > max_res:
38
  scale = max_res /max(width,height)
@@ -45,7 +45,7 @@ def inference(img):
45
  load_arch = run_path('restormer_arch.py')
46
  model = load_arch['Restormer'](**parameters)
47
 
48
- checkpoint = torch.load('deshabby.pth')
49
  model.load_state_dict(checkpoint['params'])
50
  device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
51
  model = model.to(device)
 
32
 
33
  # 'Downsampled Image'
34
  #### Resize the longer edge of the input image
35
+ max_res = 200
36
  width, height = img.size
37
  if max(width,height) > max_res:
38
  scale = max_res /max(width,height)
 
45
  load_arch = run_path('restormer_arch.py')
46
  model = load_arch['Restormer'](**parameters)
47
 
48
+ checkpoint = torch.load('net_g_92000.pth')
49
  model.load_state_dict(checkpoint['params'])
50
  device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
51
  model = model.to(device)