kyrilloswahid commited on
Commit
b5fa44d
·
verified ·
1 Parent(s): 84927b1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -4
app.py CHANGED
@@ -74,19 +74,16 @@ def predict(image):
74
 
75
  return "\n".join(results), output_image
76
 
77
-
78
-
79
  # Gradio Interface
80
  interface = gr.Interface(
81
  fn=predict,
82
- inputs=gr.Image(type="filepath", label="Upload Image"), # ✅ EDITED
83
  outputs=[
84
  gr.Textbox(label="Predictions"),
85
  gr.Image(type="numpy", label="Annotated Image"),
86
  ],
87
  title="Deepfake Detector (Multi-Face Ensemble)",
88
  description="Detects all faces in an image and classifies each one as real or fake using Xception and EfficientNetB4 ensemble.",
89
- api_name="/predict" # ✅ ADDED
90
  )
91
 
92
  interface.launch()
 
74
 
75
  return "\n".join(results), output_image
76
 
 
 
77
  # Gradio Interface
78
  interface = gr.Interface(
79
  fn=predict,
80
+ inputs=gr.Image(type="numpy", label="Upload Image"),
81
  outputs=[
82
  gr.Textbox(label="Predictions"),
83
  gr.Image(type="numpy", label="Annotated Image"),
84
  ],
85
  title="Deepfake Detector (Multi-Face Ensemble)",
86
  description="Detects all faces in an image and classifies each one as real or fake using Xception and EfficientNetB4 ensemble.",
 
87
  )
88
 
89
  interface.launch()