-
Notifications
You must be signed in to change notification settings - Fork 294
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
Add example of maml training on omniglot #349
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is probably the highest density of optimizers per 10 LOCs, I've seen O_o
@Krovatkin It's been a while since you initially reviewed this PR. I rebased on top of the master branch and the build+tests now fully succeed. Could I ask you to take another look at this please before I hit the merge button? |
This is related to pytorch#328. This PR adds an actually correct implementation of maml to the repo. The previous implementation doesn't actually compute higher order gradients where it is supposed to. I'm not familiar with how torchbench works so please let me know if there are additional files that need to be modified. Test Plan: Ran the following: ``` python test.py -k test_maml_omniglot_example_cpu python test.py -k test_maml_omniglot_eval_cpu python test.py -k test_maml_omniglot_train_cpu ``` Future work: - Delete the maml example that is currently in this repo (or rename it to make it clear that it's doing something different from the paper that it is trying to reproduce).
Please help resolve the comments and I will be happy to merge your contribution! |
@xuzhao9 I resolved the comments, could you please take another look when you get a chance? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks for the contribution!
Fixes pytorch#328 Here's some context: - We discovered that the implementation doesn't actually use maml (dragen1860/MAML-Pytorch#59) - We filed pytorch#328 - We added maml_omniglot pytorch#349 as the correct version of of the maml model. - We didn't delete the maml model (because I was worried that it was doing a "different" type of maml that I hadn't seen before that is still valid). The last step to resolve this issue is to delete the incorrect MAML example, unless we have reasons to keep it around.
This is related to #328. This PR adds an actually correct
implementation of maml to the repo. The previous implementation doesn't
actually compute higher order gradients where it is supposed to.
I'm not familiar with how torchbench works so please let me know if
there are additional files that need to be modified.
Test Plan:
Ran the following:
Future work:
to make it clear that it's doing something different from the paper that
it is trying to reproduce).