-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Description
Bread/datasets/low_light_test.py
Line 13 in e0c5068
| subsets = os.listdir(root) |
The code block can be replaced with this:
directory_name = os.path.basename(root)
print("directory_name", directory_name)
img_files = os.listdir(root)
for img_file in img_files:
if not (img_file.endswith('.jpg') or img_file.endswith('.jpeg') or img_file.endswith('.gif') or img_file.endswith('.png')):
continue
self.items.append((
os.path.join(root, img_file),
directory_name,
img_file
))
This enables the "root" directory for the dataset to be the intended input directory of images, without requiring any subdirectories.
Metadata
Metadata
Assignees
Labels
No labels