WO2022012621A1 - 联邦学习方法、装置和系统、电子设备、存储介质 - Google Patents
联邦学习方法、装置和系统、电子设备、存储介质 Download PDFInfo
- Publication number
- WO2022012621A1 WO2022012621A1 PCT/CN2021/106469 CN2021106469W WO2022012621A1 WO 2022012621 A1 WO2022012621 A1 WO 2022012621A1 CN 2021106469 W CN2021106469 W CN 2021106469W WO 2022012621 A1 WO2022012621 A1 WO 2022012621A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- layer
- node
- gradient
- global
- updated
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/602—Providing cryptographic facilities or services
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/21—Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
- G06F18/214—Generating training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/62—Protecting access to data via a platform, e.g. using keys or access control rules
- G06F21/6218—Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
- G06F21/6245—Protecting personal data, e.g. for financial or medical purposes
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N20/00—Machine learning
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
- G06N3/084—Backpropagation, e.g. using gradient descent
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
- G06N3/098—Distributed learning, e.g. federated learning
Definitions
- Embodiments of the present disclosure relate to, but are not limited to, the field of artificial intelligence, and in particular, to federated learning methods, apparatuses, and systems, electronic devices, and computer-readable storage media.
- the main solution at present is to migrate the computing of network equipment (ie, the central computing node of the network) from the network equipment to the edge of the mobile access network, so as to realize the real-time intelligent computing requirements on the edge side.
- network equipment ie, the central computing node of the network
- NCCN Near Collect Computer Node
- This approach plays a transitional role for the real-time computing requirements brought about by the intelligence of existing networks, such as 3G, 4G, and some 5G.
- Embodiments of the present disclosure provide a federated learning method, apparatus and system, electronic device, and computer-readable storage medium.
- an embodiment of the present disclosure provides a federated learning method, which is applied to the i-th layer node, where i is any one of integers greater than or equal to 2 and less than or equal to (N-1), (N-1) is the number of layers of federated learning, and the method includes: receiving a corresponding first gradient reported by at least one (i-1) layer node under the i-th layer node; and corresponding to at least one (i-1) layer node according to the The first gradient of and the (i-1)th layer weight index corresponding to the ith layer node calculate the updated (i-1)th layer global gradient corresponding to the ith layer node; wherein, the (i-1)th layer weight index for communication indicators.
- an embodiment of the present disclosure provides a federated learning method, which is applied to a layer 1 node.
- the method includes: reporting an updated gradient corresponding to the layer 1 node to the layer 2 node; and receiving a transmission from the layer 2 node.
- the updated jth layer global gradient of wherein, the jth layer global gradient is calculated according to the first gradient corresponding to at least one jth layer node and the jth layer weight index corresponding to the (j+1)th layer node; the jth layer
- the weight index is the communication index; j is any one of the integers greater than or equal to 1 and less than or equal to (N-1), where (N-1) is the number of layers of federated learning.
- an embodiment of the present disclosure provides a federated learning method, which is applied to an Nth layer node or an Nth layer subsystem, where (N-1) is the number of layers of federated learning, and the method includes: receiving an Nth layer node or the corresponding (N-2)th layer global gradient reported by at least one (N-1)th layer node under the Nth layer subsystem; 2) Layer global gradient and (N-1)th layer weight index Calculate the (N-1)th layer global gradient corresponding to the Nth layer node or the Nth layer subsystem; wherein, the (N-1)th layer weight index is communication metrics.
- an embodiment of the present disclosure provides an electronic device, including: at least one processor; and a memory, where at least one program is stored, and when the at least one program is executed by the at least one processor, the at least one processor implements the above Any federated learning method.
- an embodiment of the present disclosure provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, any one of the foregoing federated learning methods is implemented.
- an embodiment of the present disclosure provides a federated learning system, including: an Nth layer node or an Nth layer subsystem, configured to receive at least one (Nth layer) under the Nth layer node or the Nth layer subsystem -1) The corresponding (N-2) layer global gradient reported by the layer node; according to the (N-2) layer global gradient and the (N-1) layer weight corresponding to at least one (N-1) layer node
- the index calculates the (N-1) layer global gradient corresponding to the Nth layer node or the Nth layer subsystem; wherein, the (N-1)th layer weight index is the communication index; the Nth layer node or the Nth layer subsystem
- the corresponding (N-1)-th layer global gradient is sent to at least one (N-1)-th layer node; where (N-1) is the number of layers of federated learning; the i-th layer node is configured to receive the The corresponding first gradient reported by at least one (i-1)th layer node under the i-layer node
- the global gradient is calculated using the communication index as the weight index. Since the communication index is a valuable data index for operators, the global gradient calculated based on the communication index as the weight index The model training result obtained by the model training is the optimal result for the operator, thereby improving the optimization effect.
- FIG. 1 is a schematic diagram of a federated learning system architecture provided by an embodiment of the present disclosure
- FIG. 2 is a schematic diagram of the architecture of a single-layer federated learning system provided by an embodiment of the present disclosure
- FIG. 3 is a schematic diagram of the architecture of a two-layer federated learning system provided by an embodiment of the present disclosure
- FIG. 4 is a flowchart of a federated learning method provided by an embodiment of the present disclosure
- FIG. 5 is a flowchart of a federated learning method provided by another embodiment of the present disclosure.
- FIG. 6 is a flowchart of a federated learning method provided by another embodiment of the present disclosure.
- FIG. 7 is a schematic diagram of the architecture of the federated learning system provided in Examples 1-4 of the present disclosure.
- FIG. 8 is a schematic diagram of the federated learning system architecture provided in Example 5 of the present disclosure.
- FIG. 9 is a block diagram of a federated learning apparatus provided by another embodiment of the present disclosure.
- FIG. 10 is a block diagram of a federated learning apparatus provided by another embodiment of the present disclosure.
- FIG. 11 is a block diagram of a federated learning apparatus provided by another embodiment of the present disclosure.
- the current horizontal federated learning methods roughly include:
- Participants use local data for model training to obtain updated gradients, and use encryption, differential privacy (DP, Differential Privacy) or secret sharing technology to perform privacy protection processing on the updated gradients to obtain the gradients after privacy protection processing;
- the gradient is sent to the central server;
- the central server decrypts the gradient after privacy protection processing corresponding to at least one participant, obtains the updated gradient corresponding to at least one participant, calculates the updated global gradient according to the updated gradient corresponding to at least one participant, and calculates the updated global gradient. distributed to each participant separately;
- Participants update the model according to the updated global gradient.
- the updated global gradient generally adopts Google's FedAvg (Federated Averaging) algorithm, that is, the average or weighted average value of the corresponding updated gradients of all participants (or a random part of the participants). to the updated global gradient; where the weight is the amount of data that the participant participates in training.
- This method takes the amount of data involved in training as the weight. Since the amount of data involved in training is not equal to the amount of valuable data that operators are concerned about, the model training results are not optimal for operators; and , without distinguishing the participants, it is impossible to achieve personalized optimization, thereby reducing the optimization effect.
- FIG. 1 is a schematic diagram of an architecture of a federated learning system provided by an embodiment of the present disclosure. As shown in FIG. 1 , the federated learning system of the embodiment of the present disclosure is used to implement (N-1) layer federated learning, where N is an integer greater than or equal to 2.
- the (N-1) layer federated learning in the embodiment of the present disclosure is implemented by the N layer nodes, or the (N-1) layer federated learning is implemented by the first layer node to the (N-1) layer node and the Nth layer subsystem; Moreover, the first layer node to the (N-1) layer node include one or more than one node, and the Nth layer node or the Nth layer subsystem includes only one.
- the i-th layer of federated learning is implemented by the i-th layer nodes and the (i+1)-th layer nodes, where i is an integer greater than or equal to 1 and less than or equal to (N-2);
- the (N-1)-th layer Federated learning is implemented by (N-1) layer nodes and Nth layer nodes, or (N-1) layer federated learning is implemented by (N-1) layer nodes and Nth layer subsystems.
- next-layer nodes ie, the i-th layer nodes
- i+1 the next-layer nodes
- the layer 1 node can be a network element (NE, Network Element), such as a base station, and the layer 2 node to the layer (N-1) node can be NCCN, layer N node or layer N subsystem It can be a node or subsystem corresponding to the Element Management System (EMS, Element Management System).
- NE Network Element
- EMS Element Management System
- the layer 2 node to the layer (N-1) node may be physical devices or virtual nodes.
- Figure 2 shows a schematic diagram of the architecture of the single-layer federated learning system by taking the single-layer federated learning as an example.
- the single-layer federated learning system implements single-layer federated learning, which is implemented by layer 1 nodes and layer 2 nodes, or single-layer federated learning is implemented by layer 1 nodes and layer 2 subsystems accomplish.
- Figure 3 shows a schematic diagram of the architecture of the two-layer federated learning system by taking the two-layer federated learning as an example.
- two-layer federated learning is implemented by layer-1 nodes, layer-2 nodes, and layer-3 nodes, or two-layer federated learning is implemented by layer-1 nodes, layer-2 nodes, and layer-3 subsystems.
- layer 1 federated learning is implemented by layer 1 nodes and layer 2 nodes
- layer 2 federated learning is implemented by layer 2 nodes and layer 3 nodes
- layer 2 federated learning is implemented by layer 2 nodes and layer 2 nodes.
- the federated learning process is described below from the node side of layer 1, the node of layer 2 to the node side of any layer, the node of layer N, or the subsystem side of layer N, among the nodes of layer (N-1), respectively.
- FIG. 4 is a flowchart of a federated learning method provided by an embodiment of the present disclosure.
- an embodiment of the present disclosure provides a federated learning method, which is applied to the i-th layer node, where i is any one of integers greater than or equal to 2 and less than or equal to (N-1), (N-1) is the number of layers of federated learning, and the method includes:
- Step 400 Receive the corresponding first gradient reported by at least one (i-1) layer node under the i layer node.
- the first gradient corresponding to the (i-1)th layer node is the updated gradient obtained by model training performed by the (i-1)th layer node.
- the first gradient corresponding to the (i-1)th layer node may also be the updated gradient obtained after the (i-1)th layer node performs model training , the second gradient corresponding to the (i-1)th layer node is obtained by performing privacy protection processing on the updated gradient corresponding to the (i-1)th layer node.
- the first gradient corresponding to the (i-1)th layer node is the updated first gradient corresponding to the (i-1)th layer node (i-2) layer global gradient.
- the first gradient corresponding to the (i-1)th layer node may also be the (i-1)th
- the layer node performs privacy protection processing on the updated (i-2) layer global gradient corresponding to the (i-1) layer node, and the (i-2) layer node corresponding to the (i-1) layer node is obtained after privacy protection processing. ) layer global gradient.
- the privacy protection process may be implemented using encryption, DP, or secret sharing technology, or may be implemented in other manners, and the specific implementation manners are not intended to limit the protection scope of the embodiments of the present disclosure.
- Step 401 Calculate the updated (i-1)th layer corresponding to the i-th layer node according to the first gradient corresponding to at least one (i-1)th layer node and the (i-1)th layer weight index corresponding to the i-th layer node.
- layer global gradient among them, the weight index of the (i-1)th layer is the communication index.
- the communication metrics include at least one of the following: average delay, traffic volume, upstream and downstream traffic, traffic volume, and weighted average of upstream and downstream traffic.
- the weight indicators corresponding to different nodes in the same layer are the same or different, and the weight indicators corresponding to different nodes in different layers are the same or different.
- the weight indicators corresponding to different nodes in the same layer can be set to be the same, that is, at least one different node in the same layer is used to optimize the same weight indicator, similar to a distributed system;
- the weight indicators corresponding to different nodes in the same layer can be set to be different.
- the weight indicators corresponding to any two nodes in the same layer can be set to be different, or part of the same layer can be set.
- the weight indicators corresponding to the nodes are the same, and the weight indicators corresponding to another part of the nodes in the same layer are different, depending on the actual situation.
- the (i-1)-th layer weight index corresponding to the i-th layer node may be uniformly set in the N-th layer node or the N-th layer subsystem.
- the correspondence between the weight indicators of the (i-1)th layer when the Nth layer node or the Nth layer subsystem issues the federated learning task layer by layer, the (i-1) layer weight index corresponding to the i layer node can be combined with the federated learning task layer by layer.
- the layer weight index is distributed to the i-th layer node layer by layer along with the federated learning task.
- the (i-1)-th layer weight index corresponding to the i-th layer node may also be set on the corresponding i-th layer node, thus eliminating the need for the N-th layer node or the N-th layer subsystem to The process of delivering the (i-1) layer weight index corresponding to the i layer node to the i layer node layer by layer, thereby saving network overhead.
- the updated ith layer node corresponding to the ith layer node is calculated according to the first gradient corresponding to at least one (i-1)th layer node and the (i-1)th layer weight index corresponding to the ith layer node.
- the (i-1) layer global gradient includes:
- the (i-1) layer weight index value corresponding to at least one (i-1) layer node is the weight, and the weighted average value of the first gradient corresponding to at least one (i-1) layer node is calculated to obtain the updated (i- 1) Layer global gradient.
- the first gradient corresponding to the (i-1)th layer node is the second gradient corresponding to the (i-1)th layer node, or the privacy protection corresponding to the (i-1)th layer node
- the first gradient corresponding to the node of the (i-1) layer needs to be deprived of privacy protection processing, that is, the inverse processing of the privacy protection processing.
- the privacy protection processing is encryption, then the privacy protection processing is decryption, and other privacy protection processing methods are analogous; and then calculate the first privacy protection processing corresponding to at least one (i-1) layer node. Weighted average of gradients.
- some privacy protection processing methods such as homomorphic encryption methods
- the weighted average of the first gradients corresponding to the (i-1)th layer nodes it is also possible to directly calculate at least one gradient without performing privacy protection processing on the first gradient corresponding to the (i-1) layer node The weighted average of the first gradients corresponding to the (i-1)th layer nodes.
- the (i-1) layer weight index value corresponding to the (i-1) layer node may be based on the (i-1) layer corresponding to all layer 1 nodes under the (i-1) layer node. -1) Obtaining the layer weight index value, which can be obtained in various ways. For example, after each first layer node obtains the corresponding (i-1) layer weight index value, report it layer by layer to the (i-1)th layer. ) layer nodes, which are calculated uniformly by the (i-1) layer nodes; for another example, after each first layer node obtains the corresponding (i-1) layer weight index value, it is reported to the (i-1) layer layer by layer.
- the (i-1) layer node obtains the relevant information of the first layer node used to calculate the (i-1) layer weight index value , and then calculate the (i-1) layer weight index value corresponding to each first layer node based on the relevant information of the first layer node, and then calculate the (i-1) layer corresponding to the (i-1) layer node. weight index value; etc.
- the specific acquisition methods are not used to limit the protection scope of the embodiments of the present disclosure.
- GRA i is the updated (i-1) layer global gradient corresponding to the i-th layer node
- GRA m (i-1) is the m-th (i-1) layer node corresponding to the i-th layer node.
- the first gradient, KPI m(i-1) is the (i-1) layer weight index value corresponding to the mth (i-1) layer node under the i layer node.
- the weight indicator is the average delay
- the weight indicator is the traffic volume
- the weight indicator is the upstream and downstream traffic
- the weight indicator is the weighted average of the traffic volume and the uplink and downlink traffic
- the method before receiving the corresponding first gradient reported by at least one (i-1)-th layer node under the i-th layer node, the method further includes:
- Step 402 Receive the federated learning task sent by the (i+1)th layer node, and issue the federated learning task to at least one (i-1)th layer node.
- the federated learning task may be a service federated learning process request initiated by the Nth layer node or the service application in the Nth layer subsystem, and then delivered to the (N-1)th layer node, and executed one by one.
- Layer 1 nodes so that the i-th layer node sends the federated learning task to at least one (i-1)-th layer node after receiving the federated learning task sent by the (i+1)-th layer node.
- the service federated learning process request includes the training layer 1 node range
- the Nth layer node or the Nth layer subsystem obtains the trained layer 1 node range from the service federated learning process request, based on
- the range of nodes in the first layer of training determines the range of nodes in the (N-1) layer that the federated learning task needs to be issued. How to determine the (N-1) layer node range that needs to be delivered for the federated learning task based on the trained layer 1 node range depends on the (N-1) layer node connected to the layer 1 node corresponding to the trained layer 1 node range ) layer nodes, for example, are determined based on the topology shown in FIG. 1 .
- the range of the trained layer-1 node can also be issued, so that the (i-1)-th layer node Determine the (i-2) layer nodes that need to be issued for the federated learning task according to the range of the trained layer 1 nodes.
- How to determine the (i-2) layer node range that needs to be delivered for the federated learning task based on the trained layer 1 node range? ) layer nodes are determined based on the topology shown in FIG. 1 .
- the method further includes:
- the updated (i-1)-th layer global gradient corresponding to the i-th layer node is sent to the (i-1)-th layer node.
- the i-th layer node sends the updated (i-1)-th layer global gradient corresponding to the i-th layer node to the (i-1)-th layer node, and sends it to the first layer layer by layer layer node for the layer 1 node to update the model according to the (N-1)th layer global gradient.
- the method further includes:
- the i-th layer node sends any one of the updated i-th layer global gradient to the updated (N-1)-th layer global gradient to the (i-1)-th layer node, and executes the update step by step.
- the layer is sent to the layer 1 node for the layer 1 node to update the model according to the global gradient of the (N-1) layer.
- the nodes of the first layer after receiving the federated learning task, perform model training according to the federated learning task to obtain updated gradients, and report the updated gradients corresponding to the nodes of the first layer to the nodes of the second layer;
- the 2nd layer node calculates the updated 1st layer global gradient corresponding to the 2nd layer node according to the updated gradient corresponding to at least one 1st layer node and the 1st layer weight index corresponding to the 2nd layer node; if the current state is to perform the 1st layer In the federated learning process, the second layer node sends the corresponding updated first layer global gradient to the first layer node, and the first layer node updates the model according to the updated first layer global gradient; if the current state is to go to the second layer From the federated learning process to any layer of federated learning process in the (N-1) layer federated learning process, the second layer node will report the corresponding updated first layer global gradient to the third layer node;
- the i-th layer node corresponds to the i-th layer node according to the updated (i-2)-th layer global gradient corresponding to at least one (i-1)-th layer node
- the weight index of the (i-1) layer calculates the updated (i-1) layer global gradient corresponding to the i-th layer node; if the current state is to perform the (i-1)-th layer federated learning process, then the i-th layer node
- the corresponding updated (i-1)th layer global gradient is sent to the (i-1)th layer nodes, and is sent to the first layer nodes layer by layer, and the first layer nodes are based on the updated (i-1)th layer nodes.
- the node of the i-th layer will correspond to the updated (i-th layer) -1)
- the global gradient of the layer is reported to the (i+1)th layer node.
- the global gradient is calculated using the communication index as the weight index. Since the communication index is a valuable data index for operators, the global gradient calculated based on the communication index as the weight index The model training result obtained by the model training is the optimal result for the operator, thereby improving the optimization effect.
- FIG. 5 is a flowchart of a federated learning method provided by another embodiment of the present disclosure.
- FIG. 5 another embodiment of the present disclosure provides a federated learning method, which is applied to a layer 1 node, and the method includes:
- Step 500 Report the updated gradient corresponding to the node of the first layer to the node of the second layer.
- the first layer node may also perform privacy protection processing on the updated gradient corresponding to the first layer node to obtain the privacy protection processed gradient corresponding to the first layer node, and then The gradient after privacy protection processing corresponding to the first layer node is reported to the second layer node.
- the second layer node receives the gradient after privacy protection processing corresponding to the first layer node, and needs to first perform deprivation protection processing on the gradient after privacy protection processing corresponding to the first layer node, that is, the inverse processing of the privacy protection processing.
- the privacy protection processing is encryption
- the privacy protection processing is decryption
- other privacy protection processing methods are analogous; and then calculate the weighted average of the updated gradients corresponding to at least one layer 1 node.
- layer 2 nodes may directly calculate at least one layer 1 node without performing privacy-preserving processing on the gradients after privacy-preserving processing corresponding to layer 1 nodes.
- Step 501 Receive the updated jth layer global gradient sent by the second layer node; wherein, the jth layer global gradient is based on the first gradient corresponding to at least one jth layer node and the jth layer node corresponding to the (j+1)th layer node.
- the layer weight index is calculated; the jth layer weight index is the communication index; j is any one of the integers greater than or equal to 1 and less than or equal to (N-1), where (N-1) is the number of layers of federated learning.
- the first gradient corresponding to the jth layer node is the updated gradient corresponding to the jth layer node.
- the first gradient corresponding to the node in the jth layer may also be the gradient corresponding to the node in the jth layer after the node in the jth layer performs model training to obtain an updated gradient.
- the updated gradient is the second gradient corresponding to the jth layer node obtained by performing privacy protection processing.
- the first gradient corresponding to the jth layer node is the updated (j-1)th layer global gradient corresponding to the jth layer node .
- the first gradient corresponding to the jth layer node may also be that the jth layer node corresponds to the jth layer node.
- the updated (j-1)-th layer global gradient of the privacy-preserving layer is the (j-1)-th layer global gradient corresponding to the privacy-preserving node corresponding to the j-th layer node.
- the privacy protection process may be implemented using encryption, DP, or secret sharing technology, or may be implemented in other manners, and the specific implementation manners are not intended to limit the protection scope of the embodiments of the present disclosure.
- the communication metrics include at least one of the following: average delay, traffic volume, upstream and downstream traffic, traffic volume, and weighted average of upstream and downstream traffic.
- the delay refers to the delay between sending a data request and receiving data, or the delay between sending a website access request and receiving website content.
- the weight indicators corresponding to different nodes in the same layer are the same or different, and the weight indicators corresponding to different nodes in different layers are the same or different.
- the weight indicators corresponding to different nodes in the same layer can be set to be the same, that is, at least one different node in the same layer is used to optimize the same weight indicator, similar to a distributed system;
- the weight indicators corresponding to different nodes in the same layer can be set to be different.
- the weight indicators corresponding to any two nodes in the same layer can be set to be different, or part of the same layer can be set.
- the weight indicators corresponding to the nodes are the same, and the weight indicators corresponding to another part of the nodes in the same layer are different, depending on the actual situation.
- the jth layer weight index corresponding to the (j+1)th layer node may be uniformly set in the Nth layer node or the Nth layer subsystem.
- the j-th layer weight index corresponding to the (j+1)-th layer node may set the corresponding relationship between the (j+1)-th layer node and the j-th layer weight index.
- the jth layer weight index corresponding to the (j+1) layer node can be added layer by layer together with the federated learning task.
- the weight index of the jth layer corresponding to the (j+1) layer node is distributed to the (j+1)th layer node layer by layer together with the federated learning task.
- the jth layer weight index corresponding to the (j+1)th layer node may also be set on the corresponding (j+1)th layer node, thus eliminating the need for the Nth layer node or the Nth layer node.
- the layer subsystem sends the j-th layer weight index corresponding to the (j+1)-th layer node to the (j+1)-th layer node layer by layer, thereby saving network overhead.
- calculating and obtaining the jth layer global gradient according to the first gradient corresponding to at least one jth layer node and the jth layer weight index corresponding to the (j+1)th layer node includes:
- the first gradient corresponding to the jth layer node is the second gradient corresponding to the jth layer node, or the (j-1)th layer global gradient corresponding to the jth layer node after privacy protection processing
- the first gradient corresponding to the j-th layer node needs to be de-privacy-protected, that is, the inverse of the privacy-preserving process.
- the privacy-preserving process is encryption
- the de-privacy-preserving process is decryption
- the protection processing method is analogous; and then calculate the weighted average of the first gradients after deprivation protection processing corresponding to at least one j-th layer node.
- the jth layer weight index value corresponding to the jth layer node may be obtained according to the jth layer weight index value corresponding to all the first layer nodes under the jth layer node, and may be obtained in various ways.
- each first-layer node obtains the corresponding j-th layer weight index value, it is reported to the j-th layer node layer by layer, and the j-th layer nodes perform unified calculation; for another example, each first-layer node obtains After the corresponding j-th layer weight index value, it is reported to the j-th layer node layer by layer, and a calculation is performed for each layer of nodes reported; for another example, the j-th layer node obtains the first layer used to calculate the j-th layer weight index value.
- the relevant information of the 1-layer nodes and then calculate the j-th layer weight index value corresponding to each first-layer node based on the relevant information of the first-layer nodes, and then calculate the j-th layer weight index value corresponding to the j-th layer node; and so on; , of course, there are many other acquisition methods, and the specific acquisition methods are not used to limit the protection scope of the embodiments of the present disclosure.
- GRA j is the updated (j-1) layer global gradient corresponding to the jth layer node
- GRA m (j-1) is the mth (j-1) layer node corresponding to the jth layer node.
- the first gradient, KPI m(j-1) is the (j-1)th layer weight index value corresponding to the mth (j-1)th layer node under the jth layer node.
- the weight indicator is the average delay
- the weight indicator is the traffic volume
- the weight indicator is the upstream and downstream traffic
- the weight indicator is the weighted average of the traffic volume and the uplink and downlink traffic
- the method before reporting the updated gradients corresponding to the first-layer nodes to the second-layer nodes, the method further includes: performing model training to obtain the updated gradients corresponding to the first-layer nodes;
- the method further includes:
- the updated gradients corresponding to the nodes of the first layer may be obtained by performing model training according to the federated learning task.
- the federated learning task may be a service federated learning process request initiated by the Nth layer node or the service application in the Nth layer subsystem, and then delivered to the (N-1)th layer node, and executed one by one. Therefore, after receiving the federated learning task sent by the second-layer node, the first-layer node performs model training according to the federated learning task to obtain the updated gradient corresponding to the first-layer node.
- the global gradient is calculated using the communication index as the weight index. Since the communication index is a valuable data index for operators, the global gradient calculated based on the communication index as the weight index The model training result obtained by the model training is the optimal result for the operator, thereby improving the optimization effect.
- FIG. 6 is a flowchart of a federated learning method provided by another embodiment of the present disclosure.
- another embodiment of the present disclosure provides a federated learning method, which is applied to an Nth layer node or an Nth layer subsystem, where (N-1) is the number of layers of federated learning, and the method includes:
- Step 600 Receive the corresponding (N-2)th layer global gradient reported by the Nth layer node or at least one (N-1)th layer node under the Nth layer subsystem.
- Step 601 Calculate the (N-2)th layer global gradient corresponding to at least one (N-1)th layer node and the (N-1)th layer weight index to calculate the (Nth layer node or the Nth layer subsystem corresponding to the (N-1)th layer).
- N-1) layer global gradient wherein, the weight index of the (N-1) layer is the communication index.
- the communication metrics include at least one of the following:
- Average delay, traffic volume, upstream and downstream traffic weighted average of traffic volume and upstream and downstream traffic.
- the Nth layer node or the Nth layer sub is calculated according to the (N-2)th layer global gradient and the (N-1)th layer weight index corresponding to at least one (N-1)th layer node.
- the corresponding (N-1) layer global gradient of the system includes:
- the layer weight index value is the weight, calculate the weighted average of the (N-2)th layer global gradient corresponding to at least one (N-1)th layer node, and obtain the Nth layer node or the Nth layer subsystem corresponding to the The (N-1)th layer global gradient.
- the (N-1) layer weight index value corresponding to the (N-1) layer node may be based on the (N-1) layer corresponding to all layer 1 nodes under the (N-1) layer node. -1) Obtaining the layer weight index value, which can be obtained in a variety of ways. For example, after each first layer node obtains the corresponding (N-1) layer weight index value, it reports to the (N-1) layer layer by layer. ) layer nodes, which are calculated uniformly by the (N-1) layer nodes; for another example, after each first layer node obtains the corresponding (N-1) layer weight index value, it is reported to the (N-1) layer layer by layer.
- the (N-1) layer node obtains the relevant information of the first layer node used to calculate the (N-1) layer weight index value , and then calculate the (N-1) layer weight index value corresponding to each first layer node based on the relevant information of the first layer node, and then calculate the (N-1) layer corresponding to the (N-1) layer node. weight index value; etc.
- the specific acquisition methods are not used to limit the protection scope of the embodiments of the present disclosure.
- GRA N is the updated (N-1)th layer global gradient corresponding to the Nth layer node or the Nth layer subsystem
- GRA m(N-1) is the Nth layer node or the Nth layer under the subsystem.
- the first gradient corresponding to the mth (N-1) layer node, KPI m(N-1) is the (N-1)th layer corresponding to the mth (N-1) layer node under the Nth layer node Weight indicator value.
- the weight indicator is the average delay
- the weight indicator is the traffic volume
- the weight indicator is the upstream and downstream traffic
- the weight indicator is the weighted average of the traffic volume and the uplink and downlink traffic
- the method before receiving the corresponding (N-2)th layer global gradient reported by the Nth layer node or at least one (N-1)th layer node under the Nth layer subsystem, the method further include:
- Step 602 Deliver the federated learning task to the Nth layer node or at least one (N-1)th layer node under the Nth layer subsystem.
- the federated learning task may be a service federated learning process request initiated by the Nth layer node or the service application in the Nth layer subsystem, and then delivered to the (N-1)th layer node, and executed one by one.
- Layer 1 nodes so that the i-th layer node sends the federated learning task to at least one (i-1)-th layer node after receiving the federated learning task sent by the (i+1)-th layer node.
- the service federated learning process request includes the training layer 1 node range
- the Nth layer node or the Nth layer subsystem obtains the trained layer 1 node range from the service federated learning process request, based on
- the range of nodes in the first layer of training determines the range of nodes in the (N-1) layer that the federated learning task needs to be issued. How to determine the (N-1) layer node range that needs to be delivered for the federated learning task based on the trained layer 1 node range depends on the (N-1) layer node connected to the layer 1 node corresponding to the trained layer 1 node range ) layer nodes, for example, are determined based on the topology shown in FIG. 1 .
- the Nth layer node or the Nth layer sub is calculated according to the (N-2)th layer global gradient and the (N-1)th layer weight index corresponding to at least one (N-1)th layer node.
- the method further includes:
- Step 603 Deliver the (N-1)th layer global gradient corresponding to the Nth layer node or the Nth layer subsystem to at least one (N-1)th layer node.
- the Nth layer node or the Nth layer subsystem sends the (N-1)th layer global gradient corresponding to the Nth layer node or the Nth layer subsystem to at least one (N-1th layer) ) layer node, and send it to the first layer node layer by layer, so that the first layer node can update the model according to the global gradient of the (N-1) layer.
- the global gradient is calculated using the communication index as the weight index. Since the communication index is a valuable data index for operators, the global gradient calculated based on the communication index as the weight index The model training result obtained by the model training is the optimal result for the operator, thereby improving the optimization effect.
- This example describes a two-layer federated learning process based on a two-layer federated learning system.
- the two-layer federated learning system includes: EMS, one virtual NCCN, one NCCN, and four NEs.
- the virtual NCCN is set in the EMS, and two NEs are connected under the virtual NCCN, namely NE1 and NE2; the NCCN is connected to the EMS, and two NEs are connected under the NCCN, namely NE3 and NE4.
- EMS includes: business application, first task management module, first global model management module and weight index management module; virtual NCCN includes: second task management module and second global model management module; NCCN includes: third task management module module and a third global model management module.
- NE1, NE2, NE3, NE4, NCCN and virtual NCCN are used to implement the layer 1 federated learning process
- NCCN, virtual NCCN and EMS are used to implement the layer 2 federated learning process.
- the two-layer federated learning method based on the above two-layer federated learning system includes:
- NE1 and NE2 that are not connected to the NCCN, set a virtual NCCN in the EMS according to the service characteristics, and connect NE1 and NE2 to the corresponding virtual NCCN according to the service characteristics.
- the layer 2 weight indicator can be set as: traffic volume, or uplink and downlink traffic, or the weighted average of traffic volume and uplink and downlink traffic.
- the weight indicator management module of EMS set the first layer weight indicators corresponding to different NCCNs according to the business characteristics of different fields.
- the first layer weight indicators corresponding to different NCCNs may be the same or different. For example, for automatic driving, set the corresponding layer 1 weight indicator as average delay; for stadiums, set the corresponding layer 1 weight indicator as traffic volume; for science parks, set the corresponding layer 1 weight indicator as up and down line traffic.
- the area to which the virtual NCCN belongs belongs to the autonomous driving area, and the entire network requires latency as the main requirement, and the layer 1 weight index corresponding to the virtual NCCN is set as the average delay; the area to which the NCCN belongs belongs to the stadium area, and the entire network requires Focus on traffic, and set the first layer weight index corresponding to NCCN as traffic.
- the service application initiates a service federated learning process request to the first task management, and informs the training base station range.
- the first task management module obtains the layer 2 weight indicator, the layer 1 weight indicator corresponding to the virtual NCCN, and the layer 1 weight indicator corresponding to the NCCN from the weight indicator management module of the EMS, and assigns the layer 2 weight indicator and the layer 2 weight indicator corresponding to the virtual NCCN.
- the first layer weight index is placed in the federated learning task and sent to the second task management module of the virtual NCCN; the second layer weight index and the first layer weight index corresponding to NCCN are placed in the federated learning task and sent together
- the third task management module for NCCN is placed in the federated learning task and sent together.
- the second task management module of the virtual NCCN receives the federated learning task carrying the second layer weight index and the first layer weight index corresponding to the virtual NCCN, and places the second layer weight index and the first layer weight index corresponding to the virtual NCCN. In the federated learning task, it is sent to NE1 and NE2; the third task management module of NCCN receives the federated learning task carrying the second layer weight index and the first layer weight index corresponding to NCCN, and assigns the second layer weight index, NCCN The corresponding layer 1 weight indicators are placed in the federated learning task and sent to NE3 and NE4.
- NE1 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE1 according to the first layer weight index corresponding to the virtual NCCN; obtains the corresponding NE1 according to the second layer weight index The second layer weight index value; use encryption, DP or secret sharing technology to perform privacy protection processing on the updated gradient corresponding to NE1 to obtain the privacy protection processed gradient corresponding to NE1, and use encryption, DP or secret sharing technology to perform privacy protection processing on the gradient corresponding to NE1.
- the layer 1 weight index value is subjected to privacy protection processing to obtain the layer 1 weight index value after privacy protection processing corresponding to NE1, and the layer 2 weight index value corresponding to NE1 is subjected to privacy protection processing using encryption, DP or secret sharing technology to obtain NE1 Corresponding layer 2 weight index value after privacy protection processing; the gradient corresponding to NE1 after privacy protection processing, the first layer weight index value after privacy protection processing corresponding to NE1, and the second layer after privacy protection processing corresponding to NE1
- the layer weight index value is reported to the second global model management module of the virtual NCCN.
- NE2 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE2 according to the first layer weight index corresponding to the virtual NCCN; obtains the corresponding NE2 according to the second layer weight index The second layer weight index value; use encryption, DP or secret sharing technology to perform privacy protection processing on the updated gradient corresponding to NE2 to obtain the privacy protection processed gradient corresponding to NE2, and use encryption, DP or secret sharing technology to perform privacy protection processing on the gradient corresponding to NE2
- the layer 1 weight index value is subjected to privacy protection processing to obtain the layer 1 weight index value corresponding to NE2 after privacy protection processing.
- NE3 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE3 according to the first layer weight index corresponding to NCCN; obtains the corresponding value of NE3 according to the second layer weight index Layer 2 weight index value; use encryption, DP or secret sharing technology to perform privacy protection processing on the updated gradient corresponding to NE3 to obtain the privacy protection processed gradient corresponding to NE3, and use encryption, DP or secret sharing technology to perform privacy protection processing on the first gradient corresponding to NE3. Perform privacy protection processing on the layer 1 weight index value to obtain the layer 1 weight index value after privacy protection processing corresponding to NE3.
- NE4 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE4 according to the first layer weight index corresponding to NCCN; obtains the corresponding value of NE3 according to the second layer weight index Layer 2 weight index value; use encryption, DP or secret sharing technology to perform privacy protection processing on the updated gradient corresponding to NE4 to obtain the privacy protection processed gradient corresponding to NE4, and use encryption, DP or secret sharing technology to perform privacy protection processing on the gradient corresponding to NE4. Perform privacy protection processing on the layer 1 weight index value to obtain the layer 1 weight index value after privacy protection processing corresponding to NE4.
- the second global model management module of the virtual NCCN performs de-privacy protection processing on the privacy-protected gradient corresponding to NE1 to obtain the updated gradient corresponding to NE1, and performs the first-layer weight index value on the privacy-protected layer corresponding to NE1.
- the layer 1 weight index value corresponding to NE1 is obtained through the deprivation protection process, and the layer 2 weight index value corresponding to NE1 after the privacy protection process is processed to obtain the layer 2 weight index value corresponding to NE1;
- the global model management module performs deprivation protection processing on the gradient corresponding to NE2 after privacy protection processing to obtain the updated gradient corresponding to NE2, and performs deprivation protection processing on the first layer weight index value after privacy protection processing corresponding to NE2 to obtain NE2
- For the corresponding layer 1 weight index value perform the privacy protection processing on the layer 2 weight index value corresponding to NE2 after privacy protection processing to obtain the layer 2 weight index value corresponding to NE2;
- the third global model management module of NCCN performs de-privacy protection processing on the gradient corresponding to NE3 after privacy protection processing to obtain the updated gradient corresponding to NE3, and removes the first layer weight index value after privacy protection processing corresponding to NE3.
- the first layer weight index value corresponding to NE3 is obtained after privacy protection processing, and the second layer weight index value corresponding to NE3 after privacy protection processing is deprived of privacy protection processing to obtain the second layer weight index value corresponding to NE3; the third global value of NCCN
- the model management module performs de-privacy protection processing on the gradient corresponding to NE4 after privacy protection processing to obtain the updated gradient corresponding to NE4.
- the layer 2 weight index value and the layer 2 weight index value corresponding to NE4 are reported to the first global model management module of the EMS.
- the first global model management module of EMS calculates the layer 2 weight index value corresponding to the virtual NCCN according to the layer 2 weight index value corresponding to NE1 and the layer 2 weight index value corresponding to NE2; according to the layer 2 weight corresponding to NE3
- GRA 3 GRA 312 KPI 312 +GRA 322 KPI 322
- GRA 3 is the global gradient of the second layer corresponding to EMS
- GRA 312 is the global gradient of the first layer corresponding to the virtual NCCN
- KPI 312 is the weight index value of the second layer corresponding to the virtual NCCN
- GRA 322 is the global gradient of the first layer corresponding to the NCCN
- the KPI 322 is the layer 2 weight index value corresponding to the NCCN
- the layer 2 global gradient corresponding to the EMS is issued to
- the second global model management module of the virtual NCCN sends the second layer global gradient corresponding to EMS to NE1 and NE2, and the third global model management module of NCCN sends the second layer global gradient corresponding to EMS to NE3 and NE4 ; NE1, NE2, NE3 and NE4 update the model according to the layer 2 global gradient corresponding to EMS.
- This example describes a layer 1 federated learning process based on a two-layer federated learning system.
- the two-layer federated learning system includes: EMS, one virtual NCCN, one NCCN, and four NEs.
- the virtual NCCN is set in the EMS, and two NEs are connected under the virtual NCCN, namely NE1 and NE2; the NCCN is connected to the EMS, and two NEs are connected under the NCCN, namely NE3 and NE4.
- EMS includes: business application, first task management module, first global model management module and weight index management module; virtual NCCN includes: second task management module and second global model management module; NCCN includes: third task management module module and a third global model management module.
- NE1, NE2, NE3, NE4, NCCN and virtual NCCN are used to implement the layer 1 federated learning process
- NCCN, virtual NCCN and EMS are used to implement the layer 2 federated learning process.
- Layer 1 federated learning methods based on the above two-layer federated learning system include:
- NE1 and NE2 that are not connected to the NCCN, set a virtual NCCN in the EMS according to the service characteristics, and connect NE1 and NE2 to the corresponding virtual NCCN according to the service characteristics.
- the layer 2 weight indicator can be set as: traffic volume, or uplink and downlink traffic, or the weighted average of traffic volume and uplink and downlink traffic.
- the weight indicator management module of EMS set the first layer weight indicators corresponding to different NCCNs according to the business characteristics of different fields.
- the first layer weight indicators corresponding to different NCCNs may be the same or different. For example, for automatic driving, set the corresponding layer 1 weight indicator as average delay; for stadiums, set the corresponding layer 1 weight indicator as traffic volume; for science parks, set the corresponding layer 1 weight indicator as up and down line traffic.
- the area to which the virtual NCCN belongs belongs to the autonomous driving area, and the entire network requires latency as the main requirement, and the layer 1 weight index corresponding to the virtual NCCN is set as the average delay; the area to which the NCCN belongs belongs to the stadium area, and the entire network requires Focus on traffic, and set the first layer weight index corresponding to NCCN as traffic.
- the service application initiates a service federated learning process request to the first task management, and informs the training base station range.
- the first task management module obtains the first layer weight index corresponding to the virtual NCCN and the first layer weight index corresponding to the NCCN from the weight index management module of the EMS, and places the first layer weight index corresponding to the virtual NCCN in the federated learning task.
- the second task management module of the virtual NCCN is issued together; the first layer weight index corresponding to the NCCN is placed in the federated learning task and sent to the third task management module of the NCCN together.
- the second task management module of the virtual NCCN receives the federated learning task carrying the first layer weight index corresponding to the virtual NCCN, places the first layer weight index corresponding to the virtual NCCN in the federated learning task, and sends it to NE1 and NE2 ;
- the third task management module of NCCN receives the federated learning task carrying the first-layer weight index corresponding to NCCN, places the first-layer weight index corresponding to NCCN in the federated learning task, and sends it to NE3 and NE4.
- NE1 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE1 according to the first layer weight index corresponding to the virtual NCCN; uses encryption, DP or secret sharing technology to The updated gradient corresponding to NE1 is subjected to privacy protection processing to obtain the gradient corresponding to privacy protection processing of NE1, and the privacy protection processing of the first layer weight index value corresponding to NE1 is performed using encryption, DP or secret sharing technology to obtain the privacy protection processing corresponding to NE1.
- After the first layer weight index value report the gradient corresponding to NE1 after privacy protection processing and the corresponding privacy protection processed layer 1 weight index value corresponding to NE1 to the second global model management module of the virtual NCCN.
- NE2 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE2 according to the first layer weight index corresponding to the virtual NCCN; uses encryption, DP or secret sharing technology to The updated gradient corresponding to NE2 is subjected to privacy protection processing to obtain the gradient corresponding to privacy protection processing of NE2.
- privacy protection processing is performed on the first layer weight index value corresponding to NE2 to obtain the privacy protection processing corresponding to NE2.
- NE3 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE3 according to the first layer weight index corresponding to NCCN; uses encryption, DP or secret sharing technology to NE3 The corresponding updated gradient is subjected to privacy protection processing to obtain the privacy-protected gradient corresponding to NE3. Using encryption, DP or secret sharing technology, privacy-protection processing is performed on the first layer weight index value corresponding to NE3 to obtain the privacy-protected gradient corresponding to NE3. The first layer weight index value of NE3 is reported to the third global model management module of NCCN.
- NE4 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the first layer weight index value corresponding to NE4 according to the first layer weight index corresponding to NCCN; uses encryption, DP or secret sharing technology to NE4 The corresponding updated gradient is subjected to privacy protection processing to obtain the gradient corresponding to NE4 after privacy protection processing. Using encryption, DP or secret sharing technology, privacy protection processing is performed on the first layer weight index value corresponding to NE4 to obtain the corresponding privacy protection processing of NE4. The first layer weight index value of NE4 is reported to the third global model management module of the virtual NCCN.
- the second global model management module of the virtual NCCN performs de-privacy protection processing on the privacy-protected gradient corresponding to NE1 to obtain the updated gradient corresponding to NE1, and performs the first-layer weight index value on the privacy-protected value corresponding to NE1.
- the first layer weight index value corresponding to NE1 is obtained by de-privacy protection processing; the second global model management module of the virtual NCCN performs de-privacy protection processing on the privacy-protected gradient corresponding to NE2 to obtain the updated gradient corresponding to NE2, which corresponds to NE2
- the third global model management module of NCCN performs de-privacy protection processing on the gradient corresponding to NE3 after privacy protection processing to obtain the updated gradient corresponding to NE3, and removes the first layer weight index value after privacy protection processing corresponding to NE3.
- the privacy protection processing obtains the first layer weight index value corresponding to NE3; the third global model management module of NCCN performs deprivation protection processing on the gradient corresponding to the privacy protection processing corresponding to NE4 to obtain the updated gradient corresponding to NE4.
- the third global model management module of NCCN follows the formula Calculate the updated first-layer global gradient corresponding to NCCN; among them, GRA 22 is the updated first-layer global gradient corresponding to NCCN, GRA 231 is the updated gradient corresponding to NE3, and KPI 231 is the first-layer weight index value corresponding to NE3 , GRA 241 is the updated gradient corresponding to NE4, KPI 241 is the first layer weight index value corresponding to NE4; the updated first layer global gradient corresponding to NCCN is sent to NE3 and NE4; NE3 and NE4 are updated according to the corresponding NCCN The layer 1 global gradient updates the model.
- This example describes a two-layer federated learning process based on a two-layer federated learning system.
- the two-layer federated learning system includes: EMS, one virtual NCCN, one NCCN, and four NEs.
- the virtual NCCN is set in the EMS, and two NEs are connected under the virtual NCCN, namely NE1 and NE2; the NCCN is connected to the EMS, and two NEs are connected under the NCCN, namely NE3 and NE4.
- EMS includes: business application, first task management module, first global model management module and weight index management module; virtual NCCN includes: second task management module and second global model management module; NCCN includes: third task management module module and a third global model management module.
- NE1, NE2, NE3, NE4, NCCN and virtual NCCN are used to implement the layer 1 federated learning process
- NCCN, virtual NCCN and EMS are used to implement the layer 2 federated learning process.
- the two-layer federated learning method based on the above two-layer federated learning system includes:
- NE1 and NE2 that are not connected to the NCCN, set a virtual NCCN in the EMS according to the service characteristics, and connect NE1 and NE2 to the corresponding virtual NCCN according to the service characteristics.
- the weight index management module of EMS set the weight index of the second layer to be the same as the weight index of the first layer (called the global weight index in this example).
- the global weight indicator can be set as: traffic volume, or uplink and downlink traffic, or the weighted average of traffic volume and uplink and downlink traffic.
- the service application initiates a service federated learning process request to the first task management, and informs the training base station range.
- the first task management module obtains the global weight index from the weight index management module of the EMS, and places the global weight index in the federated learning task and sends it to the second task management module of the virtual NCCN and the third task management module of the NCCN.
- the second task management module of the virtual NCCN receives the federated learning task carrying the global weight index, places the global weight index in the federated learning task, and sends it to NE1 and NE2; the third task management module of NCCN receives the federated learning task carrying the global weight index.
- the global weight index is placed in the federated learning task and sent to NE3 and NE4.
- NE1 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE1 according to the global weight index; uses encryption, DP or secret sharing technology to privacy the updated gradient corresponding to NE1
- the protection processing obtains the privacy-protected gradient corresponding to NE1, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE1 to obtain the privacy-protected global weight index value corresponding to NE1;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE1 are reported to the second global model management module of the virtual NCCN.
- NE2 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE2 according to the global weight index; uses encryption, DP or secret sharing technology to perform privacy on the updated gradient corresponding to NE2
- the protection processing obtains the privacy-protected gradient corresponding to NE2, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE2 to obtain the privacy-protected global weight index value corresponding to NE2;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE2 are reported to the second global model management module of the virtual NCCN.
- NE3 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE3 according to the global weight index; uses encryption, DP or secret sharing technology to perform privacy on the updated gradient corresponding to NE3
- the protection processing obtains the privacy-protected gradient corresponding to NE3, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE3 to obtain the privacy-protected global weight index value corresponding to NE3;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE3 are reported to the third global model management module of NCCN.
- NE4 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE4 according to the global weight index; uses encryption, DP or secret sharing technology to perform privacy on the updated gradient corresponding to NE4
- the privacy-protected gradient corresponding to NE4 is obtained after protection processing, and the global weight index value corresponding to NE4 is subjected to privacy-protection processing using encryption, DP or secret sharing technology to obtain the privacy-protected global weight index value corresponding to NE4;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE4 are reported to the third global model management module of NCCN.
- the second global model management module of the virtual NCCN performs de-privacy protection processing on the privacy-protected gradient corresponding to NE1 to obtain the updated gradient corresponding to NE1, and de-privates the privacy-protected global weight index value corresponding to NE1
- the protection processing obtains the global weight index value corresponding to NE1; the second global model management module of the virtual NCCN performs de-privacy protection processing on the gradient after privacy protection processing corresponding to NE2 to obtain the updated gradient corresponding to NE2, and processes the privacy protection corresponding to NE2.
- the first layer global gradient is the updated first layer global gradient corresponding to the virtual NCCN
- GRA 111 is the updated gradient corresponding to NE1
- KPI 111 is the global weight index value corresponding to NE1
- GRA 121 is the corresponding value of NE2
- the third global model management module of NCCN performs de-privacy protection processing on the gradient corresponding to NE3 after privacy protection processing to obtain the updated gradient corresponding to NE3, and performs de-privacy protection on the global weight index value after privacy protection processing corresponding to NE3
- the global weight index value corresponding to NE3 is obtained after processing; the third global model management module of NCCN performs deprivation protection processing on the gradient corresponding to privacy protection processing corresponding to NE4 to obtain the updated gradient corresponding to NE4, and the privacy protection corresponding to NE4 is processed.
- the first global model management module of EMS calculates the global weight index value corresponding to the virtual NCCN according to the global weight index value corresponding to NE1 and the global weight index value corresponding to NE2; according to the global weight index value corresponding to NE3 and the global weight corresponding to NE4
- the second global model management module of the virtual NCCN sends the second layer global gradient corresponding to EMS to NE1 and NE2, and the third global model management module of NCCN sends the second layer global gradient corresponding to EMS to NE3 and NE4 ; NE1, NE2, NE3 and NE4 update the model according to the layer 2 global gradient corresponding to EMS.
- This example describes a layer 1 federated learning process based on a two-layer federated learning system.
- the two-layer federated learning system includes: EMS, one virtual NCCN, one NCCN, and four NEs.
- the virtual NCCN is set in the EMS, and two NEs are connected under the virtual NCCN, namely NE1 and NE2; the NCCN is connected to the EMS, and two NEs are connected under the NCCN, namely NE3 and NE4.
- EMS includes: business application, first task management module, first global model management module and weight index management module; virtual NCCN includes: second task management module and second global model management module; NCCN includes: third task management module module and a third global model management module.
- NE1, NE2, NE3, NE4, NCCN and virtual NCCN are used to implement the layer 1 federated learning process
- NCCN, virtual NCCN and EMS are used to implement the layer 2 federated learning process.
- Layer 1 federated learning methods based on the above two-layer federated learning system include:
- NE1 and NE2 that are not connected to the NCCN, set a virtual NCCN in the EMS according to the service characteristics, and connect NE1 and NE2 to the corresponding virtual NCCN according to the service characteristics.
- the weight index management module of EMS set the weight index of the second layer to be the same as the weight index of the first layer (called the global weight index in this example).
- the global weight indicator can be set as: traffic volume, or uplink and downlink traffic, or the weighted average of traffic volume and uplink and downlink traffic.
- the service application initiates a service federated learning process request to the first task management, and informs the training base station range.
- the first task management module obtains the global weight index from the weight index management module of the EMS, and places the global weight index in the federated learning task and sends it to the second task management module of the virtual NCCN and the third task management module of the NCCN.
- the second task management module of the virtual NCCN receives the federated learning task carrying the global weight index, places the global weight index in the federated learning task, and sends it to NE1 and NE2; the third task management module of NCCN receives the federated learning task carrying the global weight index.
- the global weight index is placed in the federated learning task and sent to NE3 and NE4.
- NE1 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE1 according to the global weight index; uses encryption, DP or secret sharing technology to privacy the updated gradient corresponding to NE1
- the protection processing obtains the privacy-protected gradient corresponding to NE1, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE1 to obtain the privacy-protected global weight index value corresponding to NE1;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE1 are reported to the second global model management module of the virtual NCCN.
- NE2 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE2 according to the global weight index; uses encryption, DP or secret sharing technology to perform privacy on the updated gradient corresponding to NE2
- the protection processing obtains the privacy-protected gradient corresponding to NE2, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE2 to obtain the privacy-protected global weight index value corresponding to NE2;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE2 are reported to the second global model management module of the virtual NCCN.
- NE3 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE3 according to the global weight index corresponding to NCCN; uses encryption, DP or secret sharing technology to update the corresponding update value of NE3 Perform privacy protection processing on the gradient to obtain the gradient after privacy protection processing corresponding to NE3, and use encryption, DP or secret sharing technology to perform privacy protection processing on the global weight index value corresponding to NE3 to obtain the global weight index value corresponding to NE3 after privacy protection processing; The gradient after privacy protection processing corresponding to NE3 and the global weight index value after privacy protection processing corresponding to NE3 are reported to the third global model management module of NCCN.
- NE4 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE4 according to the global weight index corresponding to NCCN; uses encryption, DP or secret sharing technology to update the corresponding update value of NE4 Perform privacy protection processing on the gradient to obtain the gradient after privacy protection processing corresponding to NE4, and use encryption, DP or secret sharing technology to perform privacy protection processing on the global weight index value corresponding to NE4 to obtain the global weight index value corresponding to NE4 after privacy protection processing; The gradient after privacy protection processing corresponding to NE4 and the global weight index value after privacy protection processing corresponding to NE4 are reported to the third global model management module of the virtual NCCN.
- the second global model management module of the virtual NCCN performs de-privacy protection processing on the privacy-protected gradient corresponding to NE1 to obtain the updated gradient corresponding to NE1, and de-privates the privacy-protected global weight index value corresponding to NE1
- the protection processing obtains the global weight index value corresponding to NE1; the second global model management module of the virtual NCCN performs de-privacy protection processing on the gradient after privacy protection processing corresponding to NE2 to obtain the updated gradient corresponding to NE2, and processes the privacy protection corresponding to NE2.
- the first layer global gradient is the updated first layer global gradient corresponding to the virtual NCCN
- GRA 111 is the updated gradient corresponding to NE1
- KPI 111 is the global weight index value corresponding to NE1
- GRA 121 is the corresponding value of NE2
- the updated gradient, KPI 121 is the global weight index value corresponding to NE2
- the updated first-layer global gradient corresponding to the virtual NCCN is sent to NE1 and NE2
- NE1 and NE2 are updated according to the updated first-layer global gradient corresponding to the virtual NCCN Model.
- the third global model management module of NCCN performs de-privacy protection processing on the gradient corresponding to NE3 after privacy protection processing to obtain the updated gradient corresponding to NE3, and performs de-privacy protection on the global weight index value after privacy protection processing corresponding to NE3
- the global weight index value corresponding to NE3 is obtained after processing; the third global model management module of NCCN performs deprivation protection processing on the gradient corresponding to privacy protection processing corresponding to NE4 to obtain the updated gradient corresponding to NE4, and the privacy protection corresponding to NE4 is processed.
- GRA 22 is the updated first-layer global gradient corresponding to NCCN
- GRA 231 is the updated gradient corresponding to NE3
- KPI 231 is the global weight index value corresponding to NE
- This example describes a single-layer federated learning process based on a single-layer federated learning system.
- the single-layer federated learning system includes: EMS, NE1 and NE2; both NE1 and NE2 are connected to the EMS.
- EMS includes: business application, task management module, global model management module and weight index management module.
- EMS NE1, and NE2 are used to realize the single-layer federated learning process.
- the single-layer federated learning method based on the above single-layer federated learning system includes:
- the global weight indicator can be set as: traffic volume, or uplink and downlink traffic, or the weighted average of traffic volume and uplink and downlink traffic.
- the service application initiates a service federated learning process request to the task management, and informs the training base station range.
- the task management module obtains the global weight index from the weight index management module of the EMS, and places the global weight index in the federated learning task and sends it to NE1 and NE2 together.
- NE1 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE1 according to the global weight index; uses encryption, DP or secret sharing technology to perform privacy on the updated gradient corresponding to NE1
- the protection processing obtains the privacy-protected gradient corresponding to NE1, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE1 to obtain the privacy-protected global weight index value corresponding to NE1;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE1 are reported to the global model management module of EMS.
- NE2 uses local data for model training according to the federated learning task to obtain the corresponding updated gradient; obtains the global weight index value corresponding to NE2 according to the global weight index; uses encryption, DP or secret sharing technology to privacy the updated gradient corresponding to NE2
- the protection processing obtains the privacy-protected gradient corresponding to NE2, and uses encryption, DP or secret sharing technology to perform privacy-protection processing on the global weight index value corresponding to NE2 to obtain the privacy-protected global weight index value corresponding to NE2;
- the gradient after privacy protection processing and the global weight index value after privacy protection processing corresponding to NE2 are reported to the global model management module of EMS.
- the global model management module of EMS performs deprivation protection processing on the gradient corresponding to NE1 after privacy protection processing to obtain the updated gradient corresponding to NE1, and performs deprivation protection processing on the global weight index value after privacy protection processing corresponding to NE1.
- the global weight index value corresponding to NE1; the global model management module of EMS performs deprivation protection processing on the gradient after privacy protection processing corresponding to NE2 to obtain the updated gradient corresponding to NE2, and the global weight index value after privacy protection processing corresponding to NE2 Perform de-privacy protection processing to obtain the global weight index value corresponding to NE2; the global model management module of EMS calculates the updated global gradient according to the formula GRA 3 GRA 1 KPI 1 +GRA 2 KPI 2 ; wherein, GRA 3 is the updated global gradient, GRA 1 is the updated gradient corresponding to NE1, KPI 1 is the global weight index value corresponding to NE1, GRA 2 is the updated gradient corresponding to NE2, and KPI 2 is the global weight index value corresponding to NE2; send the updated global gradient to NE1 and NE2; NE1 and NE2 update the model according to the updated global gradient.
- an electronic device including:
- a memory where at least one program is stored, and when the at least one program is executed by at least one processor, the at least one processor implements any one of the above federated learning methods.
- the processor is a device with data processing capability, which includes but is not limited to a central processing unit (CPU), etc.
- the memory is a device with data storage capability, which includes but is not limited to random access memory (RAM, more specifically such as SDRAM) , DDR, etc.), read-only memory (ROM), charged erasable programmable read-only memory (EEPROM), flash memory (FLASH).
- RAM random access memory
- ROM read-only memory
- EEPROM charged erasable programmable read-only memory
- FLASH flash memory
- the processor and memory are interconnected by a bus, which in turn is connected to other components of the computing device.
- an embodiment of the present disclosure provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, any one of the foregoing federated learning methods is implemented.
- FIG. 9 is a block diagram of a federated learning apparatus according to another embodiment of the present disclosure.
- a federated learning device eg, a node at layer i, where i is any one of integers greater than or equal to 2 and less than or equal to (N-1), (N-1) is the number of layers of federated learning
- the device includes:
- the first communication module 901 is configured to receive the corresponding first gradient reported by at least one (i-1) layer node under the i layer node;
- the first calculation module 902 is configured to calculate the updated value corresponding to the i-th layer node according to the first gradient corresponding to at least one (i-1) layer node and the (i-1) layer weight index corresponding to the i-th layer node.
- the first communication module 901 is further configured to:
- the federated learning task After receiving the federated learning task sent by the (i+1) layer node, the federated learning task is issued to at least one (i-1) layer node under the i layer node.
- the communication metrics include at least one of the following: average delay, traffic volume, upstream and downstream traffic, traffic volume, and weighted average of upstream and downstream traffic.
- the weight indicators corresponding to different nodes in the same layer are the same or different, and the weight indicators corresponding to different nodes in different layers are the same or different.
- the first gradient corresponding to the (i-1)th layer node is the updated gradient obtained by the (i-1)th layer node performing model training according to the federated learning task;
- the first gradient corresponding to the (i-1)th layer node is the updated (i-2)th layer corresponding to the (i-1)th layer node global gradient.
- the first computing module 902 is specifically configured to:
- the (i-1) layer weight index value corresponding to at least one (i-1) layer node is the weight, and the weighted average value of the first gradient corresponding to at least one (i-1) layer node is calculated to obtain the updated (i- 1) Layer global gradient.
- the first communication module 901 is further configured to:
- the updated (i-1)-th layer global gradient corresponding to the i-th layer node is sent to the (i-1)-th layer node.
- the first communication module 901 is further configured to:
- FIG. 10 is a block diagram of a federated learning apparatus provided by another embodiment of the present disclosure.
- a federated learning apparatus eg, a layer 1 node
- the apparatus includes:
- the second communication module 1001 is configured to report the updated gradient corresponding to the first layer node to the second layer node; receive the updated jth layer global gradient sent by the second layer node; wherein, the jth layer global gradient is based on at least The first gradient corresponding to a node at the jth layer and the weight index of the jth layer corresponding to the node at the (j+1) layer are calculated; the weight index of the jth layer is the communication index; j is greater than or equal to 1, and less than or equal to ( Any one of the integers of N-1), (N-1) is the number of layers of federated learning.
- it also includes:
- the model training update module 1002 is configured to update the model according to the updated j-th layer global gradient.
- the second communication module 1001 is further configured to:
- the first gradient corresponding to the jth layer node is the updated gradient corresponding to the jth layer node
- the first gradient corresponding to the jth layer node is the updated (j-1)th layer global gradient corresponding to the jth layer node.
- the communication indicator includes at least one of the following: average delay, traffic volume, upstream and downstream traffic, and a weighted average of the traffic volume and the upstream and downstream traffic.
- the weight indicators corresponding to different nodes in the same layer are the same or different, and the weight indicators corresponding to different nodes in different layers are the same or different.
- FIG. 11 is a block diagram of a federated learning apparatus provided by another embodiment of the present disclosure.
- another embodiment of the present disclosure provides a federated learning device (eg, an Nth layer node, where (N-1) is the number of layers of federated learning), and the device includes:
- the third communication module 1101 is configured to receive the corresponding (N-2)th layer global gradient reported by at least one (N-1)th layer node under the Nth layer node;
- the second calculation module 1102 is configured to calculate the (N-2)th layer global gradient corresponding to at least one (N-1)th layer node and the (N-1)th layer weight index corresponding to the (N-1)th layer node. N-1) layer global gradient; wherein, the weight index of the (N-1) layer is the communication index.
- the third communication module 1101 is further configured to: deliver the federated learning task to at least one (N-1)th layer node under the Nth layer node.
- the third communication module 1101 is further configured to: deliver the (N-1)th layer global gradient corresponding to the Nth layer node to at least one (N-1)th layer node.
- the communication indicator includes at least one of the following: average delay, traffic volume, upstream and downstream traffic, and a weighted average of the traffic volume and the upstream and downstream traffic.
- a federated learning system including:
- the layer-N node or the layer-N subsystem is configured to receive the corresponding layer-(N-2)-layer global report reported by the layer-N node or at least one layer-(N-1) node under the layer-N subsystem Gradient; according to the (N-2)th layer global gradient corresponding to at least one (N-1)th layer node and the (N-1)th layer weight index, the (Nth layer node or the Nth layer subsystem corresponding to the (Nth) layer is calculated -1) layer global gradient; wherein, the weight index of the (N-1)th layer is a communication index; the (N-1)th layer global gradient corresponding to the Nth layer node or the Nth layer subsystem is issued to at least one (N-1) layer node; wherein, (N-1) is the number of layers of federated learning;
- the i-th layer node is configured to receive the corresponding first gradient reported by at least one (i-1)-th layer node under the i-th layer node; A gradient and the (i-1)-th layer weight index corresponding to the i-th layer node calculate the updated (i-1)-th layer global gradient corresponding to the i-th layer node; wherein, the (i-1)-th layer weight index is communication index;
- the i-th tier node is also configured as:
- the first layer node is configured to report the updated gradient corresponding to the first layer node to the second layer node; receive the updated jth layer global gradient sent by the second layer node; wherein, the jth layer global gradient is based on at least one
- the first gradient corresponding to the jth layer node and the jth layer weight index corresponding to the (j+1) layer node are calculated; the jth layer weight index is the communication index; the jth layer weight index is the communication index; j is greater than or Equal to 1, and any one of the integers less than or equal to (N-1), (N-1) is the number of layers of federated learning.
- the first layer nodes are further configured to: perform model training to obtain updated gradients corresponding to the first layer nodes; and update the model according to the updated jth layer global gradients.
- the communication metrics include at least one of the following: average delay, traffic volume, upstream and downstream traffic, traffic volume, and weighted average of upstream and downstream traffic.
- the weight indicators corresponding to different nodes in the same layer are the same or different, and the weight indicators corresponding to different nodes in different layers are the same or different.
- the first gradient corresponding to the (i-1)th layer node is the updated gradient obtained by the (i-1)th layer node performing model training according to the federated learning task;
- the first gradient corresponding to the (i-1)th layer node is the updated (i-2)th layer corresponding to the (i-1)th layer node global gradient.
- the first gradient corresponding to the jth layer node is the updated gradient corresponding to the jth layer node
- the first gradient corresponding to the jth layer node is the updated (j-1)th layer global gradient corresponding to the jth layer node.
- the i-th layer node is specifically configured to implement the first gradient corresponding to at least one (i-1)-th layer node and the (i-1)-th layer corresponding to the i-th layer node in the following manner
- the weight indicator calculates the updated (i-1)-th layer global gradient corresponding to the i-th layer node:
- the i-th layer node is further configured to: deliver the updated (i-1)-th layer global gradient corresponding to the i-th layer node to the (i-1)-th layer node.
- the i-th tier node is further configured to:
- Such software may be distributed on computer-readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media).
- computer storage media includes both volatile and nonvolatile implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data flexible, removable and non-removable media.
- Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, magnetic tape, magnetic disk storage or other magnetic storage, or may Any other medium that stores the desired information and can be accessed by a computer.
- communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and can include any information delivery media, as is well known to those of ordinary skill in the art .
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Software Systems (AREA)
- General Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Artificial Intelligence (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Health & Medical Sciences (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Computing Systems (AREA)
- Mathematical Physics (AREA)
- Life Sciences & Earth Sciences (AREA)
- Medical Informatics (AREA)
- Bioethics (AREA)
- Computational Linguistics (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Bioinformatics & Computational Biology (AREA)
- Molecular Biology (AREA)
- Evolutionary Biology (AREA)
- Biophysics (AREA)
- Biomedical Technology (AREA)
- Computer Hardware Design (AREA)
- Computer Security & Cryptography (AREA)
- Databases & Information Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Telephonic Communication Services (AREA)
Abstract
本公开提供了一种联邦学习方法、装置和系统、电子设备、计算机可读存储介质,联邦学习方法应用于第i层节点,i为大于或等于2,且小于或等于(N-1)的整数,(N-1)为联邦学习的层数,该方法包括:接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;其中,第(i-1)层权重指标为通信指标。图4
Description
相关申请的交叉引用
本公开要求在2020年7月17日提交国家知识产权局、申请号为202010695940.2、发明名称为“联邦学习方法、装置和系统、电子设备、存储介质”的中国专利申请的优先权,该申请的全部内容通过引用结合在本公开中。
本公开实施例涉及但不限于人工智能领域,特别涉及联邦学习方法、装置和系统、电子设备、计算机可读存储介质。
在数据化最为成熟的通信领域,如果进行智能化,显然面临这样一个问题,智能化带来的计算负荷资源要求在通信领域实时性要求高的前提下,网络现存设备剩余不多的算力资源目前难以满足通信智能化发展的实时算力要求。
对于存量网络所需的实时计算要求,目前主要的解决思路是把网络设备(即网络的中心计算节点)的计算从网络设备内部迁移到移动接入网边缘,实现边缘侧的实时智能化计算需求,即在网络中靠近网元侧部署具备数据采集和计算能力的节点(即,NCCN,Near Collect Computer Node)。这种方式对于现存网络,例如3G、4G、部分5G的智能化所带来的实时计算需求起到一个过渡作用。
在这种算力架构下引入联邦学习,不仅能保护网元侧用户数据的隐私,而且能充分利用网络设备不多的算力资源,以及防止数据移动带来的带宽消耗。但是目前的联邦学习方法得到的优化结果往往不是最佳的。
发明内容
本公开实施例提供一种联邦学习方法、装置和系统、电子设备、计算机可读存储介质。
第一方面,本公开实施例提供一种联邦学习方法,应用于第i层节点,i为大于或等于2,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数,该方法包括:接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;以及根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;其中,第(i-1)层权重指标为通信指标。
第二方面,本公开实施例提供一种联邦学习方法,应用于第1层节点,该方法包括:将第1层节点对应的更新的梯度上报给第2层节点;以及接收第2层节点发送的更新的第j层全局梯度;其中,第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到;第j层权重指标为通信指标;j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
第三方面,本公开实施例提供一种联邦学习方法,应用于第N层节点或第N层子系统,(N-1)为联邦学习的层数,该方法包括:接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度;以及根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点或第N层子系统对应的第(N-1)层全局梯度;其中,第(N-1)层权重指标为通信指标。
第四方面,本公开实施例提供一种电子设备,包括:至少一个处理器;以及存储器,存储器上存储有至少一个程序,当至少一个程序被至少一个处理器执行,使得至少一个处理器实现上述任意一种联邦学习方法。
第五方面,本公开实施例提供一种计算机可读存储介质,计算机可读存储介质上存储有计算机程序,计算机程序被处理器执行时实现上述任意一种联邦学习方法。
第六方面,本公开实施例提供一种联邦学习系统,包括:第N层节点 或第N层子系统,被配置为接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度;根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点或第N层子系统对应的第(N-1)层全局梯度;其中,第(N-1)层权重指标为通信指标;将第N层节点或第N层子系统对应的第(N-1)层全局梯度下发给至少一个第(N-1)层节点;其中,(N-1)为联邦学习的层数;第i层节点,被配置为接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;其中,第(i-1)层权重指标为通信指标;第i层节点还被配置为:将第i层节点对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点;或者,将第i层节点对应的更新的第(i-1)层全局梯度上报给第(i+1)层节点;接收第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个下发给第(i-1)层节点;第1层节点,被配置为将第1层节点对应的更新的梯度上报给第2层节点;接收第2层节点发送的更新的第j层全局梯度;其中,第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到;第j层权重指标为通信指标;j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
本公开实施例提供的联邦学习方法,以通信指标为权重指标来计算全局梯度,由于通信指标对于运营商来说是比较有价值的数据指标,因此基于以通信指标为权重指标来计算的全局梯度进行模型训练得到的模型训练结果对于运营商来说是最优结果,从而提高了优化效果。
图1为本公开实施例提供的联邦学习系统架构示意图;
图2为本公开实施例提供的单层联邦学习系统架构示意图;
图3为本公开实施例提供的双层联邦学习系统架构示意图;
图4为本公开一个实施例提供的联邦学习方法的流程图;
图5为本公开另一个实施例提供的联邦学习方法的流程图;
图6为本公开另一个实施例提供的联邦学习方法的流程图;
图7为本公开示例1-4提供的联邦学习系统架构示意图;
图8为本公开示例5提供的联邦学习系统架构示意图;
图9为本公开另一个实施例提供的联邦学习装置的组成框图;
图10为本公开另一个实施例提供的联邦学习装置的组成框图;
图11为本公开另一个实施例提供的联邦学习装置的组成框图。
为使本领域的技术人员更好地理解本公开的技术方案,下面结合附图对本公开提供的联邦学习方法、装置和系统、电子设备、计算机可读存储介质进行详细描述。
在下文中将参考附图更充分地描述示例实施例,但是所述示例实施例可以以不同形式来体现且不应当被解释为限于本文阐述的实施例。反之,提供这些实施例的目的在于使本公开透彻和完整,并将使本领域技术人员充分理解本公开的范围。
在不冲突的情况下,本公开各实施例及实施例中的各特征可相互组合。
如本文所使用的,术语“和/或”包括至少一个相关列举条目的任何和所有组合。
本文所使用的术语仅用于描述特定实施例,且不意欲限制本公开。如本文所使用的,单数形式“一个”和“该”也意欲包括复数形式,除非上下文另外清楚指出。还将理解的是,当本说明书中使用术语“包括”和/或“由……制成”时,指定存在所述特征、整体、步骤、操作、元件和/或组件,但不排除存在或添加至少一个其它特征、整体、步骤、操作、元件、组件和/或其群组。
除非另外限定,否则本文所用的所有术语(包括技术和科学术语)的 含义与本领域普通技术人员通常理解的含义相同。还将理解,诸如那些在常用字典中限定的那些术语应当被解释为具有与其在相关技术以及本公开的背景下的含义一致的含义,且将不解释为具有理想化或过度形式上的含义,除非本文明确如此限定。
目前的横向联邦学习方法大致包括:
参与方用本地数据进行模型训练得到更新的梯度,使用加密、差分隐私(DP,Different Privacy)或秘密共享技术对更新的梯度进行隐私保护处理,得到隐私保护处理后的梯度;将隐私保护处理后的梯度发送到中心服务器;
中心服务器对至少一个参与方对应的隐私保护处理后的梯度进行解密,得到至少一个参与方对应的更新的梯度,根据至少一个参与方对应的更新的梯度计算更新的全局梯度,将更新的全局梯度分别下发给每一个参与者;
参与方根据更新的全局梯度更新模型。
上述横向联邦学习方法中,更新的全局梯度一般采用谷歌(Google)的联合平均(FedAvg,Federated Averaging)算法,即将所有参与方(或者随机一部分参与方)对应更新的梯度取平均值或加权平均值得到更新的全局梯度;其中,权重为参与方参与训练的数据量。这种方法以参与方参与训练的数据量作为权重,由于参与训练的数据量不等同于运营商关注的有价值的数据量,因此,模型训练结果对于运营商来说并不是最优结果;并且,没有对参与方进行区分,无法实现个性化的优化,从而降低优化效果。
下面介绍本公开实施例提供的联邦系统架构。
图1为本公开实施例提供的联邦学习系统架构示意图。如图1所示,本公开实施例的联邦学习系统用于实现(N-1)层联邦学习,N为大于或等于2的整数。
本公开实施例的(N-1)层联邦学习由N层节点实现,或(N-1)层联邦学习由第1层节点到第(N-1)层节点以及第N层子系统实现;并且, 第1层节点到第(N-1)层节点均包括一个或一个以上,而第N层节点或第N层子系统仅包括一个。
具体的,第i层联邦学习由第i层节点和第(i+1)层节点实现,i为大于或等于1,且小于或等于(N-2)的整数;第(N-1)层联邦学习由第(N-1)层节点和第N层节点实现,或第(N-1)层联邦学习由第(N-1)层节点和第N层子系统实现。
需要说明的是,不同的第(i+1)层节点的下一层节点(即,第i层节点)不同。
需要说明的是,第1层节点可以是网元(NE,Network Element),如基站,第2层节点到第(N-1)层节点可以是NCCN,第N层节点或第N层子系统可以是网元管理系统(EMS,Element Management System)对应的节点或子系统。
需要说明的是,第2层节点到第(N-1)层节点可以是实体设备,也可以是虚拟节点。
例如,图2以单层联邦学习为例给出了单层联邦学习系统架构示意图。如图2所示,单层联邦学习系统实现了单层联邦学习,单层联邦学习由第1层节点和第2层节点实现,或单层联邦学习由第1层节点和第2层子系统实现。
又如,图3以双层联邦学习为例给出了双层联邦学习系统架构示意图。如图3所示,双层联邦学习由第1层节点、第2层节点和第3层节点实现,或双层联邦学习由第1层节点、第2层节点和第3层子系统实现。具体的,第1层联邦学习由第1层节点和第2层节点实现,第2层联邦学习由第2层节点和第3层节点实现,或第2层联邦学习由第2层节点和第3层子系统实现。
下面分别从第1层节点侧、第2层节点到第(N-1)层节点中任何一层节点侧、第N层节点或第N层子系统侧来分别描述联邦学习过程。
图4为本公开一个实施例提供的联邦学习方法的流程图。
第一方面,参照图4,本公开一个实施例提供一种联邦学习方法,应 用于第i层节点,i为大于或等于2,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数,该方法包括:
步骤400、接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度。
在一些示例性实施例中,若i等于2,第(i-1)层节点对应的第一梯度为第(i-1)层节点进行模型训练得到的更新的梯度。
在一些示例性实施例中,若i等于2,为了提高安全性,第(i-1)层节点对应的第一梯度也可以是第(i-1)层节点进行模型训练得到更新的梯度后,对第(i-1)层节点对应的更新的梯度进行隐私保护处理得到的第(i-1)层节点对应的第二梯度。
在一些示例性实施例中,若i大于2,且小于或等于(N-1),第(i-1)层节点对应的第一梯度为第(i-1)层节点对应的更新的第(i-2)层全局梯度。
在一些示例性实施例中,若i大于2,且小于或等于(N-1),为了提高安全性,第(i-1)层节点对应的第一梯度也可以是第(i-1)层节点对第(i-1)层节点对应的更新的第(i-2)层全局梯度进行隐私保护处理得到的第(i-1)层节点对应的隐私保护处理后的第(i-2)层全局梯度。
在一些示例性实施例中,隐私保护处理可以采用加密、DP或秘密共享技术实现,也可以采用其他的方式实现,具体的实现方式不用于限定本公开实施例的保护范围。
步骤401、根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;其中,第(i-1)层权重指标为通信指标。
在一些示例性实施例中,通信指标包括以下至少一个:平均时延、话务量、上下行流量、话务量和上下行流量的加权平均。
在一些示例性实施例中,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。例如,为了实现网络优化的实时性,可以将同一层的不同节点对应的权重指标设置为相同,也 就是采用至少一个同一层的不同节点来实现同一个权重指标的优化,类似于分布式系统;为了实现网络优化的个性化,可以将同一层的不同节点对应的权值指标设置为不同,具体可以设置同一层的任意两个节点对应的权重指标均不相同,也可以设置同一层的其中一部分节点对应的权重指标相同,同一层的另一部分节点对应的权重指标不同,具体视实际情况而定。
在一些示例性实施例中,第i层节点对应的第(i-1)层权重指标可以统一设置在第N层节点或第N层子系统中,具体设置时,可以设置第i层节点和第(i-1)层权重指标之间的对应关系。这种设置方式中,在第N层节点或第N层子系统逐层下发联邦学习任务时,可以将第i层节点对应的第(i-1)层权重指标随联邦学习任务一起逐层下发到第i层节点,也可以单独将第i层节点对应的第(i-1)层权重指标逐层下发到第i层节点,也可以不将第i层节点对应的第(i-1)层权重指标随联邦学习任务一起逐层下发到第i层节点。
在一些示例性实施例中,第i层节点对应的第(i-1)层权重指标也可以设置在对应的第i层节点上,这样省去了第N层节点或第N层子系统将第i层节点对应的第(i-1)层权重指标逐层下发到第i层节点的过程,从而节省了网络开销。
在一些示例性实施例中,根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度包括:
根据第i层节点对应的第(i-1)层权重指标获取至少一个第(i-1)层节点对应的第(i-1)层权重指标值;以至少一个第(i-1)层节点对应的第(i-1)层权重指标值为权重,计算至少一个第(i-1)层节点对应的第一梯度的加权平均值,得到第i层节点对应的更新的第(i-1)层全局梯度。
在一些示例性实施例中,如果第(i-1)层节点对应的第一梯度为第(i-1)层节点对应的第二梯度,或第(i-1)层节点对应的隐私保护处理后的第(i-2)层全局梯度,则需要先对第(i-1)层节点对应的第一梯度进行去隐私保护处理,也就是进行隐私保护处理的反处理。例如,如果隐私保护处理为加 密,那么去隐私保护处理就是解密,其他的隐私保护处理方式以此类推;然后再计算至少一个第(i-1)层节点对应的去隐私保护处理后的第一梯度的加权平均值。
在一些示例性实施例中,对于某些隐私保护处理方式,例如同态加密方式,也可以不用对第(i-1)层节点对应的第一梯度进行去隐私保护处理,而直接计算至少一个第(i-1)层节点对应的第一梯度的加权平均值。
在一些示例性实施例中,第(i-1)层节点对应的第(i-1)层权重指标值可以根据第(i-1)层节点下的所有第1层节点对应的第(i-1)层权重指标值获得,具体可以采用多种方式获得,例如,每一个第1层节点分别获得对应的第(i-1)层权重指标值后,逐层上报到第(i-1)层节点,由第(i-1)层节点统一进行计算;又如,每一个第1层节点分别获得对应的第(i-1)层权重指标值后,逐层上报到第(i-1)层节点,每上报一层节点,则进行一次计算;又如,由第(i-1)层节点获取用于计算第(i-1)层权重指标值的第1层节点的相关信息,然后基于第1层节点的相关信息分别计算每一个第1层节点对应的第(i-1)层权重指标值,然后计算第(i-1)层节点对应的第(i-1)层权重指标值;等等,当然,还有其他很多的获取方式,具体的获取方式不用于限定本公开实施例的保护范围。
其中,GRA
i为第i层节点对应的更新的第(i-1)层全局梯度,GRA
m
(i-1)为第i层节点下的第m个第(i-1)层节点对应的第一梯度,KPI
m(i-1)为第i层节点下的第m个第(i-1)层节点对应的第(i-1)层权重指标值。
在一些示例性实施例中,如果权重指标为平均时延,那么只需要计算以平均时延为权重的全局梯度。
在一些示例性实施例中,如果权重指标为话务量,那么只需要计算以话务量为权重的全局梯度。
在一些示例性实施例中,如果权重指标为上下行流量,那么只需要计 算以上下行流量为权重的全局梯度。
在一些示例性实施例中,如果权重指标为话务量和上下行流量的加权平均,那么需要分别计算以话务量为权重的全局梯度和以上下行流量为权重的全局梯度,然后计算以话务量为权重的全局梯度和以上下行流量为权重的全局梯度的加权平均值。
在一些示例性实施例中,接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度之前,该方法还包括:
步骤402、接收到第(i+1)层节点发送的联邦学习任务,将联邦学习任务下发给至少一个第(i-1)层节点。
在一些示例性实施例中,联邦学习任务可以是第N层节点或第N层子系统中的业务应用发起的业务联邦学习过程请求后,向第(N-1)层节点下发,并逐层下发的第1层节点的,从而第i层节点在接收到第(i+1)层节点发送的联邦学习任务后,将联邦学习任务下发给至少一个第(i-1)层节点。
在一些示例性实施例中,业务联邦学习过程请求中包括训练的第1层节点范围,第N层节点或第N层子系统从业务联邦学习过程请求中获取训练的第1层节点范围,基于训练的第1层节点范围确定联邦学习任务需要下发的第(N-1)层节点范围。如何基于训练的第1层节点范围确定联邦学习任务需要下发的第(N-1)层节点范围具体取决于训练的第1层节点范围对应的第1层节点所连接的第(N-1)层节点,例如基于图1所示的拓扑结构来确定。
在一些示例性实施例中,在第i层节点向第(i-1)层节点下发联邦学习任务时,还可以下发训练的第1层节点范围,使得第(i-1)层节点根据训练的第1层节点范围确定联邦学习任务需要下发的第(i-2)层节点。如何基于训练的第1层节点范围确定联邦学习任务需要下发的第(i-2)层节点范围具体取决于训练的第1层节点范围对应的第1层节点所连接的第(i-2)层节点,例如基于图1所示的拓扑结构来确定。
在一些示例性实施例中,若当前状态是进行第(i-1)层联邦学习过程, 根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度之后,该方法还包括:
将第i层节点对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点。
在一些示例性实施例中,第i层节点将第i层节点对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点,并逐层下发至第1层节点,以供第1层节点根据第(N-1)层全局梯度更新模型。
在一些示例性实施例中,若当前状态是进行第i层联邦学习过程到第(N-1)层联邦学习过程中的任何一层联邦学习过程,根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度之后,该方法还包括:
将第i层节点对应的更新的第(i-1)层全局梯度上报给第(i+1)层节点;接收第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个下发给第(i-1)层节点。
在一些示例性实施例中,第i层节点将更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个下发给第(i-1)层节点,并逐层下发至第1层节点,以供第1层节点根据第(N-1)层全局梯度更新模型。
在一些示例性实施例中,第1层节点接收到联邦学习任务后,根据联邦学习任务进行模型训练得到更新的梯度,并将第1层节点对应的更新的梯度上报给第2层节点;第2层节点根据至少一个第1层节点对应的更新的梯度和第2层节点对应的第1层权重指标计算第2层节点对应的更新的第1层全局梯度;如果当前状态是进行第1层联邦学习过程,则第2层节点将对应的更新的第1层全局梯度下发给第1层节点,第1层节点根据更新的第1层全局梯度更新模型;如果当前状态是进行第2层联邦学习过程到第(N-1)层联邦学习过程中的任何一层联邦学习过程,则第2层节点将对应的更新的第1层全局梯度上报给第3层节点;
当i大于2,且小于或等于(N-1)时,第i层节点根据至少一个第(i-1)层节点对应的更新的第(i-2)层全局梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;如果当前状态是进行第(i-1)层联邦学习过程,则第i层节点将对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点,并逐层下发至第1层节点,第1层节点根据更新的第(i-1)层全局梯度更新模型;如果当前状态是进行第i层联邦学习过程到第(N-1)层联邦学习过程中的任何一层联邦学习过程,则第i层节点将对应的更新的第(i-1)层全局梯度上报给第(i+1)层节点。
本公开实施例提供的联邦学习方法,以通信指标为权重指标来计算全局梯度,由于通信指标对于运营商来说是比较有价值的数据指标,因此基于以通信指标为权重指标来计算的全局梯度进行模型训练得到的模型训练结果对于运营商来说是最优结果,从而提高了优化效果。
图5为本公开另一个实施例提供的联邦学习方法的流程图。
第二方面,参照图5,本公开另一个实施例提供一种联邦学习方法,应用于第1层节点,该方法包括:
步骤500、将第1层节点对应的更新的梯度上报给第2层节点。
在一些示例性实施例中,为了提高安全性,第1层节点也可以先对第1层节点对应的更新的梯度进行隐私保护处理得到第1层节点对应的隐私保护处理后的梯度,再将第1层节点对应的隐私保护处理后的梯度上报给第2层节点。
第2层节点接收到第1层节点对应的隐私保护处理后的梯度,需要先对第1层节点对应的隐私保护处理后的梯度进行去隐私保护处理,也就是进行隐私保护处理的反处理,例如,如果隐私保护处理为加密,那么去隐私保护处理就是解密,其他的隐私保护处理方式以此类推;然后再计算至少一个第1层节点对应的更新的梯度的加权平均值。
或者,对于某些隐私保护处理方式,例如同态加密方式,第2层节点也可以不用对第1层节点对应的隐私保护处理后的梯度进行去隐私保护处理,而直接计算至少一个第1层节点对应的隐私保护处理后的梯度的加权 平均值。
步骤501、接收第2层节点发送的更新的第j层全局梯度;其中,第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到;第j层权重指标为通信指标;j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
在一些示例性实施例中,若j等于1,第j层节点对应的第一梯度为第j层节点对应的更新的梯度。
在一些示例性实施例中,若j等于1,为了提高安全性,第j层节点对应的第一梯度也可以是第j层节点进行模型训练得到更新的梯度后,对第j层节点对应的更新的梯度进行隐私保护处理得到的第j层节点对应的第二梯度。
在一些示例性实施例中,若j大于1,且小于或等于(N-1),第j层节点对应的第一梯度为第j层节点对应的更新的第(j-1)层全局梯度。
在一些示例性实施例中,若j大于1,且小于或等于(N-1),为了提高安全性,第j层节点对应的第一梯度也可以是第j层节点对第j层节点对应的更新的第(j-1)层全局梯度进行隐私保护处理得到的第j层节点对应的隐私保护处理后的第(j-1)层全局梯度。
在一些示例性实施例中,隐私保护处理可以采用加密、DP或秘密共享技术实现,也可以采用其他的方式实现,具体的实现方式不用于限定本公开实施例的保护范围。
在一些示例性实施例中,通信指标包括以下至少一个:平均时延、话务量、上下行流量、话务量和上下行流量的加权平均。
在一些示例性实施例中,时延是指第1层节点发出数据请求到接收到数据之间的时延,或发出网址访问请求到接收到网址内容之间的时延。
在一些示例性实施例中,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。例如,为了实现网络优化的实时性,可以将同一层的不同节点对应的权重指标设置为相同,也 就是采用至少一个同一层的不同节点来实现同一个权重指标的优化,类似于分布式系统;为了实现网络优化的个性化,可以将同一层的不同节点对应的权值指标设置为不同,具体可以设置同一层的任意两个节点对应的权重指标均不相同,也可以设置同一层的其中一部分节点对应的权重指标相同,同一层的另一部分节点对应的权重指标不同,具体视实际情况而定。
在一些示例性实施例中,第(j+1)层节点对应的第j层权重指标可以统一设置在第N层节点或第N层子系统中。在具体设置时,第(j+1)层节点对应的第j层权重指标可以设置第(j+1)层节点和第j层权重指标之间的对应关系。这种设置方式中,在第N层节点或第N层子系统逐层下发联邦学习任务时,可以将第(j+1)层节点对应的第j层权重指标随联邦学习任务一起逐层下发到第(j+1)层节点,也可以单独将第(j+1)层节点对应的第j层权重指标逐层下发到第(j+1)层节点,也可以不将第(j+1)层节点对应的第j层权重指标随联邦学习任务一起逐层下发到第(j+1)层节点。
在一些示例性实施例中,第(j+1)层节点对应的第j层权重指标也可以设置在对应的第(j+1)层节点上,这样省去了第N层节点或第N层子系统将第(j+1)层节点对应的第j层权重指标逐层下发到第(j+1)层节点的过程,从而节省了网络开销。
在一些示例性实施例中,根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到第j层全局梯度包括:
根据第(j+1)层节点对应的第j层权重指标获取至少一个第j层节点对应的第j层权重指标值;以至少一个第j层节点对应的第j层权重指标值为权重,计算至少一个第j层节点对应的第一梯度的加权平均值,得到第(j+1)层节点对应的更新的第j层全局梯度。
在一些示例性实施例中,如果第j层节点对应的第一梯度为第j层节点对应的第二梯度,或第j层节点对应的隐私保护处理后的第(j-1)层全局梯度,则需要先对第j层节点对应的第一梯度进行去隐私保护处理,也就是进行隐私保护处理的反处理,例如,如果隐私保护处理为加密,那么 去隐私保护处理就是解密,其他的隐私保护处理方式以此类推;然后再计算至少一个第j层节点对应的去隐私保护处理后的第一梯度的加权平均值。
在一些示例性实施例中,对于某些隐私保护处理方式,例如同态加密方式,也可以不用对第j层节点对应的第一梯度进行去隐私保护处理,而直接计算至少一个第j层节点对应的第一梯度的加权平均值。
在一些示例性实施例中,第j层节点对应的第j层权重指标值可以根据第j层节点下的所有第1层节点对应的第j层权重指标值获得,具体可以采用多种方式获得,例如,每一个第1层节点分别获得对应的第j层权重指标值后,逐层上报到第j层节点,由第j层节点统一进行计算;又如,每一个第1层节点分别获得对应的第j层权重指标值后,逐层上报到第j层节点,每上报一层节点,则进行一次计算;又如,由第j层节点获取用于计算第j层权重指标值的第1层节点的相关信息,然后基于第1层节点的相关信息分别计算每一个第1层节点对应的第j层权重指标值,然后计算第j层节点对应的第j层权重指标值;等等,当然,还有其他很多的获取方式,具体的获取方式不用于限定本公开实施例的保护范围。
其中,GRA
j为第j层节点对应的更新的第(j-1)层全局梯度,GRA
m
(j-1)为第j层节点下的第m个第(j-1)层节点对应的第一梯度,KPI
m(j-1)为第j层节点下的第m个第(j-1)层节点对应的第(j-1)层权重指标值。
在一些示例性实施例中,如果权重指标为平均时延,那么只需要计算以平均时延为权重的全局梯度。
在一些示例性实施例中,如果权重指标为话务量,那么只需要计算以话务量为权重的全局梯度。
在一些示例性实施例中,如果权重指标为上下行流量,那么只需要计算以上下行流量为权重的全局梯度。
在一些示例性实施例中,如果权重指标为话务量和上下行流量的加权 平均,那么需要分别计算以话务量为权重的全局梯度和以上下行流量为权重的全局梯度,然后计算以话务量为权重的全局梯度和以上下行流量为权重的全局梯度的加权平均值。
在一些示例性实施例中,将第1层节点对应的更新的梯度上报给第2层节点之前,该方法还包括:进行模型训练得到第1层节点对应的更新的梯度;
相应的,接收第2层节点发送的更新的第j层全局梯度之后,该方法还包括:
根据更新的第j层全局梯度更新模型。
在一些示例性实施例中,可以根据联邦学习任务进行模型训练得到第1层节点对应的更新的梯度。
在一些示例性实施例中,联邦学习任务可以是第N层节点或第N层子系统中的业务应用发起的业务联邦学习过程请求后,向第(N-1)层节点下发,并逐层下发的第1层节点的,从而第1层节点在接收到第2层节点发送的联邦学习任务后,根据联邦学习任务进行模型训练得到第1层节点对应的更新的梯度。
本公开实施例提供的联邦学习方法,以通信指标为权重指标来计算全局梯度,由于通信指标对于运营商来说是比较有价值的数据指标,因此基于以通信指标为权重指标来计算的全局梯度进行模型训练得到的模型训练结果对于运营商来说是最优结果,从而提高了优化效果。
图6为本公开另一个实施例提供的联邦学习方法的流程图。
第三方面,参照图6,本公开另一个实施例提供一种联邦学习方法,应用于第N层节点或第N层子系统,(N-1)为联邦学习的层数,该方法包括:
步骤600、接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度。
步骤601、根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点或第N层子系统对应的第(N-1) 层全局梯度;其中,第(N-1)层权重指标为通信指标。
在一些示例性实施例中,通信指标包括以下至少一个:
平均时延、话务量、上下行流量、话务量和上下行流量的加权平均。
在一些示例性实施例中,根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点或第N层子系统对应的第(N-1)层全局梯度包括:
根据第(N-1)层权重指标获取至少一个第(N-1)层节点对应的第(N-1)层权重指标值;以至少一个第(N-1)层节点对应的第(N-1)层权重指标值为权重,计算至少一个第(N-1)层节点对应的第(N-2)层全局梯度的加权平均值,得到第N层节点或第N层子系统对应的第(N-1)层全局梯度。
在一些示例性实施例中,第(N-1)层节点对应的第(N-1)层权重指标值可以根据第(N-1)层节点下的所有第1层节点对应的第(N-1)层权重指标值获得,具体可以采用多种方式获得,例如,每一个第1层节点分别获得对应的第(N-1)层权重指标值后,逐层上报到第(N-1)层节点,由第(N-1)层节点统一进行计算;又如,每一个第1层节点分别获得对应的第(N-1)层权重指标值后,逐层上报到第(N-1)层节点,每上报一层节点,则进行一次计算;又如,由第(N-1)层节点获取用于计算第(N-1)层权重指标值的第1层节点的相关信息,然后基于第1层节点的相关信息分别计算每一个第1层节点对应的第(N-1)层权重指标值,然后计算第(N-1)层节点对应的第(N-1)层权重指标值;等等,当然,还有其他很多的获取方式,具体的获取方式不用于限定本公开实施例的保护范围。
其中,GRA
N为第N层节点或第N层子系统对应的更新的第(N-1)层全局梯度,GRA
m(N-1)为第N层节点或第N层子系统下的第m个第(N-1)层节点对应的第一梯度,KPI
m(N-1)为第N层节点下的第m个第(N-1)层 节点对应的第(N-1)层权重指标值。
在一些示例性实施例中,如果权重指标为平均时延,那么只需要计算以平均时延为权重的全局梯度。
在一些示例性实施例中,如果权重指标为话务量,那么只需要计算以话务量为权重的全局梯度。
在一些示例性实施例中,如果权重指标为上下行流量,那么只需要计算以上下行流量为权重的全局梯度。
在一些示例性实施例中,如果权重指标为话务量和上下行流量的加权平均,那么需要分别计算以话务量为权重的全局梯度和以上下行流量为权重的全局梯度,然后计算以话务量为权重的全局梯度和以上下行流量为权重的全局梯度的加权平均值。
在一些示例性实施例中,接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度之前,该方法还包括:
步骤602、向第N层节点或第N层子系统下的至少一个第(N-1)层节点下发联邦学习任务。
在一些示例性实施例中,联邦学习任务可以是第N层节点或第N层子系统中的业务应用发起的业务联邦学习过程请求后,向第(N-1)层节点下发,并逐层下发的第1层节点的,从而第i层节点在接收到第(i+1)层节点发送的联邦学习任务后,将联邦学习任务下发给至少一个第(i-1)层节点。
在一些示例性实施例中,业务联邦学习过程请求中包括训练的第1层节点范围,第N层节点或第N层子系统从业务联邦学习过程请求中获取训练的第1层节点范围,基于训练的第1层节点范围确定联邦学习任务需要下发的第(N-1)层节点范围。如何基于训练的第1层节点范围确定联邦学习任务需要下发的第(N-1)层节点范围具体取决于训练的第1层节点范围对应的第1层节点所连接的第(N-1)层节点,例如基于图1所示的拓扑结构来确定。
在一些示例性实施例中,根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点或第N层子系统对应的第(N-1)层全局梯度之后,该方法还包括:
步骤603、将第N层节点或第N层子系统对应的第(N-1)层全局梯度下发给至少一个第(N-1)层节点。
在一些示例性实施例中,第N层节点或第N层子系统将第N层节点或第N层子系统对应的第(N-1)层全局梯度下发给至少一个第(N-1)层节点,并逐层下发至第1层节点,以供第1层节点根据第(N-1)层全局梯度更新模型。
本公开实施例提供的联邦学习方法,以通信指标为权重指标来计算全局梯度,由于通信指标对于运营商来说是比较有价值的数据指标,因此基于以通信指标为权重指标来计算的全局梯度进行模型训练得到的模型训练结果对于运营商来说是最优结果,从而提高了优化效果。
下面通过几个示例说明本公开实施例的联邦学习方法的具体实现过程,所列举的示例仅仅是为了说明方便,并不用于限定本公开实施例的保护范围。
示例1
本示例描述基于两层联邦学习系统进行两层联邦学习过程。
如图7所示,两层联邦学习系统包括:EMS、一个虚拟NCCN、一个NCCN和四个NE。
其中,虚拟NCCN设置在EMS中,虚拟NCCN下连接有两个NE,分别为NE1和NE2;NCCN连接至EMS,NCCN下连接有两个NE,分别为NE3和NE4。
其中,EMS包括:业务应用、第一任务管理模块、第一全局模型管理模块和权重指标管理模块;虚拟NCCN包括:第二任务管理模块和第二全局模型管理模块;NCCN包括:第三任务管理模块和第三全局模型管理模块。
其中,NE1、NE2、NE3、NE4、NCCN和虚拟NCCN用于实现第1 层联邦学习过程,NCCN、虚拟NCCN和EMS用于实现第2层联邦学习过程。
基于上述两层联邦学习系统的两层联邦学习方法包括:
1.对于未连接到NCCN的NE1和NE2,在EMS中按照业务特征设置虚拟NCCN,把NE1和NE2按照业务特征连接至对应的虚拟NCCN上。
2.在EMS的权重指标管理模块中设置EMS对应的第2层权重指标。例如,如果运营商关注运营收益,则可设置第2层权重指标为:话务量、或上下行流量、或话务量和上下行流量的加权平均。
3.在EMS的权重指标管理模块中按照不同领域的业务特点设置不同的NCCN对应的第1层权重指标,不同的NCCN对应的第1层权重指标可能相同,也可能不同。例如,对于自动驾驶,设置对应的第1层权重指标为平均时延;对于体育场馆,设置对应的第1层权重指标为话务量;对于科技园,设置对应的第1层权重指标为上下行流量。本示例中,虚拟NCCN所属的区域属于自动驾驶区域,整网要求以时延为主,设置虚拟NCCN对应的第1层权重指标为平均时延;NCCN所属的区域属于体育场馆区域,整网要求以话务为主,设置NCCN对应的第1层权重指标为话务量。
4.业务应用向第一任务管理发起业务联邦学习过程请求,并告知训练的基站范围。第一任务管理模块从EMS的权重指标管理模块中获取第2层权重指标、虚拟NCCN对应的第1层权重指标和NCCN对应的第1层权重指标,将第2层权重指标、虚拟NCCN对应的第1层权重指标,放置在联邦学习任务中一起下发给虚拟NCCN的第二任务管理模块;将第2层权重指标、NCCN对应的第1层权重指标,放置在联邦学习任务中一起下发给NCCN的第三任务管理模块。
5.虚拟NCCN的第二任务管理模块接收到携带第2层权重指标、虚拟NCCN对应的第1层权重指标的联邦学习任务,将第2层权重指标、虚拟NCCN对应的第1层权重指标放置到联邦学习任务中,下发给NE1和NE2;NCCN的第三任务管理模块接收到携带第2层权重指标、NCCN对应的第1层权重指标的联邦学习任务,将第2层权重指标、NCCN对应的第1层 权重指标放置到联邦学习任务中,下发给NE3和NE4。
6.NE1根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据虚拟NCCN对应的第1层权重指标获取NE1对应的第1层权重指标值;根据第2层权重指标获取NE1对应的第2层权重指标值;使用加密,DP或秘密共享技术对NE1对应的更新的梯度进行隐私保护处理得到NE1对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE1对应的第1层权重指标值进行隐私保护处理得到NE1对应的隐私保护处理后的第1层权重指标值,使用加密,DP或秘密共享技术对NE1对应的第2层权重指标值进行隐私保护处理得到NE1对应的隐私保护处理后的第2层权重指标值;将NE1对应的隐私保护处理后的梯度、NE1对应的隐私保护处理后的第1层权重指标值和NE1对应的隐私保护处理后的第2层权重指标值上报给虚拟NCCN的第二全局模型管理模块。
7.NE2根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据虚拟NCCN对应的第1层权重指标获取NE2对应的第1层权重指标值;根据第2层权重指标获取NE2对应的第2层权重指标值;使用加密,DP或秘密共享技术对NE2对应的更新的梯度进行隐私保护处理得到NE2对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE2对应的第1层权重指标值进行隐私保护处理得到NE2对应的隐私保护处理后的第1层权重指标值,使用加密,DP或秘密共享技术对NE2对应的第2层权重指标值进行隐私保护处理得到NE2对应的隐私保护处理后的第2层权重指标值;将NE2对应的隐私保护处理后的梯度、NE2对应的隐私保护处理后的第1层权重指标值和NE2对应的隐私保护处理后的第2层权重指标值上报给虚拟NCCN的第二全局模型管理模块。
8.NE3根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据NCCN对应的第1层权重指标获取NE3对应的第1层权重指标值;根据第2层权重指标获取NE3对应的第2层权重指标值;使用加密,DP或秘密共享技术对NE3对应的更新的梯度进行隐私保护处理得到NE3对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE3 对应的第1层权重指标值进行隐私保护处理得到NE3对应的隐私保护处理后的第1层权重指标值,使用加密,DP或秘密共享技术对NE3对应的第2层权重指标值进行隐私保护处理得到NE3对应的隐私保护处理后的第2层权重指标值;将NE3对应的隐私保护处理后的梯度、NE3对应的隐私保护处理后的第1层权重指标值和NE3对应的隐私保护处理后的第2层权重指标值上报给NCCN的第三全局模型管理模块。
9.NE4根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据NCCN对应的第1层权重指标获取NE4对应的第1层权重指标值;根据第2层权重指标获取NE3对应的第2层权重指标值;使用加密,DP或秘密共享技术对NE4对应的更新的梯度进行隐私保护处理得到NE4对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE4对应的第1层权重指标值进行隐私保护处理得到NE4对应的隐私保护处理后的第1层权重指标值,使用加密,DP或秘密共享技术对NE4对应的第2层权重指标值进行隐私保护处理得到NE4对应的隐私保护处理后的第2层权重指标值;将NE4对应的隐私保护处理后的梯度、NE4对应的隐私保护处理后的第1层权重指标值和NE4对应的隐私保护处理后的第2层权重指标值上报给虚拟NCCN的第三全局模型管理模块。
10.虚拟NCCN的第二全局模型管理模块对NE1对应的隐私保护处理后的梯度进行去隐私保护处理得到NE1对应的更新的梯度,对NE1对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE1对应的第1层权重指标值,对NE1对应的隐私保护处理后的第2层权重指标值进行去隐私保护处理得到NE1对应的第2层权重指标值;虚拟NCCN的第二全局模型管理模块对NE2对应的隐私保护处理后的梯度进行去隐私保护处理得到NE2对应的更新的梯度,对NE2对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE2对应的第1层权重指标值,对NE2对应的隐私保护处理后的第2层权重指标值进行去隐私保护处理得到NE2对应的第2层权重指标值;虚拟NCCN的第二全局模型管理模块按 照公式GRA
12=GRA
111KPI
111+GRA
121KPI
121计算虚拟NCCN对应的更新的第1层全局梯度;其中,GRA
12为虚拟NCCN对应的更新的第1层全局梯度,GRA
111为NE1对应的更新的梯度,KPI
111为NE1对应的第1层权重指标值,GRA
121为NE2对应的更新的梯度,KPI
121为NE2对应的第1层权重指标值;将虚拟NCCN对应的更新的第1层全局梯度、NE1对应的第2层权重指标值和NE2对应的第2层权重指标值上报给EMS的第一全局模型管理模块。
11.NCCN的第三全局模型管理模块对NE3对应的隐私保护处理后的梯度进行去隐私保护处理得到NE3对应的更新的梯度,对NE3对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE3对应的第1层权重指标值,对NE3对应的隐私保护处理后的第2层权重指标值进行去隐私保护处理得到NE3对应的第2层权重指标值;NCCN的第三全局模型管理模块对NE4对应的隐私保护处理后的梯度进行去隐私保护处理得到NE4对应的更新的梯度,对NE4对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE4对应的第1层权重指标值,对NE4对应的隐私保护处理后的第2层权重指标值进行去隐私保护处理得到NE4对应的第2层权重指标值;NCCN的第三全局模型管理模块按照公式GRA
22=GRA
231KPI
231+GRA
241KPI
241计算NCCN对应的更新的第1层全局梯度;其中,GRA
22为NCCN对应的更新的第1层全局梯度,GRA
231为NE3对应的更新的梯度,KPI
231为NE3对应的第1层权重指标值,GRA
241为NE4对应的更新的梯度,KPI
241为NE4对应的第1层权重指标值;将NCCN对应的更新的第1层全局梯度、NE3对应的第2层权重指标值和NE4对应的第2层权重指标值上报给EMS的第一全局模型管理模块。
12.EMS的第一全局模型管理模块根据NE1对应的第2层权重指标值和NE2对应的第2层权重指标值计算虚拟NCCN对应的第2层权重指标值;根据NE3对应的第2层权重指标值和NE4对应的第2层权重指标值计算NCCN对应的第2层权重指标值;按照公式 GRA
3=GRA
312KPI
312+GRA
322KPI
322计算EMS对应的第2层全局梯度;其中,GRA
3为EMS对应的第2层全局梯度,GRA
312为虚拟NCCN对应的第1层全局梯度,KPI
312为虚拟NCCN对应的第2层权重指标值,GRA
322为NCCN对应的第1层全局梯度,KPI
322为NCCN对应的第2层权重指标值;将EMS对应的第2层全局梯度下发给虚拟NCCN的第二全局模型管理模块和NCCN的第三全局模型管理模块。
13.虚拟NCCN的第二全局模型管理模块将EMS对应的第2层全局梯度下发给NE1和NE2,NCCN的第三全局模型管理模块将EMS对应的第2层全局梯度下发给NE3和NE4;NE1、NE2、NE3和NE4根据EMS对应的第2层全局梯度更新模型。
示例2
本示例描述基于两层联邦学习系统进行第1层联邦学习过程。
如图7所示,两层联邦学习系统包括:EMS、一个虚拟NCCN、一个NCCN和四个NE。
其中,虚拟NCCN设置在EMS中,虚拟NCCN下连接有两个NE,分别为NE1和NE2;NCCN连接至EMS,NCCN下连接有两个NE,分别为NE3和NE4。
其中,EMS包括:业务应用、第一任务管理模块、第一全局模型管理模块和权重指标管理模块;虚拟NCCN包括:第二任务管理模块和第二全局模型管理模块;NCCN包括:第三任务管理模块和第三全局模型管理模块。
其中,NE1、NE2、NE3、NE4、NCCN和虚拟NCCN用于实现第1层联邦学习过程,NCCN、虚拟NCCN和EMS用于实现第2层联邦学习过程。
基于上述两层联邦学习系统的第1层联邦学习方法包括:
1.对于未连接到NCCN的NE1和NE2,在EMS中按照业务特征设置虚拟NCCN,把NE1和NE2按照业务特征连接到对应的虚拟NCCN上。
2.在EMS的权重指标管理模块中设置EMS对应的第2层权重指标。例如,如果运营商关注运营收益,则可设置第2层权重指标为:话务量、或上下行流量、或话务量和上下行流量的加权平均。
3.在EMS的权重指标管理模块中按照不同领域的业务特点设置不同的NCCN对应的第1层权重指标,不同的NCCN对应的第1层权重指标可能相同,也可能不同。例如,对于自动驾驶,设置对应的第1层权重指标为平均时延;对于体育场馆,设置对应的第1层权重指标为话务量;对于科技园,设置对应的第1层权重指标为上下行流量。本示例中,虚拟NCCN所属的区域属于自动驾驶区域,整网要求以时延为主,设置虚拟NCCN对应的第1层权重指标为平均时延;NCCN所属的区域属于体育场馆区域,整网要求以话务为主,设置NCCN对应的第1层权重指标为话务量。
4.业务应用向第一任务管理发起业务联邦学习过程请求,并告知训练的基站范围。第一任务管理模块从EMS的权重指标管理模块中获取虚拟NCCN对应的第1层权重指标和NCCN对应的第1层权重指标,将虚拟NCCN对应的第1层权重指标,放置在联邦学习任务中一起下发给虚拟NCCN的第二任务管理模块;将NCCN对应的第1层权重指标,放置在联邦学习任务中一起下发给NCCN的第三任务管理模块。
5.虚拟NCCN的第二任务管理模块接收到携带虚拟NCCN对应的第1层权重指标的联邦学习任务,将虚拟NCCN对应的第1层权重指标放置到联邦学习任务中,下发给NE1和NE2;NCCN的第三任务管理模块接收到携带NCCN对应的第1层权重指标的联邦学习任务,将NCCN对应的第1层权重指标放置到联邦学习任务中,下发给NE3和NE4。
6.NE1根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据虚拟NCCN对应的第1层权重指标获取NE1对应的第1层权重指标值;使用加密,DP或秘密共享技术对NE1对应的更新的梯度进行隐私保护处理得到NE1对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE1对应的第1层权重指标值进行隐私保护处理得到NE1对应的隐私保护处理后的第1层权重指标值;将NE1对应的隐私保护 处理后的梯度和NE1对应的隐私保护处理后的第1层权重指标值上报给虚拟NCCN的第二全局模型管理模块。
7.NE2根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据虚拟NCCN对应的第1层权重指标获取NE2对应的第1层权重指标值;使用加密,DP或秘密共享技术对NE2对应的更新的梯度进行隐私保护处理得到NE2对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE2对应的第1层权重指标值进行隐私保护处理得到NE2对应的隐私保护处理后的第1层权重指标值;将NE2对应的隐私保护处理后的梯度和NE2对应的隐私保护处理后的第1层权重指标值上报给虚拟NCCN的第二全局模型管理模块。
8.NE3根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据NCCN对应的第1层权重指标获取NE3对应的第1层权重指标值;使用加密,DP或秘密共享技术对NE3对应的更新的梯度进行隐私保护处理得到NE3对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE3对应的第1层权重指标值进行隐私保护处理得到NE3对应的隐私保护处理后的第1层权重指标值;将NE3对应的隐私保护处理后的梯度和NE3对应的隐私保护处理后的第1层权重指标值上报给NCCN的第三全局模型管理模块。
9.NE4根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据NCCN对应的第1层权重指标获取NE4对应的第1层权重指标值;使用加密,DP或秘密共享技术对NE4对应的更新的梯度进行隐私保护处理得到NE4对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE4对应的第1层权重指标值进行隐私保护处理得到NE4对应的隐私保护处理后的第1层权重指标值;将NE4对应的隐私保护处理后的梯度和NE4对应的隐私保护处理后的第1层权重指标值上报给虚拟NCCN的第三全局模型管理模块。
10.虚拟NCCN的第二全局模型管理模块对NE1对应的隐私保护处理后的梯度进行去隐私保护处理得到NE1对应的更新的梯度,对NE1对 应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE1对应的第1层权重指标值;虚拟NCCN的第二全局模型管理模块对NE2对应的隐私保护处理后的梯度进行去隐私保护处理得到NE2对应的更新的梯度,对NE2对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE2对应的第1层权重指标值;虚拟NCCN的第二全局模型管理模块按照公式GRA
12=GRA
111KPI
111+GRA
121KPI
121计算虚拟NCCN对应的更新的第1层全局梯度;其中,GRA
12为虚拟NCCN对应的更新的第1层全局梯度,GRA
111为NE1对应的更新的梯度,KPI
111为NE1对应的第1层权重指标值,GRA
121为NE2对应的更新的梯度,KPI
121为NE2对应的第1层权重指标值;将虚拟NCCN对应的更新的第1层全局梯度下发给NE1和NE2;NE1和NE2根据虚拟NCCN对应的更新的第1层全局梯度更新模型。
11.NCCN的第三全局模型管理模块对NE3对应的隐私保护处理后的梯度进行去隐私保护处理得到NE3对应的更新的梯度,对NE3对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE3对应的第1层权重指标值;NCCN的第三全局模型管理模块对NE4对应的隐私保护处理后的梯度进行去隐私保护处理得到NE4对应的更新的梯度,对NE4对应的隐私保护处理后的第1层权重指标值进行去隐私保护处理得到NE4对应的第1层权重指标值;NCCN的第三全局模型管理模块按照公式
计算NCCN对应的更新的第1层全局梯度;其中,GRA
22为NCCN对应的更新的第1层全局梯度,GRA
231为NE3对应的更新的梯度,KPI
231为NE3对应的第1层权重指标值,GRA
241为NE4对应的更新的梯度,KPI
241为NE4对应的第1层权重指标值;将NCCN对应的更新的第1层全局梯度下发给NE3和NE4;NE3和NE4根据NCCN对应的更新的第1层全局梯度更新模型。
示例3
本示例描述基于两层联邦学习系统进行两层联邦学习过程。
如图7所示,两层联邦学习系统包括:EMS、一个虚拟NCCN、一个NCCN和四个NE。
其中,虚拟NCCN设置在EMS中,虚拟NCCN下连接有两个NE,分别为NE1和NE2;NCCN连接至EMS,NCCN下连接有两个NE,分别为NE3和NE4。
其中,EMS包括:业务应用、第一任务管理模块、第一全局模型管理模块和权重指标管理模块;虚拟NCCN包括:第二任务管理模块和第二全局模型管理模块;NCCN包括:第三任务管理模块和第三全局模型管理模块。
其中,NE1、NE2、NE3、NE4、NCCN和虚拟NCCN用于实现第1层联邦学习过程,NCCN、虚拟NCCN和EMS用于实现第2层联邦学习过程。
基于上述两层联邦学习系统的两层联邦学习方法包括:
1.对于未连接到NCCN的NE1和NE2,在EMS中按照业务特征设置虚拟NCCN,把NE1和NE2按照业务特征连接到对应的虚拟NCCN上。
2.在EMS的权重指标管理模块中设置第2层权重指标和第1层权重指标相同(本示例中称为全局权重指标)。例如,如果运营商关注运营收益,则可设置全局权重指标为:话务量、或上下行流量、或话务量和上下行流量的加权平均。
3.业务应用向第一任务管理发起业务联邦学习过程请求,并告知训练的基站范围。第一任务管理模块从EMS的权重指标管理模块中获取全局权重指标,将全局权重指标放置在联邦学习任务中一起下发给虚拟NCCN的第二任务管理模块和NCCN的第三任务管理模块。
4.虚拟NCCN的第二任务管理模块接收到携带全局权重指标的联邦学习任务,将全局权重指标放置到联邦学习任务中,下发给NE1和NE2;NCCN的第三任务管理模块接收到携带全局权重指标的联邦学习任务,将全局权重指标放置到联邦学习任务中,下发给NE3和NE4。
5.NE1根据联邦学习任务采用本地数据进行模型训练得到对应的更 新的梯度;根据全局权重指标获取NE1对应的全局权重指标值;使用加密,DP或秘密共享技术对NE1对应的更新的梯度进行隐私保护处理得到NE1对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE1对应的全局权重指标值进行隐私保护处理得到NE1对应的隐私保护处理后的全局权重指标值;将NE1对应的隐私保护处理后的梯度、NE1对应的隐私保护处理后的全局权重指标值上报给虚拟NCCN的第二全局模型管理模块。
6.NE2根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE2对应的全局权重指标值;使用加密,DP或秘密共享技术对NE2对应的更新的梯度进行隐私保护处理得到NE2对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE2对应的全局权重指标值进行隐私保护处理得到NE2对应的隐私保护处理后的全局权重指标值;将NE2对应的隐私保护处理后的梯度、NE2对应的隐私保护处理后的全局权重指标值上报给虚拟NCCN的第二全局模型管理模块。
7.NE3根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE3对应的全局权重指标值;使用加密,DP或秘密共享技术对NE3对应的更新的梯度进行隐私保护处理得到NE3对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE3对应的全局权重指标值进行隐私保护处理得到NE3对应的隐私保护处理后的全局权重指标值;将NE3对应的隐私保护处理后的梯度、NE3对应的隐私保护处理后的全局权重指标值上报给NCCN的第三全局模型管理模块。
8.NE4根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE4对应的全局权重指标值;使用加密,DP或秘密共享技术对NE4对应的更新的梯度进行隐私保护处理得到NE4对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE4对应的全局权重指标值进行隐私保护处理得到NE4对应的隐私保护处理后的全局权重指标值;将NE4对应的隐私保护处理后的梯度、NE4对应的隐私保护处理后的全局权重指标值上报给NCCN的第三全局模型管理模块。
9.虚拟NCCN的第二全局模型管理模块对NE1对应的隐私保护处理 后的梯度进行去隐私保护处理得到NE1对应的更新的梯度,对NE1对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE1对应的全局权重指标值;虚拟NCCN的第二全局模型管理模块对NE2对应的隐私保护处理后的梯度进行去隐私保护处理得到NE2对应的更新的梯度,对NE2对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE2对应的全局权重指标值;虚拟NCCN的第二全局模型管理模块按照公式GRA
12=GRA
111KPI
111+GRA
121KPI
121计算虚拟NCCN对应的更新的第1层全局梯度;其中,GRA
12为虚拟NCCN对应的更新的第1层全局梯度,GRA
111为NE1对应的更新的梯度,KPI
111为NE1对应的全局权重指标值,GRA
121为NE2对应的更新的梯度,KPI
121为NE2对应的全局权重指标值;将虚拟NCCN对应的更新的第1层全局梯度、NE1对应的全局权重指标值和NE2对应的全局权重指标值上报给EMS的第一全局模型管理模块。
10.NCCN的第三全局模型管理模块对NE3对应的隐私保护处理后的梯度进行去隐私保护处理得到NE3对应的更新的梯度,对NE3对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE3对应的全局权重指标值;NCCN的第三全局模型管理模块对NE4对应的隐私保护处理后的梯度进行去隐私保护处理得到NE4对应的更新的梯度,对NE4对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE4对应的全局权重指标值;NCCN的第三全局模型管理模块按照公式GRA
22=GRA
231KPI
231+GRA
241KPI
241计算NCCN对应的更新的第1层全局梯度;其中,GRA
22为NCCN对应的更新的第1层全局梯度,GRA
231为NE3对应的更新的梯度,KPI
231为NE3对应的全局权重指标值,GRA
241为NE4对应的更新的梯度,KPI
241为NE4对应的全局权重指标值;将NCCN对应的更新的第1层全局梯度、NE3对应的全局权重指标值和NE4对应的全局权重指标值上报给EMS的第一全局模型管理模块。
11.EMS的第一全局模型管理模块根据NE1对应的全局权重指标值和NE2对应的全局权重指标值计算虚拟NCCN对应的全局权重指标值;根据 NE3对应的全局权重指标值和NE4对应的全局权重指标值计算NCCN对应的全局权重指标值;按照公式GRA
3=GRA
312KPI
312+GRA
322KPI
322计算EMS对应的第2层全局梯度;其中,GRA
3为EMS对应的第2层全局梯度,GRA
312为虚拟NCCN对应的第1层全局梯度,KPI
312为虚拟NCCN对应的全局权重指标值,GRA
322为NCCN对应的第1层全局梯度,KPI
322为NCCN对应的全局权重指标值;将EMS对应的第2层全局梯度下发给虚拟NCCN的第二全局模型管理模块和NCCN的第三全局模型管理模块。
12.虚拟NCCN的第二全局模型管理模块将EMS对应的第2层全局梯度下发给NE1和NE2,NCCN的第三全局模型管理模块将EMS对应的第2层全局梯度下发给NE3和NE4;NE1、NE2、NE3和NE4根据EMS对应的第2层全局梯度更新模型。
示例4
本示例描述基于两层联邦学习系统进行第1层联邦学习过程。
如图7所示,两层联邦学习系统包括:EMS、一个虚拟NCCN、一个NCCN和四个NE。
其中,虚拟NCCN设置在EMS中,虚拟NCCN下连接有两个NE,分别为NE1和NE2;NCCN连接至EMS,NCCN下连接有两个NE,分别为NE3和NE4。
其中,EMS包括:业务应用、第一任务管理模块、第一全局模型管理模块和权重指标管理模块;虚拟NCCN包括:第二任务管理模块和第二全局模型管理模块;NCCN包括:第三任务管理模块和第三全局模型管理模块。
其中,NE1、NE2、NE3、NE4、NCCN和虚拟NCCN用于实现第1层联邦学习过程,NCCN、虚拟NCCN和EMS用于实现第2层联邦学习过程。
基于上述两层联邦学习系统的第1层联邦学习方法包括:
1.对于未连接到NCCN的NE1和NE2,在EMS中按照业务特征设置 虚拟NCCN,把NE1和NE2按照业务特征连接到对应的虚拟NCCN上。
2.在EMS的权重指标管理模块中设置第2层权重指标和第1层权重指标相同(本示例中称为全局权重指标)。例如,如果运营商关注运营收益,则可设置全局权重指标为:话务量、或上下行流量、或话务量和上下行流量的加权平均。
3.业务应用向第一任务管理发起业务联邦学习过程请求,并告知训练的基站范围。第一任务管理模块从EMS的权重指标管理模块中获取全局权重指标,将全局权重指标,放置在联邦学习任务中一起下发给虚拟NCCN的第二任务管理模块和NCCN的第三任务管理模块。
4.虚拟NCCN的第二任务管理模块接收到携带全局权重指标的联邦学习任务,将全局权重指标放置到联邦学习任务中,下发给NE1和NE2;NCCN的第三任务管理模块接收到携带全局权重指标的联邦学习任务,将全局权重指标放置到联邦学习任务中,下发给NE3和NE4。
5.NE1根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE1对应的全局权重指标值;使用加密,DP或秘密共享技术对NE1对应的更新的梯度进行隐私保护处理得到NE1对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE1对应的全局权重指标值进行隐私保护处理得到NE1对应的隐私保护处理后的全局权重指标值;将NE1对应的隐私保护处理后的梯度和NE1对应的隐私保护处理后的全局权重指标值上报给虚拟NCCN的第二全局模型管理模块。
6.NE2根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE2对应的全局权重指标值;使用加密,DP或秘密共享技术对NE2对应的更新的梯度进行隐私保护处理得到NE2对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE2对应的全局权重指标值进行隐私保护处理得到NE2对应的隐私保护处理后的全局权重指标值;将NE2对应的隐私保护处理后的梯度和NE2对应的隐私保护处理后的全局权重指标值上报给虚拟NCCN的第二全局模型管理模 块。
7.NE3根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据NCCN对应的全局权重指标获取NE3对应的全局权重指标值;使用加密,DP或秘密共享技术对NE3对应的更新的梯度进行隐私保护处理得到NE3对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE3对应的全局权重指标值进行隐私保护处理得到NE3对应的隐私保护处理后的全局权重指标值;将NE3对应的隐私保护处理后的梯度和NE3对应的隐私保护处理后的全局权重指标值上报给NCCN的第三全局模型管理模块。
8.NE4根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据NCCN对应的全局权重指标获取NE4对应的全局权重指标值;使用加密,DP或秘密共享技术对NE4对应的更新的梯度进行隐私保护处理得到NE4对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE4对应的全局权重指标值进行隐私保护处理得到NE4对应的隐私保护处理后的全局权重指标值;将NE4对应的隐私保护处理后的梯度和NE4对应的隐私保护处理后的全局权重指标值上报给虚拟NCCN的第三全局模型管理模块。
9.虚拟NCCN的第二全局模型管理模块对NE1对应的隐私保护处理后的梯度进行去隐私保护处理得到NE1对应的更新的梯度,对NE1对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE1对应的全局权重指标值;虚拟NCCN的第二全局模型管理模块对NE2对应的隐私保护处理后的梯度进行去隐私保护处理得到NE2对应的更新的梯度,对NE2对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE2对应的全局权重指标值;虚拟NCCN的第二全局模型管理模块按照公式GRA
12=GRA
111KPI
111+GRA
121KPI
121计算虚拟NCCN对应的更新的第1层全局梯度;其中,GRA
12为虚拟NCCN对应的更新的第1层全局梯度,GRA
111为NE1对应的更新的梯度,KPI
111为NE1对应的全局权重指标值, GRA
121为NE2对应的更新的梯度,KPI
121为NE2对应的全局权重指标值;将虚拟NCCN对应的更新的第1层全局梯度下发给NE1和NE2;NE1和NE2根据虚拟NCCN对应的更新的第1层全局梯度更新模型。
10.NCCN的第三全局模型管理模块对NE3对应的隐私保护处理后的梯度进行去隐私保护处理得到NE3对应的更新的梯度,对NE3对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE3对应的全局权重指标值;NCCN的第三全局模型管理模块对NE4对应的隐私保护处理后的梯度进行去隐私保护处理得到NE4对应的更新的梯度,对NE4对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE4对应的全局权重指标值;NCCN的第三全局模型管理模块按照公式GRA
22=GRA
231KPI
231+GRA
241KPI
241计算NCCN对应的更新的第1层全局梯度;其中,GRA
22为NCCN对应的更新的第1层全局梯度,GRA
231为NE3对应的更新的梯度,KPI
231为NE3对应的全局权重指标值,GRA
241为NE4对应的更新的梯度,KPI
241为NE4对应的全局权重指标值;将NCCN对应的更新的第1层全局梯度下发给NE3和NE4;NE3和NE4根据NCCN对应的更新的第1层全局梯度更新模型。
示例5
本示例描述基于单层联邦学习系统进行单层联邦学习过程。
如图8所示,单层联邦学习系统包括:EMS、NE1和NE2;NE1和NE2均连接到EMS。
其中,EMS包括:业务应用、任务管理模块、全局模型管理模块和权重指标管理模块。
其中,EMS、NE1、NE2用于实现单层联邦学习过程。
基于上述单层联邦学习系统的单层联邦学习方法包括:
1.在EMS的权重指标管理模块中设置全局权重指标。例如,如果运营商关注运营收益,则可设置全局权重指标为:话务量、或上下行流量、或话务量和上下行流量的加权平均。
2.业务应用向任务管理发起业务联邦学习过程请求,并告知训练的基站范围。任务管理模块从EMS的权重指标管理模块中获取全局权重指标,将全局权重指标,放置在联邦学习任务中一起下发给NE1和NE2。
3.NE1根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE1对应的全局权重指标值;使用加密,DP或秘密共享技术对NE1对应的更新的梯度进行隐私保护处理得到NE1对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE1对应的全局权重指标值进行隐私保护处理得到NE1对应的隐私保护处理后的全局权重指标值;将NE1对应的隐私保护处理后的梯度和NE1对应的隐私保护处理后的全局权重指标值上报给EMS的全局模型管理模块。
4.NE2根据联邦学习任务采用本地数据进行模型训练得到对应的更新的梯度;根据全局权重指标获取NE2对应的全局权重指标值;使用加密,DP或秘密共享技术对NE2对应的更新的梯度进行隐私保护处理得到NE2对应的隐私保护处理后的梯度,使用加密,DP或秘密共享技术对NE2对应的全局权重指标值进行隐私保护处理得到NE2对应的隐私保护处理后的全局权重指标值;将NE2对应的隐私保护处理后的梯度和NE2对应的隐私保护处理后的全局权重指标值上报给EMS的全局模型管理模块。
5.EMS的全局模型管理模块对NE1对应的隐私保护处理后的梯度进行去隐私保护处理得到NE1对应的更新的梯度,对NE1对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE1对应的全局权重指标值;EMS的全局模型管理模块对NE2对应的隐私保护处理后的梯度进行去隐私保护处理得到NE2对应的更新的梯度,对NE2对应的隐私保护处理后的全局权重指标值进行去隐私保护处理得到NE2对应的全局权重指标值;EMS的全局模型管理模块按照公式GRA
3=GRA
1KPI
1+GRA
2KPI
2计算更新的全局梯度;其中,GRA
3为更新的全局梯度,GRA
1为NE1对应的更新的梯度,KPI
1为NE1对应的全局权重指标值,GRA
2为NE2对应的更新的梯度,KPI
2为NE2对应的全局权重指标值;将更新的全局梯度下发 给NE1和NE2;NE1和NE2根据更新的全局梯度更新模型。
第四方面,本公开实施例提供一种电子设备,包括:
至少一个处理器;
存储器,存储器上存储有至少一个程序,当至少一个程序被至少一个处理器执行,使得至少一个处理器实现上述任意一种联邦学习方法。
其中,处理器为具有数据处理能力的器件,其包括但不限于中央处理器(CPU)等;存储器为具有数据存储能力的器件,其包括但不限于随机存取存储器(RAM,更具体如SDRAM、DDR等)、只读存储器(ROM)、带电可擦可编程只读存储器(EEPROM)、闪存(FLASH)。
在一些实施例中,处理器、存储器通过总线相互连接,进而与计算设备的其它组件连接。
第五方面,本公开实施例提供一种计算机可读存储介质,计算机可读存储介质上存储有计算机程序,计算机程序被处理器执行时实现上述任意一种联邦学习方法。
图9为本公开另一个实施例提供的联邦学习装置的组成框图。
第六方面,参照图9,本公开另一个实施例提供一种联邦学习装置(如第i层节点,i为大于或等于2,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数),该装置包括:
第一通信模块901,被配置为接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;
第一计算模块902,被配置为根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;其中,第(i-1)层权重指标为通信指标。
在一些示例性实施例中,第一通信模块901还被配置为:
接收到第(i+1)层节点发送的联邦学习任务,将联邦学习任务下发给第i层节点下的至少一个第(i-1)层节点。
在一些示例性实施例中,通信指标包括以下至少一个:平均时延、话务量、上下行流量、话务量和上下行流量的加权平均。
在一些示例性实施例中,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。
在一些示例性实施例中,若所述i等于2,第(i-1)层节点对应的第一梯度为第(i-1)层节点根据联邦学习任务进行模型训练得到的更新的梯度;
若i大于2,且小于或等于(N-1),第(i-1)层节点对应的第一梯度为所述第(i-1)层节点对应的更新的第(i-2)层全局梯度。
在一些示例性实施例中,第一计算模块902具体被配置为:
根据第i层节点对应的第(i-1)层权重指标获取至少一个第(i-1)层节点对应的第(i-1)层权重指标值;以至少一个第(i-1)层节点对应的第(i-1)层权重指标值为权重,计算至少一个第(i-1)层节点对应的第一梯度的加权平均值,得到第i层节点对应的更新的第(i-1)层全局梯度。
在一些示例性实施例中,第一通信模块901还被配置为:
将第i层节点对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点。
在一些示例性实施例中,第一通信模块901还被配置为:
将第i层节点对应的更新的第(i-1)层全局梯度上报给第(i+1)层节点;接收第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个下发给第(i-1)层节点。
上述联邦学习装置的具体实现过程与前述实施例的联邦学习方法的具体实现过程相同,这里不再赘述。
图10为本公开另一个实施例提供的联邦学习装置的组成框图。
第七方面,参照图10,本公开另一个实施例提供一种联邦学习装置(如第1层节点),该装置包括:
第二通信模块1001,被配置为将第1层节点对应的更新的梯度上报给第2层节点;接收第2层节点发送的更新的第j层全局梯度;其中,第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对 应的第j层权重指标计算得到;第j层权重指标为通信指标;j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
在一些示例性实施例中,还包括:
模型训练更新模块1002,被配置为根据更新的第j层全局梯度更新模型。
在一些示例性实施例中,第二通信模块1001还被配置为:
接收第2层节点发送的联邦学习任务。
在一些示例性实施例中,若j等于1,第j层节点对应的第一梯度为第j层节点对应的更新的梯度;
若j大于1,且小于或等于(N-1),第j层节点对应的第一梯度为第j层节点对应的更新的第(j-1)层全局梯度。
在一些示例性实施例中,通信指标包括以下至少一个:平均时延、话务量、上下行流量、所述话务量和所述上下行流量的加权平均。
在一些示例性实施例中,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。
上述联邦学习装置的具体实现过程与前述实施例的联邦学习方法的具体实现过程相同,这里不再赘述。
图11为本公开另一个实施例提供的联邦学习装置的组成框图。
第八方面,参照图11,本公开另一个实施例提供一种联邦学习装置(如第N层节点,(N-1)为联邦学习的层数),该装置包括:
第三通信模块1101,被配置为接收到第N层节点下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度;
第二计算模块1102,被配置为根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点对应的第(N-1)层全局梯度;其中,第(N-1)层权重指标为通信指标。
在一些示例性实施例中,第三通信模块1101还被配置为:向第N层节点下的至少一个第(N-1)层节点下发联邦学习任务。
在一些示例性实施例中,第三通信模块1101还被配置为:将第N层节点对应的第(N-1)层全局梯度下发给至少一个第(N-1)层节点。
在一些示例性实施例中,通信指标包括以下至少一个:平均时延、话务量、上下行流量、所述话务量和所述上下行流量的加权平均。
上述联邦学习装置的具体实现过程与前述实施例的联邦学习方法的具体实现过程相同,这里不再赘述。
第九方面,本公开另一个实施例提供一种联邦学习系统,包括:
第N层节点或第N层子系统,被配置为接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度;根据至少一个第(N-1)层节点对应的第(N-2)层全局梯度和第(N-1)层权重指标计算第N层节点或第N层子系统对应的第(N-1)层全局梯度;其中,第(N-1)层权重指标为通信指标;将第N层节点或第N层子系统对应的第(N-1)层全局梯度下发给至少一个第(N-1)层节点;其中,(N-1)为联邦学习的层数;
第i层节点,被配置为接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;根据至少一个所述第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度;其中,第(i-1)层权重指标为通信指标;
第i层节点还被配置为:
将第i层节点对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点;或者,将第i层节点对应的更新的第(i-1)层全局梯度上报给第(i+1)层节点;接收第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个下发给第(i-1)层节点;
第1层节点,被配置为将第1层节点对应的更新的梯度上报给第2层节点;接收第2层节点发送的更新的第j层全局梯度;其中,第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到;第j层权重指标为通信指标;第j层权重指标为通信 指标;j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
在一些示例性实施例中,第1层节点还被配置为:进行模型训练得到第1层节点对应的更新的梯度;根据更新的第j层全局梯度更新模型。
在一些示例性实施例中,通信指标包括以下至少一个:平均时延、话务量、上下行流量、话务量和上下行流量的加权平均。
在一些示例性实施例中,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。
在一些示例性实施例中,若i等于2,第(i-1)层节点对应的第一梯度为所述第(i-1)层节点根据联邦学习任务进行模型训练得到的更新的梯度;
若i大于2,且小于或等于(N-1),第(i-1)层节点对应的第一梯度为所述第(i-1)层节点对应的更新的第(i-2)层全局梯度。
在一些示例性实施例中,若j等于1,第j层节点对应的第一梯度为第j层节点对应的更新的梯度;
若j大于1,且小于或等于(N-1),第j层节点对应的第一梯度为第j层节点对应的更新的第(j-1)层全局梯度。
在一些示例性实施例中,第i层节点具体被配置为采用以下方式实现根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度:
根据第i层节点对应的第(i-1)层权重指标获取至少一个第(i-1)层节点对应的第(i-1)层权重指标值;
以至少一个第(i-1)层节点对应的第(i-1)层权重指标值为权重,计算至少一个第(i-1)层节点对应的第一梯度的加权平均值,得到第i层节点对应的更新的第(i-1)层全局梯度。
在一些示例性实施例中,第i层节点还被配置为:将第i层节点对应的更新的第(i-1)层全局梯度下发给第(i-1)层节点。
在一些示例性实施例中,第i层节点还被配置为:
将第i层节点对应的更新的第(i-1)层全局梯度上报给第(i+1)层节点;
接收第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将更新的第i层全局梯度到所述更新的第(N-1)层全局梯度中的任意一个下发给第(i-1)层节点。
上述联邦学习系统的具体实现过程与前述实施例的联邦学习方法的具体实现过程相同,这里不再赘述。
本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统、装置中的功能模块/单元可以被实施为软件、固件、硬件及其适当的组合。在硬件实施方式中,在以上描述中提及的功能模块/单元之间的划分不一定对应于物理组件的划分;例如,一个物理组件可以具有多个功能,或者一个功能或步骤可以由若干物理组件合作执行。某些物理组件或所有物理组件可以被实施为由处理器,如中央处理器、数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分布在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其它数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其它存储器技术、CD-ROM、数字多功能盘(DVD)或其它光盘存储、磁盒、磁带、磁盘存储或其它磁存储器、或者可以用于存储期望的信息并且可以被计算机访问的任何其它的介质。此外,本领域普通技术人员公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其它传输机制之类的调制数据信号中的其它数据,并且可包括任何信息递送介质。
本文已经公开了示例实施例,并且虽然采用了具体术语,但它们仅用于并仅应当被解释为一般说明性含义,并且不用于限制的目的。在一些实例中,对本领域技术人员显而易见的是,除非另外明确指出,否则可单独 使用与特定实施例相结合描述的特征、特性和/或元素,或可与其它实施例相结合描述的特征、特性和/或元件组合使用。因此,本领域技术人员将理解,在不脱离由所附的权利要求阐明的本公开的范围的情况下,可进行各种形式和细节上的改变。
Claims (16)
- 一种联邦学习方法,应用于第i层节点,所述i为大于或等于2,且小于或等于(N-1)的整数中的任意一个,所述(N-1)为联邦学习的层数,该方法包括:接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;以及根据至少一个所述第(i-1)层节点对应的所述第一梯度和所述第i层节点对应的第(i-1)层权重指标计算所述第i层节点对应的更新的第(i-1)层全局梯度;其中,所述第(i-1)层权重指标为通信指标。
- 根据权利要求1所述的联邦学习方法,其中,所述通信指标包括以下至少一个:平均时延、话务量、上下行流量、所述话务量和所述上下行流量的加权平均。
- 根据权利要求1所述的联邦学习方法,其中,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。
- 根据权利要求1所述的联邦学习方法,其中,若所述i等于2,所述第(i-1)层节点对应的所述第一梯度为所述第(i-1)层节点进行模型训练得到的更新的梯度;若所述i大于2,且小于或等于(N-1),所述第(i-1)层节点对应的所述第一梯度为所述第(i-1)层节点对应的更新的第(i-2)层全局梯度。
- 根据权利要求1所述的联邦学习方法,其中,所述根据至少一 个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度包括:根据所述第i层节点对应的所述第(i-1)层权重指标获取至少一个所述第(i-1)层节点对应的第(i-1)层权重指标值;以至少一个所述第(i-1)层节点对应的第(i-1)层权重指标值为权重,计算至少一个所述第(i-1)层节点对应的所述第一梯度的加权平均值,得到所述第i层节点对应的所述更新的第(i-1)层全局梯度。
- 根据权利要求1-5任一项所述的联邦学习方法,所述根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度之后,该方法还包括:将所述第i层节点对应的所述更新的第(i-1)层全局梯度下发给所述第(i-1)层节点。
- 根据权利要求1-5任一项所述的联邦学习方法,所述根据至少一个第(i-1)层节点对应的第一梯度和第i层节点对应的第(i-1)层权重指标计算第i层节点对应的更新的第(i-1)层全局梯度之后,该方法还包括:将所述第i层节点对应的所述更新的第(i-1)层全局梯度上报给所述第(i+1)层节点;接收所述第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将所述更新的第i层全局梯度到所述更新的第(N-1)层全局梯度中的任意一个下发给所述第(i-1)层节点。
- 一种联邦学习方法,应用于第1层节点,该方法包括:将所述第1层节点对应的更新的梯度上报给第2层节点;接收所述第2层节点发送的更新的第j层全局梯度;其中,所述第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到;所述第j层权重指标为通信指标;所述j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
- 根据权利要求8所述的联邦学习方法,其中,若j等于1,所述第j层节点对应的第一梯度为所述第j层节点对应的更新的梯度;若j大于1,且小于或等于(N-1),所述第j层节点对应的第一梯度为所述第j层节点对应的更新的第(j-1)层全局梯度。
- 根据权利要求8所述的联邦学习方法,其中,所述通信指标包括以下至少一个:平均时延、话务量、上下行流量、所述话务量和所述上下行流量的加权平均。
- 根据权利要求8所述的联邦学习方法,同一层的不同节点对应的权重指标相同或不同,不同层的不同节点对应的权重指标相同或不同。
- 一种联邦学习方法,应用于第N层节点或第N层子系统,(N-1)为联邦学习的层数,该方法包括:接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度;根据至少一个所述第(N-1)层节点对应的所述第(N-2)层全局梯度和第(N-1)层权重指标计算所述第N层节点或所述第N层子系统对应的第(N-1)层全局梯度;其中,所述第(N-1)层权重指标为通信指标。
- 根据权利要求12所述的联邦学习方法,其中,所述通信指标包括以下至少一个:平均时延、话务量、上下行流量、所述话务量和所述上下行流量的加权平均。
- 一种电子设备,包括:至少一个处理器;存储器,所述存储器上存储有至少一个程序,当所述至少一个程序被所述至少一个处理器执行,使得所述至少一个处理器实现根据权利要求1-13任意一项所述的联邦学习方法。
- 一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时实现根据权利要求1-13任意一项所述的联邦学习方法。
- 一种联邦学习系统,包括:第N层节点或第N层子系统,被配置为接收到第N层节点或第N层子系统下的至少一个第(N-1)层节点上报的对应的第(N-2)层全局梯度;根据至少一个所述第(N-1)层节点对应的所述第(N-2)层全局梯度和第(N-1)层权重指标计算所述第N层节点或所述第N层子系统对应的第(N-1)层全局梯度;其中,所述第(N-1)层权重指标为通信指标;将所述第N层节点或所述第N层子系统对应的所述第(N-1)层全局梯度下发给至少一个所述第(N-1)层节点;其中,(N-1)为联邦学习的层数;第i层节点,被配置为接收到第i层节点下的至少一个第(i-1)层节点上报的对应的第一梯度;根据至少一个所述第(i-1)层节点对应的所述第一梯度和所述第i层节点对应的第(i-1)层权重指标计算 所述第i层节点对应的更新的第(i-1)层全局梯度;其中,所述第(i-1)层权重指标为通信指标;所述第i层节点还被配置为:将所述第i层节点对应的所述更新的第(i-1)层全局梯度下发给所述第(i-1)层节点;或者,将所述第i层节点对应的所述更新的第(i-1)层全局梯度上报给所述第(i+1)层节点;接收所述第(i+1)层节点发送的更新的第i层全局梯度到更新的第(N-1)层全局梯度中的任意一个,将所述更新的第i层全局梯度到所述更新的第(N-1)层全局梯度中的任意一个下发给所述第(i-1)层节点;第1层节点,被配置为将所述第1层节点对应的更新的梯度上报给所述第2层节点;接收所述第2层节点发送的更新的第j层全局梯度;其中,所述第j层全局梯度根据至少一个第j层节点对应的第一梯度和第(j+1)层节点对应的第j层权重指标计算得到;所述第j层权重指标为通信指标;所述第j层权重指标为通信指标;所述j为大于或等于1,且小于或等于(N-1)的整数中的任意一个,(N-1)为联邦学习的层数。
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| US18/016,470 US20230281508A1 (en) | 2020-07-17 | 2021-07-15 | Federated learning method, apparatus and system, electronic device and storage medium |
| EP21841778.0A EP4184361A4 (en) | 2020-07-17 | 2021-07-15 | FEDERATED LEARNING METHOD, DEVICE AND SYSTEM, ELECTRONIC DEVICE AND STORAGE MEDIUM |
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202010695940.2 | 2020-07-17 | ||
| CN202010695940.2A CN113282933B (zh) | 2020-07-17 | 2020-07-17 | 联邦学习方法、装置和系统、电子设备、存储介质 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2022012621A1 true WO2022012621A1 (zh) | 2022-01-20 |
Family
ID=77275594
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2021/106469 Ceased WO2022012621A1 (zh) | 2020-07-17 | 2021-07-15 | 联邦学习方法、装置和系统、电子设备、存储介质 |
Country Status (4)
| Country | Link |
|---|---|
| US (1) | US20230281508A1 (zh) |
| EP (1) | EP4184361A4 (zh) |
| CN (1) | CN113282933B (zh) |
| WO (1) | WO2022012621A1 (zh) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN114726706A (zh) * | 2022-04-15 | 2022-07-08 | 河海大学 | 一种面向多层无线网络联邦学习的模型同步方法及系统 |
| CN115146292A (zh) * | 2022-06-16 | 2022-10-04 | 上海富数科技有限公司广州分公司 | 一种树模型构建方法、装置、电子设备及存储介质 |
| CN115859344A (zh) * | 2022-04-19 | 2023-03-28 | 西安电子科技大学 | 基于秘密共享的联邦无人机群数据安全共享方法 |
Families Citing this family (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN114492841B (zh) | 2022-01-28 | 2025-03-25 | 中国银联股份有限公司 | 一种模型梯度更新方法及装置 |
| US12505382B2 (en) * | 2022-08-30 | 2025-12-23 | Google Llc | Hybrid federated learning of machine learning model(s) |
| US20240421950A1 (en) * | 2023-03-20 | 2024-12-19 | Qualcomm Incorporated | Non-coherent combining for full gradients transmission in federated learning |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20150324690A1 (en) * | 2014-05-08 | 2015-11-12 | Microsoft Corporation | Deep Learning Training System |
| CN110728376A (zh) * | 2019-10-21 | 2020-01-24 | 深圳前海微众银行股份有限公司 | 一种基于树状拓扑结构的联邦学习方法及装置 |
| CN111062493A (zh) * | 2019-12-20 | 2020-04-24 | 深圳前海微众银行股份有限公司 | 基于公共数据的纵向联邦方法、装置、设备及介质 |
Family Cites Families (17)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101621404B (zh) * | 2008-07-05 | 2012-07-18 | 中兴通讯股份有限公司 | 一种故障分层处理方法和系统 |
| EP3622438A4 (en) * | 2017-05-09 | 2021-03-10 | Neurala, Inc. | SYSTEMS AND PROCEDURES TO ENABLE CONTINUOUS MEMORY-LIMITED LEARNING IN ARTIFICIAL INTELLIGENCE AND DEEP LEARNING, CONTINUOUSLY WORKING APPLICATIONS VIA NETWORKED COMPUTER EDGES |
| CN108804715A (zh) * | 2018-07-09 | 2018-11-13 | 北京邮电大学 | 融合视听感知的多任务协同识别方法及系统 |
| CN109189825B (zh) * | 2018-08-10 | 2022-03-15 | 深圳前海微众银行股份有限公司 | 横向数据切分联邦学习建模方法、服务器及介质 |
| US12052145B2 (en) * | 2018-12-07 | 2024-07-30 | Telefonaktiebolaget Lm Ericsson (Publ) | Predicting network communication performance using federated learning |
| US11010637B2 (en) * | 2019-01-03 | 2021-05-18 | International Business Machines Corporation | Generative adversarial network employed for decentralized and confidential AI training |
| CN109919313B (zh) * | 2019-01-31 | 2021-06-08 | 华为技术有限公司 | 一种梯度传输的方法及分布式训练系统 |
| CN109871702B (zh) * | 2019-02-18 | 2024-06-28 | 深圳前海微众银行股份有限公司 | 联邦模型训练方法、系统、设备及计算机可读存储介质 |
| CN110399742B (zh) * | 2019-07-29 | 2020-12-18 | 深圳前海微众银行股份有限公司 | 一种联邦迁移学习模型的训练、预测方法及装置 |
| CN110610242B (zh) * | 2019-09-02 | 2023-11-14 | 深圳前海微众银行股份有限公司 | 一种联邦学习中参与者权重的设置方法及装置 |
| CN110719158B (zh) * | 2019-09-11 | 2021-11-23 | 南京航空航天大学 | 基于联合学习的边缘计算隐私保护系统及保护方法 |
| CN110909865B (zh) * | 2019-11-18 | 2022-08-30 | 福州大学 | 边缘计算中基于分层张量分解的联邦学习方法 |
| CN111176929B (zh) * | 2019-11-29 | 2023-04-18 | 广东工业大学 | 一种面向边缘联邦学习的高能效计算通信联合优化方法 |
| CN110955907B (zh) * | 2019-12-13 | 2022-03-25 | 支付宝(杭州)信息技术有限公司 | 一种基于联邦学习的模型训练方法 |
| CN111245903B (zh) * | 2019-12-31 | 2022-07-01 | 烽火通信科技股份有限公司 | 一种基于边缘计算的联合学习方法及系统 |
| CN111310932B (zh) * | 2020-02-10 | 2024-09-27 | 深圳前海微众银行股份有限公司 | 横向联邦学习系统优化方法、装置、设备及可读存储介质 |
| CN111260061B (zh) * | 2020-03-09 | 2022-07-19 | 厦门大学 | 联邦学习梯度交换中的差异化加噪方法及系统 |
-
2020
- 2020-07-17 CN CN202010695940.2A patent/CN113282933B/zh active Active
-
2021
- 2021-07-15 US US18/016,470 patent/US20230281508A1/en active Pending
- 2021-07-15 WO PCT/CN2021/106469 patent/WO2022012621A1/zh not_active Ceased
- 2021-07-15 EP EP21841778.0A patent/EP4184361A4/en active Pending
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20150324690A1 (en) * | 2014-05-08 | 2015-11-12 | Microsoft Corporation | Deep Learning Training System |
| CN110728376A (zh) * | 2019-10-21 | 2020-01-24 | 深圳前海微众银行股份有限公司 | 一种基于树状拓扑结构的联邦学习方法及装置 |
| CN111062493A (zh) * | 2019-12-20 | 2020-04-24 | 深圳前海微众银行股份有限公司 | 基于公共数据的纵向联邦方法、装置、设备及介质 |
Non-Patent Citations (1)
| Title |
|---|
| See also references of EP4184361A4 * |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN114726706A (zh) * | 2022-04-15 | 2022-07-08 | 河海大学 | 一种面向多层无线网络联邦学习的模型同步方法及系统 |
| CN114726706B (zh) * | 2022-04-15 | 2023-03-14 | 河海大学 | 一种面向多层无线网络联邦学习的模型同步方法及系统 |
| CN115859344A (zh) * | 2022-04-19 | 2023-03-28 | 西安电子科技大学 | 基于秘密共享的联邦无人机群数据安全共享方法 |
| CN115146292A (zh) * | 2022-06-16 | 2022-10-04 | 上海富数科技有限公司广州分公司 | 一种树模型构建方法、装置、电子设备及存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| US20230281508A1 (en) | 2023-09-07 |
| EP4184361A1 (en) | 2023-05-24 |
| CN113282933B (zh) | 2022-03-01 |
| EP4184361A4 (en) | 2024-08-07 |
| CN113282933A (zh) | 2021-08-20 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| WO2022012621A1 (zh) | 联邦学习方法、装置和系统、电子设备、存储介质 | |
| US20250028996A1 (en) | An adaptive personalized federated learning method supporting heterogeneous model | |
| CN109167787B (zh) | 一种移动边缘计算网络中安全计算卸载的资源优化方法 | |
| CN114827198A (zh) | 一种应用于车联网的多层中心异步联邦学习方法 | |
| CN113518007B (zh) | 一种基于联邦学习的多物联网设备异构模型高效互学习方法 | |
| CN111585811B (zh) | 一种基于多智能体深度强化学习的虚拟光网络映射方法 | |
| WO2022222110A1 (zh) | 应用于移动通信系统的联邦学习方法、装置、终端及介质 | |
| CN108810846B (zh) | 一种基于城市公共交通的车载网络群感知覆盖方法 | |
| CN109117856A (zh) | 基于智能边缘云的人及物追踪方法、装置及系统 | |
| CN106506360B (zh) | 一种基于链路动态负载的光纤网络均衡路由方法 | |
| CN117499995A (zh) | 基站算力编排方法、装置、电子设备及存储介质 | |
| CN113285960B (zh) | 一种服务数据共享云平台的数据加密方法及系统 | |
| Li et al. | Parameter Estimation of $ M_ {t}/M/1/K $ Queueing Systems With Utilization Data | |
| CN118095410A (zh) | 神经网络架构搜索的联邦学习参数高效微调方法及装置 | |
| CN117648994A (zh) | 一种基于无监督学习的高效异构纵向联邦学习方法 | |
| WO2022083549A1 (zh) | 流量信号转换方法、装置、电子设备及存储介质 | |
| CN110826019A (zh) | 一种基于隐马尔科夫模型的空间频谱状态预测方法 | |
| CN118780348A (zh) | 一种用于无线边缘网络的大模型分布式微调联邦分割学习方法、系统及介质 | |
| CN114116233B (zh) | 基于ap聚类算法和多目标优化算法的边缘服务器配置方法及系统 | |
| CN116708440A (zh) | 分布式训练的通信方法、系统和相关设备 | |
| WO2024033341A1 (en) | Methods and apparatuses for controlling federated learning being performed by a flock of wireless devices | |
| CN113222318B (zh) | 分布式的星上自主任务规划方法、系统及存储介质 | |
| CN116846754A (zh) | 联邦学习的策略管理方法及装置、计算机可存储介质 | |
| CN111708936B (zh) | 基于相似性传播策略的Web服务推荐系统及方法 | |
| FR2999030A1 (fr) | Procede de zonage dynamique d'un reseau de distribution electrique |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 21841778 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| ENP | Entry into the national phase |
Ref document number: 2021841778 Country of ref document: EP Effective date: 20230216 |


