Haiss123 commited on
Commit
bf19522
·
verified ·
1 Parent(s): 025b678

Update detection_api.py

Browse files
Files changed (1) hide show
  1. detection_api.py +3 -4
detection_api.py CHANGED
@@ -214,9 +214,8 @@ async def detect_video(file: UploadFile = File(...)):
214
 
215
 
216
  if __name__ == "__main__":
 
217
  import os
218
  port = int(os.environ.get("PORT", 7860))
219
- options = {
220
- "bind": f"0.0.0.0:{port}"
221
- }
222
- StandaloneApplication(app, options).run()
 
214
 
215
 
216
  if __name__ == "__main__":
217
+ import uvicorn
218
  import os
219
  port = int(os.environ.get("PORT", 7860))
220
+ uvicorn.run("main:app", host="0.0.0.0", port=port, reload=False)
221
+