Closed maddy023 closed 4 years ago
Thanks for the comment, these two arguments were missing from the argument parser and we updated the python file test_miccai_2019.py
!python test_miccai_2019.py --dataset_name "miccai2019" --nEpochs 2 --opt adam --model VNET
2020-05-01 10:28:53.155633: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcudart.so.10.1
Traceback (most recent call last):
File "test_miccai_2019.py", line 88, in <module>
main()
File "test_miccai_2019.py", line 34, in main
path='.././datasets')
File "/content/MedicalZooPytorch/lib/medloaders/__init__.py", line 40, in generate_datasets
save=True)
File "/content/MedicalZooPytorch/lib/medloaders/miccai_2019_pathology.py", line 34, in __init__
image_paths, label_paths = utils.shuffle_lists(image_paths, label_paths)
File "/content/MedicalZooPytorch/lib/utils/general.py", line 38, in shuffle_lists
a, b = zip(*c)
ValueError: not enough values to unpack (expected 2, got 0)
!python test_miccai_2019.py --dataset_name ixi --nEpochs 2
2020-05-01 11:06:22.042564: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcudart.so.10.1
Traceback (most recent call last):
File "test_miccai_2019.py", line 88, in <module>
main()
File "test_miccai_2019.py", line 34, in main
path='.././datasets')
File "/content/MedicalZooPytorch/lib/medloaders/__init__.py", line 48, in generate_datasets
loader = IXIMRIdataset(dataset_path=path, voxels_space=args.dim, modalities=args.inModalities, save=True)
File "/content/MedicalZooPytorch/lib/medloaders/ixi_t1_t2.py", line 43, in __init__
self.voxels_space[2])
IndexError: tuple index out of range
for the miccai dataset you should produce the labels first based on majority voting from the annotators i have included the mode in the miccai 2019 dataloder in lib/medloades but you have to work that out yourself. You can check my old repo here https://github.com/black0017/MICCAI-2019-Prostate-Cancer-segmentation-challenge. Based on the updates, all the rest should work. Please keep in mind that you have to modify some code based on your paths to configure it for your project. Medical data are tricky! All the best. N.A.
command:
!python test_miccai_2019.py --dataset_name MICCAI_2019_pathology_challenge --nEpochs 2 --opt adam --model UNET2D
output:
updated command :
!python test_miccai_2019.py --dataset_name MICCAI_2019_pathology_challenge --nEpochs 2 --opt adam --model UNET2D --samples_train 10
ouput:
Other way around by altering the test_miccai_2019.py code:
Adding samples_train and Samples_val ,rises error in generate_dataset()