Update main.py
Browse files
main.py
CHANGED
@@ -15,7 +15,7 @@ from vtoonify_model import Model
|
|
15 |
app = FastAPI()
|
16 |
model = Model(device='cuda' if torch.cuda.is_available() else 'cpu')
|
17 |
|
18 |
-
@app.post("/
|
19 |
async def process_image(file: UploadFile = File(...)):
|
20 |
# Save the uploaded image locally
|
21 |
with open("uploaded_image.jpg", "wb") as buffer:
|
|
|
15 |
app = FastAPI()
|
16 |
model = Model(device='cuda' if torch.cuda.is_available() else 'cpu')
|
17 |
|
18 |
+
@app.post("/upload/")
|
19 |
async def process_image(file: UploadFile = File(...)):
|
20 |
# Save the uploaded image locally
|
21 |
with open("uploaded_image.jpg", "wb") as buffer:
|