MIC-DKFZ / nnUNet

Apache License 2.0
5.68k stars 1.72k forks source link

Error when plan_and_preprocess with .nrrd files #2165

Open casami3 opened 5 months ago

casami3 commented 5 months ago

Hello, i'm following the how_to_use_nnunet.md and I'm encountering an error. When doing the planning and preprocessing I use the command nnUNetv2_plan_and_preprocess -d DATASET_ID --verify_dataset_integrity. Then I obtain the following error: nibabel.filebasedimages.ImageFileError: Cannot work out file type of "C:/Users/joanc/OneDrive/Escritorio/UPF/curs2trim3/AABI/proy/nnUNet_raw/Dataset002_Dongyang2/labelsTr/D_001.nrrd".

The segmentations were in .seg.nrrd format so I changed it by changing the file name. It seems not corrupted because it opens OK in ITK-SNAP.

What should I try now?

Thanks in advance

JackRio commented 4 months ago

Instead of changing the file name manually try to open the file using SimpleITK for instance and save it in NIFTI format.