Datasets:
Update CC6204-Hackaton-Cub-Dataset.py
Browse files
CC6204-Hackaton-Cub-Dataset.py
CHANGED
@@ -86,11 +86,10 @@ class CubDataset(datasets.GeneratorBasedBuilder):
|
|
86 |
for batch in data_files:
|
87 |
path_files = dl_manager.iter_files(batch)
|
88 |
for img in path_files:
|
89 |
-
if _IMGNAME2ID
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
test_files.append(img)
|
94 |
|
95 |
return [
|
96 |
datasets.SplitGenerator(
|
|
|
86 |
for batch in data_files:
|
87 |
path_files = dl_manager.iter_files(batch)
|
88 |
for img in path_files:
|
89 |
+
if _IMGNAME2ID[os.path.basename(img)] in train_images_idx:
|
90 |
+
train_files.append(img)
|
91 |
+
else:
|
92 |
+
test_files.append(img)
|
|
|
93 |
|
94 |
return [
|
95 |
datasets.SplitGenerator(
|