diff --git a/frigate/data_processing/real_time/custom_classification.py b/frigate/data_processing/real_time/custom_classification.py index 2dae9f0b7..ee72e145c 100644 --- a/frigate/data_processing/real_time/custom_classification.py +++ b/frigate/data_processing/real_time/custom_classification.py @@ -519,6 +519,13 @@ class CustomObjectClassificationProcessor(RealTimeProcessorApi): 0.0, max_files=save_attempts, ) + + # Still track history even when model doesn't exist to respect MAX_OBJECT_CLASSIFICATIONS + # Add an entry with "unknown" label so the history limit is enforced + if object_id not in self.classification_history: + self.classification_history[object_id] = [] + + self.classification_history[object_id].append(("unknown", 0.0, now)) return input = np.expand_dims(resized_crop, axis=0)