Compensation method and system for distributed power distribution network model integrating safety shuffle
By performing safe shuffling and compensation processing on the distribution network model in the power grid communication scenario, the aggregation deviation of model parameters caused by clock drift and safety shuffling between nodes is solved, and high-precision global power model parameters acquisition is achieved.
Patent Information
- Application Number
- CN202510186959.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-20
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2045-02-20
AI Technical Summary
In power grid communication scenarios, due to clock drift and safety shuffling between nodes, deviations are prone to occur when model parameters are aggregated, affecting the accuracy of the global model.
Local power model parameters are obtained by training each local node in the distribution network, and are safely shuffled and divided, and sent to other nodes. The first local node determines the compensation parameters based on the transmission time, calculation time and network delay of the received model subparameters, and performs parameter compensation and aggregation, and finally obtains the target global power model parameters through reverse shuffling.
After the shuffle, parameter compensation can still be performed based on the information of each node, the accuracy of local model parameters can be improved, and high-precision global power model parameters can be obtained through aggregation.
Smart Images

Figure CN119674963B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of power grid communication technology, and in particular to a compensation method and system for a distributed power distribution network model integrating safety shuffling. Background Art
[0002] In the power grid communication scenario, due to hardware differences, environmental interference and other factors, there are different degrees of drift between the clocks of each node, which makes it easy for deviations to occur when aggregating the local model parameters of each node, and affects the accuracy of the fused global model.
[0003] Therefore, in the process of model aggregation, since a large number of nodes are involved, the model parameters submitted by each node need to be compensated during aggregation to improve the accuracy of model fusion.
[0004] However, for different nodes, a unified compensation strategy is adopted, which makes it difficult to balance the real-time and accuracy of model aggregation. Moreover, in order to protect the privacy of nodes, a secure shuffling protocol is introduced before model aggregation to securely shuffle the model features or parameters submitted by each node. In this way, the model parameters after secure shuffling are disrupted, and it is difficult to directly use the original parameter compensation mechanism for compensation. Therefore, how to reasonably compensate the model parameters after secure shuffling is a technical problem that needs to be solved in this field. Summary of the invention
[0005] The present invention provides a compensation method and system for a distributed power distribution network model integrating safety shuffling, which can solve at least one of the above technical problems.
[0006] According to one aspect of the present invention, a compensation method for a distributed power distribution network model integrating safety shuffle is provided, comprising:
[0007] Each local node in the power distribution network trains a local power model based on local power data of the local node to obtain a first local power model parameter of the local node;
[0008] Each of the local nodes shuffles its first local power model parameter based on the security shuffle matrix of the local node to obtain a second local power model parameter of the local node;
[0009] Each of the local nodes respectively divides its second local power model parameter to obtain a plurality of first local power model sub-parameters, and sends each of the first local power model sub-parameters to other local nodes;
[0010] When the first local node in the power distribution network receives the first local power model sub-parameter of any second local node in the power distribution network, the first local node determines the compensation parameter of the second local node based on the transmission time, calculation time and network delay of the first local power model sub-parameter of the second local node, and compensates the first local power model sub-parameter of the second local node based on the compensation parameter of the second local node to obtain the second local power model sub-parameter of the second local node;
[0011] When the first local node obtains the second local power model sub-parameters that meet the preset number, based on the reputation value of each of the second local nodes and the reputation value of the first local node, the second local power model sub-parameters of each of the second local nodes and the first local power model sub-parameters of the first local node are aggregated to obtain the first global power model parameter;
[0012] The first local node reversely shuffles the first global power model parameters based on the security shuffle matrix of the first local node to obtain target global power model parameters.
[0013] According to another aspect of the present invention, a compensation device for a distributed power distribution network model integrating safety shuffle is provided, comprising:
[0014] A local model training module is applied to each local node in the power distribution network and is used to train the local power model based on the local power data of the local node to obtain a first local power model parameter of the local node;
[0015] A local parameter shuffling module, applied to each of the local nodes, and used to shuffle the first local power model parameter of the local node based on the security shuffling matrix of the local node to obtain the second local power model parameter of the local node;
[0016] A local parameter segmentation module, applied to each of the local nodes, and used to segment the second local power model parameter thereof respectively to obtain a plurality of first local power model sub-parameters, and send each of the first local power model sub-parameters to other local nodes;
[0017] a parameter compensation module, applied to a first local node in the power distribution network, and used to determine a compensation parameter of the second local node based on a transmission time, a calculation time and a network delay of the first local power model sub-parameter of the second local node when receiving the first local power model sub-parameter of any second local node in the power distribution network, and compensate the first local power model sub-parameter of the second local node based on the compensation parameter of the second local node to obtain a second local power model sub-parameter of the second local node;
[0018] a parameter aggregation module, applied to the first local node, and configured to aggregate the second local power model sub-parameters of each of the second local nodes and the first local power model sub-parameters of the first local node based on the reputation values of each of the second local nodes and the reputation value of the first local node to obtain a first global power model parameter when a preset number of the second local power model sub-parameters are obtained;
[0019] A reverse shuffle module is applied to the first local node and is used to reverse shuffle the first global power model parameters based on the security shuffle matrix of the first local node to obtain target global power model parameters.
[0020] By adopting the technical solution of the present invention, each local node in the distribution network is trained to obtain its own local power model parameters, which are shuffled and divided to obtain multiple local power model sub-parameters and distribute the local model sub-parameters to other nodes. When the first local node in the distribution network receives the local model sub-parameters of other second local nodes, the compensation parameters of the second local node are determined based on the transmission time, calculation time and network delay of the second local node for its local model sub-parameters, and then the local model sub-parameters of the second local node are compensated based on the compensation parameters. In this way, after shuffling, the parameters of each node can still be compensated according to the different information of each node, thereby improving the accuracy of the local model parameters. Subsequently, after the first local node obtains a sufficient number of local model sub-parameters, the reputation values of each node are used to aggregate the compensated local model sub-parameters to obtain the global power model parameters, and finally the global power model parameters are shuffled to obtain the target global power model parameters. Thus, the accuracy of the global power model is improved.
[0021] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] The accompanying drawings are used to better understand the present invention and do not constitute a limitation of the present invention.
[0023] Figure 1 It is a flow chart of a compensation method of a distributed power distribution network model integrating safety shuffle according to an embodiment of the present invention;
[0024] Figure 2 It is a structural block diagram of a compensation device of a distributed power distribution network model integrating safe shuffling according to an embodiment of the present invention;
[0025] Figure 3 The block diagram is a block diagram of an electronic device for implementing the method according to the embodiment of the present invention. DETAILED DESCRIPTION
[0026] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be appreciated by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope of the present invention. Similarly, for clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.
[0027] Figure 1 It is a flow chart of a compensation method for a distributed power distribution network model integrating safety shuffling according to an embodiment of the present invention.
[0028] like Figure 1 As shown, the compensation method may include:
[0029] S110, each local node in the power distribution network trains a local power model based on local power data of the local node to obtain a first local power model parameter of the local node;
[0030] S120, each local node shuffles its first local power model parameter based on the security shuffle matrix of the local node to obtain a second local power model parameter of the local node;
[0031] S130, each local node divides its second local power model parameter respectively to obtain a plurality of first local power model sub-parameters, and sends each first local power model sub-parameter to other local nodes;
[0032] S140, when a first local node in the power distribution network receives a first local power model sub-parameter of any second local node in the power distribution network, the first local node determines a compensation parameter of the second local node based on the transmission time, calculation time and network delay of the first local power model sub-parameter of the second local node, and compensates the first local power model sub-parameter of the second local node based on the compensation parameter of the second local node to obtain a second local power model sub-parameter of the second local node;
[0033] S150, when the first local node obtains the second local power model sub-parameters that meet the preset number, based on the reputation value of each second local node and the reputation value of the first local node, the second local power model sub-parameters of each second local node and the first local power model sub-parameter of the first local node are aggregated to obtain the first global power model parameter;
[0034] S160: The first local node reversely shuffles the first global power model parameters based on the security shuffle matrix of the first local node to obtain target global power model parameters.
[0035] For example, a power distribution network may include multiple power edge computing nodes, one of which may be used as a central computing node. Each power edge computing node is used to calculate power data in its corresponding regional power grid. For example, the power data is used to train a power generation prediction model.
[0036] Exemplarily, the security shuffle matrix may be a preset two-dimensional scrambled matrix. The two-dimensional scrambled matrix is multiplied by the corresponding first local power model parameter to obtain the second local power model parameter.
[0037] Exemplarily, a shared secret algorithm may be used to segment the second local power model parameter to obtain a plurality of first local power model sub-parameters.
[0038] It can be understood that the first local node can be any one of the local nodes in the power distribution network. The second local node can be any node in the power distribution network except the first local node. The first local node can also be considered as a global node.
[0039] Exemplarily, the first local power model parameter of the first local node may not be compensated or may be compensated. For example, based on the time consumed by the first local node to calculate its first local power model sub-parameter, the compensation parameter of the first local node is determined, and based on the compensation parameter of the first local node, the first local power model sub-parameter of the first local node is compensated to obtain the second local power model sub-parameter of the first local node.
[0040] Exemplarily, during the aggregation in step S150 above, based on the reputation value of each second local node and the reputation value of the first local node, the second local power model sub-parameters of each second local node and the second local power model sub-parameters of the first local node are aggregated to obtain the first global power model parameters.
[0041] Exemplarily, the transposed matrix of the security shuffle matrix of the first local node is multiplied by the first global power model parameter to achieve reverse shuffle and obtain the target global power model parameter.
[0042] It can be understood that based on the target global power model parameters, the target global power model can be determined. In this way, the model parameters after fusion shuffling can be compensated, and after compensation, the model parameters are aggregated and reversely shuffled to obtain the target global power model parameters.
[0043] According to the above implementation, each local node in the power distribution network is trained to obtain its own local power model parameters, which are shuffled and divided to obtain multiple local power model sub-parameters and the local model sub-parameters are distributed to other nodes. When the first local node in the power distribution network receives the local model sub-parameters of other second local nodes, the compensation parameters of the second local node are determined based on the transmission time, calculation time and network delay of the second local node for its local model sub-parameters, and then the local model sub-parameters of the second local node are compensated based on the compensation parameters. In this way, after shuffling, the parameters of each node can still be compensated according to the different information of each node, thereby improving the accuracy of the local model parameters. Subsequently, after the first local node obtains a sufficient number of local model sub-parameters, the reputation values of each node are used to aggregate the compensated local model sub-parameters to obtain the global power model parameters, and finally the global power model parameters are shuffled to obtain the target global power model parameters. Thus, the accuracy of the global power model is improved.
[0044] In one embodiment, each local node shuffles its first local power model parameter based on the security shuffle matrix of the local node to obtain the second local power model parameter of the local node, including: each local node determines the security shuffle offset direction of the local node based on the model parameter offset information between the first local power model parameter obtained in this round of training and the target global power model parameter obtained in the previous round of training; each local node adjusts the security shuffle matrix of the local node based on the security shuffle offset direction of the local node; each local node shuffles the local model parameters of the local node based on the adjusted security shuffle matrix of the local node to obtain the second local power model parameter of the local node.
[0045] It can be understood that the model parameter offset information may be the gradient information of the model parameters.
[0046] Exemplarily, the gradient information is used as the safe shuffle offset direction. Alternatively, a preset offset value is used to adjust the gradient information, and the adjusted gradient information is used as the safe shuffle offset direction.
[0047] Exemplarily, the safe shuffle offset direction may be a one-dimensional vector including a gradient value and a gradient direction. The one-dimensional vector is multiplied by the safe shuffle matrix to obtain an adjusted safe shuffle matrix.
[0048] Exemplarily, the adjusted security shuffle matrix is multiplied by the local model parameters of the local node to shuffle the local model parameters of the local node and obtain the second local power model parameters of the local node.
[0049] According to the above implementation, the model parameter gradient information between the first local power model parameters obtained in this round of training and the target global power model parameters obtained in the previous round of training can be used to adjust the security shuffling matrix of the local node. Thus, the local model parameters of the local node can be shuffled using the adjusted security shuffling matrix of the local node to obtain the second local power model parameters of the local node. In this way, the possibility of the local model parameters being stolen after shuffling can be further reduced, thereby improving the transmission security of the model parameters.
[0050] In one embodiment, based on the transmission time, calculation time and network delay of the second local node for its first local power model sub-parameter, the compensation parameters of the second local node are determined, including: the first local node sums the transmission time, calculation time and network delay of the second local node for its first local power model sub-parameter to obtain the total transmission time of the first local power model sub-parameter of the second local node; the first local node adjusts a preset compensation matrix based on the ratio of the total transmission time of the first local power model sub-parameter of the second local node to the historical average time to obtain the compensation parameters of the second local node.
[0051] It can be understood that the transmission time refers to the time taken by the second local node to transmit the first local power model sub-parameter to the first local node.
[0052] It can be understood that the calculation time may be the time from the second local node starting to train the model to obtaining the first local power model sub-parameters.
[0053] It can be understood that the network delay may be the network delay between the second local node and the first local node.
[0054] It can be understood that the historical average time consumption is the time obtained by summing up and averaging the total transmission time consumption of the first local power model sub-parameter of each second local node within the historical time.
[0055] Exemplarily, the ratio of the total transmission time of the first local power model sub-parameter of the second local node to the historical average transmission time is multiplied by a preset compensation matrix to obtain the compensation parameter of the second local node.
[0056] According to the above implementation, based on the transmission time, calculation time and network delay of the second local node for the sub-parameters of its first local power model, the preset compensation matrix is adjusted to obtain the compensation parameters of the second local node. In this way, when the model parameter compensation and aggregation are performed subsequently, the deviation of the aggregated global model caused by the different degrees of clock drift between nodes can be avoided, and the accuracy of the fused global model can be improved.
[0057] In one embodiment, based on the reputation value of each second local node and the reputation value of the first local node, the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node are aggregated to obtain the first global power model parameters, including: the first local node performs weighted summation of the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node based on the reputation value of each second local node and the reputation value of the first local node to obtain the first global power model parameters.
[0058] Exemplarily, the reputation value of each second local node is multiplied by its corresponding second local power model sub-parameter, and the reputation value of the first local node is multiplied by the first local power model sub-parameter of the first local node, and the products are summed to obtain the first global power model parameter.
[0059] According to the above implementation, based on the reputation value of each second local node and the reputation value of the first local node, the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node are aggregated to obtain the first global power model parameter. In this way, there is no need to shuffle and then aggregate, which improves the efficiency of obtaining the global model parameter.
[0060] In one embodiment, it also includes: the first local node constructs a four-dimensional eigenvector of each second local node based on the number of interactions and the average interaction data flow between each second local node and the first local node, the time sensitivity of each second local node, and the amount of power data of each second local node; the first local node performs singular value decomposition on the four-dimensional eigenvector of each second local node to obtain a first eigenvalue of rank 0, a second eigenvalue of rank 1, and a third eigenvalue of rank 2 of each second local node; the first local node determines the credibility value of each second local node based on the ratio between the third eigenvalue of each second local node and the sum of the first eigenvalue, second eigenvalue and third eigenvalue of each second local node.
[0061] It can be understood that the number of interactions, average interaction data flow and power data volume are all data counted within a specified time.
[0062] It can be understood that the time sensitivity can be a scoring value, and the higher the sensitivity, the larger the scoring value. For example, the time sensitivity is also scored from 1 to 10, and the score of the second local node B is 8.
[0063] Exemplarily, the ratio of the third feature value of the second local node to the sum of the first feature value, the second feature value and the third feature value of the second local node is used as the reputation value of the second local node.
[0064] Exemplarily, the reputation value of the first local node may be a preset value.
[0065] According to the above implementation, the corresponding four-dimensional feature vector can be constructed by the number of interactions and the average interaction data flow between the second local node and the first local node, the time sensitivity of the second local node, and the power data volume of the second local node. Then, the four-dimensional feature vector is subjected to singular value decomposition to obtain the first eigenvalue of the second local node with a rank of 0, the second eigenvalue of the rank of 1, and the third eigenvalue of the rank of 2. In this way, these eigenvalues can be used to accurately calculate the reputation value of the second local node.
[0066] In one embodiment, the above method also includes: the first local node updates the local power model of the first local node based on the target global power model parameters; the first local node sends the target global power model parameters to each second local node; and each second local node updates the local power model of each second local node based on the received target global power model parameters.
[0067] According to the above implementation, the target global power model parameters obtained after shuffling, compensation, aggregation and reverse shuffling are used to update the local power model of each local node, so as to synchronize the local power models of each local node.
[0068] Figure 2 It is a structural block diagram of a compensation device for a distributed power distribution network model integrating safety shuffling according to an embodiment of the present invention.
[0069] like Figure 2 As shown, the compensation device of the distributed distribution network model integrating the safety shuffle may include:
[0070] A local model training module 210 is applied to each local node in the power distribution network and is used to train a local power model based on local power data of the local node to obtain a first local power model parameter of the local node;
[0071] A local parameter shuffling module 220, applied to each of the local nodes, and used to shuffle the first local power model parameter of the local node based on the security shuffling matrix of the local node to obtain the second local power model parameter of the local node;
[0072] A local parameter segmentation module 230, applied to each of the local nodes, and used to segment the second local power model parameter thereof, respectively, to obtain a plurality of first local power model sub-parameters, and to send each of the first local power model sub-parameters to other local nodes;
[0073] a parameter compensation module 240, applied to a first local node in the power distribution network, and used to determine a compensation parameter of the second local node based on the transmission time, calculation time and network delay of the first local power model sub-parameter of the second local node when receiving the first local power model sub-parameter of any second local node in the power distribution network, and compensate the first local power model sub-parameter of the second local node based on the compensation parameter of the second local node to obtain the second local power model sub-parameter of the second local node;
[0074] a parameter aggregation module 250, applied to the first local node, and configured to aggregate the second local power model sub-parameters of each of the second local nodes and the first local power model sub-parameters of the first local node based on the reputation values of each of the second local nodes and the reputation value of the first local node to obtain a first global power model parameter when a preset number of the second local power model sub-parameters are obtained;
[0075] The reverse shuffle module 260 is applied to the first local node and is used to reverse shuffle the first global power model parameters based on the security shuffle matrix of the first local node to obtain target global power model parameters.
[0076] In one embodiment, the local parameter shuffling module 230 includes:
[0077] An offset direction determining unit, configured to determine a safe shuffle offset direction of the local node based on model parameter offset information between a first local power model parameter obtained in this round of training and a target global power model parameter obtained in a previous round of training;
[0078] A shuffle matrix determination unit, configured for each of the local nodes to adjust the security shuffle matrix of the local node based on the security shuffle offset direction of the local node;
[0079] The local parameter shuffling unit is used for each of the local nodes to shuffle the local model parameters of the local node based on the adjusted security shuffling matrix of the local node to obtain the second local power model parameters of the local node.
[0080] In one implementation, the parameter compensation module 240 includes:
[0081] A total time determination unit is used for the first local node to sum up the transmission time, calculation time and network delay of the first local power model sub-parameter of the second local node to obtain the total transmission time of the first local power model sub-parameter of the second local node;
[0082] The compensation parameter determination unit is used for the first local node to adjust the preset compensation matrix based on the ratio of the total transmission time of the first local power model sub-parameter of the second local node to the historical average time to obtain the compensation parameter of the second local node.
[0083] In one implementation, based on the reputation value of each of the second local nodes and the reputation value of the first local node, the second local power model sub-parameters of each of the second local nodes and the first local power model sub-parameters of the first local node are aggregated to obtain the first global power model parameter, which is specifically used to:
[0084] The first local node performs weighted summation of the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node based on the reputation values of each second local node and the reputation value of the first local node to obtain the first global power model parameters.
[0085] In one embodiment, the above device further comprises:
[0086] a feature vector determination module, configured for the first local node to construct a four-dimensional feature vector of each second local node based on the number of interactions and average interaction data flow between each second local node and the first local node, the time sensitivity of each second local node, and the power data volume of each second local node;
[0087] A singular value decomposition module, configured for the first local node to perform singular value decomposition on the four-dimensional eigenvectors of each of the second local nodes to obtain a first eigenvalue of rank 0, a second eigenvalue of rank 1, and a third eigenvalue of rank 2 of each of the second local nodes;
[0088] A reputation value determination module is used for the first local node to determine the reputation value of each second local node based on the ratio between the third feature value of each second local node and the sum of the first feature value, the second feature and the third feature value of each second local node.
[0089] In one embodiment, the above device comprises:
[0090] A first model updating module, configured for the first local node to update a local power model of the first local node based on the target global power model parameter;
[0091] A full-mode model parameter sending module, used for the first local node to send the target global power model parameters to each of the second local nodes;
[0092] The second model updating module is used for each of the second local nodes to update the local power model of each of the second local nodes based on the received target global power model parameters.
[0093] For the description of specific functions and examples of each module and submodule of the system in the embodiment of the present invention, reference can be made to the relevant description of the corresponding steps in the above method embodiment, which will not be repeated here.
[0094] In the technical solution of the present invention, the acquisition, storage and application of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0095] According to an embodiment of the present invention, the present invention also provides a system and a readable storage medium.
[0096] Figure 3 A schematic block diagram of an example electronic device 800 that can be used to implement an embodiment of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.
[0097] like Figure 3As shown, the device 800 includes a computing unit 801, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 802 or a computer program loaded from a storage unit 808 to a random access memory (RAM) 803. In the RAM 803, various programs and data required for the operation of the device 800 can also be stored. The computing unit 801, the ROM 802, and the RAM 803 are connected to each other via a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.
[0098] A number of components in the device 800 are connected to the I / O interface 805, including: an input unit 806, such as a keyboard, a mouse, etc.; an output unit 807, such as various types of displays, speakers, etc.; a storage unit 808, such as a disk, an optical disk, etc.; and a communication unit 809, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 809 allows the device 800 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0099] The computing unit 801 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 801 performs the various methods and processes described above, such as the compensation method of the distributed distribution network model of the fusion safety shuffle. For example, in some embodiments, the compensation method of the distributed distribution network model of the fusion safety shuffle may be implemented as a computer software program, which is tangibly included in a machine-readable medium, such as a storage unit 808. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 800 via the ROM 802 and / or the communication unit 809. When the computer program is loaded into the RAM 803 and executed by the computing unit 801, one or more steps of the compensation method of the distributed distribution network model of the fusion safety shuffle described above may be performed. Alternatively, in other embodiments, the computing unit 801 may be configured in any other appropriate manner (eg, by means of firmware) to execute the compensation method for the distributed power distribution network model integrating the safety shuffle.
[0100] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0101] The program code for implementing the method of the present invention can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code can be executed entirely on the machine, partially on the machine, partially on the machine as a stand-alone software package and partially on a remote machine, or entirely on a remote machine or server.
[0102] In the context of the present invention, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0103] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0104] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.
[0105] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.
[0106] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution disclosed in the present invention can be achieved, and this document does not limit this.
[0107] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A compensation method for a distributed power distribution network model integrating safety shuffle, characterized in that: include: Each local node in the power distribution network trains a local power model based on local power data of the local node to obtain a first local power model parameter of the local node; Each of the local nodes shuffles its first local power model parameter based on the security shuffle matrix of the local node to obtain a second local power model parameter of the local node; Each of the local nodes respectively divides its second local power model parameter to obtain a plurality of first local power model sub-parameters, and sends each of the first local power model sub-parameters to other local nodes; When the first local node in the power distribution network receives the first local power model sub-parameter of any second local node in the power distribution network, the first local node determines the compensation parameter of the second local node based on the transmission time, calculation time and network delay of the first local power model sub-parameter of the second local node, and compensates the first local power model sub-parameter of the second local node based on the compensation parameter of the second local node to obtain the second local power model sub-parameter of the second local node; When the first local node obtains the second local power model sub-parameters that meet the preset number, the first local node constructs a four-dimensional feature vector of each second local node based on the number of interactions and the average interaction data flow between each second local node and the first local node, the time sensitivity of each second local node, and the power data volume of each second local node; performs singular value decomposition on the four-dimensional feature vector of each second local node to obtain a first eigenvalue of rank 0, a second eigenvalue of rank 1, and a third eigenvalue of rank 2 of each second local node; determines the reputation value of each second local node based on the ratio between the third eigenvalue of each second local node and the sum of the first eigenvalue, the second eigenvalue, and the third eigenvalue of each second local node; aggregates the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node based on the reputation value of each second local node and the reputation value of the first local node to obtain a first global power model parameter; wherein the reputation value of the first local node is a preset value; The first local node reversely shuffles the first global power model parameters based on the security shuffle matrix of the first local node to obtain target global power model parameters.
2. The method according to claim 1, characterized in that Each of the local nodes shuffles its first local power model parameter based on the security shuffle matrix of the local node to obtain the second local power model parameter of the local node, including: Each of the local nodes determines the safe shuffle offset direction of the local node based on the model parameter offset information between the first local power model parameter obtained in the current round of training and the target global power model parameter obtained in the previous round of training; Each of the local nodes adjusts the security shuffle matrix of the local node based on the security shuffle offset direction of the local node; Each of the local nodes shuffles the local model parameters of the local node based on the adjusted security shuffle matrix of the local node to obtain the second local power model parameters of the local node.
3. The method according to claim 1, characterized in that The determining of the compensation parameter of the second local node based on the transmission time, calculation time and network delay of the second local node for the sub-parameter of the first local power model includes: The first local node sums the transmission time, calculation time and network delay of the first local power model sub-parameter of the second local node to obtain a total transmission time of the first local power model sub-parameter of the second local node; The first local node adjusts a preset compensation matrix based on the ratio of the total transmission time of the first local power model sub-parameter of the second local node to the historical average transmission time to obtain the compensation parameter of the second local node.
4. The method according to claim 1, characterized in that The step of aggregating the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node based on the reputation values of each second local node and the reputation value of the first local node to obtain the first global power model parameter includes: The first local node performs weighted summation of the second local power model sub-parameters of each second local node and the first local power model sub-parameters of the first local node based on the reputation values of each second local node and the reputation value of the first local node to obtain the first global power model parameters.
5. The method according to any one of claims 1 to 4, characterized in that include: The first local node updates a local power model of the first local node based on the target global power model parameter; The first local node sends the target global power model parameter to each of the second local nodes; Each of the second local nodes updates the local power model of each of the second local nodes based on the received target global power model parameters.
6. A compensation device for a distributed power distribution network model integrating safety shuffle, characterized in that: include: A local model training module is applied to each local node in the power distribution network and is used to train the local power model based on the local power data of the local node to obtain a first local power model parameter of the local node; A local parameter shuffling module, applied to each of the local nodes, and used to shuffle the first local power model parameter of the local node based on the security shuffling matrix of the local node to obtain the second local power model parameter of the local node; A local parameter segmentation module, applied to each of the local nodes, and used to segment the second local power model parameter thereof respectively to obtain a plurality of first local power model sub-parameters, and send each of the first local power model sub-parameters to other local nodes; a parameter compensation module, applied to a first local node in the power distribution network, and used to determine a compensation parameter of any second local node in the power distribution network based on a transmission time, a calculation time and a network delay of the second local node for its first local power model sub-parameter, and to compensate the first local power model sub-parameter of the second local node based on the compensation parameter of the second local node, so as to obtain a second local power model sub-parameter of the second local node; A parameter aggregation module is applied to the first local node and is used to construct a four-dimensional feature vector of each second local node based on the number of interactions and average interaction data flow between each second local node and the first local node, the time sensitivity of each second local node, and the amount of power data of each second local node when a preset number of second local power model sub-parameters are obtained; perform singular value decomposition on the four-dimensional feature vector of each second local node to obtain a first eigenvalue of rank 0, a second eigenvalue of rank 1, and a third eigenvalue of rank 2 of each second local node; determine the reputation value of each second local node based on the ratio between the third eigenvalue of each second local node and the sum of the first eigenvalue, the second eigenvalue, and the third eigenvalue of each second local node; based on the reputation value of each second local node and the reputation value of the first local node, aggregate the second local power model sub-parameter of each second local node and the first local power model sub-parameter of the first local node to obtain a first global power model parameter; wherein the reputation value of the first local node is a preset value; A reverse shuffle module is applied to the first local node and is used to reverse shuffle the first global power model parameters based on the security shuffle matrix of the first local node to obtain target global power model parameters.
7. The device according to claim 6, characterized in that The local parameter shuffling module comprises: An offset direction determining unit, configured to determine a safe shuffle offset direction of the local node based on model parameter offset information between a first local power model parameter obtained in this round of training and a target global power model parameter obtained in a previous round of training; A shuffle matrix determination unit, configured for each of the local nodes to adjust the security shuffle matrix of the local node based on the security shuffle offset direction of the local node; The local parameter shuffling unit is used for each of the local nodes to shuffle the local model parameters of the local node based on the adjusted security shuffling matrix of the local node to obtain the second local power model parameters of the local node.
8. A compensation system for a distributed power distribution network model integrating safety shuffle, comprising: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 5.
9. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-5.
Citation Information
Patent Citations
Distributed cloud collaborative encryption method and device based on differential privacy
CN115118531A
Distributed deep learning method based on communication frequency optimization and error compensation mechanism
CN116863235A