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

BCNN loss increases and accuracy dips badly when finetuning the complete model #11

Open
aniket03 opened this issue Oct 5, 2017 · 2 comments

Comments

@aniket03
Copy link

aniket03 commented Oct 5, 2017

@abhaydoke09
I have been trying to use BCNN model for a different dataset.

When I used BCNN and only fine tuned the last fc layer then the loss was decreasing and after 20 epochs validation acc was also equal to 80%. But when I fine tune the complete model the accuracy drops sharply and loss increases.

So would you suggest only finetuning some layers of BCNN?

For stage 1 fine-tuning:
lr = 0.9
momentum = 0.9

For stage 2 fine tuning:
lr = 0.001
momentum = 0.9

I have also tried using 1e-4 and 1e-5 here but did not find any solution

Also PS I have a small dataset of nearly 4000 images and I use image data augmentation to take that to 6500 train images.

@abhaydoke09
Copy link
Owner

Did you check for gradient flow. It might happen that your gradients are overflowing. Clipping the gradients might help you.

@JUSTDODoDo
Copy link

hello, I still have a problem. After running the second part of the whole model, I will finish training. It seems that the final model is not saved in the code. Why is this done in the absence of the training model? Can you give me some details?

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

3 participants