kasper-boy commited on
Commit
78f2b67
1 Parent(s): 4b2a8a9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -43,7 +43,10 @@ def object_detection(image):
43
  buf.seek(0)
44
  plt.close()
45
 
46
- return buf
 
 
 
47
 
48
  # Define the Gradio interface
49
  demo = gr.Interface(
 
43
  buf.seek(0)
44
  plt.close()
45
 
46
+ # Convert buffer to an Image object
47
+ result_image = Image.open(buf)
48
+
49
+ return result_image
50
 
51
  # Define the Gradio interface
52
  demo = gr.Interface(