Federated Learning Lab

Train models on distributed data without moving it: try FedAvg, FedProx and SCAFFOLD in a simulator that really computes in your browser, with privacy, medical applications, projects and quizzes.

14interactive experiments

One federated round in detail

Federated Learning Fundamentals · Lesson beginner

The idea

A round consists of: selecting participating clients, sending the model, local training, sending updates, aggregation, and updating the global model.

Explanation

After aggregation the server evaluates the model on test data (or collects client metrics). In the simulator you can watch these steps: each client card shows its samples, loss, accuracy and state (not selected / training / sent). Press “Next round” to run a single round and watch the server panel and the maths.

Diagram (text)

  1. Select S_t
  2. Broadcast w_t
  3. E local epochs
  4. Upload w_{t+1}^k
  5. Aggregate
  6. Evaluate

Mathematical form

w^{k}\leftarrow w^{k}-\eta\nabla \ell(w^{k};b)\quad(E\text{ epochs}),\qquad w_{t+1}=\sum_{k\in S_t}\frac{n_k}{\sum_{j\in S_t}n_j}w^{k}

Related experiments

See also

References

  1. McMahan, Moore, Ramage, Hampson, Agüera y Arcas (2017). Communication-Efficient Learning of Deep Networks from Decentralized Data. AISTATS 2017 (PMLR 54); arXiv:1602.05629. Link