felixrosberg commited on
Commit
7d2b3a9
Β·
1 Parent(s): 81695aa

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -173,7 +173,7 @@ def run_inference(target, source, slider, adv_slider, settings):
173
  total_img *= 255.0
174
  total_img = total_img.astype('uint8')
175
 
176
- return total_img
177
  except Exception as e:
178
  print(e)
179
  return None
@@ -202,7 +202,7 @@ iface = gradio.Interface(run_inference,
202
  "reconstruction attack",
203
  "adversarial defense"],
204
  label='Options')],
205
- gradio.outputs.Image(),
206
  title="Face Swap",
207
  description=description,
208
  examples=examples,
 
173
  total_img *= 255.0
174
  total_img = total_img.astype('uint8')
175
 
176
+ return total_img, 1.0
177
  except Exception as e:
178
  print(e)
179
  return None
 
202
  "reconstruction attack",
203
  "adversarial defense"],
204
  label='Options')],
205
+ [gradio.outputs.Image(), gradio.outputs.Number()],
206
  title="Face Swap",
207
  description=description,
208
  examples=examples,