From f9b0cc920bfc3bf77333209e07abfc5b7c30e2d4 Mon Sep 17 00:00:00 2001 From: Nicolas Mowen Date: Wed, 5 Nov 2025 05:11:06 -0700 Subject: [PATCH] Incrase max number of object classifications --- frigate/data_processing/real_time/custom_classification.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/frigate/data_processing/real_time/custom_classification.py b/frigate/data_processing/real_time/custom_classification.py index 65a62b568..e4048b6ec 100644 --- a/frigate/data_processing/real_time/custom_classification.py +++ b/frigate/data_processing/real_time/custom_classification.py @@ -466,6 +466,7 @@ class CustomObjectClassificationProcessor(RealTimeProcessorApi): now, self.labelmap[best_id], score, + max_files=200, ) if score < self.model_config.threshold: @@ -529,6 +530,7 @@ def write_classification_attempt( timestamp: float, label: str, score: float, + max_files: int = 100, ) -> None: if "-" in label: label = label.replace("-", "_") @@ -544,5 +546,5 @@ def write_classification_attempt( ) # delete oldest face image if maximum is reached - if len(files) > 100: + if len(files) > max_files: os.unlink(os.path.join(folder, files[-1]))