Code Monkey home page Code Monkey logo

Comments (9)

dragen1860 avatar dragen1860 commented on July 21, 2024

NO.
in meta-learning setting, meta-training includes training and testing, meta-test includes training and testing as well. The label space between meta-training and meta-testing is separated properly. For sub-stage, say training and testing in meta-train or meta-testing, the leakage is normal, not an error.

from maml-pytorch.

xiangjjj avatar xiangjjj commented on July 21, 2024

Thank you for your response!
I am aware that the sub-stage update is achieved through fast_weights. My question is, at the end of the forward() function, does self.meta_optim.step() update parameters of the base learner, i.e., the \theta in the paper?

from maml-pytorch.

dragen1860 avatar dragen1860 commented on July 21, 2024

Yes, the meta_optim.step() will update \theta parameters only. The updates of fast_weights will be ignored in sub-stage of test.

from maml-pytorch.

xiangjjj avatar xiangjjj commented on July 21, 2024

At the meta-testing phrase, we need to forward() the meta-test tasks to evaluate the corresponding testing performance at the meta level (not the task level). More importantly, we only want to get the fast weights for those tasks, because the meta test tasks should not be used to update the meta learner, i.e., \theta. However, the \theta is also updated since self.meta_optim.step() is always part of forward().

Do you think there is any need to take out self.meta_optim.step() in meta testing?

from maml-pytorch.

xiangjjj avatar xiangjjj commented on July 21, 2024

In stead of self.meta_optim.step(), shouldn't we do the following?

if training is True: self.meta_optim.step()

from maml-pytorch.

dragen1860 avatar dragen1860 commented on July 21, 2024

Oh, maybe u r right.
During the test, no need to optimize the \theta parameters.
U can try it and see any problems.

from maml-pytorch.

xiangjjj avatar xiangjjj commented on July 21, 2024

I have already tried and it turned out the optimization step is required to be left out in meta testing. Otherwise it would give overly optimistic results for be trained on meta test sets.

from maml-pytorch.

dragen1860 avatar dragen1860 commented on July 21, 2024

Ok, thx. Feel free to submit a PR.

from maml-pytorch.

dragen1860 avatar dragen1860 commented on July 21, 2024

Hi, all. Please git pull to get the latest version which solved test data leaking bugs.

from maml-pytorch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.