Git Product home page Git Product logo

large-scale-fl's Introduction

Large-Scale_FL

This is an implementation of the seminal algorithm federated learning algorithm FedAvg described in the AISTATS 2017 paper Communication-Efficient Learning of Deep Networks from Decentralized Data by McMahan et al.

Implementation details

The main steps are as follows:

  1. A centralized server coordinates several clients. The clients are the devices which contain the data and actually carry out the training and backpropagation.
  2. At the beginning of each round, the server sends it's version of the model weights to all devices. Each device trains these weights on it's own subset of the dataset (in this case IID shards of MNIST).
  3. After a certain number of updations, all devices send their local version of the weights (now updated by gradient) back to the server.
  4. The server essentially scales these received weights by a factor proportional to the number of clients and aggregates them.
  5. The weights of this new aggregated model are then sent out to all the clients again in the next round.
  6. This process repeats till the final aggregated model converges in expectation.

FedAvg.ipynb simulates this process by using several independent instances of the model to represent the clients and the server.

Acknowledgement

Major credits for the implementation details go to https://github.com/eceisik/ece_fl_public
Also check out the original paper at Communication-Efficient Learning of Deep Networks from Decentralized Data

large-scale-fl's People

Contributors

120205690 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.