taigw / brats17

Brain tumor segmentation for MICCAI 2017 BraTS challenge
BSD 3-Clause "New" or "Revised" License
321 stars 130 forks source link

Cannot output image #7

Closed mbasak1 closed 6 years ago

mbasak1 commented 6 years ago

When trying to run test.py, data is loaded correctly but when it's time to output, we get this error:

** ERROR (nifti_image_write_hdr_img2): cannot open output file 'result18/HGG/Brats18_CBICA_ANP_1.nii.gz' HGG/Brats18_CBICA_ANP_1 test time 666.759003162384

Have you ever run into this problem?

cb632482135qq commented 6 years ago

@mbasak1 Hello , I have the same problem with you!

ERROR (nifti_image_write_hdr_img2): cannot open output file 'D:/TF/brats17-master/data/result15/HGG/brats_tcia_pat417_0001.nii.gz' HGG/brats_tcia_pat417_0001 ERROR (nifti_image_write_hdr_img2): cannot open output file 'D:/TF/brats17-master/data/result15/HGG/brats_tcia_pat205_0001.nii.gz' HGG/brats_tcia_pat205_0001 test time 32.53745257854462

Excuse me , have you ever solved this problem?

Good luck!

taigw commented 6 years ago

You need to create the folders for saving results manually. For example, if you want to save the results in result15/HGG and result15/LGG, you can type:

mkdir result15 cd result15 mkdir HGG mkdir LGG cd ..

cb632482135qq commented 6 years ago

@taigw

Excitingly!

I have solved this problem by creating folders as what you mentioned above.

Thank you very much for your enthusiastic answer.

Best wishes !