CN-121998033-A - Federal learning method, device, network equipment, medium and program product
Abstract
The invention provides a federal learning method, a federal learning device, network equipment, media and program products, and relates to the technical field of federal learning. The method comprises the steps of obtaining a first sub-model and a second sub-model corresponding to each second network element according to a model segmentation point segmentation model, sending corresponding model segmentation information to the second network elements, obtaining a trained second sub-model sent by the second network elements, wherein the trained second sub-model is obtained by training the second network elements according to first model parameters, the first model parameters are obtained by training the first sub-model by the first network elements, and obtaining a model trained by the first network elements according to the trained second sub-model and sending the model to a third network element. According to the scheme, the federal learning is performed through the three-layer federal learning architecture and the model segmentation points, so that wireless resources are fully utilized, and the calculation efficiency and the training efficiency are improved.
Inventors
- LIU CHUNHUI
- ZHANG KAI
- SUN QI
Assignees
- 中国移动通信有限公司研究院
- 中国移动通信集团有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20241101
Claims (20)
- 1. A federal learning method, applied to a first network element, the method comprising: for each second network element, a first sub-model and a second sub-model corresponding to the second network element are obtained according to a model segmentation point segmentation model, wherein the model segmentation point is determined according to the resource information of the first network element and the link information of the second network element, the first sub-model is arranged on the first network element, and the second sub-model is arranged on the second network element; Transmitting corresponding model segmentation information to the second network element, wherein the model segmentation information is used for indicating the first sub-model and the second sub-model; Acquiring a trained second sub-model sent by the second network element, wherein the trained second sub-model is obtained by training the second network element according to a first model parameter, and the first model parameter is obtained by training the first sub-model by the first network element; and obtaining the trained model of the first network element according to the trained second sub-model, and sending the trained model of the first network element to a third network element.
- 2. The federal learning method according to claim 1, wherein obtaining the first network element trained model from the trained second sub-model comprises: Combining the trained first sub-model and the trained second sub-model to obtain a model trained by the second network element, wherein the trained first sub-model is obtained according to the first model parameters; And aggregating at least one model trained by the second network element to obtain a model trained by the first network element.
- 3. The federal learning method according to claim 1, wherein before obtaining, for each second network element, a first sub-model and a second sub-model corresponding to the second network element according to a model partitioning point partitioning model, the method further comprises: Acquiring a first request, wherein the first request is used for requesting federal learning; According to the first request, a second request is sent to at least one second network element, wherein the second request is used for requesting the second network element to participate in federal learning; And acquiring first feedback information sent by at least one second network element, wherein the first feedback information is used for indicating the second network element to agree to participate in federal learning.
- 4. A federal learning method according to claim 3, wherein transmitting a second request to at least one of the second network elements in accordance with the first request comprises: Determining at least one second network element participating in federal learning according to network element restriction information in the first request, wherein the network element restriction information is used for indicating the second network element participating in federal learning; And sending a second request to at least one second network element.
- 5. The federal learning method according to claim 1, wherein obtaining the trained second sub-model transmitted by the second network element comprises: acquiring a second model parameter sent by the second network element, wherein the second model parameter is obtained by the second network element through forward propagation training of the second sub-model according to network element data; performing forward propagation and backward propagation training on the first sub-model according to the second model parameters to obtain the first model parameters; Transmitting the first model parameters to the second network element; And acquiring a trained second sub-model sent by the second network element, wherein the trained second sub-model is obtained by the second network element through back propagation training of the second sub-model according to the first model parameters.
- 6. The federal learning method according to claim 1, wherein obtaining the trained second sub-model transmitted by the second network element comprises: acquiring a third request sent by a first target network element, wherein the third request is sent according to a fourth request sent by the second network element, and the third request and the fourth request are used for requesting the second network element to continue federal learning; Acquiring a second model parameter of the second network element forwarded by the first target network element, wherein the second model parameter is obtained by the second network element performing forward propagation training on the second sub-model according to network element data; performing forward propagation and backward propagation training on the first sub-model according to the second model parameters to obtain the first model parameters; Transmitting the first model parameters to the first target network element; And acquiring a second sub-model which is forwarded by the first target network element and trained by the second network element.
- 7. The federal learning method according to claim 6, wherein the third request is sent in the event of a handoff of the first network element corresponding to the second network element, the method further comprising one of: Sending a first notification to the second network element; Acquiring a first notification sent by the second network element; The first notification is used for indicating that a first network element corresponding to the second network element is about to be switched.
- 8. The federal learning method according to claim 1, wherein the method further comprises: Transmitting a fifth request to the third network element when the first network element has temporary resource occupation, wherein the fifth request is used for requesting to transfer federal learning; Transmitting a sixth request to a second target network element, wherein the second target network element is determined by the third network element according to the resource information of at least one first network element except the first network element, and the sixth request is used for requesting federal learning and comprises second model parameters of the second network element; and acquiring the first model parameter sent by the second target network element, wherein the first model parameter is obtained by training the first sub-model by the second target network element according to the second model parameter.
- 9. The federal learning method according to claim 1, wherein the method further comprises: Acquiring a seventh request sent by the second network element, wherein the seventh request is used for requesting to exit federal learning; and sending an eighth request to the third network element, wherein the eighth request is used for requesting the second network element to exit federal learning, and the third network element updates the credit score and the network element restriction information of the second network element according to the eighth request.
- 10. A federal learning method, applied to a third network element, the method comprising: Acquiring a trained model sent by at least one first network element; And aggregating the trained models sent by at least one first network element to obtain an aggregated model.
- 11. The federal learning method according to claim 10, wherein prior to obtaining the trained model transmitted by the at least one first network element, the method further comprises: Acquiring resource information sent by a plurality of first network elements and link information sent by a plurality of second network elements; determining at least one first network element and at least one second network element participating in federal learning according to the resource information of the plurality of first network elements and the link information of the plurality of second network elements; And sending a first request to at least one first network element.
- 12. The federal learning method according to claim 11, wherein prior to sending the first request to at least one of the first network elements, the method further comprises: obtaining a target request, wherein the target request comprises one of the following: A federal learning request sent by the second network element; A federal learning request sent by the first network element; a model request sent by the second network element; a model request sent by the first network element; And judging whether the model indicated by the target request needs federal learning or not according to the target request.
- 13. The federal learning method according to claim 11, wherein the method further comprises: acquiring an eighth request sent by the first network element, wherein the eighth request is used for requesting the second network element to exit federal learning; Updating the credit score of the second network element according to the eighth request; and updating the network element limit information under the condition that the credit score of the second network element is smaller than the credit threshold value.
- 14. A federal learning method, for use with a second network element, the method comprising: obtaining model segmentation information sent by a first network element, wherein the model segmentation information is used for indicating a first sub-model and a second sub-model corresponding to the second network element; training the second sub-model according to a first model parameter, wherein the first model parameter is obtained by training the first sub-model by the first network element; and sending the trained second sub-model to the first network element.
- 15. The federal learning method according to claim 14, wherein prior to obtaining the model segmentation information transmitted by the first network element, the method further comprises: sending a target request; acquiring a second request sent by the first network element; Sending first feedback information to the first network element, wherein the first feedback information is used for indicating the second network element to agree to participate in federal learning; wherein the sending the target request includes one of: Transmitting a first request to the first network element, wherein the first request is used for requesting federal learning; sending a federal learning request to a third network element; sending a model request to the first network element; And sending a model request to the third network element.
- 16. The federal learning method according to claim 14, wherein training the second sub-model according to the first model parameters to obtain a trained second sub-model comprises: performing forward propagation training on the second sub-model according to the network element data to obtain second model parameters; And carrying out back propagation training on the second sub-model according to the first model parameters to obtain a trained second sub-model.
- 17. The federal learning method according to claim 16, wherein training the second sub-model according to the first model parameters to obtain a trained second sub-model comprises: Under the condition that a first network element corresponding to the second network element is switched, a fourth request is sent to a first target network element, wherein the fourth request is used for requesting the second network element to continue federal learning; Transmitting second model parameters to the first target network element, wherein the second model parameters are obtained by performing forward propagation training on the second sub-model according to network element data; acquiring a first model parameter forwarded by the first target network element; And carrying out back propagation training on the second sub-model according to the first model parameters to obtain a trained second sub-model.
- 18. The federal learning method according to claim 16, wherein before the handoff occurs to the first network element corresponding to the second network element, the method further comprises one of: Acquiring a first notification sent by the first network element; Sending a first notification to the first network element; The first notification is used for indicating that a first network element corresponding to the second network element is about to be switched.
- 19. A federal learning apparatus for use with a first network element, the apparatus comprising: The first acquisition module is used for acquiring a first sub-model and a second sub-model corresponding to each second network element according to a model partitioning point partitioning model, wherein the model partitioning point is determined according to the resource information of the first network element and the link information of the second network element, the first sub-model is arranged on the first network element, and the second sub-model is arranged on the second network element; the first sending module is used for sending corresponding model segmentation information to the second network element, wherein the model segmentation information is used for indicating the first sub-model and the second sub-model; The second obtaining module is used for obtaining a trained second sub-model sent by the second network element, wherein the trained second sub-model is obtained by the second network element through training the second sub-model according to a first model parameter, and the first model parameter is obtained by the first network element through training the first sub-model; and the second sending module is used for obtaining the model trained by the first network element according to the trained second sub-model and sending the model trained by the first network element to a third network element.
- 20. A federal learning apparatus for use with a third network element, the apparatus comprising: a third obtaining module, configured to obtain a trained model sent by at least one first network element; The first obtaining module is used for aggregating the trained models sent by at least one first network element to obtain aggregated models.
Description
Federal learning method, device, network equipment, medium and program product Technical Field The present invention relates to the field of federal learning technologies, and in particular, to a federal learning method, apparatus, network device, medium, and program product. Background In artificial intelligence applications, machine learning models, including convolutional neural networks or deep neural networks, are trained using rich data generated by network edges (e.g., sensors and internet of things devices), the principle of which is to update parameters of the model to minimize errors in the output results, and finally to build a mapping function to predict unknown data. Data is often privacy sensitive (such as medical and financial data) and therefore businesses or individuals may refuse to share their data to service providers for centralized training. To ensure data privacy and security, a distributed machine learning technique, federal learning, is currently provided. Federal learning enables model training using local data for multiple participants and each of the multiple participants without disclosing local data for each participant. Each participant trains its own model locally and contributes the model to the alliance center to train a model jointly, and the center opens the model again for each participant to use. However, due to the limited computing and communication capabilities of the device, federal learning techniques suffer from computational inefficiency in wireless/edge networks and inefficiency of federal learning systems. Disclosure of Invention The invention aims to provide a federal learning method, a federal learning device, a federal learning network device, a federal learning medium and a federal learning program product, which are used for solving the problems of low calculation efficiency and low efficiency of a federal learning system in a wireless/edge network in the prior art. To achieve the above object, the present invention is achieved by: in a first aspect, an embodiment of the present invention provides a federal learning method, applied to a first network element, the method including: for each second network element, a first sub-model and a second sub-model corresponding to the second network element are obtained according to a model segmentation point segmentation model, wherein the model segmentation point is determined according to the resource information of the first network element and the link information of the second network element, the first sub-model is arranged on the first network element, and the second sub-model is arranged on the second network element; Transmitting corresponding model segmentation information to the second network element, wherein the model segmentation information is used for indicating the first sub-model and the second sub-model; Acquiring a trained second sub-model sent by the second network element, wherein the trained second sub-model is obtained by training the second network element according to a first model parameter, and the first model parameter is obtained by training the first sub-model by the first network element; and obtaining the trained model of the first network element according to the trained second sub-model, and sending the trained model of the first network element to a third network element. Optionally, the federal learning method, wherein obtaining the trained model of the first network element according to the trained second sub-model includes: Combining the trained first sub-model and the trained second sub-model to obtain a model trained by the second network element, wherein the trained first sub-model is obtained according to the first model parameters; And aggregating at least one model trained by the second network element to obtain a model trained by the first network element. Optionally, before the federal learning method, for each second network element, the method further includes, before obtaining the first sub-model and the second sub-model of the second network element according to a model segmentation point segmentation model: Acquiring a first request, wherein the first request is used for requesting federal learning; According to the first request, a second request is sent to at least one second network element, wherein the second request is used for requesting the second network element to participate in federal learning; And acquiring first feedback information sent by at least one second network element, wherein the first feedback information is used for indicating the second network element to agree to participate in federal learning. Optionally, the federal learning method, wherein sending, according to the first request, a second request to at least one second network element includes: Determining at least one second network element participating in federal learning according to network element restriction information in the first request, wherein the network element restricti