Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -10,7 +10,16 @@ from transformers import AutoTokenizer, AutoModelForSeq2SeqLM, pipeline
|
|
10 |
import torch
|
11 |
from flores200_codes import flores_codes
|
12 |
import gradio as gr
|
|
|
|
|
|
|
|
|
13 |
from starlette.middleware.base import BaseHTTPMiddleware
|
|
|
|
|
|
|
|
|
|
|
14 |
|
15 |
CUSTOM_PATH = "/gradio"
|
16 |
|
|
|
10 |
import torch
|
11 |
from flores200_codes import flores_codes
|
12 |
import gradio as gr
|
13 |
+
|
14 |
+
from fastapi import FastAPI, Request
|
15 |
+
from fastapi.responses import JSONResponse
|
16 |
+
import uvicorn
|
17 |
from starlette.middleware.base import BaseHTTPMiddleware
|
18 |
+
import logging
|
19 |
+
|
20 |
+
# Configure logging
|
21 |
+
logging.basicConfig(level=logging.INFO)
|
22 |
+
logger = logging.getLogger(__name__)
|
23 |
|
24 |
CUSTOM_PATH = "/gradio"
|
25 |
|