
FederatedLearningPyTorch CNNFashion_Mnist
Image classification12 ops21.8K params
A small convolutional network for MNIST digits, the CNN of the FederatedAveraging experiments.
Image classification · 12 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
How this diagram was made
menagerie.classics.federated_nets:build_cnn_mnist: build({}) This is the convolutional network that the Federated Learning paper trains on the MNIST digit recognition task. The paper's subject is the training method more than the network: it introduces FederatedAveraging (FedAvg), which combines local stochastic gradient descent on each client with a server that performs model averaging. In that setting each client keeps a local training dataset that is never uploaded to the server.
In the paper the CNN has two 5x5 convolution layers, the first with 32 channels and the second with 64, each followed by 2x2 max pooling, then a fully connected layer with 512 units and ReLu activation and a final softmax output layer. The paper reports 1,663,370 total parameters for that configuration.
For the experiments MNIST was divided among 100 clients, either shuffled (IID) or sorted by digit label so that each client received 2 shards of 300 examples. With a target of 99% test-set accuracy on MNIST, the paper reports that more computation per client decreased the number of communication rounds by 35× for the CNN on the IID partition. It also reports a FedAvg CNN reaching 99.44% accuracy after 300 rounds, against 99.22% after 1200 rounds for the FedSGD baseline.
Key idea. The paper introduces FederatedAveraging, which combines local stochastic gradient descent on each client with a server that performs model averaging.
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
@misc{mcmahan2023communicationefficientlearningdeepnetworks,
title={Communication-Efficient Learning of Deep Networks from Decentralized Data},
author={H. Brendan McMahan and Eider Moore and Daniel Ramage and Seth Hampson and Blaise Agüera y Arcas},
year={2023},
eprint={1602.05629},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/1602.05629},
}