Bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation
Through the method of dynamic hybrid path and federated multiple distillation, the problems of data silos and model drift are solved, and the generalization ability and stability of bearing fault diagnosis are improved. In particular, the fault identification accuracy is significantly improved in cross-device and cross-working condition diagnosis tasks.
Patent Information
- Application Number
- CN202510970648.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-15
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2045-07-15
AI Technical Summary
In industrial scenarios, the data island effect and client data heterogeneity limit the model's generalization capabilities, especially in cross-device and cross-working-condition migration diagnosis tasks. In addition, the classic federated learning algorithm has the problem of model drift, which affects the diagnostic performance.
A bearing fault diagnosis method based on dynamic hybrid path and federated multi-distillation is adopted. By constructing a multi-condition vibration dataset, a global diagnosis model is initialized using a deep convolutional neural network. Dynamic weighted aggregation and historical model time decay are performed on the server side. Multi-path KL divergence regularization and missing category knowledge distillation loss function are combined to optimize the local diagnosis model.
It alleviates model drift under non-independent and identically distributed data, improves the generalization ability of cross-device fault diagnosis, enhances the ability to identify low-frequency faults, and suppresses overfitting of noisy data, ensuring the stability and reliability of the diagnostic model.
Smart Images

Figure CN120470446B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of mechanical fault diagnosis, and in particular to a bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation. Background Art
[0002] Mechanical system fault diagnosis is a key link in ensuring the safe operation of industrial equipment and realizing intelligent manufacturing. In recent years, intelligent diagnosis methods based on deep learning have significantly improved the accuracy of fault identification by extracting high-dimensional features from multi-source sensor data, and have become the mainstream technology in industrial applications. However, such data-driven methods face significant bottlenecks in actual deployment: the generalization ability of the model is limited by the feasibility of constructing massive high-quality annotated data sets. In industrial scenarios, due to the heterogeneity of equipment, high annotation costs, and data privacy barriers between enterprises, only small-scale, fragmented local data sets can be obtained in most scenarios, forming a "data island" effect. This problem limits the generalization ability of the model, especially in the migration diagnosis task across equipment and working conditions.
[0003] To overcome the limitations of data silos, federated learning has been introduced as a privacy-preserving distributed learning framework. Federated learning theoretically enables cross-enterprise collaborative modeling by aggregating local model parameters across multiple clients under the coordination of a central server, rather than directly sharing raw data. However, in industrial fault diagnosis scenarios, the non-independent and identically distributed (IID) characteristics of client data, such as differences in equipment operating conditions, uneven fault classifications, and inconsistent sampling frequencies, lead to serious model drift. This is a phenomenon in which differences in client data distribution cause local model parameters to deviate from the global optimal solution, resulting in a decrease in the global model convergence stability and diagnostic performance of the classic federated average aggregation algorithm. Summary of the Invention
[0004] Purpose of the invention: In response to the above problems, the purpose of the present invention is to provide a bearing fault diagnosis method based on dynamic hybrid paths and federated multiple distillation, which effectively solves problems such as data silos, client data heterogeneity and model drift, and achieves better bearing fault diagnosis results.
[0005] Technical solution: The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation of the present invention includes the following steps:
[0006] Step 1: Use an accelerometer to collect real-time vibration signals from the bearing seat closest to the target monitoring bearing. Combined with the different health states of the bearing and the changes in equipment load, a multi-condition vibration dataset is constructed, and category labels are defined based on the fault type and load level.
[0007] Step 2: preprocess the vibration signal data obtained in step 1, and construct the preprocessed vibration signal data into a training set and a test set in proportion;
[0008] Step 3: The server initializes the global diagnostic model and broadcasts it to each client;
[0009] Step 4: Each client loads the global diagnostic model as a local diagnostic model, trains the local diagnostic model using the training set, and uploads the trained local diagnostic model parameters to the server.
[0010] Step 5: The server performs weighted aggregation on the received model parameters based on the dynamic weights generated by the Dirichlet distribution, updates the global diagnostic model at the current iteration number, and integrates the historical multi-round global diagnostic models according to the time decay weight as the latest global diagnostic model, and broadcasts the latest global diagnostic model to the client;
[0011] Step 6: Repeat steps 4 and 5 until the maximum number of iterations is reached, and each client obtains the final local diagnosis model;
[0012] In step 7, each client uses the final local diagnosis model to obtain the bearing fault diagnosis result.
[0013] Furthermore, step 3 includes:
[0014] A global diagnostic model is constructed on the server side, which adopts a deep convolutional neural network. The parameters of the global diagnostic model are initialized and broadcast to a total of K participating clients.
[0015] Furthermore, the steps of training the local diagnosis model using the training set include:
[0016] Step 401: Adaptively construct a multi-path hierarchical fusion network on the client, comprising independent local paths and dynamically constructed parallel hybrid paths. The local paths fully retain all network layers of the local diagnostic model and maintain the original feature propagation paths. The hybrid paths dynamically cascade the preceding layers of the local diagnostic model with the subsequent layers of the global diagnostic model based on the split points, forming multiple parallel branches with differentiated feature expression capabilities.
[0017] Step 402: Cosine similarity measurement based on the feature tensor output by the local path and the feature tensor output by the parallel hybrid path branch , dynamically assign weight coefficients to each path , the formula is:
[0018] ,
[0019] Where t and T represent the current training round and the total number of training rounds, respectively, and M represents the number of hybrid paths;
[0020] In step 403 , the local diagnosis model is jointly optimized by using a weighted cross entropy loss function, a multi-path KL divergence regularization loss function, and a missing category knowledge distillation loss function.
[0021] Furthermore, in step 401, when constructing the parallel hybrid path, the segmentation points are based on the feature similarity of each layer of the local diagnostic model and the global diagnostic model. and threshold Perform dynamic selection, where the calculation expression of feature similarity is:
[0022] ,
[0023] Where, is the L2 norm, and Representing the Output features of layer-local diagnosis model and global diagnosis model;
[0024] When the feature similarity of the lth layer Less than threshold When , the lth layer of the local diagnosis model is used as the segmentation point.
[0025] Furthermore, the hybrid path includes at least one of the following methods:
[0026] The shallow feature extraction layer of the local diagnosis model is cascaded with the mid- and deep-level feature layers and classification layers of the global diagnosis model;
[0027] The shallow and middle feature extraction layers of the local diagnosis model are cascaded with the deep feature layers and fully connected layers of the global diagnosis model;
[0028] The feature map outputs of all local feature extraction layers are cascaded with the fully connected layers of the global diagnosis model.
[0029] Furthermore, step 5 includes:
[0030] The server generates the client weight vector based on Dirichlet distribution ,in, satisfy , according to the dynamic weights, the received local diagnostic model parameters Perform weighted aggregation, expressed as:
[0031] ,
[0032] Where, represents the aggregation weight, is the number of local samples on the client;
[0033] The server executes the dynamic weighted federated averaging algorithm to obtain the global diagnostic model parameters under the current iteration round, which is expressed as: ;
[0034] The server maintains a fixed-capacity N historical model queue and aggregates the parameters generated after each round. Add to the historical queue. If the queue is full, use the first-in-first-out strategy to roll out historical model parameters according to time priority to update the queue.
[0035] Generate a time decay weight for the i-th historical model parameter in the queue, the formula is:
[0036] ,
[0037] Where, represents the time decay factor, i is the time index of the model in the queue;
[0038] Decay weight over time The weighted average of all historical model parameters in the queue is used to obtain the global diagnostic model parameters after integrating the new historical model. The formula is:
[0039] ,
[0040] Where N is the queue length, is the i-th historical model parameter.
[0041] Furthermore, in step 403, the calculation formula of the path KL divergence regularization loss function is:
[0042] ,
[0043] Where, express Probability distribution function, is the temperature parameter, and Represent the output logic values of the local path and the mth hybrid path respectively, represents the KL divergence, and M represents the number of mixing paths.
[0044] Furthermore, in step 403, the calculation process of the missing category knowledge distillation loss function includes:
[0045] The client traverses the local training set labels to identify the set of fault categories that exist locally, recorded as ;
[0046] based on Generate a Boolean mask matrix and perform a mask operation on the prediction outputs of the local diagnostic model and the global diagnostic model: that is, the global diagnostic model output logical values are Output logical value with local diagnostic model Belongs to category The masked logical value is obtained by setting the elements of and ;
[0047] The masked output values are temperature scaled and the normalized probability distribution is calculated. The formulas are:
[0048] ,
[0049] ,
[0050] Where, and Represent the normalized probability distribution of the local diagnosis model and the global diagnosis model on the client missing class respectively;
[0051] The KL divergence is used to measure the distribution difference between the two probability distributions in the missing class space, which is used as the missing class knowledge distillation loss. The calculation formula is:
[0052] .
[0053] Furthermore, in step 403, the loss function of the joint optimization local diagnosis model is:
[0054] ,
[0055] Where, represents the cross entropy loss, 、 represents the hyperparameter that determines the weight of the loss term.
[0056] Beneficial effects: Compared with the prior art, the present invention has the following significant advantages:
[0057] 1. Alleviate model drift under non-IID data and improve the generalization capability of cross-device fault diagnosis:
[0058] In an industrial multi-device environment, the operating conditions (such as load and speed) of different devices vary greatly, and the data distribution is highly heterogeneous. This paper constructs a dynamic hybrid path to fuse local features with global features, enabling the diagnostic model to simultaneously learn device specificity and global commonality. It also adaptively selects segmentation points based on the feature similarity between the local and global diagnostic models, generating a multi-path parallel fusion network.
[0059] 2. Solve the problem of client-side missing category fault identification and enhance the classification boundary capability:
[0060] Certain faults in industrial equipment, such as cracks in the inner ring of a bearing, have a low probability of occurrence, and individual clients may lack such samples. This invention strengthens classification boundaries through knowledge distillation, enabling the local diagnostic model to absorb the features learned by other clients about local rare faults, significantly improving the diagnostic accuracy of low-frequency faults. The missing class distillation loss is used to mask the categories that exist locally on the client, forcing the local diagnostic model to learn the knowledge of the server's global diagnostic model on the missing categories, thereby improving the classification boundary capabilities of the local diagnostic model.
[0061] 3. Enhance the robustness of the diagnostic model and suppress overfitting of small sample noise data:
[0062] There are a large number of edge devices (such as sensor nodes) in industrial sites. Their data volume is small and may contain noise (such as vibration signal interference). The present invention uses a queue's first-in-first-out mechanism to cache historical global models and a time-decay weighted strategy to integrate models, suppressing overfitting of single-device noise and ensuring the stability and reliability of the diagnostic model under complex working conditions. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 The flowchart of the bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation is shown in FIG.
[0064] Figure 2 A diagram of the dynamic hybrid path guidance constraint framework under knowledge distillation;
[0065] Figure 3 This is a diagram of the optimization framework based on multiple federated distillation;
[0066] Figure 4 This is the confusion matrix diagram of the fault diagnosis results. DETAILED DESCRIPTION
[0067] In order to make the purpose, technical solutions and advantages of this application more clear, this application is further described in detail below with reference to the accompanying drawings and embodiments.
[0068] Combine Figure 1 As shown, the bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation described in this embodiment includes the following steps:
[0069] Step 1: Use an acceleration sensor to collect the vibration signal of the bearing seat closest to the target monitoring bearing in real time. Combined with the different health states of the bearing and the changes in equipment load, a multi-condition vibration dataset is constructed, and category labels are jointly defined based on the fault type and load level.
[0070] In one example, the bearing states were categorized as healthy (NC), inner race fault (IF), outer race fault (OF), and rolling element fault (RF). The healthy state did not distinguish between damage sizes, while each fault state was categorized by damage size: 0.18mm, 0.36mm, and 0.54mm. Vibration signals were collected under four motor load conditions: 0hp, 1hp, 2hp, and 3hp. The same fault states under different loads were considered to be the same category, resulting in a dataset of 10 independent categories.
[0071] Step 2: preprocess the vibration signal data obtained in step 1, and construct the preprocessed vibration signal data into a training set and a test set in proportion.
[0072] The original vibration signal data X is standardized to eliminate the impact of dimensional differences on model training. The formula is:
[0073] ,
[0074] Where, is the data mean, is the standard deviation.
[0075] Dirichlet distribution is used to divide data among multiple clients, generating non-IID local datasets. The local data is then divided into a training set and a test set in a 3:1 ratio. The training set serves as the client's local data, and the local diagnostic model is iteratively updated.
[0076] Step 3: The server initializes the global diagnosis model and broadcasts it to each client.
[0077] Furthermore, step 3 includes:
[0078] A global diagnostic model is constructed on the server side, which adopts a deep convolutional neural network. The parameters of the global diagnostic model are initialized and broadcast to a total of K participating clients.
[0079] This example includes 1 server and K industrial clients. A global diagnosis model is built on the server side, and a local diagnosis model is built on each client. The global diagnosis model uses a deep convolutional neural network, which includes 3 convolutional layers and 2 fully connected layers set in sequence, denoted as { , The convolutional layer serves as the feature extraction layer, and the fully connected layer serves as the classification layer. The client adaptively generates a multi-path cascade network using the cosine similarity metric and a threshold segmentation strategy. The server also maintains a historical model buffer queue of size N to store historical global model parameters. The server initializes the fault diagnosis model and broadcasts the initial global model parameters to all industrial equipment clients. The client receives the latest model from the server and iteratively updates it based on its local private data according to the algorithm.
[0080] In step 4, each client loads the global diagnostic model as a local diagnostic model, trains the local diagnostic model using the training set, and uploads the trained local diagnostic model parameters to the server.
[0081] Combine Figures 2 to 3 ,The steps of training the local diagnosis model using the training set include:
[0082] Step 401: Adaptively construct a multi-path hierarchical fusion network on the client, comprising independent local paths and dynamically constructed parallel hybrid paths. The local paths fully retain all network layers of the local diagnostic model and maintain the original feature propagation paths. The hybrid paths dynamically cascade the preceding layers of the local diagnostic model with the subsequent layers of the global diagnostic model based on the split points, forming multiple parallel branches with differentiated feature expression capabilities.
[0083] Step 402: Cosine similarity measurement based on the feature tensor output by the local path and the feature tensor output by the parallel hybrid path branch , dynamically assign weight coefficients to each path , the formula is:
[0084] ,
[0085] Where t and T represent the current training round and the total number of training rounds, respectively, and M represents the number of hybrid paths;
[0086] In step 403 , the local diagnosis model is jointly optimized by using a weighted cross entropy loss function, a multi-path KL divergence regularization loss function, and a missing category knowledge distillation loss function.
[0087] In step 401, when constructing the parallel hybrid path, the segmentation points are based on the feature similarity of each layer of the local diagnostic model and the global diagnostic model. and threshold Perform dynamic selection, where the calculation expression of feature similarity is:
[0088] ,
[0089] Where, and Representing the The output features of the local diagnosis model and the global diagnosis model, is the L2 norm, ;
[0090] When the feature similarity of the lth layer Less than threshold When , the lth layer of the local diagnosis model is used as the segmentation point.
[0091] Among them, the weight coefficient of dynamic multipath is calculated The process includes:
[0092] Input the sample data X into the local path and the hybrid path respectively, and output the feature tensor of the local path Perform the global maximum pooling operation to generate the main feature vector, which is expressed as:
[0093] ,
[0094] Where, Represents the global maximum pooling operation; Represents batch size, number of channels, height, and width respectively;
[0095] The feature tensor output for the mth hybrid path Perform dimension alignment, if If is a multi-dimensional tensor (such as the output of a convolutional layer), global maximum pooling is performed to generate a feature vector; if If it is a two-dimensional vector (such as the output of the fully connected layer), its original dimension is retained directly;
[0096] If the dimensions of the main eigenvector and the mixed eigenvector are inconsistent, zero padding is performed to ensure that the dimensions of the two match.
[0097] The principal eigenvector With all mixed eigenvectors , calculate cosine similarity by batch, based on similarity score , generating exponential weights:
[0098] ,
[0099] ,
[0100] SHWH (Similarity-High Weight High) indicates that a higher weight is assigned when the similarity between the hybrid path output and the local path output is high; SLWH (Similarity-Low Weight High) indicates that a higher weight is assigned when the similarity is low.
[0101] According to the ratio factor of the current training round t and the total round T , linear interpolation of the two types of weights is performed to obtain the mixed weight, which is expressed as:
[0102] ,
[0103] Then normalize the mixed weights to get the dynamic weight coefficients:
[0104] .
[0105] In this example, the similarity threshold is set , filter similarity lower than The layer is used as the candidate set of segmentation points ; If the candidate set is empty, the intermediate feature layer Conv2 is selected as the split point by default to ensure path diversity.
[0106] The hybrid path dynamically cascades the preceding layers of the local diagnostic model with the subsequent layers of the global diagnostic model according to the segmentation points, forming multiple parallel branches with differentiated feature expression capabilities. The parameters of the global layer in the hybrid path remain frozen during training, and only the parameters of the local layers in the cascade layer participate in the gradient update.
[0107] When constructing a hybrid path, for example, the local data of industrial equipment 1 (including labels 2, 3, and 6) is mainly labeled 6. Its hybrid path can combine local shallow features (such as Conv1) with global deep features (such as Conv3) to avoid the local diagnostic model being overly biased towards label 6, which will cause the global diagnostic model to shift.
[0108] Furthermore, the hybrid path includes at least one of the following methods:
[0109] The shallow feature extraction layer of the local diagnosis model is cascaded with the mid- and deep-level feature layers and classification layers of the global diagnosis model;
[0110] The shallow and middle feature extraction layers of the local diagnosis model are cascaded with the deep feature layers and fully connected layers of the global diagnosis model;
[0111] The feature map outputs of all local feature extraction layers are cascaded with the fully connected layers of the global diagnosis model.
[0112] In this example, the path combination strategy is generated based on the split point. If Conv2 is used as the split point, the number of paths at this time is , each path consists of a cascade of local layers (trainable parameters) and global layers (frozen parameters):
[0113] Path 1 includes shallow local features and deep global features:
[0114]
[0115] Path 2 includes mid-level local features and deep global features:
[0116]
[0117] Path 3 includes deep local features and a global classification layer:
[0118]
[0119] Enter sample data The layer-by-layer forward propagation process under the hybrid path is:
[0120] ,
[0121] Where, Representative Path m The local layer combination, Represents the corresponding global layer combination.
[0122] In step 403, the calculation formula of the path KL divergence regularization loss function is:
[0123] ,
[0124] Where, express Probability distribution function, is the temperature parameter, and Represent the output logic values of the local path and the mth hybrid path respectively, represents the KL divergence, and M represents the number of mixing paths.
[0125] The missing class distillation loss masks the classes that exist locally on the client, forcing the model to learn global knowledge of the client's missing class faults. The regularization loss is used to constrain the distribution consistency between the hybrid path and the local path.
[0126] In step 403, the calculation process of the missing category knowledge distillation loss function includes:
[0127] The client traverses the local training set labels to identify the set of fault categories that exist locally, recorded as ;
[0128] based on Generate a Boolean mask matrix and perform a mask operation on the prediction outputs of the local diagnostic model and the global diagnostic model: that is, the global diagnostic model output logical values are Output logical value with local diagnostic model Belongs to category The masked logical value is obtained by setting the elements of and ;
[0129] The masked output values are temperature scaled and the normalized probability distribution is calculated. The formulas are:
[0130] ,
[0131] ,
[0132] Where, and Represent the normalized probability distribution of the local diagnosis model and the global diagnosis model on the client missing class respectively;
[0133] The KL divergence is used to measure the distribution difference between the two probability distributions in the missing class space, which is used as the missing class knowledge distillation loss. The calculation formula is:
[0134] .
[0135] Cross entropy loss is used to measure the local path output and the real fault label The difference is:
[0136] ,
[0137] in, Indicates the output logical value of the local path. is the Softmax function, C is the number of fault categories, is the fault label under the cth fault category.
[0138] After weighting the above three loss functions, we can get the joint loss function:
[0139] ,
[0140] Where, 、 is the weight coefficient.
[0141] Step 5: The server performs weighted aggregation on the received model parameters based on the dynamic weights generated by the Dirichlet distribution, updates the global diagnostic model at the current iteration number, and integrates the historical multi-round global diagnostic models according to the time decay weight as the latest global diagnostic model, and broadcasts the latest global diagnostic model to the client;
[0142] Furthermore, step 5 includes:
[0143] The server generates the client weight vector based on Dirichlet distribution ,in, satisfy , according to the dynamic weights, the received local diagnostic model parameters Perform weighted aggregation, expressed as:
[0144] ,
[0145] Where, represents the aggregation weight, is the number of local samples on the client;
[0146] The server executes the dynamic weighted federated averaging algorithm to obtain the global diagnostic model parameters under the current iteration round, which is expressed as: ;
[0147] The server maintains a fixed-capacity N historical model queue and aggregates the parameters generated after each round. Add to the historical queue. If the queue is full, use the first-in-first-out strategy to roll out historical model parameters according to time priority to update the queue.
[0148] Generate a time decay weight for the i-th historical model parameter in the queue, the formula is:
[0149] ,
[0150] Where, Represents the time decay factor, i is the time index of the model in the queue, the historical model is stored in an array, i=0 corresponds to the historical model parameters stored in the array with index subscript 0;
[0151] Decay weight over time The weighted average of all historical model parameters in the queue is used to obtain the global diagnostic model parameters after integrating the new historical model. The formula is:
[0152] ,
[0153] Where, is the i-th historical model parameter.
[0154] The latest global diagnostic model is used as the teacher model for knowledge distillation, providing stable and diverse global knowledge constraints to reduce the impact of single-round model fluctuations, alleviate the gradient deviation problem in client-side local training, and ensure the consistency of global convergence direction.
[0155] Step 6: Repeat steps 4 and 5 until the maximum number of iterations is reached, and each client obtains the final local diagnosis model;
[0156] In step 7, each client uses the final local diagnosis model to obtain the bearing fault diagnosis result, that is, the accuracy rate.
[0157] To further illustrate the effectiveness and excellence of the bearing fault diagnosis method of the present invention, the following examples are provided for illustration.
[0158] This example uses a bearing fault diagnosis method based on dynamic hybrid paths and federated multi-distillation to train a model and perform fault diagnosis on CWRU bearing data. The following steps are included:
[0159] Step 10: Build the bearing dataset.
[0160] This example uses the CWRU bearing dataset as an example. Its experimental fault types are shown in Table 1. This example has 10 types of faults, labeled 0 to 9, representing inner race, outer race, and ball faults of different fault sizes. NC indicates a healthy state, IF indicates an inner race fault, OF indicates an outer race fault, and RF indicates a rolling element fault.
[0161] Table 1
[0162]
[0163] Step 20: Initialize the federal diagnostic system.
[0164] The client receives the bearing fault diagnosis model broadcast by the server after initialization as a local diagnosis model. The local diagnosis model consists of three convolutional layers and two fully connected layers, where the convolutional layers mainly include maximum pooling layers and activation layers.
[0165] Step 30: Client local training.
[0166] The client calculates the similarity of each feature layer between the local diagnostic model and the global diagnostic model and dynamically selects the segmentation point based on the similarity threshold, constructs a parallel network containing local paths and hybrid paths, calculates the feature vector output by each path, and dynamically assigns the weight of each path based on feature similarity and training round ratio; the missing class distillation loss masks the locally existing fault categories and forces the learning of global knowledge of missing fault types; finally, a joint loss function of local path cross entropy loss, multi-path regularization constraint loss and missing class knowledge distillation loss is constructed to optimize local training.
[0167] Step 40: The server performs weighted aggregation based on the dynamic weight of the Dirichlet distribution, adopts a first-in-first-out strategy to manage and update the historical model queue, and applies time-decay weighting to the historical model queue to generate an integrated model.
[0168] Step 50: After the training is completed, the test bearing data is input into the trained local diagnosis model to obtain the fault diagnosis results. In this example, the confusion matrix diagram of the fault diagnosis results of the test data is as follows: Figure 4 As shown in Figure 2, the confusion matrix shows that the final local model prediction of each client is highly consistent with the real data, indicating that the local model is close to the optimal one.
[0169] The bearing fault diagnosis method described in the present invention was compared with other federated learning methods. Using the Dirichlet distribution to simulate real-world scenarios where industrial enterprise data is not independent and identically distributed (IID), an experimental comparison was conducted on the same Case Western Reserve University bearing dataset, using computation time and test set accuracy as test metrics. The analysis results, shown in Table 2, further demonstrate the superiority of the method described in the present invention in bearing fault diagnosis performance, based on both accuracy and computation time. This comparison revealed that the present invention achieved the best speed and accuracy compared to the federated distillation algorithm in scenarios with non-IID data.
[0170] Table 2
[0171]
Claims
1. A bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation, characterized in that: The following steps are involved: Step 1: Use an accelerometer to collect real-time vibration signals from the bearing seat closest to the target monitoring bearing. Combined with the different health states of the bearing and the changes in equipment load, a multi-condition vibration dataset is constructed, and category labels are defined based on the fault type and load level. Step 2: preprocess the vibration signal data obtained in step 1, and construct the preprocessed vibration signal data into a training set and a test set in proportion; Step 3: The server initializes the global diagnostic model and broadcasts it to each client; Step 4: Each client loads the global diagnostic model as a local diagnostic model, trains the local diagnostic model using the training set, and uploads the trained local diagnostic model parameters to the server. Step 5: The server performs weighted aggregation on the received model parameters based on the dynamic weights generated by the Dirichlet distribution, updates the global diagnostic model at the current iteration number, and integrates the historical multi-round global diagnostic models according to the time decay weight as the latest global diagnostic model, and broadcasts the latest global diagnostic model to the client; Step 6: Repeat steps 4 and 5 until the maximum number of iterations is reached, and each client obtains the final local diagnosis model; Step 7: Each client uses the final local diagnosis model to obtain the bearing fault diagnosis result; The steps for training the local diagnostic model using the training set include: Step 401: Adaptively construct a multi-path hierarchical fusion network on the client, comprising independent local paths and dynamically constructed parallel hybrid paths. The local paths fully retain all network layers of the local diagnostic model and maintain the original feature propagation paths. The hybrid paths dynamically cascade the preceding layers of the local diagnostic model with the subsequent layers of the global diagnostic model based on the split points, forming multiple parallel branches with differentiated feature expression capabilities. Step 402: Cosine similarity measurement based on the feature tensor output by the local path and the feature tensor output by the parallel hybrid path branch , dynamically assign weight coefficients to each path , the formula is: , Where t and T represent the current training round and the total number of training rounds, respectively, and M represents the number of hybrid paths; Step 403 , jointly optimizing the local diagnosis model by using a weighted cross entropy loss function, a multi-path KL divergence regularization loss function, and a missing category knowledge distillation loss function; In step 401, when constructing the hybrid path, the segmentation points are based on the feature similarity of each layer of the local diagnostic model and the global diagnostic model. and threshold Perform dynamic selection, where the calculation expression of feature similarity is: , Where, is the L2 norm, and Representing the Output features of layer-local diagnosis model and global diagnosis model; When the feature similarity of the lth layer Less than threshold When , the lth layer of the local diagnosis model is used as the segmentation point.
2. The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation according to claim 1, characterized in that: Step 3 includes: A global diagnostic model is constructed on the server side, which adopts a deep convolutional neural network. The parameters of the global diagnostic model are initialized and broadcast to a total of K participating clients.
3. The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation according to claim 2, characterized in that: The hybrid path includes at least one of the following: The shallow feature extraction layer of the local diagnosis model is cascaded with the mid- and deep-level feature layers and classification layers of the global diagnosis model; The shallow and medium feature extraction layers of the local diagnosis model are cascaded with the deep feature layers and fully connected layers of the global diagnosis model; The feature map outputs of all local feature extraction layers are cascaded with the fully connected layers of the global diagnosis model.
4. The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation according to claim 3, characterized in that: In step 5 include: The server generates the client weight vector based on Dirichlet distribution ,in, satisfy , according to the dynamic weights, the received local diagnostic model parameters Perform weighted aggregation, expressed as: , Where, represents the aggregation weight, is the number of local samples on the client; The server executes the dynamic weighted federated averaging algorithm to obtain the global diagnostic model parameters under the current iteration round, which is expressed as: ; The server maintains a fixed-capacity N historical model queue and aggregates the parameters generated after each round. Add to the historical queue. If the queue is full, use the first-in-first-out strategy to roll out historical model parameters according to time priority to update the queue. Generate a time decay weight for the i-th historical model parameter in the queue, the formula is: , Where, represents the time decay factor, i is the time index of the model in the queue; Decay weight over time The weighted average of all historical model parameters in the queue is used to obtain the global diagnostic model parameters after integrating the new historical model. The formula is: , Where N is the queue length, is the i-th historical model parameter.
5. The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation according to claim 4, characterized in that: In step 403, the calculation formula of the path KL divergence regularization loss function is: , Where, express Probability distribution function, is the temperature parameter, and Represent the output logic values of the local path and the mth hybrid path respectively, represents the KL divergence, and M represents the number of mixing paths.
6. The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation according to claim 5, characterized in that: In step 403, the calculation process of the missing category knowledge distillation loss function includes: The client traverses the local training set labels to identify the set of fault categories that exist locally, recorded as ; based on Generate a Boolean mask matrix and perform a mask operation on the prediction outputs of the local diagnostic model and the global diagnostic model: that is, the global diagnostic model output logical values are Output logical value with local diagnostic model Belongs to category The masked logical value is obtained by setting the elements of and ; The masked output values are temperature scaled and the normalized probability distribution is calculated. The formulas are: , , Where, and Represent the normalized probability distribution of the local diagnosis model and the global diagnosis model on the client missing class respectively; The KL divergence is used to measure the distribution difference between the two probability distributions in the missing class space, which is used as the missing class knowledge distillation loss. The calculation formula is: 。 7. The bearing fault diagnosis method based on dynamic hybrid path and federated multiple distillation according to claim 6, characterized in that: In step 403, the loss function of the joint optimization local diagnosis model is: , Where, represents the cross entropy loss, 、 represents the hyperparameter that determines the weight of the loss term.
Citation Information
Patent Citations
Rolling bearing fault diagnosis method based on combination of federated learning and knowledge distillation
CN118245778A
Rolling bearing fault diagnosis method based on fast fourier transform coding and lightweight convolutional neural network
US12222259B1