LiuZichen commited on
Commit
2d6ee23
·
verified ·
1 Parent(s): 6286d5f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -144,7 +144,7 @@ def get_root_url(request: Request, route_path: str, root_path: str | None):
144
  print(root_path)
145
  return root_path
146
  gr.route_utils.get_root_url = get_root_url
147
- gr.mount_gradio_app(app, demo, path="/demo", root_path="/demo")
148
 
149
  @app.post("/magic_quill/generate_image")
150
  async def generate_image(request: Request):
@@ -313,7 +313,7 @@ async def segmentation(request: Request):
313
  return {"error": str(e)}
314
 
315
  # Mount the Gradio app
316
- app = gr.mount_gradio_app(app, demo, path="/")
317
 
318
  if __name__ == "__main__":
319
  uvicorn.run(app, host="0.0.0.0", port=7860)
 
144
  print(root_path)
145
  return root_path
146
  gr.route_utils.get_root_url = get_root_url
147
+ # gr.mount_gradio_app(app, demo, path="/demo", root_path="/demo")
148
 
149
  @app.post("/magic_quill/generate_image")
150
  async def generate_image(request: Request):
 
313
  return {"error": str(e)}
314
 
315
  # Mount the Gradio app
316
+ app = gr.mount_gradio_app(app, demo, path="/", root_path="/")
317
 
318
  if __name__ == "__main__":
319
  uvicorn.run(app, host="0.0.0.0", port=7860)