SaladSlayer00 commited on
Commit
fb90d20
1 Parent(s): 276b619

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -0
app.py CHANGED
@@ -82,6 +82,13 @@ def predict_and_fetch_images(input_image):
82
  traceback.print_exc()
83
  return "Error during prediction", 0, [], "N/A", str(e)
84
 
 
 
 
 
 
 
 
85
  # Gradio interface
86
  iface = gr.Interface(
87
  fn=predict_and_fetch_images,
@@ -93,6 +100,7 @@ iface = gr.Interface(
93
  "html", # Info/Description as HTML
94
  gr.Textbox(type="text", label="Feedback", placeholder="Provide feedback here") # Feedback textbox
95
  ],
 
96
  live=True,
97
  title="Celebrity Lookalike Predictor",
98
  description="Take a snapshot or upload an image to see which celebrity you look like!"
 
82
  traceback.print_exc()
83
  return "Error during prediction", 0, [], "N/A", str(e)
84
 
85
+ example_images = [
86
+ "images/megan_fox.jpg",
87
+ "images/chris_evans.jpg",
88
+ "images/millie_bobby_brown.jpg",
89
+ "images/alvaro_morte.jpg"
90
+ ]
91
+
92
  # Gradio interface
93
  iface = gr.Interface(
94
  fn=predict_and_fetch_images,
 
100
  "html", # Info/Description as HTML
101
  gr.Textbox(type="text", label="Feedback", placeholder="Provide feedback here") # Feedback textbox
102
  ],
103
+ examples=example_images,
104
  live=True,
105
  title="Celebrity Lookalike Predictor",
106
  description="Take a snapshot or upload an image to see which celebrity you look like!"