Nightfury16 commited on
Commit
bc39c4b
·
1 Parent(s): 807a6f4
Files changed (1) hide show
  1. app/main.py +6 -4
app/main.py CHANGED
@@ -1,14 +1,16 @@
1
  from fastapi import FastAPI
 
2
  from app.api.endpoints import staging
3
- from app.ui.gradio_ui import gradio_app
4
 
5
  app = FastAPI(
6
- title="Auto Pick MobileCLIP API",
7
- description="An API to rank images using MobileCLIP2. Ideal for auto-picking the best photos for real estate, e-commerce, and more.", # <-- CHANGED
8
  version="1.0.0"
9
  )
10
 
11
 
12
  app.include_router(staging.router, prefix="/api/v1", tags=["Image Ranking"])
13
 
14
- app.mount("/", gradio_app)
 
 
1
  from fastapi import FastAPI
2
+ import gradio as gr
3
  from app.api.endpoints import staging
4
+ from app.ui.gradio_ui import gradio_app as gradio_blocks_ui
5
 
6
  app = FastAPI(
7
+ title="Auto Pick MobileCLIP API",
8
+ description="An API to rank images using MobileCLIP2. Ideal for auto-picking the best photos for real estate, e-commerce, and more.",
9
  version="1.0.0"
10
  )
11
 
12
 
13
  app.include_router(staging.router, prefix="/api/v1", tags=["Image Ranking"])
14
 
15
+
16
+ app = gr.mount_gradio_app(app, gradio_blocks_ui, path="/")