From 4302d1d7061402801c00b3eba4353513ab3724e6 Mon Sep 17 00:00:00 2001 From: niten Date: Tue, 10 Jan 2023 23:17:47 -0800 Subject: [PATCH] Forgot to read labels file --- src/objectifier.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/objectifier.py b/src/objectifier.py index b8741b4..67a796d 100644 --- a/src/objectifier.py +++ b/src/objectifier.py @@ -32,11 +32,15 @@ def to_int(input_int): yolo_config = get_envvar_or_fail('OBJECTIFIER_YOLOV3_CONFIG') yolo_weights = get_envvar_or_fail('OBJECTIFIER_YOLOV3_WEIGHTS') -yolo_labels = get_envvar_or_fail('OBJECTIFIER_YOLOV3_LABELS') +yolo_labels_file = get_envvar_or_fail('OBJECTIFIER_YOLOV3_LABELS') buffer_size = to_int(get_envvar('OBJECTIFIER_BUFFER_SIZE')) or 524288 max_file_age = to_int(get_envvar('OBJECTIFIER_CLEANUP_MAX_AGE')) file_cleanup_delay = to_int(get_envvar('OBJECTIFIER_CLEANUP_DELAY')) +yolo_labels = [] +with open(yolo_labels_file, "r") as f: + yolo_labels = f.readlines() + incoming_dir = Path(get_envvar_or_fail('CACHE_DIRECTORY')) outgoing_dir = Path(get_envvar_or_fail('STATE_DIRECTORY'))