nobl3Y commited on
Commit
e867ce7
·
verified ·
1 Parent(s): 60b9091

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -10,7 +10,6 @@ def remove_bg(image):
10
  result = remove(img_bytes)
11
  return Image.open(io.BytesIO(result))
12
 
13
- # Create Gradio interface
14
  app = gr.Interface(
15
  fn=remove_bg,
16
  inputs=gr.Image(type="pil", label="Upload Image"),
@@ -19,5 +18,5 @@ app = gr.Interface(
19
  description="Upload an image and remove the background instantly for free!",
20
  )
21
 
22
- # Launch with API enabled
23
- app.launch(server_name="0.0.0.0", server_port=7860, enable_api=True)
 
10
  result = remove(img_bytes)
11
  return Image.open(io.BytesIO(result))
12
 
 
13
  app = gr.Interface(
14
  fn=remove_bg,
15
  inputs=gr.Image(type="pil", label="Upload Image"),
 
18
  description="Upload an image and remove the background instantly for free!",
19
  )
20
 
21
+ # launch the gradio app normally (API will auto-exist at /api/predict/)
22
+ app.launch(server_name="0.0.0.0", server_port=7860)