mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-05 18:55:23 +03:00
update python deps
This commit is contained in:
parent
aee2d5a46d
commit
6daeb044d1
@ -107,33 +107,64 @@ class FrigateApp:
|
|||||||
for camera_name in self.config.cameras.keys():
|
for camera_name in self.config.cameras.keys():
|
||||||
# create camera_metrics
|
# create camera_metrics
|
||||||
self.camera_metrics[camera_name] = {
|
self.camera_metrics[camera_name] = {
|
||||||
"camera_fps": mp.Value("d", 0.0),
|
"camera_fps": mp.Value("d", 0.0), # type: ignore[typeddict-item]
|
||||||
"skipped_fps": mp.Value("d", 0.0),
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
"process_fps": mp.Value("d", 0.0),
|
# from mypy 0.981 onwards
|
||||||
"detection_enabled": mp.Value(
|
"skipped_fps": mp.Value("d", 0.0), # type: ignore[typeddict-item]
|
||||||
"i", self.config.cameras[camera_name].detect.enabled
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"process_fps": mp.Value("d", 0.0), # type: ignore[typeddict-item]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"detection_enabled": mp.Value( # type: ignore[typeddict-item]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"i",
|
||||||
|
self.config.cameras[camera_name].detect.enabled,
|
||||||
),
|
),
|
||||||
"motion_enabled": mp.Value("i", True),
|
"motion_enabled": mp.Value("i", True), # type: ignore[typeddict-item]
|
||||||
"improve_contrast_enabled": mp.Value(
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
"i", self.config.cameras[camera_name].motion.improve_contrast
|
# from mypy 0.981 onwards
|
||||||
|
"improve_contrast_enabled": mp.Value( # type: ignore[typeddict-item]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"i",
|
||||||
|
self.config.cameras[camera_name].motion.improve_contrast,
|
||||||
),
|
),
|
||||||
"motion_threshold": mp.Value(
|
"motion_threshold": mp.Value( # type: ignore[typeddict-item]
|
||||||
"i", self.config.cameras[camera_name].motion.threshold
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"i",
|
||||||
|
self.config.cameras[camera_name].motion.threshold,
|
||||||
),
|
),
|
||||||
"motion_contour_area": mp.Value(
|
"motion_contour_area": mp.Value( # type: ignore[typeddict-item]
|
||||||
"i", self.config.cameras[camera_name].motion.contour_area
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"i",
|
||||||
|
self.config.cameras[camera_name].motion.contour_area,
|
||||||
),
|
),
|
||||||
"detection_fps": mp.Value("d", 0.0),
|
"detection_fps": mp.Value("d", 0.0), # type: ignore[typeddict-item]
|
||||||
"detection_frame": mp.Value("d", 0.0),
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
"read_start": mp.Value("d", 0.0),
|
# from mypy 0.981 onwards
|
||||||
"ffmpeg_pid": mp.Value("i", 0),
|
"detection_frame": mp.Value("d", 0.0), # type: ignore[typeddict-item]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"read_start": mp.Value("d", 0.0), # type: ignore[typeddict-item]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"ffmpeg_pid": mp.Value("i", 0), # type: ignore[typeddict-item]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
"frame_queue": mp.Queue(maxsize=2),
|
"frame_queue": mp.Queue(maxsize=2),
|
||||||
"capture_process": None,
|
"capture_process": None,
|
||||||
"process": None,
|
"process": None,
|
||||||
}
|
}
|
||||||
self.record_metrics[camera_name] = {
|
self.record_metrics[camera_name] = {
|
||||||
"record_enabled": mp.Value(
|
"record_enabled": mp.Value( # type: ignore[typeddict-item]
|
||||||
"i", self.config.cameras[camera_name].record.enabled
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"i",
|
||||||
|
self.config.cameras[camera_name].record.enabled,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -262,8 +262,12 @@ def stats_snapshot(
|
|||||||
for name, detector in stats_tracking["detectors"].items():
|
for name, detector in stats_tracking["detectors"].items():
|
||||||
pid = detector.detect_process.pid if detector.detect_process else None
|
pid = detector.detect_process.pid if detector.detect_process else None
|
||||||
stats["detectors"][name] = {
|
stats["detectors"][name] = {
|
||||||
"inference_speed": round(detector.avg_inference_speed.value * 1000, 2),
|
"inference_speed": round(detector.avg_inference_speed.value * 1000, 2), # type: ignore[attr-defined]
|
||||||
"detection_start": detector.detection_start.value,
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
|
"detection_start": detector.detection_start.value, # type: ignore[attr-defined]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
"pid": pid,
|
"pid": pid,
|
||||||
}
|
}
|
||||||
stats["detection_fps"] = round(total_detection_fps, 2)
|
stats["detection_fps"] = round(total_detection_fps, 2)
|
||||||
|
|||||||
@ -24,7 +24,9 @@ class FrigateWatchdog(threading.Thread):
|
|||||||
|
|
||||||
# check the detection processes
|
# check the detection processes
|
||||||
for detector in self.detectors.values():
|
for detector in self.detectors.values():
|
||||||
detection_start = detector.detection_start.value
|
detection_start = detector.detection_start.value # type: ignore[attr-defined]
|
||||||
|
# issue https://github.com/python/typeshed/issues/8799
|
||||||
|
# from mypy 0.981 onwards
|
||||||
if detection_start > 0.0 and now - detection_start > 10:
|
if detection_start > 0.0 and now - detection_start > 10:
|
||||||
logger.info(
|
logger.info(
|
||||||
"Detection appears to be stuck. Restarting detection process..."
|
"Detection appears to be stuck. Restarting detection process..."
|
||||||
|
|||||||
@ -3,13 +3,13 @@ Flask == 2.3.*
|
|||||||
faster-fifo == 1.4.*
|
faster-fifo == 1.4.*
|
||||||
imutils == 0.5.*
|
imutils == 0.5.*
|
||||||
matplotlib == 3.7.*
|
matplotlib == 3.7.*
|
||||||
mypy == 0.942
|
mypy == 1.4.1
|
||||||
numpy == 1.23.*
|
numpy == 1.23.*
|
||||||
onvif_zeep == 0.2.12
|
onvif_zeep == 0.2.12
|
||||||
opencv-python-headless == 4.7.0.*
|
opencv-python-headless == 4.7.0.*
|
||||||
paho-mqtt == 1.6.*
|
paho-mqtt == 1.6.*
|
||||||
peewee == 3.16.*
|
peewee == 3.16.*
|
||||||
peewee_migrate == 1.10.*
|
peewee_migrate == 1.11.*
|
||||||
psutil == 5.9.*
|
psutil == 5.9.*
|
||||||
pydantic == 1.10.*
|
pydantic == 1.10.*
|
||||||
git+https://github.com/fbcotter/py3nvml#egg=py3nvml
|
git+https://github.com/fbcotter/py3nvml#egg=py3nvml
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user