# An Improved Federated Learning-Assisted Data Aggregation Scheme for Smart Grids
## 1 Introduction
### Contributions  
This paper makes the following contributions:  
(1) As a pioneering work, this paper presents an FL-based framework for the PIoT. Building upon the existing system architecture of the smart grid of IoT and the collaborative cloud-edge-end structure, the framework is enhanced to address the current privacy issues and leverage the characteristics of federated learning.  
In this framework, machine learning tasks are executed at edge nodes, and only the model's trained parameters are transmitted to the cloud server. This approach ensures the privacy and security of local data, as no data from any party involved in the learning process are leaked when compared to directly aggregating all power consumption data on the cloud server. The use of the cloud server for aggregating parameter data transmitted from edge nodes involves identity verification during the aggregation process, effectively guarding against forged identities of edge nodes within the framework, thus enhancing overall security.  
(2) A secure aggregation algorithm based on federated learning is proposed. This method improves upon traditional federated learning approaches by combining secure multi-party computations and differential privacy techniques. By securely aggregating data, this method prevents attackers from decrypting the encrypted data during the learning process and inferring private information from intermediate results, thus providing sufficient privacy protection for the aggregation of data in the PIoT.  
Moreover, this method utilizes aggregation algorithms based on secret sharing and key negotiations to support edge node dropouts, mid-process, while ensuring the security of data transmission. Through security analysis, it has been demonstrated that the proposed secure aggregation algorithm in this paper can achieve secure and reliable data aggregation from edge nodes to cloud servers in the PIoT.  
(3) A privacy-preserving aggregation result verification algorithm is proposed. This method utilizes homomorphic hash functions and pseudo-random functions to protect data privacy while supporting edge nodes in verifying the aggregation results on the cloud server, ensuring the data correctness during the federated learning process. The performance analysis of the efficiency and overall overhead of the federated learning process demonstrates that the framework and method proposed in this paper can effectively execute FL tasks without compromising the normal efficiency of data model training.  
(4) A performance evaluation concerning the efficiency and overall cost of the FL process demonstrates that the proposed framework and methods can effectively execute federated learning tasks with good model accuracy and a shorter learning time.  
The subsequent sections of this paper are structured in the following manner. Section 2 examines previous studies on privacy-preserving strategies in smart grids. Our suggested model is introduced in Section 3. Section 4 presents the preliminaries relevant to our scheme. In Sections 5 and 6, we present the technical intuition and proposed scheme in detail. The security analysis is displayed in Section 7. The experiments and performance analysis are presented in detail in Section 8. Finally, a brief conclusion is drawn in Section 9.