mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-04-27 09:07:41 +03:00
Add enum for type of classification for objects
This commit is contained in:
parent
7ea288fe32
commit
81d4b26b01
@ -3,6 +3,8 @@ from typing import Dict, List, Optional
|
||||
|
||||
from pydantic import ConfigDict, Field
|
||||
|
||||
from frigate.types import ObjectClassificationType
|
||||
|
||||
from .base import FrigateBaseModel
|
||||
|
||||
__all__ = [
|
||||
@ -88,6 +90,10 @@ class CustomClassificationStateConfig(FrigateBaseModel):
|
||||
|
||||
class CustomClassificationObjectConfig(FrigateBaseModel):
|
||||
objects: list[str] = Field(title="Object types to classify.")
|
||||
classification_type: ObjectClassificationType = Field(
|
||||
default=ObjectClassificationType.sub_label,
|
||||
title="Type of classification that is applied.",
|
||||
)
|
||||
|
||||
|
||||
class CustomClassificationConfig(FrigateBaseModel):
|
||||
|
||||
@ -25,6 +25,11 @@ class ModelStatusTypesEnum(str, Enum):
|
||||
complete = "complete"
|
||||
|
||||
|
||||
class ObjectClassificationType(str, Enum):
|
||||
sub_label = "sub_label"
|
||||
attribute = "attribute"
|
||||
|
||||
|
||||
class TrackedObjectUpdateTypesEnum(str, Enum):
|
||||
description = "description"
|
||||
face = "face"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user