tkuanlun350 / 3DUnet-Tensorflow-Brats18

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

TypeError: join() argument must be str or bytes, not 'list' #29

Closed Faizad closed 4 years ago

Faizad commented 5 years ago

Hey! I just trained the model i.e. CROSS_VALIDATION = False, it's work fine. But when I want to try the model to train on CROSS_VALIDATION = True, it gives me the error i.e.

Traceback (most recent call last): File "train.py", line 211, in data=QueueInput(get_train_dataflow()), File "/home/faizad/3DUnet-Tensorflow-Brats18/data_sampler.py", line 221, in get_train_dataflow imgs = BRATS_SEG.load_from_file(config.BASEDIR, config.TRAIN_DATASET) File "/home/faizad/3DUnet-Tensorflow-Brats18/data_loader.py", line 113, in load_from_file brats = BRATS_SEG(basedir, names) File "/home/faizad/3DUnet-Tensorflow-Brats18/data_loader.py", line 33, in init self.basedir = os.path.join(basedir, mode) File "/usr/lib/python3.7/posixpath.py", line 94, in join genericpath._check_arg_types('join', a, *p) File "/usr/lib/python3.7/genericpath.py", line 149, in _check_arg_types (funcname, s.class.name)) from None

TypeError: join() argument must be str or bytes, not 'list'

Note: I follow all the steps given below:

  1. First run generate_5fold.py to save 5fold.pkl
  2. Set CROSS_VALIDATION to True
  3. CROSS_VALIDATION_PATH to /path/to/5fold.pkl
  4. Set FOLD to 4

Thanks in anticipation.