File "E:\paper\zzd\lung\3DUNet-Pytorch-master\dataset\dataset_lits2.py", line 45, in get_train_batch_by_index sub_img, sub_label = random_crop_3d(img, label, crop_size) TypeError: 'NoneType' object is not iterable
Opened this issue · 6 comments
zzddmmzzdzd commented
When I load the dataset......
lee-zq commented
Maybe your path of dataset is wrong, please check it
zzddmmzzdzd commented
OK, thanks
zzddmmzzdzd commented
I'm sure that the path of my dataset is not wrong
lee-zq commented
The function sitk_read_row () in /utils/common.py is to read the .nii file from the hard disk, you can debug here to check whether the returned data is empty
PumayHui commented
The same question…
lee-zq commented
Please check your data's shape, ensure that the image is read correctly.
I have modified the code to throw the suitable error message.