Shaoxiong Ji. (2018, March 30). A PyTorch Implementation of Federated Learning. Zenodo. http://doi.org/10.5281/zenodo.4321561
This is part of a master thesis. The aim of the thesis is to explore potentiall roles of device scheduling in federated learning.
python>=3.6
pytorch>=0.4
The MLP and CNN models are produced by:
python main_nn.py
Federated learning with MLP and CNN is produced by:
python main_fed.py
See the arguments in options.py.
For example:
python main_fed.py --dataset mnist --iid --num_channels 1 --model cnn --epochs 50 --gpu 0
--all_clients
for averaging over all client models
NB: for CIFAR-10, num_channels
must be 3.