Multi-condition-oriented self-organizing multi-teacher personalized federated learning method
By employing a self-organizing, multi-teacher personalized federated learning approach, a central server generates and optimizes teacher models, while enterprise clients integrate knowledge to build private models. This approach solves the problems of model accuracy and adaptability in traditional federated learning under various working conditions, achieving more efficient personalized model configuration and faster convergence.
Patent Information
- Application Number
- CN202411693045.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-25
- Publication Date
- 2026-02-27
- Estimated Expiration
- 2044-11-25
AI Technical Summary
Traditional federated learning faces challenges in multi-condition industrial environments, including the degradation of model performance due to differences in data distribution and the difficulty of personalized configuration. Furthermore, changes in the production environment cause data distribution characteristics to change over time, affecting the model's autonomous adaptability and accuracy.
We adopt a self-organizing, multi-teacher, personalized federated learning approach for various working conditions. We generate teacher collaboration relationships through a central server, optimize the teacher model, and integrate the teacher model knowledge on the enterprise client to establish a private model. We use the multi-teacher model to guide personalized configuration, reduce the impact of distribution differences, and improve the model convergence speed.
It improves the accuracy of private models in multi-condition scenarios, reduces the impact of distribution differences on randomly configured networks, and enhances the personalized adaptability and convergence speed of the model.
Smart Images

Figure CN119539126B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of federated learning, and in particular to a multi-condition-oriented self-organizing multi-teacher personalized federated learning method. BACKGROUND
[0002] Federated learning is a distributed machine learning method that can ensure data privacy. In recent years, federated learning has achieved remarkable results in the medical, transportation, and financial fields by enabling participants distributed in various regions to collaborate in modeling under the premise of ensuring data security. Therefore, federated learning has become a viable solution to the challenge of distributed collaborative modeling with data privacy considerations in industrial enterprises. However, the application of traditional federated learning in industrial environments faces two challenges. First, due to climate, demand, and equipment changes in real industrial scenarios, enterprise process data distributed in multiple locations differ in data distribution and effectiveness. This phenomenon leads to multi-condition process data in different enterprises, causing non-identically distributed problems in distributed data, which damages the effectiveness of the global model established by traditional federated learning. Second, changes in the production environment can cause the distribution characteristics of data to change over time. Therefore, models in industrial application scenarios face higher requirements in terms of personalized configuration and autonomous adaptability.
[0003] In related technologies, incremental construction of randomly configured networks provides a beneficial approach to solving the challenge of synchronously optimizing model structure and parameter configuration through adaptive analysis of data features. However, differences in data distribution often hinder the realization of ideal results in federated incremental collaborative modeling. SUMMARY
[0004] The present application aims to at least partially solve one of the technical problems in the related art. To this end, the first purpose of the present application is to propose a multi-condition-oriented self-organizing multi-teacher personalized federated learning method to establish a multi-teacher model based on data distribution differences to guide the personalization of private models, improve the accuracy of private models in multi-condition scenarios, and enable enterprises with similar distributions to collaboratively establish teacher models, reduce the impact of distribution differences on the difficulty of meeting the supervision conditions of randomly configured networks, and improve model convergence speed.
[0005] To achieve the above-mentioned purpose, the first aspect of the present application proposes a multi-condition-oriented self-organizing multi-teacher personalized federated learning method, which comprises the following steps:
[0006] S10: The central server acquires node information of enterprise clients, which is constructed by a generated model based on local process data;
[0007] S20: The central server analyzes the node information of the enterprise client based on a multi-teacher model generation mechanism, self-organizes the teacher collaboration relationship corresponding to the enterprise client, and generates a corresponding teacher model for the enterprise client;
[0008] S30: The central server evaluates the result of the establishment of the teacher model, optimizes the teacher collaboration relationship of the teacher model according to the evaluation result, and transmits the optimized teacher model to the corresponding enterprise client;
[0009] S40: The enterprise client integrates teacher model knowledge through consensus based on local data, establishes a private model, obtains a current error through the private model, and evaluates the current error.
[0010] S50: In the case where the current error is less than a preset error threshold, the private model is output.
[0011] According to the multi-condition-oriented self-organizing multi-teacher personalized federated learning method, the central server first obtains the node information of the enterprise client, which is constructed by the generation model according to the local process data. Then the central server analyzes the node information of the enterprise client based on a multi-teacher model generation mechanism, self-organizes the teacher collaboration relationship corresponding to the enterprise client, and generates a corresponding teacher model for the enterprise client. The central server evaluates the result of the establishment of the teacher model, optimizes the teacher collaboration relationship of the teacher model according to the evaluation result, and transmits the optimized teacher model to the corresponding enterprise client. The enterprise client integrates teacher model knowledge through consensus based on local data, establishes a private model, obtains a current error through the private model, and evaluates the current error. In the case where the current error is less than a preset error threshold, the private model is output. Thus, the method establishes a multi-teacher model based on data distribution difference to guide the personalization of the private model, which can improve the accuracy of the private model in the multi-condition scene, and can enable enterprises with similar distribution to collaborate to establish a teacher model, which can reduce the influence of distribution difference on the difficulty of meeting the random configuration network supervision condition, and improve the model convergence speed.
[0012] In addition, the multi-condition-oriented self-organizing multi-teacher personalized federated learning method according to the above embodiments of the present application can also have the following additional technical features:
[0013] According to an embodiment of the present application, the step S10 includes: the enterprise client generates the weight and bias of the node of the private model randomly within a preset range based on the supervision of the local process data, and uploads the weight and bias corresponding to the maximum supervision value output value of the current hidden layer parameter of the enterprise client to the central server.
[0014] According to one embodiment of the present application, the supervised value output value of the current hidden layer parameter is determined according to the following formula:
[0015] (1)
[0016] wherein, is the supervised value output value of the Lth node added by the enterprise client, is the hidden layer output value of the node L of the enterprise client, is the local data of the enterprise client, is the hidden layer output value of the node L of the enterprise client, is the activation function of the enterprise client, is the prediction error of the private model when having L nodes, which is obtained by calculating the mean square error of the prediction value of the local data of the private model and the real value. is the hidden layer weight value of the Lth node added by the enterprise client, is the hidden layer bias value of the Lth node added by the enterprise client, is the hyperparameter used in the supervision mechanism, which is obtained by randomly selecting a positive real number between 0 and 1; is a non-negative real number sequence.
[0017] According to one embodiment of the present application, the step S20 comprises:
[0018] S21: The central server uses a set of learning automata to establish a multi-teacher model, each enterprise client is configured with a learning automaton, and the central server records the probability of each learning automaton participating in the construction of a teacher model;
[0019] S22: Each enterprise client generates nodes of the corresponding teacher model using a quality-first strategy, and when the nodes meet the constraints of all enterprise clients in the group, the corresponding nodes are taken as optimal nodes;
[0020] S23: Each enterprise client calculates the local output weight value in a global update manner, and each enterprise client performs horizontal strengthening aggregation of the corresponding teacher model in the group according to the local output weight value.
[0021] According to one embodiment of the present application, in the step S23, the local output weight value of the enterprise client is determined according to the following formula:
[0022] (2)
[0023] wherein, is the enterprise client the actual label set of the sample; is the weight of the jth node of the output layer of the enterprise client is the local data of the enterprise client the hidden layer output value of the node
[0024] The corresponding participating enterprise client of each teacher model is aggregated horizontally in the group by the following formula:
[0025] (3)
[0026] wherein, is the total number of samples of the enterprise client is the total number of samples participating in the construction of the teacher model The aggregated model information is used for the optimization of the subsequent private model and the optimization of the relationship of the next round of teacher model construction.
[0027] According to an embodiment of the present application, the step S30 comprises:
[0028] S31: The central server analyzes the output weight distribution of the enterprise client, establishes an information similarity matrix of the enterprise client based on cosine similarity, and judges the cooperability matrix between the enterprise clients based on the similarity matrix;
[0029] S32: Determine the reward and punishment signal based on the cooperability matrix, determine the reinforcement signal type according to the reward and punishment signal, and update the cooperation relationship probability distribution;
[0030] S33: When there is no punishment record in the current learning automaton set, return the teacher model corresponding to this moment to the enterprise client to help the enterprise client establish the corresponding private model.
[0031] According to an embodiment of the present application, in the step S31, the output weight distribution of the enterprise client is determined according to the following formula :
[0032] (4)
[0033] The information similarity matrix of the enterprise client is: wherein, The element in the matrix represents the cosine similarity between clients i and j.
[0034] The cooperability matrix Z between enterprise clients is represented by the following formula:
[0035] ,
[0036] wherein, is a similarity threshold, is the element in the matrix, representing the cosine similarity between clients i and j.
[0037] According to one embodiment of the present application, in the step S32, the reinforcement signal of the current teacher model construction result between enterprises is determined according to the following manner:
[0038] Define the reward and punishment signal , wherein the reward and punishment signal is calculated as follows:
[0039]
[0040] wherein, is the current enterprise set joining the construction of the teacher model , obtained by the output of a plurality of learning automata.
[0041] According to one embodiment of the present application, the step S40 comprises:
[0042] S41: The output layer of the private model is trained with new output weights by fitting the local prediction consistency of the teacher model, wherein the private model determines the learning target according to the output weights;
[0043] S42: The output weight update target function is solved by using the multiplier method;
[0044] S43: The effect of the current teacher model construction relationship is analyzed by model error fluctuation.
[0045] According to one embodiment of the present application, in the step S41, the learning target of the private model is determined according to the following formula:
[0046] (5)
[0047] wherein, is the optimal output weight of the private model , is the KL divergence term parameter, which is set according to the prediction accuracy of the teacher model on local data; is the regularization term parameter, which can be obtained by grid search on the actual data set.
[0048] According to one embodiment of the present application, in the step S42, the target function of output weight update is solved according to the following formula:
[0049] (6)
[0050] The above formula is an equivalent conversion of the target function in the step S41, which can be further converted into the form of augmented Lagrange:
[0051] (7)
[0052] wherein, is a dual variable, is a Lagrange penalty coefficient;
[0053] The update strategy of solving the optimization problem of the target function is:
[0054] (8)
[0055] Let , the above update method can be rewritten as:
[0056] (9)
[0057] wherein, The calculation process of is:
[0058] (10)
[0059] The partial derivative of with respect to can be obtained: (11)
[0060] Let , then
[0061] can be obtained; The calculation process of is:
[0062] (19)
[0063] wherein, represents a soft threshold operator;
[0064] The output weight of the private model obtained after iterative update converges will be used as the optimal output layer weight of the private model
[0065] .
[0066] Additional aspects and advantages of the application will be set forth in part in the description which follows, and in part will become apparent to those having ordinary skill in the art upon examination of the following or can be learned by practice of the application. BRIEF DESCRIPTION OF DRAWINGS
[0067] Figure 1 A flowchart of a multi-condition-oriented self-organizing multi-teacher personalized federated learning method according to an embodiment of the application;
[0068] Figure 2 A framework diagram of a multi-condition-oriented self-organizing multi-teacher personalized federated learning method according to an embodiment of the application;
[0069] Figure 3 A flowchart of generating a corresponding teacher model for an enterprise client according to an embodiment of the application;
[0070] Figure 4 A flowchart of evaluating the result of establishing a teacher model according to an embodiment of the application;
[0071] Figure 5 A flowchart of establishing a private model and obtaining a current error through the private model according to an embodiment of the application. DETAILED DESCRIPTION
[0072] Embodiments of the application are described in detail below with reference to the accompanying drawings, in which like or similar elements or components are denoted throughout by like reference numerals, and the embodiments described below are exemplary and are intended to explain the application, and should not be understood as limiting the application.
[0073] A multi-condition-oriented self-organizing multi-teacher personalized federated learning method according to an embodiment of the application is described below with reference to the accompanying drawings.
[0074] Figure 1 A flowchart of a multi-condition-oriented self-organizing multi-teacher personalized federated learning method according to an embodiment of the application.
[0075] As shown in the flowchart, the multi-condition-oriented self-organizing multi-teacher personalized federated learning method according to an embodiment of the application can include the following steps: Figure 1
[0076] S10: The central server obtains node information of the enterprise client, which is constructed by the model generation according to local process data.
[0077] S20: The central server analyzes the node information of the enterprise client based on a multi-teacher model generation mechanism, self-organizes to generate a corresponding teacher collaboration relationship for the enterprise client, and generates a corresponding teacher model for the enterprise client.
[0078] S30: The central server evaluates the result of the teacher model establishment, optimizes the teacher collaboration relationship of the teacher model according to the evaluation result, and transmits the optimized teacher model to the corresponding enterprise client.
[0079] S40: The enterprise client integrates the knowledge of the teacher model based on the local data through consensus, establishes a private model, and obtains the current error through the private model and evaluates the current error.
[0080] S50: In the case where the current error is less than the preset error threshold, the private model is output. The preset error threshold can be calibrated according to actual conditions, which is not limited here.
[0081] Specifically, the multi-condition federal cooperation scenario considers a central server and multiple different enterprises with similar process procedures, such as Figure 2 As shown, multiple different enterprises are installed with enterprise clients, and the central server first needs to obtain node information from each enterprise client, wherein the node information of each enterprise client is constructed by the generation model based on its corresponding local process data. The central server uses a multi-teacher model generation mechanism to analyze the node information of each enterprise client, which can self-organize to generate the teacher collaboration relationship corresponding to each enterprise client, determine which teacher model will collaborate with a specific client, and based on the collaboration relationship, the central server can generate a corresponding teacher model for each enterprise client, so that the personalized teacher model adapts to the specific needs of each enterprise client.
[0082] Further, the central server evaluates the generated teacher model to determine the performance of the teacher model, and according to the evaluation result, the central server optimizes the collaboration relationship of the teacher model, wherein the optimization may include adjusting the weight, parameter or other characteristics of the teacher model, etc. to improve the overall performance of the teacher model. The optimized teacher model is transmitted back to the corresponding enterprise client.
[0083] The enterprise client uses local data to integrate the knowledge of the teacher model through consensus to establish its own private model. Thus, the combination of the knowledge of the teacher model and the local data can make the formed private model more accurate. The enterprise client can obtain the current error through the private model, and compare the current error with the preset error threshold to evaluate the error. If the current error is less than the preset error threshold, it means that the performance of the private model meets the expected performance, and the enterprise client will output the private model for use. If the current error is greater than or equal to the preset error threshold, it means that the performance of the private model does not meet the user's needs, and the above steps S10-S40 are repeated until the private model meets the expected performance.
[0084] According to an embodiment of the present invention, step S10 includes: the enterprise client, based on the supervision of local process data, randomly generates weights and biases of nodes in the private model within a preset range, and selects the weights and biases corresponding to the maximum output value of the supervision value of the current hidden layer parameters of the enterprise client and uploads them to the central server. The preset range can be defined according to actual conditions; for example, the preset range can be... and ,in, Is firm k in the interval {λ} min :Δλ:λ max The parameter selected within}, λ min It is the lower bound of the distribution interval of the random parameter, λ. max Δλ is the upper limit of the random parameter allocation interval, and Δλ is the increment parameter of the random parameter allocation interval.
[0085] Specifically, the multi-condition federated collaboration scenario considers a central server and multiple similar technological processes from different enterprises. These processes possess process data under different production conditions, and the total number of processes can be defined as follows: The enterprise client set is denoted as Each enterprise client The set of process data we possess is denoted as ,in, It is a characteristic of the data. For the label of the sample, It is an enterprise client. The total number of samples, and Given the feature and label set, the distribution corresponding to the process data is denoted as . The learning objective of the proposed federated learning method is to... In this case, by keeping private data local, and incrementally building a better private model for the enterprise through federated collaboration, the following objective function can be minimized:
[0086]
[0087] In the above formula, A private model built on a randomly configured network The loss function is typically set to mean squared error loss.
[0088] Furthermore, enterprise clients monitor local process data. and Internal random generation private model Hidden node parameters The weight of each node and the The bias of each node And select the supervised value of the current hidden layer parameter of the enterprise client k as the output value. The weight corresponding to the maximum and bias Uploaded to the central server.
[0089] Furthermore, according to one embodiment of the present invention, the supervised output value of the current hidden layer parameters is determined according to the following formula:
[0090] (1)
[0091] in, For the first Each enterprise client adds a new supervisory value output for the Lth node. For local data of enterprise clients Passing through the node The hidden layer output value, For enterprise clients activation function, For private model In having The prediction error at each node is calculated using the private model. For local data Predicted value Compared with the true value The mean square error is obtained; For the first Each enterprise client adds a hidden layer weight for the Lth node; For the first A new hidden layer bias is added to the Lth node of the enterprise client; The hyperparameters used in the monitoring mechanism are obtained by randomly selecting positive real numbers between 0 and 1. It is a sequence of non-negative real numbers.
[0092] According to one embodiment of the present invention, such as Figure 3 As shown, step S20 includes the following steps:
[0093] S21: The central server uses a set of learning automata to build a multi-teacher model. Each enterprise client is configured with a learning automaton, and the central server records the probability of each learning automaton participating in the construction of the teacher model.
[0094] Specifically, the central server reduces the negative impact of distribution difference problems in multi-scenario scenes on private models by establishing a multi-teacher model. The central server uses a set of learning automata, each enterprise client is configured with an automatic learning machine, and each learning automaton has k actions, where action i represents its participation in building teacher model i. Each learning automaton selects a cooperation relationship based on the probability distribution at the current time t; recording the cooperation relationship probability distribution of the learning automaton at the t time node is where, is the probability of the learning automaton participating in building teacher model k. It should be understood that in the initial state, for all learning automata, It should be noted that the learning automaton is a probability-based algorithm that can make decisions in uncertain environments.
[0095] S22: Each enterprise client generates a node corresponding to the teacher model using a quality-first strategy, and when the node meets the constraints of all enterprise clients in the group, the corresponding node is taken as the optimal node.
[0096] Specifically, each enterprise client uses a quality-first strategy to generate a node corresponding to the teacher model, that is, when selecting a node, data quality is given priority. The node needs to meet the constraints of all enterprise clients in the group, thereby ensuring the generalization ability and adaptability of the teacher model. When the node meets all the constraints, the node is considered as the optimal node and is used to build the teacher model.
[0097] Specifically, let the current hidden layer parameter of the enterprise client be the supervised value output , and set the supervision record function to , where the supervision record function can be represented by the following formula:
[0098] .
[0099] Then, set the variable at the central server, where the variable . If the variable is the total number of processes , the central server selects the current supervised value output value corresponding weight and bias as the weight and bias of the new node of the teacher model.
[0100] S23: Each enterprise client calculates the local output weight using a global update method, and each enterprise client performs horizontal strengthening aggregation of the corresponding teacher model in the group according to the local output weight.
[0101] According to one embodiment of the present application, in step S23, the local output weight of the enterprise client is determined according to the following formula :
[0102] (2)
[0103] wherein, is the actual label set of the sample of the enterprise client ; is the weight of the jth node of the output layer of the enterprise client ; is the hidden layer output value of the enterprise client through the node ;
[0104] The corresponding participating enterprise of each teacher model carries out intra-group horizontal reinforcement aggregation through the following formula:
[0105] (3)
[0106] wherein, is the total number of samples of the enterprise client , is the total number of samples participating in the construction of the teacher model , and the aggregated model information is used for the optimization of the subsequent private model and the optimization of the relationship of the next round of teacher model construction.
[0107] Specifically, in order to realize the rapid convergence of the model, each enterprise client calculates the local output weight in a global update manner, i.e., the local output weight is determined by formula (2). The corresponding participating enterprise of each teacher model carries out intra-group horizontal reinforcement aggregation through formula (3) to combine the knowledge of the teacher model with the local data, forming a more accurate model. The aggregated information is used for the optimization of the private model and the optimization of the relationship of the next round of teacher model construction. It should be understood that the horizontal reinforcement aggregation is an optimization technique that can improve the overall performance of the model by strengthening the performance of the model in a specific direction.
[0108] According to one embodiment of the present application, as shown in Figure 4 , step S30 can include the following steps:
[0109] S31: The central server analyzes the distribution result according to the output weight of the enterprise client, establishes an information similarity matrix of the enterprise client based on the cosine similarity, and judges the cooperability matrix between the enterprise clients based on the similarity matrix.
[0110] According to one embodiment of the present application, in step S31, the output weight analysis distribution result of the enterprise client is determined according to the following formula :
[0111] (4)
[0112] The information similarity matrix of the enterprise client is: , wherein the element in the matrix represents the cosine similarity between the clients i and j. The cooperability matrix Z between the enterprise clients is represented by the following formula:
[0113]
[0114] ,
[0115] , wherein the element in the matrix represents the cosine similarity between the clients i and j. is a similarity threshold value, is the element in the matrix, representing the cosine similarity between the clients i and j. According to experience, the similarity threshold value may be selected as a value around 0.7-0.8.
[0116] Specifically, the central server designs a reinforcement signal for the construction of the teacher model by the parameter similarity of the in-group teacher model and the model training effect. The reinforcement signal feedback consists of two parts: the output layer and the error fluctuation. A randomly configured network is used for the construction of the enterprise private model, which is generated based on the supervision mechanism of the process data, and the model parameters reflect the distribution of the data. The consistency of the data distribution can be studied by analyzing the model parameters.
[0117] Specifically, the output layer parameters of the model can be analyzed based on the reinforcement signal of the coefficient of variation, and the output weight analysis distribution result of each enterprise client can be determined by formula (4) . Then, based on the output weight analysis distribution result of the enterprise client , the information similarity matrix of the output client based on the cosine similarity is established , and the cooperability matrix Z between the participating ends is determined based on , and the cooperability between enterprises is determined according to the cooperability matrix Z.
[0118] S32: Determine the reward and punishment signal based on the cooperability matrix, and determine the reinforcement signal type according to the reward and punishment signal, and update the cooperation relationship probability distribution.
[0119] According to one embodiment of the present application, in the step S32, the reinforcement signal of the current teacher model establishment result between the enterprises is determined according to the following manner:
[0120] The reward and punishment signal is defined wherein the reward-punishment signal is calculated as follows:
[0121]
[0122] wherein, is the current set of enterprises that join the construction of the teacher model, obtained from the outputs of the plurality of learning automata.
[0123] Specifically, if the reward-punishment signal is 0, the reinforcement signal is a reward, and the way to update the cooperation relationship probability distribution is:
[0124]
[0125] If the reward-punishment signal is 1, the reinforcement signal is a punishment, and the way to update the cooperation relationship probability distribution is:
[0126]
[0127] S33: When the current set of learning automata does not have a punishment record, return the teacher model corresponding to the moment to the enterprise client to help the enterprise client establish a corresponding private model.
[0128] Specifically, if the current set of learning automata does not have a punishment record, it means that the performance of the teacher model is as expected, and the central server returns the teacher model corresponding to the moment to the enterprise client. After receiving the teacher model, the enterprise client can establish a corresponding private model based on local data.
[0129] According to one embodiment of the present application, as Figure 5 shown in FIG. 4, step S40 can include the following steps:
[0130] S41: The output layer of the private model trains new output weights by fitting the local prediction consistency of the teacher model, and the private model determines the learning target according to the output weights.
[0131] According to one embodiment of the present application, in step S41, the learning target of the private model is determined according to the following formula:
[0132] (5)
[0133] wherein, is the optimal output weight of the private model, is a KL divergence term parameter, which is set according to the prediction accuracy of the teacher model on local data; is a regularization term parameter, which can be obtained by grid search on the actual data set.
[0134] Specifically, the first part of the objective function for optimizing the output weights (i.e., Equation (5)) is the local label error, the second part is the difference in the predicted distribution between the local model and other group models on the local data, and the third part is the regularization term. The goal of updating the first part of Equation (5) is to ensure the effectiveness of local learning on the private model, which includes acquiring localized personalized knowledge. The second part integrates common sense and non-local personalized knowledge, extracting useful parts from different teacher models to construct the local model.
[0135] S42: Solve the objective function for updating the output weights using the multiplier method.
[0136] According to an embodiment of the present invention, in step S42, the objective function for updating the output weights is solved according to the following formula:
[0137] (6)
[0138] Formula (6) above is an equivalent transformation of the objective function in step S41, and it is further transformed into the augmented Lagrange form as follows:
[0139] (7)
[0140] in, As dual variables, The Lagrange penalty coefficient;
[0141] The update strategy for solving the optimization problem of the objective function is as follows:
[0142] (8)
[0143] remember The above update method can be rewritten as follows:
[0144] (9)
[0145] in, The calculation process is as follows:
[0146] (10)
[0147] right beg The partial derivatives can be obtained as follows:
[0148] (11)
[0149] make achievable ;
[0150] The calculation process is as follows:
[0151] (19)
[0152] wherein, denotes a soft threshold operator;
[0153] the output weight of the private model obtained after iterative updating converges the output weight of the private model obtained after iterative updating converges the output layer weight of the private model. It needs to be understood that the Lagrange penalty coefficient is selected according to different data sets, and generally a smaller positive number is taken, such as 0.003.
[0154] S43: Analyze the effect of the current teacher model construction relationship through model error fluctuation.
[0155] Specifically, the error of the L-1 node is denoted as , the error of the L node is denoted as , and the error fluctuation can be obtained. If , the model is in positive feedback fluctuation; otherwise, it is recorded as negative feedback fluctuation.
[0156] In summary, according to the multi-condition-oriented self-organizing multi-teacher personalized federated learning method of the embodiment of the application, first, the central server obtains the node information of the enterprise client, and the node information is constructed by the generated model according to the local process data; then the central server analyzes the node information of the enterprise client based on the multi-teacher model generation mechanism, self-organizes to generate the teacher cooperation relationship corresponding to the enterprise client, and generates the corresponding teacher model for the enterprise client; the central server evaluates the result of the teacher model establishment, optimizes the teacher cooperation relationship of the teacher model according to the evaluation result, and transmits the optimized teacher model to the corresponding enterprise client; the enterprise client integrates the knowledge of the teacher model based on the local data through consensus, establishes a private model, and obtains the current error through the private model and evaluates the current error; and in the case that the current error is less than the preset error threshold, the private model is output. Thus, the method establishes a multi-teacher model based on data distribution difference to guide the personalization of the private model, which can improve the accuracy of the private model in the multi-condition scene, and can enable enterprises with similar distribution to cooperate to establish a teacher model, which can reduce the influence of distribution difference on the difficulty of meeting the random configuration network supervision condition, and improve the model convergence speed.
[0157] It is to be appreciated that the above description and the examples that follow are intended to be illustrative only and that changes can be made to the description, as represented by the above listed elements, by the steps recited in the flow charts, and by the examples that follow, without departing from the spirit of the application. Accordingly, the scope of the present application is intended to be defined only by the appended claims.
[0158] It should be understood that aspects of the application can be implemented in hardware, software, firmware or a combination thereof. In the above embodiments, various steps or methods can be implemented in software or firmware that is stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any of the following technologies, known in the art, can be used: a hybrid of the above technologies, a combination of any of the above technologies, etc.
[0159] In the description of the present specification, the description of the terms "one embodiment", "some embodiments", "an example", "a specific example", or "some examples" and the like means 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 application. In the present specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Also, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in an appropriate manner.
[0160] In addition, the terms "first", "second", etc. are used only for the purpose of description, and should not be understood as indicating or implying relative importance or implying a number of the technical features indicated. Therefore, the features defined as "first", "second" can explicitly or implicitly include at least one of the features. In the description of the present application, the meaning of "a plurality of" is at least two, for example, two, three, etc., unless otherwise explicitly specified and limited.
[0161] In the present application, unless otherwise explicitly specified and limited, the terms "mounting", "connecting", "connecting", "fixing" and the like should be understood broadly, for example, it can be fixedly connected, or it can be detachably connected, or it can be integrated; it can be mechanically connected, or it can be electrically connected; it can be directly connected, or it can be indirectly connected through an intermediate medium; it can be the internal communication of two elements or the interaction relationship between two elements, unless otherwise explicitly limited. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.
[0162] Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limiting the present application, and those skilled in the art can make changes, modifications, replacements and variations to the above embodiments within the scope of the present application.
Claims
1. A self-organizing, multi-teacher, personalized federated learning method for multiple work conditions, characterized in that: The method includes the following steps: S10: The central server obtains the node information of the enterprise client, which is constructed by the generation model based on local process data; S20: The central server analyzes the node information of the enterprise client based on the multi-teacher model generation mechanism, self-organizes and generates the teacher collaboration relationship corresponding to the enterprise client, and generates the corresponding teacher model for the enterprise client; wherein, step S20 includes: S21: The central server uses a set of learning automata to build a multi-teacher model. Each enterprise client is configured with a learning automata, and the central server records the probability of each learning automata participating in the construction of the teacher model. S22: Each of the enterprise clients generates a node for the corresponding teacher model using a quality-first strategy, and when a node satisfies the constraints of all the enterprise clients in the group, the corresponding node is taken as the optimal node; S23: Each enterprise client calculates its local output weights using a global update method, and each enterprise client performs horizontal enhancement aggregation within the group based on its local output weights for the corresponding teacher model. S30: The central server evaluates the results of the teacher model establishment, optimizes the teacher collaboration relationships in the teacher model based on the evaluation results, and transmits the optimized teacher model to the corresponding enterprise client; wherein, step S30 includes: S31: The central server analyzes the distribution results of the output weights of the enterprise clients, establishes an information similarity matrix of the enterprise clients based on cosine similarity, and determines the cooperationability matrix between enterprise clients based on the similarity matrix; S32: Determine the reward / penalty signal based on the cooperativeness matrix, determine the reinforcement signal type based on the reward / penalty signal, and update the cooperative relationship probability distribution; S33: When there is no penalty record in the current set of learning automata, return the teacher model corresponding to that moment to the enterprise client to help the enterprise client build the corresponding private model; S40: The enterprise client, based on local data, integrates teacher model knowledge through consensus to establish a private model, and obtains the current error through the private model, and evaluates the current error; S50: If the current error is less than a preset error threshold, output the private model.
2. The self-organizing multi-teacher personalized federated learning method for multiple work conditions as described in claim 1, characterized in that, Step S10 includes: Based on the supervision of local process data, the enterprise client randomly generates the weights and biases of the nodes of the private model within a preset range, and uploads the weights and biases corresponding to the largest output value of the supervision value of the current hidden layer parameter of the enterprise client to the central server.
3. The self-organizing multi-teacher personalized federated learning method for multiple work conditions as described in claim 2, characterized in that, The supervised output value of the current hidden layer parameters is determined according to the following formula: (1) in, For the first Each enterprise client adds a new supervisory value output for the Lth node. For enterprise clients Local data Passing through the node The hidden layer output value, For enterprise clients activation function, For private model In having The prediction error at each node is calculated using the private model. For local data Predicted value Compared with the true value The mean square error is obtained; For the first Each enterprise client adds a hidden layer weight for the Lth node; For the first A new hidden layer bias is added to the Lth node of the enterprise client; The hyperparameters used in the monitoring mechanism are obtained by randomly selecting positive real numbers between 0 and 1. It is a sequence of non-negative real numbers.
4. The self-organizing multi-teacher personalized federated learning method for multiple work conditions as described in claim 3, characterized in that, In step S23, the enterprise is determined according to the following formula. Local output weights : (2) in, For enterprise clients The actual label set of the sample; For the first The weight of the j-th node in the output layer of an enterprise client; For enterprise clients Local data Passing through the node The hidden layer output value; The corresponding participating enterprise clients for each teacher model perform horizontal reinforcement aggregation within the group using the following formula: (3) in, It is an enterprise client. The total number of samples, It is involved in building the teacher model Total number of samples, aggregated model information This is used for optimizing the private model and the relationship in the next round of teacher model construction.
5. The self-organizing multi-teacher personalized federated learning method for multiple work conditions as described in claim 4, characterized in that, In step S31, the output weight analysis distribution result of the enterprise client is determined according to the following formula. : (4) The information similarity matrix for enterprise clients is as follows: ,in, The elements in the expression represent the cosine similarity between clients i and j; The collaborability matrix Z between enterprise clients is represented by the following formula: , in, For similarity threshold, for The elements in the expression represent the cosine similarity between clients i and j.
6. The self-organizing multi-teacher personalized federated learning method for multiple work conditions as described in claim 5, characterized in that, In step S32, the reinforcement signal of the current teacher model establishment results among enterprises is determined according to the following method: Define reward and punishment signals The calculation method for reward and punishment signals is as follows: in, To add a teacher model to the current process The set of enterprises is obtained from the outputs of multiple learning automata.
7. The self-organizing multi-teacher personalized federated learning method for multiple work conditions as described in claim 1, characterized in that, Step S40 includes: S41: The output layer of the private model trains new output weights by fitting the local prediction consistency of the teacher model, and the private model determines the learning objective based on the output weights; S42: Solve the objective function for updating the output weights using the multiplier method; S43: Analyze the effectiveness of the current teacher model in constructing relationships through model error fluctuation analysis.
Citation Information
Patent Citations
Industrial process soft measurement method based on federal increment random configuration network
CN113761748A
Knowledge distillation method and computer equipment for dual-purpose intra-domain and intra-domain data sets
CN116502705A