Snearec commited on
Commit
d3a7688
1 Parent(s): 0d6b2e0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -14,9 +14,8 @@ def detect_objects(image: Image.Image):
14
  for r in results:
15
  im_array = r.plot() # plot a BGR numpy array of predictions
16
  im = Image.fromarray(im_array[..., ::-1]) # Convertir a imagen RGB
17
- description += r.print() # Obtener la descripci贸n de los objetos detectados
18
 
19
- return im, description # Retornar la imagen y la descripci贸n
20
 
21
  # Crear la interfaz de Gradio
22
- gr.Interface(fn=detect_objects, inputs="image", outputs=["image", "text"]).launch()
 
14
  for r in results:
15
  im_array = r.plot() # plot a BGR numpy array of predictions
16
  im = Image.fromarray(im_array[..., ::-1]) # Convertir a imagen RGB
 
17
 
18
+ return im
19
 
20
  # Crear la interfaz de Gradio
21
+ gr.Interface(fn=detect_objects, inputs="image", outputs="image").launch()