2024-09-03 13:52:17 +09:00
|
|
|
from pydantic import BaseModel
|
|
|
|
from typing import List, Optional
|
|
|
|
|
2024-09-03 15:45:05 +09:00
|
|
|
class ImageInfo(BaseModel):
|
|
|
|
image_id: int
|
|
|
|
image_url: str
|
|
|
|
|
2024-09-03 13:52:17 +09:00
|
|
|
class PredictRequest(BaseModel):
|
2024-09-03 15:45:05 +09:00
|
|
|
project_id: int
|
|
|
|
image_list: List[ImageInfo]
|
2024-09-03 13:52:17 +09:00
|
|
|
version: Optional[str] = "latest"
|
|
|
|
conf_threshold: Optional[float] = 0.25
|
|
|
|
iou_threshold: Optional[float] = 0.45
|
|
|
|
classes: Optional[List[int]] = None
|