Lightweight differential privacy federal learning method for cross-domain management and control of power data

By proposing a lightweight differential privacy federated learning method in cross-domain control of power data, combined with technologies such as model pruning, quantitative compression, secret sharing and homomorphic encryption, the contradiction between power data privacy protection and efficient utilization is solved, the effect of reducing computing complexity and communication overhead is achieved, and the intelligent development of the power industry is promoted.

CN120145445APending Publication Date: 2025-06-13ELECTRIC POWER SCI RES INST OF STATE GRID XINJIANG ELECTRIC POWER CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202510219007.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-26
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

In the cross-domain control of power data, the existing technology is difficult to effectively protect data privacy, and it also faces the problems of high computing resource consumption and large communication overhead. Especially when dealing with large-scale high-dimensional power data, it is difficult to meet the real-time decision-making needs.

Method used

A lightweight differential privacy federated learning method for cross-domain management of power data is proposed. The global model architecture and differential privacy parameters are determined through a central server, and model training and parameter processing are carried out locally on the client, including model pruning, quantitative compression, secret sharing and homomorphic encryption and other technologies to reduce the communication and computing overhead of cross-domain data collaboration.

Benefits of technology

On the basis of ensuring the privacy and security of power data, it significantly reduces the computing complexity and communication overhead of cross-domain data collaboration, improves model training efficiency, promotes the safe and efficient cross-domain utilization of power data, and promotes the intelligent development of the power industry.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120145445A_ABST
    Figure CN120145445A_ABST
Patent Text Reader

Abstract

The invention discloses a lightweight differential privacy federal learning method for cross-domain management and control of power data. The method comprises the following steps: S1, performing initialization setting; s2, performing local training and parameter processing on the client; s3, uploading and aggregating parameters; s4, privacy loss evaluation and parameter adjustment; s5, pruning and compressing the model; s6, privacy protection and full mask multiplexing based on secret sharing; and S7, preventing collusion attacks. According to the method, the calculation complexity is remarkably reduced, and the core contradiction that privacy protection and model practicability are difficult to consider in cross-domain cooperation of power data is solved; the problems of high communication overhead and insufficient computing power of edge equipment during massive power data processing of traditional federated learning are solved, and the real-time performance and expandability of cross-domain cooperation are remarkably improved; while data availability is guaranteed, complex threats such as multi-client collusion and man-in-the-middle attack are effectively handled, and a privacy protection framework with a higher security level is provided for multi-agent cooperation of a power system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence security and data privacy protection, and particularly to a lightweight differential privacy federated learning method for cross-domain control of power data. Background Art

[0002] The intelligent development of the power industry depends on multi-source and cross-domain data fusion and collaborative analysis. The control of transmission lines needs to combine real-time operation parameters, meteorological data, and geographical information data to achieve accurate fault prediction and operation and maintenance scheduling. The operation of the power market needs to integrate information such as power generation costs, unit output characteristics, energy structure, load demand curves, and user electricity consumption behavior characteristics to optimize resource allocation and formulate reasonable electricity prices. However, cross-domain data circulation exacerbates the risk of privacy leakage, and innovative privacy protection technologies and management strategies are urgently needed to ensure the security and availability of power data in cross-domain control.

[0003] Under the traditional power data processing mode, centralized data storage and processing pose a risk of privacy leakage. Homomorphic encryption technology has a high computational complexity, which affects the timeliness of data processing. Secure multi-party computation (SMC) has a large communication overhead, is prone to causing communication congestion, and reduces computational efficiency. Privacy protection methods based on access control are difficult to cope with the complex data circulation paths brought about by the increasing number of cross-departmental and cross-enterprise projects, and are prone to permission abuse or misoperation, resulting in data leakage.

[0004] Federated learning is widely used in the power field. By locally training models and uploading parameters, it avoids the direct transmission of original data and reduces the risk of privacy leakage. In power load forecasting and equipment fault diagnosis, federated learning combines with homomorphic encryption technology to improve the accuracy of the model and the level of privacy protection. However, federated learning still has deficiencies in privacy protection mechanisms and computational resource consumption. For example, privacy protection is not perfect in the face of complex attack methods, the requirements for computing devices are high when dealing with massive high-dimensional data, and frequent parameter transmission increases the network burden. Differential privacy technology protects data privacy by adding noise, effectively preventing attackers from inferring individual data details from the output results. In federated learning, differential privacy technology is particularly important in the parameter uploading link to prevent attackers from reverse-deriving sensitive information. However, differential privacy technology faces challenges such as the difficulty of setting privacy budgets, increasing computational costs and communication overheads. Especially when dealing with large-scale high-dimensional power data, it may lead to an overly long training process and be difficult to meet the needs of real-time decision-making. Therefore, it is necessary to design a lightweight differential privacy federated learning method with stronger adaptability and better privacy protection effect. Summary of the Invention

[0005] The objective of the present invention is to solve the contradiction between data privacy protection and efficient utilization in cross-domain control of power data, and propose a lightweight differential privacy federated learning method for cross-domain control of power data, which can reduce the communication and computing overhead of cross-domain data collaboration, improve the model training efficiency, promote the safe and efficient cross-domain utilization of power data, and drive the intelligent development of the power industry while ensuring the privacy and security of power data.

[0006] To achieve the above technical objectives, the technical solution adopted by the present invention is as follows:

[0007] A lightweight differential privacy federated learning method for cross-domain control of power data, including: the central server determines the global model architecture, sets the differential privacy parameters, and broadcasts the differential privacy parameters and the initial parameters of the global model to each client; after the client completes local model training, it uploads the parameter added with noise to the central server; the central server randomly selects the clients participating in aggregation, and the central server further adds noise when aggregating the parameters to obtain the updated global model parameters; the central server uses the validation set to evaluate the performance of the updated model; the client reduces the number of model parameters through model pruning and quantization compression during local training; the client performs secret sharing before uploading the parameters, adopts the full mask reuse mechanism, uses the double mask structure during training, uploads and submits the auxiliary vector, and encrypts the data using homomorphic encryption.

[0008] Preferably, the method specifically includes the following steps:

[0009] S1. Initialization settings, the central server determines the global model architecture, and the initial parameters of the global model are obtained after training the historical data by the global model architecture. At the same time, the differential privacy parameters are set and these parameters are broadcast to each client;

[0010] S2. Client local training and parameter processing, after receiving the parameters, the client performs model training, calculates the gradient vector and clips it, calculates the uplink sensitivity and noise scale, and obtains the upload parameters after adding noise;

[0011] S3. Parameter upload and aggregation, the central server randomly selects the clients participating in aggregation, the selected clients upload the processed parameters, and the server aggregates the parameters and adds noise to obtain the updated global model parameters;

[0012] S4. Privacy loss evaluation and parameter adjustment, the central server uses the validation set to evaluate the performance of the updated model, adjusts the clipping threshold, noise scale according to the evaluation results and randomly selects clients again for retraining;

[0013] S5. Model pruning and compression. When the client conducts local training, it uses a pruning algorithm to remove weights below a set threshold, and then uses a quantization compression algorithm to reduce the data volume.

[0014] S6. Privacy protection based on secret sharing and full mask reuse. Before uploading the parameters, the client performs secret sharing and reuses the mask shares during iteration.

[0015] S7. Prevention of collusion attacks. During training, a double-mask structure is adopted, auxiliary vectors are uploaded and submitted, and homomorphic encryption is used to encrypt the data.

[0016] Preferably, in the step S1, the central server selects a recurrent neural network as the global model architecture, uses the recurrent neural network to train historical data, obtains a set of model parameters that fit the historical data, extracts these parameters from the historical training results as the initial parameters of the global model, denoted as , and at the same time sets the differential privacy parameter and , sets the clipping threshold , and broadcasts the initial parameters of the global model, the differential privacy parameter, and the clipping threshold to each client through a communication protocol.

[0017] Preferably, in the step S2, after receiving the parameters from the central server, the client conducts model training, calculates the obtained gradient vector , if it exceeds the set clipping threshold , then perform the clipping operation:

[0018]

[0019] wherein, is the gradient vector of the i-th client, is the L2 norm of the gradient vector , is the clipped gradient vector, is the set clipping threshold;

[0020] Then, calculate the uplink sensitivity , calculate the noise scale according to the following formula , assuming that the number of times the local parameter is exposed on the uplink is 1:

[0021]

[0022] wherein, is the privacy budget, is the error rate;

[0023] Then add from the Gaussian distribution

[0024] Sampled noise vector to obtain the final upload parameter:

[0025]

[0026] In the formula, is the noise vector obtained by uplink sampling, is the clipped gradient vector, is the upload parameter.

[0027] Preferably, in the step S3, the central server randomly selects clients participating in aggregation according to the client data volume, data timeliness, and data reliability index, and the selected clients upload the processed upload parameter using the file transfer protocol , and the server adopts a weighted average aggregation method during the aggregation process:

[0028]

[0029] where, is the weight, and the formula is as follows:

[0030]

[0031] where , , are weight coefficients used to balance the importance of different factors, represents the client data volume, represents the data timeliness, represents the data reliability index;

[0032] Then calculate the downlink sensitivity, and the downlink sensitivity is obtained by calculating the maximum change in the update of the global model parameters, and its calculation formula is:

[0033]

[0034] where, represents the update amount of the model parameters, represents the L2 norm of, and max is to take the maximum value; then calculate the downlink noise scale according to the following formula:

[0035]

[0036] In the formula, is the privacy budget, is the error rate;

[0037] from the Gaussian distribution Sampling noise vector Added to the aggregated posterior gradient to obtain the updated global model parameters :

[0038]

[0039] wherein is the noise vector obtained by downlink sampling is the gradient after weighted average aggregation is the updated global model parameter

[0040] Preferably, in step S4, the central server evaluates the performance of the updated model using a specially reserved power data validation set, and the evaluation metrics include prediction accuracy Acc, mean square error MSE, and F1 value; if the performance of the updated model does not meet the expectation, adjust the pruning threshold and the noise scale , and at the same time randomly select clients again and retrain

[0041] Preferably, in step S5, when the client performs local training, it adopts a pruning algorithm based on structural importance and data-driven, removes the weights below the set threshold, and obtains the pruned weight matrix , and then adopts a hybrid quantization compression algorithm to quantize 32-bit floating-point parameters into 8-bit integer representation to reduce the data volume. The quantization formula is:

[0042]

[0043] wherein is the quantized weight is the pruned weight matrix

[0044] Preferably, in step S6, before uploading the parameters, the client selects a random number as a mask, and uses Shamir secret sharing to split it into shares , and sends them to other clients and the server respectively; during the generation and transmission of the shares, the shares are hashed using the cryptographic hash function SHA-3 to ensure the integrity and authenticity of the shares

[0045] Preferably, in step S7, when preventing collusion attacks, the client calculates the main function , selects a random vector as a double-mask structure in the local model training of the client, calculates the auxiliary vectors and , uploads and submits the auxiliary vectors and During the data transmission and storage processes, homomorphic encryption is used to encrypt the auxiliary vector and , and the parameters of the random vector and the main function are updated regularly. Compared with the prior art, the beneficial effects of the present invention are as follows:

[0046] 1. Breakthrough in the balance between privacy protection and efficient collaboration: Traditional federated learning faces challenges in power data cross-domain management, such as complex privacy budget settings and performance degradation of the model caused by noise superposition. The present invention uses a dynamic differential privacy mechanism to add adaptive noise hierarchically in the parameter upload and aggregation links, and combines privacy loss evaluation to dynamically adjust the noise scale and clipping threshold. While strictly restricting the leakage of individual sensitive information, it ensures the convergence efficiency of the model. Compared with high-overhead technologies such as homomorphic encryption, this method significantly reduces the computational complexity and solves the core contradiction that it is difficult to balance privacy protection and model practicality in power data cross-domain collaboration;

[0047] 2. Lightweight design for efficient resource utilization: Aiming at the characteristics of high-dimensional power data and limited cross-domain device resources, the present invention proposes model pruning and hybrid quantization compression technologies. By evaluating and removing redundant parameters and quantizing 32-bit floating-point parameters into 8-bit integers, the communication data volume is reduced. Combined with the client random scheduling strategy, resource allocation is optimized and network load is reduced, solving the pain points of large communication overhead and insufficient computing power of edge devices in traditional federated learning when processing massive power data, and significantly improving the real-time performance and scalability of cross-domain collaboration;

[0048] 3. Enhancement of robustness in complex attack scenarios: Aiming at the potential risk of collusion attacks in the cross-domain circulation of power data, the present invention introduces a double-mask structure and a secret sharing mechanism. By random vector masking, auxiliary vector encryption, and regular key updates, the path for attackers to reverse-engineer the original data through parameters is blocked. Compared with traditional access control or single encryption methods, this solution effectively addresses complex threats such as multi-client collusion and man-in-the-middle attacks while ensuring data availability, providing a higher security level privacy protection framework for multi-agent collaboration in the power system. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 is a flowchart of the method according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0050] The following further clarifies the present invention with reference to specific embodiments. The embodiments are implemented on the premise of the technical solution of the present invention. It should be understood that these embodiments are only used to illustrate the present invention and not to limit the scope of the present invention.

[0051] Embodiment 1:

[0052] As Figure 1 shown, the lightweight differential privacy federated learning method for cross-domain control of power data in this embodiment is aimed at the load forecasting task of the power system. The dataset is a dataset of detailed electricity consumption behaviors of power users. This method includes the following steps:

[0053] Step 1, Initialization settings: The central server determines the architecture of the global model according to the type, scale, and application objectives of the power data. In this embodiment, a recurrent neural network (RNN) architecture is selected as the global model architecture. (Common types of recurrent neural networks include basic RNN, long short-term memory network (LSTM), gated recurrent unit (GRU), etc. These variants have their own advantages in processing data. In this embodiment, according to the characteristics of power data and application requirements, the basic RNN architecture is selected in this embodiment). The recurrent neural network (RNN) is suitable for processing time series data and can effectively capture the changing patterns of power loads. Specifically, this recurrent neural network structure consists of an input layer, two hidden layers, and an output layer. The input layer receives a feature vector with a dimension of 10×1; the first hidden layer is an RNN layer with a dimension of 64×10, indicating that it has 64 hidden units, and each unit receives a 10-dimensional input; the second hidden layer is an RNN layer with a dimension of 32×64, indicating that it has 32 hidden units, and each unit receives the 64-dimensional output from the first hidden layer; finally, the output layer maps the 32-dimensional output of the second hidden layer to a 1-dimensional output space for prediction, and its dimension is 1×32. Then use the RNN to train the historical load data to obtain a set of model parameters that can better fit the historical data. These parameters include the weights and biases of the network. Extract these parameters from multiple sets of historical training results as the initial parameters of the global model, denoted as . At the same time, combined with the privacy regulations of the power industry and the sensitivity of the data, set the differential privacy parameters and , and set the clipping threshold . The dataset in this embodiment is a dataset involving the detailed electricity consumption behaviors of power users. Set the privacy budget to 0.03, the error rate to , the clipping threshold to 2.5, and broadcast these parameters and to each client through a secure and reliable communication protocol (SSL / TLS) to ensure the confidentiality and integrity of information during transmission. The purpose of initialization is to provide a shared initial state for all clients, thereby ensuring the effectiveness of differential privacy throughout the federated learning process.

[0054] Step 2: Local Training and Parameter Processing on the Client Side: After receiving the parameters from the central server, the client conducts model training. To ensure compatibility with the globally initialized model on the central server, the client uses the same architecture as the global model for training. In this embodiment, the globally initialized model on the central server is a Recurrent Neural Network (RNN), so the client also uses the Recurrent Neural Network (RNN) architecture for local training. Taking the client of the power operation and maintenance department in a certain region as an example, its local data covers the equipment operation parameters of different substations in the past month, such as the transformer oil temperature (ranging from 45 to 85 degrees, and the data shows certain time-series patterns and seasonal fluctuations), and the winding current (100 - 1000A, which varies significantly under different time periods and load conditions).

[0055] In one training iteration, the gradient descent algorithm with an adaptive learning rate is adopted. This algorithm dynamically adjusts the learning rate of each parameter by calculating the first moment and the second moment of the gradient, so as to adaptively update the model parameters according to the magnitude and change of the gradient in each iteration, in order to accelerate convergence and improve stability. The gradient vector obtained by calculating the partial derivative of the loss function with respect to the model parameters has the following calculation formula:

[0056]

[0057] In the formula, represents the gradient vector of the i-th client, reflecting the update direction and magnitude of the model parameters by the local data of this client; L represents the loss function; represents the parameters of the model; represents the loss function of the i-th client The partial derivative with respect to the n-th parameter, where n is the total number of model parameters.

[0058] In this embodiment, the calculated gradient vector (gradient values corresponding to different device parameter dimensions), and the norm . Compare 's L2 norm with the clipping threshold . Since , the clipping operation needs to be performed. The clipped gradient vector . In the formula, is the gradient vector of the i-th client, is the L2 norm of the gradient vector , is the clipped gradient vector, is the set clipping threshold;

[0059] Then calculate the uplink sensitivity . Calculate the uplink noise scale according to the following formula (assuming the number of exposures of local parameters on the uplink is 1):

[0060]

[0061] Wherein, is the noise scale, is the privacy budget, is the error rate; After calculation, ;

[0062] Sample the noise vector from the Gaussian distribution , and the uploaded parameter is obtained after addition, is the noise vector obtained by uplink sampling. During the calculation process, a high-precision numerical calculation library is used to ensure the accuracy of the calculation, and the intermediate results are securely stored to prevent data leakage.

[0063] Step 3: Parameter Upload and Aggregation: The central server selects from clients. In this embodiment , considering factors such as the client data volume, data timeliness, and data reliability index, randomly select clients to participate in the aggregation. In this embodiment . The selected clients upload the processed parameters using the Secure File Transfer Protocol (SFTP). During the aggregation process, the server adopts a weighted average aggregation method:

[0064]

[0065] Wherein, is the gradient vector after weighted average aggregation, is the weight, is 45;

[0066] The weight is determined by considering not only the client data volume (clients with a larger proportion of the total data volume have relatively higher weights), data timeliness (recently updated data has a greater weight), but also introducing a data reliability index (clients with data that has been verified multiple times and has a small error have higher weights), expressed as:

[0067]

[0068] Among them, , , are weight coefficients used to balance the importance of different factors, represents the client data volume, represents the data timeliness, represents the data reliability index.

[0069] Downlink Sensitivity It is obtained by calculating the maximum change in the update of the global model parameters, and its calculation formula is:

[0070]

[0071] where represents the update amount of the model parameters, represents the L2 norm of, and max is to take the maximum value. After calculation , and then calculate the downlink noise scale according to the following formula:

[0072]

[0073] After calculation, , sample the noise vector from the Gaussian distribution and add it to to obtain the updated global model parameters:

[0074]

[0075] In the formula, is the updated global model parameter, is the noise vector sampled by the downlink, is the gradient vector after weighted average aggregation;

[0076] During the aggregation operation, the security mechanism of the distributed computing framework is used to ensure the parallelism and security of the calculation.

[0077] Step 4, Privacy Loss Evaluation and Parameter Adjustment: The central server uses the data validation set (the data validation set refers to a part divided from the data set, and the data set is divided into a training set, a validation set, and a test set) to evaluate the performance of the updated model. The evaluation indicators include prediction accuracy, mean square error, F1 value, etc. If the model accuracy is lower than 80%, it is considered that the expected result is not achieved. If the privacy budget consumption is more than 30%, it is considered that the budget consumption is too fast. During the evaluation process of this embodiment, the evaluation model accuracy is 73%, the privacy budget has been used 35%, and through performance analysis, it is found that the accuracy is lower than expected and the privacy budget consumption exceeds, then appropriately reduce the clipping threshold (set as ) and the noise scale ( is adjusted to 0.42, is adjusted to 0.5), and at the same time randomly select clients again and retrain (after adjusting the parameters, the entire model is retrained in the same way as in step 2). During the evaluation process, an automated test framework and data analysis tools are used to accurately record and analyze the evaluation results to provide a scientific basis for parameter adjustment.

[0078] Step 5, Model Pruning and Compression: When the client conducts local training, a pruning algorithm based on structural importance and data-driven is adopted. For a weight matrix of a certain layer of the recurrent neural network model used in this embodiment (with a size of ), first, the importance score of the weight is determined by calculating the second-order derivative information of the weight (eigenvalues of the Hessian matrix) and data correlation (Pearson correlation coefficient).

[0079] For example, a higher score is given to the weights that are highly correlated with the key features of the power load and have a relatively large absolute value of the second derivative. A threshold is set, and the weights below this threshold are removed, thereby removing the weights that have less impact on the model performance. In this embodiment, about 38% of the weights are removed to obtain the pruned weight matrix . Then, a hybrid quantization compression algorithm is adopted. First, the weights are non-uniformly quantized (a quantization method based on the exponential distribution) to map them to a lower-precision numerical range, and then the activation values are linearly quantized. The 32-bit floating-point parameters are quantized into 8-bit integer representations, significantly reducing the data volume. The quantization formula is:

[0080]

[0081] In the formula, is the quantized weight, min is to take the minimum value, and max is to take the maximum value. During the pruning and compression process, a backup and recovery mechanism is adopted to ensure that the model's dot product parameters are quantized into 8-bit integer representations, significantly reducing the data volume. During the pruning and compression process, a backup and recovery mechanism is adopted to ensure the recoverability of the model and prevent data loss caused by operational errors.

[0082] Step 6, Privacy Protection Based on Secret Sharing: Before uploading the parameters, the client selects a random number as a mask. A certain client selects , and uses the Shamir secret sharing scheme to split it into shares In this embodiment , 4 shares , satisfying and are sent to other clients and the server respectively.

[0083] For example, for the share , since other parties lack sufficient share information, they cannot restore , effectively protecting privacy. During the generation and transmission of the shares, the cryptographic hash function SHA-3 is used to hash the shares to ensure the integrity and authenticity of the shares and prevent the shares from being tampered with during transmission.

[0084] Step 7, Full Mask Reuse: In the iteration, use the SHA-256 hash function to map the seed (e.g., the initial seed is "powerdata0815") to coefficients. Assume that the coefficient obtained from the first round of hashing is , and the coefficient obtained from the second round is . Reuse the mask shares by Lagrange interpolation and adding jointly generated random numbers (e.g., in the first round, in the second round). Specifically, when calculating the new mask shares according to the Lagrange interpolation formula, adopt an efficient polynomial calculation algorithm to reduce the computational overhead, and at the same time use cryptographic signature technology to verify the signature of the calculation process to ensure the correctness and traceability of the calculation. During each round of iteration, record in detail the changes in the hash values, random numbers (jointly generated random numbers), and mask shares for subsequent auditing and debugging.

[0085] Step 8, Collusion Attack Prevention: During the initialization in the collusion attack prevention, the client calculates the main function (the main function refers to the mathematical function used to generate keys and perform data encryption in cryptography). In this embodiment, a certain client calculates the main function ( is a function based on elliptic curve cryptography, seed is a random seed, refers to the share). In the collusion attack prevention, calculate the auxiliary vectors and ; First, the client calculates the gradient of the model parameters based on its local data, and this gradient reflects how the model parameters need to be adjusted to reduce the value of the loss function . To protect this gradient information from being inferred by other clients or the server, the client introduces a random vector v, which is used as the first layer of mask for the double-mask structure. In this embodiment, the random vector , and the client calculates , which is obtained by adding the random vector v to the original gradient , that is, . aims to conceal the true value of the original gradient , so that even if it is intercepted during data transmission, the attacker cannot directly recover the original gradient from .

[0086] Then, the client calculates the second auxiliary vector , which is obtained by subtracting half of the gradient from the random vector v, that is, . This vector serves as the second layer of mask, further increasing the strength of privacy protection.

[0087] Then, upload and submit the auxiliary vectors . During data transmission and storage, homomorphic encryption technology is used to encrypt , and other data to ensure the security of data in the collusion attack scenario. Meanwhile, regularly update the parameters of the random vector and regularly update the calculation of the main function . The calculation of the main function is a function based on elliptic curve cryptography and has a random parameter seed. When it needs to be updated, recalculate the main function. At this time, the seed will be the new random seed, avoiding the problems of key leakage and being cracked, and increasing the difficulty and cost for attackers to crack.

[0088] The present invention is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowcharts and / or block diagrams, and the combination of processes and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, so that the instructions run by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in one process Figure 1 one process or multiple processes and / or blocks Figure 1 one block or multiple blocks.

[0089] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory generate a manufactured article including instruction means, and the instruction means implements the functions specified in one process Figure 1 one process or multiple processes and / or blocks Figure 1 one block or multiple blocks.

[0090] These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are run on the computer or other programmable device to generate a computer-implemented process, and thus the instructions run on the computer or other programmable device provide steps for implementing the functions specified in one process Figure 1 one process or multiple processes and / or blocks Figure 1 one block or multiple blocks.

[0091] Although the preferred embodiments of the present invention have been described, those skilled in the art can make additional changes and modifications once they know the basic creative concept. Therefore, the appended claims are intended to be construed to include the preferred embodiments and all changes and modifications falling within the scope of the present invention.

[0092] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalent technologies, the present invention is also intended to include these modifications and variations.

Claims

1. A lightweight differential privacy federated learning method for cross-domain control of power data, characterized in that: include: The central server determines the global model architecture, sets the differential privacy parameters, and broadcasts the differential privacy parameters and the initial parameters of the global model to each client; After the client completes model training locally, it uploads the parameters with added noise to the central server; the central server randomly selects clients to participate in the aggregation, and further adds noise when aggregating the parameters to obtain updated global model parameters; the central server uses the validation set to evaluate the performance of the updated model; the client reduces the number of model parameters through model pruning and quantization compression during local training; the client shares secrets before uploading parameters, adopts a full-mask multiplexing mechanism, uses a double-mask structure during training, uploads and submits auxiliary vectors, and uses homomorphic encryption to encrypt data.

2. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 1 is characterized in that: The method specifically comprises the following steps: S1. Initialization settings: The central server determines the global model architecture, which is trained on historical data to obtain the initial parameters of the global model, sets differential privacy parameters, and broadcasts these parameters to each client. S2, client local training and parameter processing. After receiving the parameters, the client performs model training, calculates the gradient vector and performs clipping, calculates the uplink sensitivity and noise scale, and obtains the upload parameters after adding noise. S3, parameter upload and aggregation, the central server randomly selects the clients participating in the aggregation, the selected clients upload the processed parameters, the server aggregates the parameters and adds noise to obtain the updated global model parameters; S4, Privacy loss evaluation and parameter adjustment. The central server uses the validation set to evaluate the performance of the updated model. According to the evaluation results, the cropping threshold and noise scale are adjusted, and the client is randomly selected again to retrain. S5, model pruning and compression. During local training, the client uses a pruning algorithm to remove weights below a set threshold, and then uses a quantization compression algorithm to reduce the amount of data. S6, Privacy protection based on secret sharing and full mask reuse, the client performs secret sharing before uploading parameters and reuses the mask share in iterations; S7,Collusion attack prevention,Use a double mask structure in training, upload and submit auxiliary vectors, and use homomorphic encryption to encrypt data.

3. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 2 is characterized in that: In step S1, the central server selects a recurrent neural network as the global model architecture, uses the recurrent neural network to train historical data, obtains a set of model parameters that fit the historical data, and extracts these parameters from the historical training results as the initial parameters of the global model, denoted as , and set the differential privacy parameters and , set the clipping threshold , and broadcast the initial parameters, differential privacy parameters, and pruning thresholds of the global model to each client through the communication protocol.

4. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 3 is characterized in that: In step S2, after receiving the parameters from the central server, the client performs model training and calculates the gradient vector If the clipping threshold is exceeded, , then perform the cropping operation: ; In the formula, is the gradient vector of the i-th client, is the gradient vector The L2 norm of is the clipped gradient vector, is the set clipping threshold; Then, calculate the uplink sensitivity , the noise scale is calculated according to the following formula , assuming that the number of times the local parameters are exposed in the uplink is 1: ; In the formula, It's the privacy budget. is the error rate; Then add the Gaussian distribution Sampled noise vector , get the final upload parameters: ; In the formula, is the noise vector obtained by uplink sampling, is the clipped gradient vector, Upload parameters.

5. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 4 is characterized in that: In step S3, the central server randomly selects The selected client uses the file transfer protocol to upload the processed upload parameters , during the aggregation process, the server adopts the weighted average aggregation method: ; in, is the weight, and the formula is as follows: ; in , , is the weight coefficient, which is used to balance the importance of different factors. Indicates the amount of client data. Indicates the timeliness of data. Reliability index of the data; Then calculate the downlink sensitivity, downlink sensitivity It is obtained by calculating the maximum change in the global model parameter update, and its calculation formula is: ; in, represents the update amount of the model parameters, express The L2 norm of , max is the maximum value; then calculate the downlink noise scale according to the following formula: ; In the formula, It's the privacy budget. is the error rate; From Gaussian distribution Sampled noise vector Add to post-aggregation gradient , and get the updated global model parameters : ; In the formula, is the noise vector sampled in the downlink, is the gradient after weighted average aggregation, are the updated global model parameters.

6. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 5 is characterized in that: In step S4, the central server uses a specially reserved power data validation set to evaluate the performance of the updated model. The evaluation indicators include prediction accuracy Acc, mean square error MSE and F1 value. If the performance of the updated model does not meet expectations, the clipping threshold is adjusted. and noise scale , and randomly select the client again and re-train.

7. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 1 is characterized in that: In step S5, the client uses a pruning algorithm based on structural importance and data-driven during local training to remove weights below a set threshold and obtain a pruned weight matrix , and then a hybrid quantization compression algorithm is used to quantize the 32-bit floating-point parameters into 8-bit integer representation to reduce the amount of data. The quantization formula is: ; In the formula, is the quantized weight, is the weight matrix after pruning.

8. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 1 is characterized in that: In step S6, the client selects a random number before uploading the parameters As a mask, Shamir secret sharing is used to split it into Share , and are sent to other clients and servers respectively; during the share generation and transmission process, the cryptographic hash function SHA-3 is used to hash the shares to ensure the integrity and authenticity of the shares.

9. The lightweight differential privacy federated learning method for cross-domain control of power data according to claim 1 is characterized in that: In step S7, when preventing collusion attacks, the client calculates the main function , select a random vector in the client local model training Make a double mask structure and calculate the auxiliary vector and , upload and submit auxiliary vectors and During data transmission and storage, homomorphic encryption is used to encrypt the auxiliary vector and Perform encryption processing and regularly update the random vector Parameters and periodic updates of the main function .

Citation Information

Cited By

  • Consumer goods data security protection method and system based on federal learning

    CN120850346A

  • Private weight adaptive heterogeneous data federal cooperative training method and system

    CN120974543A