From af4e9d5d19ec316d11f47ec5a9cb99d80f1313d7 Mon Sep 17 00:00:00 2001 From: Catl Neo <156419922+catl-neo@users.noreply.github.com> Date: Thu, 1 Feb 2024 14:06:09 +0800 Subject: [PATCH] Fix typo (#336) * Update README.md and cityscapes.py --- README.md | 2 +- easycv/datasets/segmentation/data_sources/cityscapes.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 73df5bc8..0a92ff3e 100644 --- a/README.md +++ b/README.md @@ -248,7 +248,7 @@ Please refer to the following model zoo for more details. ## Data Hub -EasyCV have collected dataset info for different senarios, making it easy for users to finetune or evaluate models in EasyCV model zoo. +EasyCV have collected dataset info for different scenarios, making it easy for users to finetune or evaluate models in EasyCV model zoo. Please refer to [data_hub.md](docs/source/data_hub.md). diff --git a/easycv/datasets/segmentation/data_sources/cityscapes.py b/easycv/datasets/segmentation/data_sources/cityscapes.py index 845caf87..35e74838 100644 --- a/easycv/datasets/segmentation/data_sources/cityscapes.py +++ b/easycv/datasets/segmentation/data_sources/cityscapes.py @@ -110,16 +110,16 @@ def get_source_iterator(self): '')[:-len(self.img_suffix[0])] find_label_path = False for label_format in self.label_suffix: - lable_path = os.path.join(self.label_root, + label_path = os.path.join(self.label_root, img_name + label_format) - if io.exists(lable_path): + if io.exists(label_path): find_label_path = True - self.label_files.append(lable_path) + self.label_files.append(label_path) break if not find_label_path: logging.warning( 'Not find label file %s for img: %s, skip the sample!' % - (lable_path, img_path)) + (label_path, img_path)) self.img_files.remove(img_path) assert len(self.img_files) == len(self.label_files)