This repo is the implementation of the paper Federated optimization in heterogeneous networks
Run this repo:
-
Downloaded datasets and oraganize them as follows:
data ├── clinical │ ├── clinical_test.csv │ └── tmp │ ├── beta0.05 │ │ ├── clinical_node_0.csv │ │ ├── clinical_node_1.csv │ │ ├── clinical_node_2.csv │ │ ├── clinical_node_3.csv │ │ └── clinical_node_4.csv │ ├── beta0.5 │ └── ... └── ... -
Edit the configuration file
conf.py. Some important arguments are:global_epochs: number of global epochslocal_epochs: number of local epochsbeta: parameter of Dirichlet distributionmean_batch: number of instances used in computing the average in FedMixlambda: coefficient in loss of FedMixlr,momentum: optimizernum_parties: number of parties- ...
-
Start training:
python main.py #or python main.py --global_epoch=n --beta=m