diff --git a/yolo/tools/data_loader.py b/yolo/tools/data_loader.py index d80a1bc..5138060 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 ]