tkuanlun350 / 3DUnet-Tensorflow-Brats18

3D Unet biomedical segmentation model powered by tensorpack with fast io speed
202 stars 68 forks source link

test failed #4

Open xuhuaren opened 6 years ago

xuhuaren commented 6 years ago

Firstly, appreciate your code :+1: I really like it. While, when I test it, the code has some bugs. My data architecture: DIR/ training/ HGG/ LGG/ val/ case1/ t1.nii.gz t1c.nii.gz flair.nii.gz t2.nii.gz case2/ t1.nii.gz t1c.nii.gz flair.nii.gz t2.nii.gz

While, the error is:

Traceback (most recent call last): File "/home/xuhuaren/anaconda3/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap self.run() File "/home/xuhuaren/anaconda3/lib/python3.6/site-packages/tensorpack-0.8.9-py3.6.egg/tensorpack/dataflow/parallel.py", line 269, in run for dp in self.ds: File "/home/xuhuaren/anaconda3/lib/python3.6/site-packages/tensorpack-0.8.9-py3.6.egg/tensorpack/dataflow/common.py", line 282, in iter ret = self.func(copy(dp)) # shallow copy the list File "/home/xuhuaren/anaconda3/lib/python3.6/site-packages/tensorpack-0.8.9-py3.6.egg/tensorpack/dataflow/common.py", line 317, in _mapper r = self._func(dp[self._index]) File "/work/cvpr2019/experiment/brats/1/data_sampler.py", line 269, in f volume_list, label, weight, original_shape, bbox = data ValueError: too many values to unpack (expected 5)

Do you have any suggestions?

tkuanlun350 commented 6 years ago

The file name should be {BRATS_XX}/{BRATS_XX}_t1c.nii.gz ... The modality files should have caseID as prefix. Can you try to print "data" object at line 269 to see whether the object is empty ?