NVR with realtime local object detection for IP cameras
TypeScript aicameragoogle-coralhome-assistanthome-automationhomeautomationmqttnvrobject-detectionrealtimertsptensorflow
Only try to import memryx SDK when memry detector is used (#19737)
Josh Hawkins1636fee36a35
diff --git a/frigate/detectors/plugins/memryx.py b/frigate/detectors/plugins/memryx.pyindex 4c251ef0fb..2c741e0f67 100644--- a/frigate/detectors/plugins/memryx.py+++ b/frigate/detectors/plugins/memryx.py@@ -9,15 +9,6 @@ from queue import Queueimport cv2import numpy as np--try:- # from memryx import AsyncAccl # Import MemryX SDK- from memryx import AsyncAccl-except ModuleNotFoundError:- raise ImportError(- "MemryX SDK is not installed. Install it and set up MIX environment."- )-from pydantic import BaseModel, Fieldfrom typing_extensions import Literal@@ -55,6 +46,14 @@ class MemryXDetector(DetectionApi):def __init__(self, detector_config):"""Initialize MemryX detector with the provided configuration."""+ try:+ # Import MemryX SDK+ from memryx import AsyncAccl+ except ModuleNotFoundError:+ raise ImportError(+ "MemryX SDK is not installed. Install it and set up MIX environment."+ )+ returnmodel_cfg = getattr(detector_config, "model", None)