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

Issue with training 3D U-Net using ZeroCostDL4Mic: validation set #266

Open
jbogomolovas2 opened this issue May 12, 2023 · 2 comments
Open

Comments

@jbogomolovas2
Copy link

jbogomolovas2 commented May 12, 2023

First of all, I want to express my gratitude towards ZeroCostDL4Mic. It is an amazing tool that I use for almost every image analysis task in my work. However, I am currently facing an issue with training a 3D U-Net to recognize bright cell clones in light-sheet microscopy images.

To train the model, I have provided 22 labeled 128x128x128 pixel images. I have varied the validation set (20-50%), batch size (1-5), and patch size (64-128x64-128x8-32), but the validation loss function does not converge. As seen in the attached image, the validation set behaves way worse than the training set.
Unknown-11
I also came across a similar issue reported on the image.sc forum:
https://forum.image.sc/t/u-net-3d-zerocostdl4mic-training/79457

To investigate the issue further, I ran a sanity check on the dataset by repeating the same 128x128x128 labeled image 10 times and using a 50% validation fraction. However, even in this case, the validation set behaved differently than the training set. :
Unknown-13

I understand that loss functions might differ because of regularization and at what point loss is measured, but shouldn't dice coefficient be identical in this test case? This suggests that there might be a bug in the script.

I would appreciate any help or suggestions to resolve this issue. Thank you in advance!

@jing00011
Copy link

I have similar graph before and adding elastic deformation + choosing default parameters helped with the issue.

@jbogomolovas2
Copy link
Author

@jing00011 Thank you for suggestion. So activate elastic deformation and keep the rest default?

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