nnUNet icon indicating copy to clipboard operation
nnUNet copied to clipboard

Assertion Error: If does not seem like you trained all the folds! --> But trained all folds

Open annewiet opened this issue 2 years ago • 3 comments

Thank you for developing and managing this great tool! I have trained nnU-Net succesfully on one dataset, but now I have created a new task and trained all the folds again for the 3d_fullres configuration (with --npz) on the MM-WHS17 challenge data.

However, when I run nnUNet_determine_postprocessing -m 3d_fullres -t 504 or nnUNet_find_best_configuration, I get 'Assertion Error: If does not seem like you trained all the folds! Train all fold first!'

I am sure I have trained folds 0 to 4 and also checked the traininglog for each fold. What could be the issue? Thanks in advance.

annewiet avatar May 10 '22 14:05 annewiet

HI, I trained on my custom dataset (on all folds) and when I want to get the best parameters with the following command: nnUNet_find_best_configuration -m 2d -t 715 the same error occurs. I also checked that all the folds are trained.

Thanks in advance!

Andras1396 avatar May 25 '22 07:05 Andras1396

Maybe it's because of some problem in figure_out_what_to_submit.py . If just want to get a result,regard less of performance,you can copy file nnUNet_trained_models/nnUNet/3d_fullres/Task001_XXX/nnUNetTrainerV2__nnUNetPlansv2.1/fold_X/postprocessing.json to folder nnUNet_trained_models/nnUNet/3d_fullres/Task001_Effusions/nnUNetTrainerV2__nnUNetPlansv2.1/,and copy file nnUNet_trained_models/nnUNet/3d_fullres/Task001_Effusions/nnUNetTrainerV2__nnUNetPlansv2.1/fold_0/validation_raw_postprocessed/summary.json to folder nnUNet_trained_models/nnUNet/3d_fullres/Task001_Effusions/nnUNetTrainerV2__nnUNetPlansv2.1/cv_niftis_raw, for me, it's OK

911456451 avatar Jun 08 '22 07:06 911456451

Did you maybe use a different trainer? If so then you need to specify which one. Can you also share the path of your trained model?

FabianIsensee avatar Aug 23 '22 09:08 FabianIsensee

Hi @annewiet @Andras1396,

I assume that your problem is solved and will close the issue in two weeks if I don't hear anything from you.

Best, Yannick

ykirchhoff avatar Jul 31 '23 17:07 ykirchhoff