Datasets:
Tasks:
Image Classification
Sub-tasks:
multi-class-image-classification
Languages:
English
Size:
100K<n<1M
ArXiv:
License:
Add condition to check if an image path belong to train-val-set
Browse files
NIH-Chest-X-ray-dataset.py
CHANGED
@@ -113,8 +113,7 @@ class XChest(datasets.GeneratorBasedBuilder):
|
|
113 |
logger.info(f"Batch for data_files: {batch}")
|
114 |
path_files = dl_manager.iter_files(batch)
|
115 |
for img in path_files:
|
116 |
-
|
117 |
-
if img in train_val_list:
|
118 |
train_files.append(img)
|
119 |
else:
|
120 |
test_files.append(img)
|
|
|
113 |
logger.info(f"Batch for data_files: {batch}")
|
114 |
path_files = dl_manager.iter_files(batch)
|
115 |
for img in path_files:
|
116 |
+
if img.split('/')[-1] in train_val_list:
|
|
|
117 |
train_files.append(img)
|
118 |
else:
|
119 |
test_files.append(img)
|