freddyaboulton HF staff commited on
Commit
7290ef1
·
verified ·
1 Parent(s): bc0c6f3

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -84,7 +84,7 @@ stream = Stream(
84
  # Mount the STREAM UI to the FastAPI app
85
  # Because I don't want to build the UI manually
86
  app = FastAPI()
87
- gr.mount_gradio_app(app, stream.ui, path="/")
88
 
89
 
90
  if __name__ == "__main__":
@@ -95,6 +95,4 @@ if __name__ == "__main__":
95
  elif mode == "PHONE":
96
  stream.fastphone(host="0.0.0.0", port=7860)
97
  else:
98
- import uvicorn
99
-
100
- uvicorn.run(app, host="0.0.0.0", port=7860)
 
84
  # Mount the STREAM UI to the FastAPI app
85
  # Because I don't want to build the UI manually
86
  app = FastAPI()
87
+ app = gr.mount_gradio_app(app, stream.ui, path="/")
88
 
89
 
90
  if __name__ == "__main__":
 
95
  elif mode == "PHONE":
96
  stream.fastphone(host="0.0.0.0", port=7860)
97
  else:
98
+ stream.ui.launch(server_port=7860)