Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding New Data to nnUNet Training Set for Active Learning #2721

Open
JiaGUO1997 opened this issue Feb 27, 2025 · 1 comment
Open

Adding New Data to nnUNet Training Set for Active Learning #2721

JiaGUO1997 opened this issue Feb 27, 2025 · 1 comment
Assignees

Comments

@JiaGUO1997
Copy link

Hello,

I am currently working on integrating nnUNet for active learning. As part of this process, I need to add new data to the training set each time I update the segmentation. However, I’ve noticed that the preprocessing step alters the size of the imageTr/labelTr data.

I would appreciate your guidance on how to correctly add new data and their corresponding segmentation files to the training set, specifically to the imageTr and labelTr folders.

Additionally, I am uncertain about how to perform preprocessing before training using the nnUNetPlans.json file which defines all the things. Could you provide some insights or point me towards relevant documentation or best practices?

Thank you for your support!
Best regards,

@ykirchhoff
Copy link
Member

Hi @JiaGUO1997,

I think doing it right, requires some coding, as nnUNet per default isn't optimally suited for active learning. Something you could do is using separate datasets for each stage, preprocessing them and then training on the specific datasets. This wouldn't require any coding, but isn't the best way imo to achieve this. If you want to preprocess more data using a previously generated nnUNetPlans.json, you can run nnUNetv2_preprocess ... -plans_name nnUNetPlans_active.json on a separate dataset and copy the plans file in there, but that then generates a completely separate preprocessed dataset, which is just preprocessed with the same plan.
Let me know if you have further questions or need some guidance how you can change specific parts of the code.

Best,
Yannick

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants