efeperro commited on
Commit
6f9e813
1 Parent(s): aa98dc9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -137,15 +137,16 @@ sample_images = [
137
  "sample_image3.jpg"
138
  ]
139
 
140
- # Define Gradio interface
141
  interface = gr.Interface(
142
  fn=generate_caption,
143
- inputs=gr.inputs.Image(tool="editor", label="Upload an image or take a photo"), # Corrected usage
144
  outputs="text",
145
  examples=sample_images,
146
  title="Image Captioning Model",
147
  description="Upload an image, select a sample image, or use your webcam to take a photo and generate a caption."
148
  )
149
 
 
150
  # Run the interface
151
  interface.launch(debug=True)
 
137
  "sample_image3.jpg"
138
  ]
139
 
140
+
141
  interface = gr.Interface(
142
  fn=generate_caption,
143
+ inputs="image", # Specify the input type as "image"
144
  outputs="text",
145
  examples=sample_images,
146
  title="Image Captioning Model",
147
  description="Upload an image, select a sample image, or use your webcam to take a photo and generate a caption."
148
  )
149
 
150
+
151
  # Run the interface
152
  interface.launch(debug=True)