Chris Oswald commited on
Commit ·
c213c69
1
Parent(s): 9c3c13b
debugging
Browse files
SPIDER.py
CHANGED
|
@@ -429,12 +429,12 @@ class SPIDER(datasets.GeneratorBasedBuilder):
|
|
| 429 |
|
| 430 |
image_files = [
|
| 431 |
file for file in image_files
|
| 432 |
-
if any(str(patient_id)
|
| 433 |
]
|
| 434 |
|
| 435 |
mask_files = [
|
| 436 |
file for file in mask_files
|
| 437 |
-
if any(str(patient_id)
|
| 438 |
]
|
| 439 |
assert len(image_files) == len(mask_files), "The number of image files\
|
| 440 |
does not match the number of mask files--verify subsetting operation."
|
|
|
|
| 429 |
|
| 430 |
image_files = [
|
| 431 |
file for file in image_files
|
| 432 |
+
if any(str(patient_id) == file.split('_')[0] for patient_id in subset_ids)
|
| 433 |
]
|
| 434 |
|
| 435 |
mask_files = [
|
| 436 |
file for file in mask_files
|
| 437 |
+
if any(str(patient_id) == file.split('_')[0] for patient_id in subset_ids)
|
| 438 |
]
|
| 439 |
assert len(image_files) == len(mask_files), "The number of image files\
|
| 440 |
does not match the number of mask files--verify subsetting operation."
|