mirror of
https://github.com/blakeblackshear/frigate.git
synced 2025-12-10 23:35:42 +03:00
Incrase max number of object classifications
This commit is contained in:
parent
b533dd041d
commit
f9b0cc920b
@ -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]))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user