Giter VIP home page Giter VIP logo

adamp-tensorflow's Introduction

AdamP Optimizer โ€” Unofficial TensorFlow Implementation

"Slowing Down the Weight Norm Increase in Momentum-based Optimizers"

Implemented by Junho Kim

[Paper] [Project page] [Official Pytorch]

Validation

I have checked that the code is working, but I couldn't confirm if the performance is the same as the offical code.

Usage

Usage is exactly same as tf.keras.optimizers library!

from adamp_tf import AdamP
from sgdp_tf import SGDP

optimizer_adamp = AdamP(learning_rate=0.001, betas=(0.9, 0.999), weight_decay=1e-2)
optimizer_sgdp = SGDP(learning_rate=0.1, weight_decay=1e-5, momentum=0.9, nesterov=True)
  • Do not use with tf.nn.scale_regularization_loss. Use the weight_decay argument.

Arguments

SGDP and AdamP share arguments with tf.keras.optimizers.SGD and tf.keras.optimizers.Adam. There are two additional hyperparameters; we recommend using the default values.

  • delta : threhold that determines whether a set of parameters is scale invariant or not (default: 0.1)
  • wd_ratio : relative weight decay applied on scale-invariant parameters compared to that applied on scale-variant parameters (default: 0.1)

Both SGDP and AdamP support Nesterov momentum.

  • nesterov : enables Nesterov momentum (default: False)

How to cite

@article{heo2020adamp,
    title={Slowing Down the Weight Norm Increase in Momentum-based Optimizers},
    author={Heo, Byeongho and Chun, Sanghyuk and Oh, Seong Joon and Han, Dongyoon and Yun, Sangdoo and Uh, Youngjung and Ha, Jung-Woo},
    year={2020},
    journal={arXiv preprint arXiv:2006.08217},
}

adamp-tensorflow's People

Contributors

taki0112 avatar

Watchers

 avatar  avatar

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.