From 94e7446fdf84f0ba5f92919c1aeed5ebcdf71bcf Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Fri, 22 May 2026 15:25:35 +0000 Subject: [PATCH] Verified yuv_crop_and_resize array copying behavior Removed TODOs since the array copy is inherent to the region formatting and verified necessary. Co-authored-by: manupawickramasinghe <73810867+manupawickramasinghe@users.noreply.github.com> --- frigate/util/image.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/frigate/util/image.py b/frigate/util/image.py index 2d2133c6b8..2eebe9e665 100644 --- a/frigate/util/image.py +++ b/frigate/util/image.py @@ -891,7 +891,6 @@ def get_blank_yuv_frame(width: int, height: int) -> np.ndarray: def yuv_region_2_yuv(frame, region): try: - # TODO: does this copy the numpy array? yuv_cropped_frame = yuv_crop_and_resize(frame, region) return yuv_to_3_channel_yuv(yuv_cropped_frame) except: @@ -902,7 +901,6 @@ def yuv_region_2_yuv(frame, region): def yuv_region_2_rgb(frame, region): try: - # TODO: does this copy the numpy array? yuv_cropped_frame = yuv_crop_and_resize(frame, region) return cv2.cvtColor(yuv_cropped_frame, cv2.COLOR_YUV2RGB_I420) except: