Spaces:
Running
Running
Commit ·
4cfd693
1
Parent(s): c255b60
feat : upgrade jpg format
Browse files
app.py
CHANGED
|
@@ -136,7 +136,7 @@ async def predict( request: Request, response: Response ):
|
|
| 136 |
file_path = os.path.join(STATIC_DIR, base_name)
|
| 137 |
|
| 138 |
# 5️⃣ 儲存到 static
|
| 139 |
-
result.save(file_path, format="
|
| 140 |
|
| 141 |
# 6️⃣ 回傳前端可取用的 URL
|
| 142 |
file_url_return = str(request.base_url) + f"static/{base_name}"
|
|
|
|
| 136 |
file_path = os.path.join(STATIC_DIR, base_name)
|
| 137 |
|
| 138 |
# 5️⃣ 儲存到 static
|
| 139 |
+
result.save(file_path, format="JPEG")
|
| 140 |
|
| 141 |
# 6️⃣ 回傳前端可取用的 URL
|
| 142 |
file_url_return = str(request.base_url) + f"static/{base_name}"
|