An Asynchronous Federated Learning Method, Device and Storage Medium for Heterogeneous Scenarios
By determining the client with the highest autocorrelation entropy in asynchronous federated learning for training, and combining the multi-period hierarchical update strategy and weight decay strategy, the problems of data heterogeneity and communication delay in heterogeneous scenarios are solved, achieving high accuracy and low communication cost.
Patent Information
- Application Number
- CN202111250303.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-26
- Publication Date
- 2025-07-01
- Estimated Expiration
- 2041-10-26
AI Technical Summary
Asynchronous federated learning faces data heterogeneity and communication delay problems in heterogeneous scenarios, making it difficult to simultaneously improve model accuracy and reduce communication costs.
By determining the target client with the highest autocorrelation entropy from the candidate clients for training, uploading the target parameters to the server, and using a multi-period hierarchical update strategy, a time weight decay strategy and an information weight enhancement strategy for model aggregation and evaluation.
Improve the accuracy and convergence speed of the asynchronous federated learning global model, while reducing communication costs.
Smart Images

Figure CN114037089B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of artificial intelligence, and in particular to an asynchronous federated learning method, device and storage medium for heterogeneous scenarios. Background Art
[0002] With the rapid development of the Internet of Things, a multi-functional network has been created to connect a large number of devices in various fields such as transportation, healthcare, and administration to support diverse data perception and service experience improvement. However, since user information has become sensitive, the mode of centrally collecting data in a data center may violate laws and regulations related to data security and privacy protection, causing the data processing paradigm to shift from centralized data integration to distributed parameter aggregation.
[0003] To eliminate data islands caused by data security and data privacy, a decentralized mechanism called federated learning has been proposed. This mechanism trains a global model by using the local data and computing resources of each learning participant without sharing the original data. Federated learning can work in a synchronous environment, that is, all learning participants have the same work plan. Asynchronous federated learning, which allows participants to participate in training relatively independently without being restricted by other participants, is more suitable for ubiquitous heterogeneous Internet of Things systems.
[0004] Since current research is usually carried out in a synchronous environment, asynchronous federated learning still faces many challenges. First, since the generation of local data usually coincides with the behavior of users, the data may vary in terms of the 4V characteristics (i.e., Volume, Variety, Value, Velocity). Therefore, it is very difficult to select appropriate client data and solve the heterogeneity among local data to train a high-performance global model. Second, the running state of the selected clients may change over time and space. Therefore, the communication delay between the clients and the server should be minimized, learning intrusion should be reduced, and the delay problem when uploading local models should be effectively solved to improve the performance of model training.
[0005] To address these problems, existing solutions mostly improve the model accuracy by solving data heterogeneity and reduce the communication cost between the client and the server by compressing data packets. However, it is very difficult to simultaneously improve the accuracy and reduce the communication cost. Recently, a more advanced solution, that is, designing and jointly using a time-weighted aggregation strategy and a hierarchical model update strategy, enables the model to have better performance in terms of accuracy and convergence. However, how to integrate client activation, communication optimization, and aggregation enhancement strategies to effectively support asynchronous federated learning while improving the model accuracy and reducing the communication cost has not been deeply discussed. Summary of the Invention
[0006] In view of this, embodiments of the present invention provide an asynchronous federated learning method, apparatus and storage medium for heterogeneous scenarios to improve the model accuracy and reduce the communication cost.
[0007] One aspect of the present invention provides an asynchronous federated learning method for heterogeneous scenarios, including:
[0008] Determine a target client from candidate clients, where the self-correlation entropy of the target client is higher than that of other clients among the candidate clients;
[0009] Train the target client to obtain target parameters, and upload the target parameters to the server;
[0010] The server performs aggregation enhancement processing on the process of model aggregation according to the target parameters to obtain a first federated model;
[0011] Perform policy integration processing on the first federated model to obtain a second federated model;
[0012] Perform model evaluation on the second federated model to determine the target federated model.
[0013] Optionally, the determining a target client from candidate clients includes:
[0014] Obtain perception data from each client among the candidate clients;
[0015] Calculate the self-correlation entropy of each client according to the perception data obtained from each client;
[0016] Select the client with the highest self-correlation entropy from the candidate clients as the target client according to the self-correlation entropy of each client and the informative client activation policy.
[0017] Optionally, training the target client to obtain target parameters and uploading the target parameters to the server includes:
[0018] The target client obtains the current global model and local data for training to obtain target parameters;
[0019] The target client sends the target parameters to the server;
[0020] The server polls and waits to receive the target parameters sent by the client.
[0021] Optionally, the server performing aggregation enhancement processing on the process of model aggregation according to the target parameters to obtain a first federated model includes:
[0022] The server divides the communication into several cycles according to the multi-period hierarchical update strategy;
[0023] Optimize the update frequencies of the shallow and deep layers of the deep neural network during the model aggregation process;
[0024] According to the several cycles and the optimized update frequencies, perform model aggregation based on the target parameters to obtain a first federated model.
[0025] Optionally, perform policy integration processing on the first federated model to obtain a second federated model, including:
[0026] Perform policy integration processing on the first federated model according to the informative client activation policy, multi-cycle hierarchical update policy, time weight decay policy, and information weight enhancement policy to obtain a second federated model.
[0027] Optionally, perform model evaluation on the second federated model to determine the target federated model, including:
[0028] Calculate the accuracy and convergence speed of the global model under client activation to determine the optimal activation ratio;
[0029] Calculate the accuracy and convergence speed of the global model under communication optimization to determine the optimal communication cycle;
[0030] Calculate the accuracy and convergence speed of the global model under aggregation enhancement to determine whether to use information entropy or the number of labels in the local dataset;
[0031] Calculate the accuracy and convergence speed of the global model under the integration strategy to generate a model evaluation result.
[0032] Another aspect of the embodiments of the present invention provides an asynchronous federated learning device for heterogeneous scenarios, including:
[0033] A first module for determining a target client from candidate clients, where the self-correlation entropy of the target client is higher than that of other clients among the candidate clients;
[0034] A second module for training the target client to obtain target parameters and uploading the target parameters to the server;
[0035] A third module for the server to perform aggregation enhancement processing on the process of model aggregation according to the target parameters to obtain a first federated model;
[0036] A fourth module for performing policy integration processing on the first federated model to obtain a second federated model;
[0037] A fifth module for performing model evaluation on the second federated model to determine the target federated model.
[0038] On the other hand, an embodiment of the present invention provides an electronic device, including a processor and a memory;
[0039] The memory is used to store a program;
[0040] The processor executes the program to implement the method described above.
[0041] On the other hand, an embodiment of the present invention provides a computer-readable storage medium, where the storage medium stores a program, and the program is executed by a processor to implement the method described above.
[0042] On the other hand, an embodiment of the present invention provides a computer program product, including a computer program, and when the computer program is executed by a processor, it implements the method described above.
[0043] In the embodiment of the present invention, a target client is determined from candidate clients, where the autocorrelation entropy of the target client is higher than that of other clients among the candidate clients; the target client is trained to obtain target parameters, and the target parameters are uploaded to the server; the server performs aggregation enhancement processing on the process of model aggregation according to the target parameters to obtain a first federated model; performs policy integration processing on the first federated model to obtain a second federated model; and performs model evaluation on the second federated model to determine a target federated model. The present invention can improve the model accuracy and reduce the communication cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0045] Figure 1 It is the overall step flow chart provided by the embodiment of the present invention;
[0046] Figure 2 It is the accuracy curve graph of various ICA variables in MNIST of the three-stage asynchronous federated learning model provided by the embodiment of the present invention;
[0047] Figure 3 It is the accuracy growth graph of MLU(200,3,1) and MLU(200,15,5) in MNIST of the three-stage asynchronous federated learning model provided by the embodiment of the present invention;
[0048] Figure 4Accuracy curve of the three-stage asynchronous federated learning model provided by the embodiments of the present invention under the action of TWF, IWE-IE, and IWE-LN in MNIST;
[0049] Figure 5 Accuracy growth graph of various integration strategies of the three-step asynchronous federated learning model provided by the embodiments of the present invention in MNIST. Detailed implementation manners
[0050] In order to make the objectives, technical solutions and advantages of the present application more clear and understandable, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0051] Aiming at the problems existing in the prior art, the present invention proposes a three-stage asynchronous federated learning mechanism for heterogeneous scenarios, realizing the integration of client activation, communication optimization and aggregation enhancement strategies, while improving the model accuracy and reducing the communication cost to effectively support asynchronous federated learning, as Figure 1 shown, the method of the present invention includes the following steps:
[0052] Determine a target client from candidate clients, wherein the self-correlation entropy of the target client is higher than that of other clients among the candidate clients;
[0053] Train the target client to obtain target parameters, and upload the target parameters to the server;
[0054] The server performs aggregation enhancement processing on the process of model aggregation according to the target parameters to obtain a first federated model;
[0055] Perform policy integration processing on the first federated model to obtain a second federated model;
[0056] Perform model evaluation on the second federated model to determine a target federated model.
[0057] Optionally, the determining a target client from candidate clients includes:
[0058] Obtain perception data from each client among the candidate clients;
[0059] Calculate the self-correlation entropy of each client according to the perception data obtained from each client;
[0060] Select the client with the highest self-correlation entropy from the candidate clients as the target client according to the self-correlation entropy of each client and the informative client activation strategy.
[0061] Optionally, training the target client to obtain target parameters and uploading the target parameters to the server includes:
[0062] The target client obtains the current global model and local data for training to obtain target parameters;
[0063] The target client sends the target parameters to the server;
[0064] The server polls and waits to receive the target parameters sent by the client.
[0065] Optionally, the server performs aggregation enhancement processing on the model aggregation process according to the target parameters to obtain a first federated model, including:
[0066] The server divides the communication into several cycles according to a multi-period hierarchical update strategy;
[0067] Optimize the update frequencies of the shallow and deep layers of the deep neural network in the model aggregation process;
[0068] According to the several cycles and the optimized update frequencies, perform model aggregation according to the target parameters to obtain a first federated model.
[0069] Optionally, performing policy integration processing on the first federated model to obtain a second federated model includes:
[0070] Perform policy integration processing on the first federated model according to the informative client activation policy, multi-period hierarchical update policy, time weight decay policy, and information weight enhancement policy to obtain a second federated model.
[0071] Optionally, performing model evaluation on the second federated model to determine a target federated model includes:
[0072] Calculate the accuracy and convergence speed of the global model under the activation of the client to determine the optimal activation ratio;
[0073] Calculate the accuracy and convergence speed of the global model under the communication optimization to determine the optimal communication cycle;
[0074] Calculate the accuracy and convergence speed of the global model under the aggregation enhancement to determine the use of information entropy or the number of labels in the local dataset;
[0075] Calculate the accuracy and convergence speed of the global model under the integrated policy to generate a model evaluation result.
[0076] Another aspect of the embodiments of the present invention provides an asynchronous federated learning device for heterogeneous scenarios, including:
[0077] The first module is used to determine a target client from candidate clients, where the autocorrelation entropy of the target client is higher than that of other clients among the candidate clients;
[0078] The second module is used to train the target client to obtain target parameters and upload the target parameters to the server;
[0079] The third module is used for the server to perform aggregation enhancement processing on the process of model aggregation according to the target parameters to obtain a first federated model;
[0080] The fourth module is used to perform policy integration processing on the first federated model to obtain a second federated model;
[0081] The fifth module is used to evaluate the second federated model to determine a target federated model.
[0082] Another aspect of the embodiments of the present invention provides an electronic device, including a processor and a memory;
[0083] The memory is used to store a program;
[0084] The processor executes the program to implement the method as described above.
[0085] Another aspect of the embodiments of the present invention provides a computer-readable storage medium, where the storage medium stores a program, and the program is executed by a processor to implement the method as described above.
[0086] Another aspect of the embodiments of the present invention provides a computer program product, including a computer program, and the computer program implements the method as described above when executed by a processor.
[0087] The following combines the specification drawings to describe the specific implementation process of the present invention in detail:
[0088] Step 1: Client activation. Collect data in each client and calculate the autocorrelation entropy SRE of each client according to formula (1):
[0089]
[0090] where SRE k (D k,t ||D k,t-1 ) is the autocorrelation entropy between D k,t and D k,t-1 ; p i,t and p i,t-1 are the percentages of the i-th type of label in D k,t and D k,t-1 respectively; n is the total number of labels; c is a constant introduced to avoid infinite values.
[0091] Taking the self - related entropy SRE as the standard, ICA(α) is obtained according to formula (2), and the client with a higher self - related entropy is selected as the participant for training:
[0092]
[0093] Among them,
[0094] Among them, K0 is the total number of clients; is the normalized client activation index of client k in the t - th round of learning; Topk0() represents selecting the largest k0 clients from ; n k,t and are the data sizes of client k and all clients in the t - th round of learning respectively; CAI k represents the initial activation index of client k calculated by SRE k ; CAI t is the sum of CAI k ; α is the activation ratio, which is a hyper - parameter; among them, k0 = α×K0.
[0095] It should be noted that the perception data collected in step 1 of the embodiments of the present invention includes but is not limited to: 1) When an intelligent network - connected vehicle is used as a client, it dynamically perceives and collects the acceleration, speed data of the vehicle, as well as the image and voice data of the driver in the vehicle. The data can be used for driving behavior analysis, especially dangerous driving prediction; 2) When a mobile phone is used as a client, it dynamically perceives and collects the behavior data of users such as commodity browsing, collection, purchase, etc., as well as the attribute data such as age, gender, income, etc. The data can be used for a commodity recommendation system.
[0096] The informative client activation strategy provided by the embodiments of the present invention calculates the activation index according to the self - related entropy and the data volume, and takes the client with a high activation index as the client with rich information and the client for training.
[0097] Step 2, communication optimization. The activated clients perform local training and upload the obtained parameters to the server. The server waits and accepts the uploaded local model parameters. When aggregating the models in the server, a multi - cycle hierarchical update strategy (MLU) is introduced to optimize the update frequencies of the shallow and deep parameters of the DNN. MLU(M,m,n) represents dividing M rounds of communication into cycles. In each cycle, the deep layer is updated only in the last n communication rounds; the shallow layer is updated every m communication rounds.
[0098] It should be noted that the parameter types and functions of the target parameters obtained in the embodiments of the present invention include: 1) The weight parameters of the neural network, which are used to describe the local model; 2) Informative parameters such as the size of the local data volume, the model generation time, the information entropy, and the number of labels, which are used for global model aggregation.
[0099] Step 3: Aggregation enhancement. When performing model aggregation in the server, according to the configuration of MLU(M, m, n), there are two aggregation modes: (1) When the t-th round of communication within the MLU stage belongs to rounds 1 to m - n, the shallow layer is updated separately. (2) When the t-th round of communication within the MLU stage belongs to rounds m - n + 1 to m, the shallow layer and the deep layer are jointly updated. In both of the above modes, the asynchronous federated learning server aggregates two types of local parameters: (a) Parameters generated in the previous rounds of learning but not yet used; (b) Parameters generated and received in the current learning interaction. The heterogeneity of the time and information attributes of these two types of parameters may affect the performance of the global model and cannot be directly aggregated. Therefore, by designing and implementing a time weight decay strategy and an information weight enhancement strategy, the aggregation process is enhanced.
[0100] The time weight decay strategy is defined by formula (3). In the formula, k is the total number of clients participating in aggregation in the t-th round of communication; n t is the data size of all clients; is the normalized time weight of client k in the t-th round of communication; TW k,t is the initial weight, and and TW t ; r k represents the start time of the communication round when the parameters of client k are formed.
[0101]
[0102] Among them,
[0103] The information weight enhancement strategy is defined by formula (4). In the formula, IE k (D k,t ) is the information entropy of the local dataset D k,t of client k in the t-th round of communication; p i is the percentage of the i-th type of label in D k,t ; n is the total number of labels; LN k (D k,t ) is the number of labels of the local dataset D k,t ; L i represents the presence or absence of the i-th label, and its value is 1 or 0; is the normalized information weight of client k in the t-th round of communication; IW k,t is IE k (D k,t ) or LN k(D k,t Measured initial weight; IW t is the sum of IW k,t .
[0104]
[0105]
[0106] TWF can aggregate client parameters based on normalized weights, and its value decreases according to the difference between the generation and processing times of the parameters. IWE with LN or IE, identified as IWE-LN or IWE-IE, can enhance its weight according to the information richness of the relevant parameters.
[0107] Step 4, Policy integration. The four policy applications include: the application of the informative client activation policy in client activation, the application of the multi-cycle hierarchical update policy in communication optimization, the application of the time-weight decay policy in aggregation enhancement, and the application of the information-weight enhancement policy in aggregation enhancement. The integrated application of the above policies can efficiently utilize resources and improve the performance of the federated model. The performance of the integrated policy represents the final performance of the proposed mechanism.
[0108] Among them, the informative client activation policy, as the policy in the first stage, is used to activate information-rich clients as participants in heterogeneous scenarios. Specifically, the activation index is calculated using autocorrelation entropy and data volume size, and a part of the clients with a high activation index are selected for this round of training.
[0109] The multi-cycle hierarchical update policy, as the policy in the second stage, is used to reduce communication volume and improve communication efficiency in heterogeneous scenarios. Specifically, the M-round communication is divided into cycles, and the deep parameters are only updated in the last m rounds of learning, while the shallow parameters are updated in all M rounds of learning.
[0110] The time-weight decay policy and the information-weight enhancement policy, as the policies in the third stage, are used to perform efficient aggregation according to the time attribute and information attribute of the local model in heterogeneous scenarios, improving the performance and training efficiency of the global model; specifically, according to the time exponential decay function, a smaller aggregation weight is given to the locally generated model that is generated earlier; according to the number of labels and information entropy, a larger aggregation weight is given to the clients with richer information.
[0111] In the integrated use, the informative client activation policy and the multi-stage layer update policy are two initialization policies: ICA(α) defines the activation ratio of asynchronous federated learning clients in each iteration, and MLU(M,m,n) configures the update frequencies of the shallow and deep layers; the time-weight decay policy and the information-weight enhancement policy are two running policies, aggregating local parameters with normalized weights . It is defined as shown in Formula 5.
[0112]
[0113] The integration implementation process is as follows:
[0114] ICA(α) and MLU(M, m, n) initialize the asynchronous federated learning clients and the server: Define ICA(α) and MLU(M, m, n); the proportion α of clients activated in the learning iteration; divide M rounds of communication into cycles, within each cycle, the shallow layer is updated every m communication rounds, and the deep layer is updated in the last n communication rounds.
[0115] All asynchronous federated learning clients calculate the required parameters and upload them to the server, which specifically includes the following steps:
[0116] A. Within each client, calculate ICA k () or LNC k (); k n k,t Obtain the data size from D k,t ;
[0117] B. Transmit ICA k and n k,t to the server;
[0118] C. Perform client selection; if activated, perform training and continue with the following steps;
[0119] D. Calculate IW k (D k,t ) or LN k (D k,t ); k ;
[0120] E. Assign t k to the current timestamp of client k;
[0121] F. Calculate ω k using the local data;
[0122] G. Upload ω k , IW k , and t k to the server.
[0123] The server calculates the normalized weights and uses them to calculate the global parameter ω t+1 , which specifically includes the following steps:
[0124] A. Receive ICA k and nk,t ;
[0125] B. Activate the first k0 clients;
[0126] C. Receive local parameters and wait for the default time WT t , and start aggregation after WT t .
[0127] D. Calculate TW and IW according to TWF and IWE;
[0128] E. Calculate the normalized weights This step specifically includes:
[0129] 1). When the communication round t belongs to the 1 to m - n rounds of the MLU stage, update the shallow layer separately:
[0130]
[0131] where ω s represents the shallow layer, and ω d represents the deep layer;
[0132] 2). When the communication round t belongs to the m - n + 1 to m rounds of the MLU stage, update the shallow layer and the deep layer simultaneously:
[0133]
[0134] 4. Use the "judgment" strategy to compare the performance of ω t and ω t+1 . When the accuracy of the ω t+1 model is not lower than that of the ω t model, receive the new aggregated model to ensure the stability of the learning process and avoid the degradation of the global model.
[0135] Step 5. Model mechanism evaluation. The evaluation of this model mechanism will be divided into four steps: client activation performance evaluation, communication optimization performance evaluation, aggregation enhancement performance evaluation, and integration strategy performance evaluation.
[0136] In this embodiment, 60 clients are simulated through experiments. Based on the Modified National Institute of Standards and Technology (MNIST) dataset, a federated convolutional neural network model is trained in an asynchronous environment and a data dynamic perception environment, with FedAvg as the baseline and accuracy and convergence speed as the evaluation metrics. The experimental constraints are shown in Table 1.
[0137] Table 1
[0138] Variable Description Value <![CDATA[A min > Minimum data volume 200 <![CDATA[A max > Maximum data volume 2000 <![CDATA[L min > Minimum number of labels per partition 2 <![CDATA[L max > Maximum number of labels per partition 6 <![CDATA[I min > Minimum proportion of initialized data 5% <![CDATA[I max > Maximum proportion of initialized data 15% <![CDATA[G1 min > Minimum proportion of new data learned per round 3% <![CDATA[G1 max > Maximum proportion of new data learned per round 5% <![CDATA[G2 min > Minimum proportion of new data learned per round 0.1% <![CDATA[G2 max > Maximum proportion of new data learned per round 0.2%
[0139] Among them, the experimental results of client activation, communication optimization, aggregation enhancement, and integration strategy are shown in Figure 2 , Figure 3 , Figure 4 and Figure 5 respectively. In particular, as shown in the results of Table 2, the highest accuracy rate of the integration strategy reaches 93.71%, which is 8.19% higher than the baseline; and it converges at the 46th round of communication, and the convergence speed is 3.48 times that of the baseline. The experimental results prove the superiority of the mechanism proposed in the present invention.
[0140] Table 2
[0141]
[0142] To sum up, the present invention uses an informative client activation strategy to select clients with rich new information for training and upload parameters to the server; when the server performs aggregation, it uses a multi-cycle hierarchical update strategy to optimize the update frequency of DNN shallow and deep layer parameters; and uses a time weight decay strategy and an information weight enhancement strategy to enhance model aggregation. The present invention effectively improves the performance of the asynchronous federated learning global model; while reducing the communication cost, it greatly improves the accuracy rate and convergence speed.
[0143] In some alternative embodiments, the functions / operations mentioned in the block diagram may not occur in the order mentioned in the operation diagram. For example, depending on the functions / operations involved, two consecutive blocks shown may actually be executed substantially simultaneously or the blocks can sometimes be executed in the reverse order. In addition, the embodiments presented and described in the flowcharts of the present invention are provided by way of example for the purpose of providing a more comprehensive understanding of the technology. The disclosed methods are not limited to the operations and logical flows presented herein. Alternative embodiments are contemplated, where the order of various operations is changed and where sub-operations described as part of a larger operation are executed independently.
[0144] In addition, although the present invention has been described in the context of functional modules, it should be understood that, unless otherwise stated to the contrary, one or more of the described functions and / or features may be integrated in a single physical device and / or software module, or one or more functions and / or features may be implemented in separate physical devices or software modules. It should also be understood that a detailed discussion of the actual implementation of each module is not necessary for understanding the present invention. Rather, given the attributes, functions, and internal relationships of the various functional modules in the devices disclosed herein, the actual implementation of the modules will be understood within the ordinary skills of an engineer. Thus, those skilled in the art can implement the present invention as set forth in the claims without undue experimentation. It should also be understood that the specific concepts disclosed are merely illustrative and are not intended to limit the scope of the present invention, which is determined by the full scope of the appended claims and their equivalents.
[0145] If the described function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs that can store program codes.
[0146] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a predefined sequence of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, apparatus, or device (such as a computer-based system, a system including a processor, or other systems that can fetch and execute instructions from the instruction execution system, apparatus, or device), or in conjunction with these instruction execution systems, apparatuses, or devices. For the purposes of this specification, a "computer-readable medium" can be any device that can contain, store, communicate, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0147] More specific examples (a non-exhaustive list) of computer-readable media include the following: an electrical connection (electronic device) having one or more wirings, a portable computer diskette (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable media can even be paper or other suitable media on which the program can be printed, as the program can be obtained electronically, for example, by optically scanning the paper or other media, followed by editing, interpretation, or otherwise processing as appropriate, and then stored in a computer memory.
[0148] It should be understood that various parts of the present invention can be implemented by hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, any one or a combination of the following techniques well known in the art can be used: discrete logic circuits having logic gate circuits for implementing logical functions on data signals, application specific integrated circuits having appropriate combinational logic gate circuits, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.
[0149] In the description of this specification, the descriptions referring to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples", etc. mean that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0150] Although the embodiments of the present invention have been shown and described, those of ordinary skill in the art can understand that various changes, modifications, substitutions, and variations can be made to these embodiments without departing from the principles and spirit of the present invention, and the scope of the present invention is defined by the claims and their equivalents.
[0151] The above has specifically described the preferred embodiments of the present invention, but the present invention is not limited to the described embodiments. Those skilled in the art can also make various equivalent deformations or substitutions without departing from the spirit of the present invention, and these equivalent deformations or substitutions are all included within the scope defined by the claims of this application.
Claims
1. An asynchronous federated learning method for heterogeneous scenarios, characterized in that Including: Determine a target client from candidate clients, where the autocorrelation entropy of the target client is higher than that of other clients among the candidate clients; Train the target client to obtain target parameters, and upload the target parameters to the server; The server performs an aggregation enhancement process on the model aggregation process according to the target parameters to obtain a first federated model; Perform a policy integration process on the first federated model to obtain a second federated model; Perform a model evaluation on the second federated model to determine a target federated model; The server performs an aggregation enhancement process on the model aggregation process according to the target parameters to obtain a first federated model, including: The server divides the communication into several cycles according to a multi-period hierarchical update policy; Optimize the update frequencies of the shallow and deep layers of the deep neural network during the model aggregation process; According to the several cycles and the optimized update frequencies, perform model aggregation according to the target parameters to obtain a first federated model; Among them, the multi-cycle hierarchical update strategy is used to divide the communication rounds into cycles. The deep layer of the deep neural network is updated in the last rounds of learning, and the shallow layer of the deep neural network is updated in all rounds of learning.
2. The asynchronous federated learning method for heterogeneous scenarios according to claim 1, wherein The determining a target client from candidate clients includes: Obtain perception data from each client among the candidate clients; Calculate the autocorrelation entropy of each client according to the perception data obtained from each client; Select the client with the highest autocorrelation entropy from the candidate clients as the target client according to the autocorrelation entropy of each client and the informative client activation policy.
3. An asynchronous federated learning method for heterogeneous scenarios according to claim 2, characterized in that Training the target client to obtain target parameters and uploading the target parameters to the server includes: The target client obtains the current global model and local data for training to obtain target parameters; The target client sends the target parameters to the server; The server polls and waits to receive the target parameters sent by the client.
4. An asynchronous federated learning method for heterogeneous scenarios according to claim 1, characterized in that The performing a policy integration process on the first federated model to obtain a second federated model includes: Perform a policy integration process on the first federated model according to the informative client activation policy, multi-period hierarchical update policy, time weight decay policy, and information weight enhancement policy to obtain a second federated model; Among them, the informative client activation policy is used to calculate an activation index by using the autocorrelation entropy and the data volume size, and select some clients with a high activation index for this round of training; The time weight decay policy and the information weight enhancement policy are used to give a smaller aggregation weight to the local models generated earlier according to the time exponential decay function; and give a larger aggregation weight to the clients with a large number of labels and a high information entropy according to the number of labels and the information entropy; The applications of the policy integration include: the application of the informative client activation policy in client activation, the application of the multi-period hierarchical update policy in communication optimization, the application of the time weight decay policy in aggregation enhancement, and the application of the information weight enhancement policy in aggregation enhancement.
5. An asynchronous federated learning method for heterogeneous scenarios according to claim 4, characterized in that, The performing a model evaluation on the second federated model to determine a target federated model includes: Calculate the accuracy and convergence speed of the global model under the action of client activation to determine the optimal activation ratio; Calculate the accuracy and convergence speed of the global model under the action of communication optimization to determine the optimal communication cycle; Calculate the accuracy and convergence speed of the global model under the aggregation enhancement, and determine whether to use the information entropy or the number of labels in the local dataset; Calculate the accuracy and convergence speed of the global model under the integration strategy, and generate the model evaluation result.
6. An asynchronous federated learning device for heterogeneous scenarios, characterized in that, It includes: The first module is used to determine the target client from the candidate clients, where the autocorrelation entropy of the target client is higher than that of other clients among the candidate clients; The second module is used to train the target client to obtain target parameters and upload the target parameters to the server; The third module is used for the server to perform aggregation enhancement processing on the model aggregation process according to the target parameters to obtain the first federated model; The fourth module is used to perform policy integration processing on the first federated model to obtain the second federated model; The fifth module is used to perform model evaluation on the second federated model to determine the target federated model; The third module is specifically used for: The server divides the communication into several cycles according to the multi-period hierarchical update strategy; Optimize the update frequencies of the shallow and deep layers of the deep neural network in the model aggregation process; According to the several cycles and the optimized update frequencies, perform model aggregation according to the target parameters to obtain the first federated model; Among them, the multi-period hierarchical update strategy is used to divide the communication rounds into cycles. The deep layer of the deep neural network is updated in the last rounds of learning, and the shallow layer of the deep neural network is updated in all rounds of learning.
7. An electronic device, characterized in that, It includes a processor and a memory; The memory is used to store programs; The processor executes the program to implement the method according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, The storage medium stores a program, and the program is executed by the processor to implement the method according to any one of claims 1 to 5.
9. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Federated learning client intelligent selection method and system based on deep reinforcement learning
CN113191484A
Federal learning-based efficient mutual learning method for heterogeneous models of multiple Internet of Things devices
CN113518007A