How curlytheses/pwhfl works
PWHFL is a research pipeline for robust image classification with heterogeneous federated clients. The main workflow prepares private/public/test data, pretrains participant models, then runs public-data collaboration and local updates; baseline and ablation routines provide comparison paths. The graph preserves the README’s documented capabilities, including corruption handling, AugMix/JSD, contrastive learning, and performance-weighted transfer. Source excerpts are partial, so links between implementation modules are included only where documented; the README supports the broader workflow links.
Main entry points: pretrain.py Client pretraining · pwhfl.py PWHFL collaboration · init_dataset.py FL datasets · make_cifar_c.py Corruption generation
Components 18
Data preparation
- CIFAR wrappers
Dataset/cifar.py - FL datasets
Dataset/init_dataset.py - Data partitioning
Dataset/sampling.py - Dataset utilities
Dataset/utils.py - Corruption generation
Dataset/make_cifar_c.py - Image augmentations
Dataset/augmentations.py - Data augmentation
Dataset/dataaug.py
Client models
- ResNet models
Network/Models_Def/resnet.py - ShuffleNet model
Network/Models_Def/shufflenet.py - MobileNetV2 model
Network/Models_Def/mobilnet_v2.py
Federated training
- Client pretraining
Network/pretrain.py - Model checkpoints
- PWHFL collaboration
HHF/pwhfl.py - Contrastive losses
HHF/loss.py
Comparison studies
- RAHFL baseline
HHF/rahfl.py - Ablation studies
HHF/ablation.py
Other components
- CIFAR data
- Experimenter
Connections 19
- CIFAR data → CIFAR wrappers: loads CIFAR
README.md - CIFAR data → FL datasets: provides datasets
README.md - CIFAR data → Corruption generation: generates corruptions
README.md - Experimenter → Client pretraining: starts pretraining
README.md - Client pretraining → Model checkpoints: stores checkpoints
README.md - Client pretraining → ResNet models: trains client models
README.md - Client pretraining → ShuffleNet model: trains client models
README.md - Client pretraining → MobileNetV2 model: trains client models
README.md - Experimenter → PWHFL collaboration: starts collaboration
README.md - PWHFL collaboration → Model checkpoints: loads pretrained
README.md - PWHFL collaboration → CIFAR data: uses public data
README.md - PWHFL collaboration → Contrastive losses: uses contrastive objectives
README.md - Experimenter → RAHFL baseline: runs baseline
README.md - Experimenter → Ablation studies: runs ablations
README.md - Experimenter → Corruption generation: prepares corruptions
README.md - Experimenter → Image augmentations: configures robustness training
README.md - Experimenter → Data augmentation: configures robustness training
- FL datasets → Data partitioning: partitions clients
- FL datasets → Dataset utilities: uses loader utilities