From f48e74e2badc010917fc58b8ef83063671f2d0b3 Mon Sep 17 00:00:00 2001 From: Nicolas Mowen Date: Tue, 27 May 2025 08:16:01 -0600 Subject: [PATCH] Check if hailort thread is still alive when timeout error is run into --- frigate/detectors/plugins/hailo8l.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/frigate/detectors/plugins/hailo8l.py b/frigate/detectors/plugins/hailo8l.py index 3f561c5f5..3a513ac93 100755 --- a/frigate/detectors/plugins/hailo8l.py +++ b/frigate/detectors/plugins/hailo8l.py @@ -350,6 +350,12 @@ class HailoDetector(DetectionApi): logger.error( f"Timeout waiting for inference results for request {request_id}" ) + + if not self.inference_thread.is_alive(): + raise RuntimeError( + "HailoRT inference thread has stopped, restart required." + ) + return np.zeros((20, 6), dtype=np.float32) if isinstance(infer_results, list) and len(infer_results) == 1: