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.
- Home
- Federated Learning Fundamentals
- Architecture and Workflow
- Interactive Simulator
- Algorithms
- Experiments
- Medical Applications
- Privacy and Security
- Federated Deep Learning
- Applications
- Projects and Code
- Research Center
- Quizzes
- My experiments
- Scientific references
- Glossary and FAQ
What is federated learning?
Federated Learning Fundamentals · Lesson beginner
The idea
Federated learning trains one shared model on data held by several parties. Raw data stays with each party; instead, model updates (parameters or parameter differences) travel to a coordinating server that combines them.
Explanation
McMahan et al. (2017) made the idea practical with FedAvg: the server sends the current model to selected clients, each trains it for several steps on local data, and returns the updated model, which the server averages weighted by sample counts. The cycle repeats for a number of rounds.
Federated learning does not make privacy automatic: the updates themselves can leak information, which is why it is usually paired with differential privacy and secure aggregation (see the privacy module).
Example
Five hospitals want a radiograph classifier, but images may not leave each hospital. A shared model is trained without moving the images; only model updates are exchanged.
Diagram (text)
- Server sends the global model w_t to clients
- Each client trains on its local data
- Clients return their updates
- Server aggregates the updates into w_{t+1}
Mathematical form
w_{t+1}=\sum_{k\in S_t}\frac{n_k}{n}\,w_{t+1}^{k}Review questions
- What travels between client and server, and what does not?
- Why does not moving data not guarantee privacy?
Related experiments
See also
References
- 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
- Kairouz, McMahan, et al. (2021). Advances and Open Problems in Federated Learning. Foundations and Trends in Machine Learning 14(1-2):1-210. doi:10.1561/2200000083
- Li, Sahu, Talwalkar, Smith (2020). Federated Learning: Challenges, Methods, and Future Directions. IEEE Signal Processing Magazine 37(3):50-60. doi:10.1109/msp.2020.2975749
