Helpers
app.infrastructure.detection.model.helpersModule for helpers; implements concrete processing and I/O behind application-facing contracts.
See Also
ModelSelectionViewModel— represents provider-specific model choicesload_detection_model— loads a selected model
Layer: Infrastructure. Context: Implements concrete processing and i/o behind application-facing contracts at this architectural boundary.
DETECTION_MODEL_PROVIDER_ALL = 'all'
module-attribute
DETECTION_MODEL_PROVIDER_TORCH = 'torch'
module-attribute
DETECTION_MODEL_PROVIDER_YOLO = 'yolo'
module-attribute
DETECTION_MODEL_PROVIDER_MTCNN = 'mtcnn'
module-attribute
get_available_detection_model_names_as_str() -> list[str]
Return list of all available model names (Dummy, Torch, YOLO variants).
get_detection_model_provider_options() -> list[tuple[str, str]]
Return provider dropdown options in display order.
| RETURNS | DESCRIPTION |
|---|---|
list[tuple[str, str]]
|
|
resolve_detection_model_provider(model_name: str) -> str
Map a model name to its provider/family identifier.
| PARAMETER | DESCRIPTION |
|---|---|
model_name
|
Registered model name to classify.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
str
|
Provider identifier ( |
get_detection_model_names_as_view_model_by_provider_id(provider_id: str = DETECTION_MODEL_PROVIDER_ALL) -> list[ModelSelectionViewModel]
Retrieves a list of available detection model with their display names.