From ed15456738c08de96caec0d1a82e0b8043155957 Mon Sep 17 00:00:00 2001 From: pdisbeschl Date: Thu, 7 Aug 2025 17:50:40 +0200 Subject: [PATCH] :bug: [FIX] filter_data Images are now loaded from correct images_path instead of dataset_path, this also impacts labels_path Typo "pache" now reverted to "cache" --- yolo/tools/data_loader.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yolo/tools/data_loader.py b/yolo/tools/data_loader.py index d80a1bcf..5138060b 100644 --- a/yolo/tools/data_loader.py +++ b/yolo/tools/data_loader.py @@ -49,7 +49,7 @@ def load_data(self, dataset_path: Path, phase_name: str): Returns: dict: The loaded data from the cache for the specified phase. """ - cache_path = dataset_path / f"{phase_name}.pache" + cache_path = dataset_path / f"{phase_name}.cache" if not cache_path.exists(): logger.info(f":factory: Generating {phase_name} cache") @@ -87,7 +87,7 @@ def filter_data(self, dataset_path: Path, phase_name: str, sort_image: bool = Fa data_type, adjust_path = "txt", True # TODO: should i sort by name? with open(file_list, "r") as file: - images_list = [dataset_path / line.rstrip() for line in file] + images_list = [images_path / line.rstrip() for line in file] labels_list = [ Path(str(image_path).replace("images", "labels")).with_suffix(".txt") for image_path in images_list ]