Giter Club home page Giter Club logo

newton_admm's Introduction

Newton ADMM

This project has the implementation of Newton ADMM of the paper

Distributed Second-order Convex Optimization

Environment

We implemented Newton-ADMM on top of Pytorch with mpi support.

Currently, if user wants Pytorch with mpi support, one needs to install Pytorch from source.

For the instructions of installing it from source, please see here

Running the Script

The main python script that runs Newton-ADMM is ADMM_mpi.py.

It takes the following 7 arguments:

  1. Lambda : The regularization parameter.
  2. CG_tol : The tolerance of Congugate Gradient(CG) Descent Method
  3. CG_maxit : The maximun number of CG iterations
  4. Newton_maxit : The maximun number of Newton iterations, that is, epoch.
  5. LS_maxit : The maximun number of Line Search Method iterations
  6. data_path : The path of BOTH your training set and testing set.
  7. num_nodes : The number of nodes(including Master and Workers) to run Newton-ADMM.

For example

mpirun -np num_nodes -hostfile yourhostfile  python ADMM_mpi.py Lambda CG_tol CG_maxit Newton_maxit LS_maxit data_path num_nodes

Specifically, if a user wants 1 Master and 2 workers to run Newton-ADMM, the above command would be

mpirun -np 3 -hostfile yourhostfile  python ADMM_mpi.py Lambda CG_tol CG_maxit Newton_maxit LS_maxit data_path 3

And the format/content of "yourhostfile" in this case is:

master_host_name
worker1_host_name
worker2_host_name

License

This project is licensed under the MIT License - see the LICENSE.md file for details

newton_admm's People

Contributors

fang150 avatar

Watchers

 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.