From d9d98f9d3a68bdbfc1f4b6190deeb585b31b1934 Mon Sep 17 00:00:00 2001 From: Nicolas Mowen Date: Tue, 21 Oct 2025 16:32:21 -0600 Subject: [PATCH] Remove max check on classification objects --- .../real_time/custom_classification.py | 24 ------------------- 1 file changed, 24 deletions(-) diff --git a/frigate/data_processing/real_time/custom_classification.py b/frigate/data_processing/real_time/custom_classification.py index d80ee0ee6..1fb9dfc97 100644 --- a/frigate/data_processing/real_time/custom_classification.py +++ b/frigate/data_processing/real_time/custom_classification.py @@ -35,10 +35,6 @@ except ModuleNotFoundError: logger = logging.getLogger(__name__) -MAX_CLASSIFICATION_VERIFICATION_ATTEMPTS = 6 -MAX_CLASSIFICATION_ATTEMPTS = 12 - - class CustomStateClassificationProcessor(RealTimeProcessorApi): def __init__( self, @@ -268,26 +264,6 @@ class CustomObjectClassificationProcessor(RealTimeProcessorApi): if obj_data["label"] not in self.model_config.object_config.objects: return - if ( - obj_data["id"] in self.detected_objects - and len(self.detected_objects[obj_data["id"]]) - >= MAX_CLASSIFICATION_VERIFICATION_ATTEMPTS - ): - # if we are at max attempts after rec and we have a rec - if obj_data.get("sub_label"): - logger.debug( - "Not processing due to hitting max attempts after true recognition." - ) - return - - # if we don't have a rec and are at max attempts - if ( - len(self.detected_objects[obj_data["id"]]) - >= MAX_CLASSIFICATION_ATTEMPTS - ): - logger.debug("Not processing due to hitting max rec attempts.") - return - now = datetime.datetime.now().timestamp() x, y, x2, y2 = calculate_region( frame.shape,