TL;DR
This paper introduces a novel Federated Learning (FL) approach called Distillation-based Federated Learning (DFL) that enhances model accuracy for AIoT applications by incorporating Knowledge Distillation (KD). DFL achieves this by uploading both local model gradients and "soft targets" (probabilistic predictions) to the cloud server, enabling more informed global model updates without significantly increasing communication overhead.
What Problem Does This Paper Address?
Federated Learning (FL) is a promising paradigm for training machine learning models on decentralized data, particularly for Artificial Intelligence of Things (AIoT) applications, as it preserves user privacy by keeping data local. However, traditional FL suffers from model inaccuracy because local models are trained only on "hard labels" (the definitive correct answer), ignoring valuable information contained in incorrect predictions with small probabilities. While existing solutions like Knowledge Distillation (KD) can improve accuracy, many introduce substantial communication overhead, making them impractical for large-scale AIoT deployments with limited network and memory resources. This paper aims to bridge this gap by proposing an efficient and accurate FL method that leverages KD without incurring significant communication costs.
Methods
The core of the proposed DFL method lies in its integration of Knowledge Distillation (KD) into the FL training loop. Instead of solely relying on hard labels, DFL trains local models with two objectives: minimizing the error against hard labels and approximating "soft targets" derived from the global model's predictions on previous rounds.
Key methodological contributions include:
- DFL Architecture: A novel architecture that combines global soft targets and local model gradients for enhanced knowledge sharing.
- Soft Target Generation: In each round, AIoT devices upload not only their model gradients but also label-wise sample logits. These logits are aggregated on the cloud server to form global soft targets, which are then dispatched back to the devices. This process is designed to have negligible extra communication overhead as soft target sizes are much smaller than global models.
- Dynamic Adjustment Strategy: A crucial component is a dynamic adjustment strategy for the loss function weights. This strategy tunes the ratio between the cross-entropy loss (for hard labels) and the Kullback-Leibler divergence loss (for soft targets). In the early stages of training, when soft targets are less reliable, the hard label loss is prioritized. As training progresses, the weight shifts towards the soft target loss to leverage the richer knowledge it provides. A threshold is used to prevent the hard label loss from becoming too small in later stages, ensuring model stability.
- Convergence Analysis: The paper provides theoretical analysis of DFL's convergence, proving it can match FedAvg's convergence rate even in heterogeneous data scenarios.
Datasets
The paper evaluates the DFL approach on four well-known benchmark datasets:
- MNIST: A dataset of handwritten digits.
- CIFAR-10: A dataset of 10 classes of small images.
- CIFAR-100: A dataset of 100 classes of small images.
- FEMNIST: A dataset derived from the Federated Extended MNIST dataset, known for its inherent non-IID distribution.
The experiments consider two data distribution scenarios: IID (Independent and Identically Distributed), where data is uniformly distributed across devices, and non-IID, where data is skewed (e.g., 80% of samples on a device belong to one label).
Key Insights and Ideas
- Soft Targets as a Privacy-Preserving Knowledge Transfer Mechanism: DFL effectively uses soft targets for knowledge transfer without needing to share raw data, aligning with FL's privacy goals.
- The Importance of Dynamic Loss Weighting: Simply applying KD with a fixed ratio can be detrimental. The dynamic adjustment strategy is key to balancing the influence of hard labels and soft targets, adapting to the evolving reliability of soft targets throughout training.
- Synergy Between Gradients and Soft Targets: The paper highlights that combining local model gradients with global soft targets offers a more powerful signal for model improvement than either alone.
- Efficiency Gains: The proposed method achieves significant accuracy improvements without a substantial increase in communication overhead, making it practical for resource-constrained AIoT environments.
Key Results
- Superior Accuracy: DFL consistently outperforms state-of-the-art methods like FedAvg, FD, SCAFFOLD, and FedGen in terms of test accuracy across various datasets and models, particularly in non-IID scenarios. For instance, on CIFAR-10 with a CNN model in the non-IID scenario, DFL achieved 61.48% accuracy, significantly higher than FedAvg (57.92%), SCAFFOLD (58.32%), and FedGen (55.22%).
- Faster Convergence (in some cases): While not always the fastest, DFL demonstrates competitive convergence speeds, often reaching higher accuracies at similar communication rounds compared to baselines.
- Negligible Communication Overhead: The additional communication cost for transmitting soft targets is minimal, typically a few KB, making it suitable for AIoT.
- Optimal Threshold for Dynamic Strategy: Experiments suggest that a threshold of T=0.6 for the dynamic loss function ratio provides the best performance for most scenarios.
Limitations and Future Work
- Limitations: The paper acknowledges that the dynamic adjustment strategy could be further improved. While the current strategy is effective, it relies on a fixed threshold and a simple ratio based on training rounds. The paper notes that the FD method's convergence can be difficult, and FedGen's generated samples might be too simplistic for complex datasets.
- Future Work: The authors suggest exploring more sophisticated dynamic adjustment strategies, potentially by using model accuracy feedback to dynamically control the loss function ratio. This could lead to even better performance and adaptation to diverse training conditions.
Summary updated