Skip to content

[CVPR 2023] Federated Domain Generalization with Generalization Adjustment

Notifications You must be signed in to change notification settings

MediaBrain-SJTU/FedDG-GA

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Federated Domain Generalization with Generalization Adjustment - CVPR 2023

Video of our work

Alt text

Poster of our work

image

Paper of our work

This repo provides a demo for the CVPR 2023 paper "Federated Domain Generalization with Generalization Adjustment". paper link

To cite, please use:

@InProceedings{Zhang_2023_CVPR,
    author    = {Zhang, Ruipeng and Xu, Qinwei and Yao, Jiangchao and Zhang, Ya and Tian, Qi and Wang, Yanfeng},
    title     = {Federated Domain Generalization With Generalization Adjustment},
    booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
    month     = {June},
    year      = {2023},
    pages     = {3954-3963}
}

Requirements

  • Python 3.9.7
  • numpy 1.20.3
  • torch 1.11.0
  • torchvision 0.12.0

Dataset

Firstly create directory for log files and change the dataset path (pacs_path, officehome_path and terrainc_path) and log path (log_count_path) in configs/default.py. Please download the datasets from the official links:

Training from scratch

We release the code for PACS dataset and the other two benchmarks can be applied by only changing the dataloader_obj in data/{officehome, terrainc}_dataset.py. All the five FedDG methods are released (FedAvg, FedProx, SCAFFOLD, AM, RSC).

Then running the code:

python algorithms/fedavg/train_pacs_GA.py --test_domain p --lr 0.001 --batch_size 16 --comm 40 --model resnet18 --note debug

Acknowledgement

Part of our code is borrowed from the following repositories.

About

[CVPR 2023] Federated Domain Generalization with Generalization Adjustment

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages