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

Recommendations for configuring heads/training on custom datasets? #1

Closed
lessw2020 opened this issue Oct 25, 2021 · 5 comments
Closed

Comments

@lessw2020
Copy link

Thanks for developing MobileVit!
I'm wondering if there are any specific tips/examples for fine-tuning the pre-trained classification and detection models using mobilevit on custom datasets?
I see the n_classes reference in both classifier (1000) and detection (80), but can you provide any quick example of modifying for custom datasets and if you have any recommended lr for finetuning?
Thanks very much!

@lessw2020
Copy link
Author

I was able to do some surgery to rework mobilevit classifier to be trainable within Jupyter notebook and customize the fc to match the original ImageNet setup.
It is doing extremely well fine tuning with lr=9e-4 (using Ranger21 optimizer).
If it helps others, here's how I modified the fc (my current work is binary classification so it's 2 instead of 1000).
I think it would be nice to add in this as a simple function call much like how it's done in Timm. I can do a PR for it if interested.
mvit_customized

@batrlatom
Copy link

do you think you could share the jupyter notebook for training?

@sacmehta
Copy link
Collaborator

@lessw2020 Inspired by this issue, we have added the functionality of fine-tuning pre-trained classification backbones on other classification datasets in v0.2 of this library. See fine-tuning example here.

@sacmehta
Copy link
Collaborator

Closing issue because of no activity

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

4 participants