Home

Awesome

Fed-GraB: Federated Long-tailed Learning with Self-Adjusting Gradient Balancer

This is the code for paper "Fed-GraB: Federated Long-tailed Learning with Self-Adjusting Gradient Balancer".

Parameters

parametersdescription
roundsNumber of rounds in training process, option:500
num_usersNumber of clients, option:40,20
local_bsBatch size for local training, option:5
betaCoefficient for local proximal term, option: 0.01,0
modelneural network model, option: resnet18,resnet34,resnet50
datasetDataset, option:cifar10,cifar100,imagenet and inat
iidAction iid or non iid, option: store_true
alpha_dirichletParameter for Dirichlet distribution, option: 10,1

Usage

python fed_grab.py --dataset cifar10 --iid --IF 0.01 --local_bs 5 --rounds 500 --num_users 40 --beta 0 --dataset cifar10  --model resnet18 --gpu 0
python fed_grab.py --dataset cifar10 --alpha_dirichlet 1 --IF 0.01 --local_bs 5 --rounds 500 --num_users 40 --beta 0 --dataset cifar10  --model resnet18 --gpu 0