Labels missing for several training images
david-wb opened this issue · comments
David Brown commented
The ribseg labels appear to be missing for many of the ribfrac images.
This is causing data_prepare.py
to fail with errors such as:
$ python data_prepare.py
Traceback (most recent call last):
File "/home/david/miniconda3/envs/RibSeg/lib/python3.7/site-packages/nibabel/loadsave.py", line 42, in load
stat_result = os.stat(filename)
FileNotFoundError: [Errno 2] No such file or directory: './data/RibSeg/nii/RibFrac43-rib-seg.nii.gz'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "data_prepare.py", line 102, in <module>
main()
File "data_prepare.py", line 20, in main
label = nib.load('./data/RibSeg/nii/'+data[:-12]+'rib-seg.nii.gz')
File "/home/david/miniconda3/envs/RibSeg/lib/python3.7/site-packages/nibabel/loadsave.py", line 44, in load
raise FileNotFoundError("No such file or no access: '%s'" % filename)
FileNotFoundError: No such file or no access: './data/RibSeg/nii/RibFrac43-rib-seg.nii.gz'
David Brown commented
I updated data_prepare.py
locally to handle the missing ribseg labels for certain ribfrac images. Happy to open a PR if you grant me permission.
Leslie commented
Thanks! Yes, I noticed data_prepare.py used the complete RibFrac dataset, which contains 660 CT scans, while RibSeg contains 480 cases. I just updated the code, let me know if there's still an issue. Appreciate your help!