Code Monkey home page Code Monkey logo

Comments (5)

kiryteo avatar kiryteo commented on June 4, 2024

As AdamW is available in torch.optim (as mentioned in issue description), does the modification expect something more than adding 'adamW' after this as another optimizer choice?

from lumin.

GilesStrong avatar GilesStrong commented on June 4, 2024

Yes, adding 'adamw' to that part of the code would be enough to get it used by passing a string argument in the opt_args, however it might cause an error if a user tries to use it with a lower version of PyTorch (current requirement for lumin is torch > 1.0.0).

Either we could increase the minimum version to 1.2.0 (I'm currently running 1.5.1 and Lumin works fine), or there could be a check on the torch version to make sure that AdamW is present.

There should also be the recommendation to the user to use AdamW if they request Adam and L2 regularisation. This should probably go prior to this line
Additionally, these lines set the default optimiser to Adam, if no optimiser was specified. This could be improved to change the default optimiser to AdamW if no optimisre was specified but L2 regularisation was specified, and the torch version is high enough.

from lumin.

kiryteo avatar kiryteo commented on June 4, 2024

Alright, thanks for the pointers! I can add the changes along with the assertions/ warnings for the user. This could be a starting step, later we can just modify the requirements for PyTorch version >= 1.2.0 and mention in the readme as well.

from lumin.

GilesStrong avatar GilesStrong commented on June 4, 2024

That would be great, thank you!

from lumin.

kiryteo avatar kiryteo commented on June 4, 2024

@GilesStrong The updated model_builder module has AdamW included but other checks as discussed above are currently commented out. In case we use 'regularizer' as an argument, this will have to be changed accordingly.

from lumin.

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.