Federated Learning and Analytics
What you'll learn: How to train machine learning models and compute analytics on data that stays distributed across many devices or institutions, without ever pooling it centrally.
The Core Idea
Federated learning flips traditional ML on its head. Instead of bringing data to the model (centralizing sensitive information in one place), you bring the model to the data. Each participant—whether a hospital, smartphone, or organization—trains a local copy of a shared model on their own data. Only the model updates (like gradient vectors or parameter changes) are sent to a central coordinator, which aggregates them into a global model. The raw data never leaves its origin.
Federated analytics extends this concept beyond ML training to compute aggregate statistics—like averages, histograms, or counts—across decentralized datasets without exposing individual records.
Why It Matters for Privacy
This architecture provides structural privacy protection: since raw data never centralizes, you eliminate single points of failure and reduce attack surface. Even if the coordinator is compromised, attackers don't immediately gain access to everyone's personal information.
Think of it like this: Instead of everyone mailing their medical records to a research lab, the lab sends analysis instructions to each hospital. Each hospital computes results locally and only sends back summary statistics. The full patient data never travels.
Combining with Other Privacy Technologies
Federated learning pairs powerfully with secure aggregation (from lesson 2844) to encrypt updates in transit, and differential privacy (lessons 2912+) to add noise that prevents inference attacks on individual contributions. These layers create defense-in-depth against model updates inadvertently leaking sensitive information.
Key Takeaway: Federated learning and analytics enable collaborative computation across sensitive, distributed datasets by keeping data local and only sharing aggregated model updates or statistics—providing inherent privacy benefits when combined with cryptographic and statistical protections.