Method and device for bearing fault diagnosis

By adopting the joint learning strategy of primary and auxiliary branches and a convolutional neural network based on quadratic neurons in bearing fault diagnosis, the problem that deep learning models are difficult to effectively diagnose in unknown target domains is solved, and better generalization ability and reduced dependence on labeled data is achieved.

CN119293489BActive Publication Date: 2025-03-25HUBEI UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411815569.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-11
Publication Date
2025-03-25
Estimated Expiration
2044-12-11

AI Technical Summary

Technical Problem

In the prior art, bearing fault diagnosis methods based on deep learning are difficult to achieve effective fault diagnosis when facing data from unknown target domains, and obtaining high-quality labeled data requires huge manpower and professional knowledge investment.

Method used

The joint learning strategy of the primary branch and auxiliary branch is adopted to generate high confidence pseudo-labels through a mixed feature alignment strategy and entropy value minimization method. The primary branch uses these pseudo-labels for general knowledge learning. The primary branch and auxiliary branch use a convolutional neural network based on quadratic neurons. The primary branch implements classifier weight decomposition based on domain labels to improve the generalization ability of the model.

Benefits of technology

It effectively solves the problem of bearing fault diagnosis under unknown target conditions, improves the generalization ability of the model on unknown target domain, and reduces the dependence on high-quality labeled data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119293489B_ABST
    Figure CN119293489B_ABST
Patent Text Reader

Abstract

The present invention provides a method and device for bearing fault diagnosis, wherein the method comprises: obtaining target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing that needs to be fault diagnosed under target working conditions; inputting the target bearing data into a preset bearing fault diagnosis model, and outputting the fault diagnosis category of the target bearing through the preset bearing fault diagnosis model. Using the method of the present invention, the preset bearing fault diagnosis model obtained by training can be used for intelligent fault diagnosis under unknown target working conditions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of fault diagnosis, and in particular to a method, a device, an electronic device, a non-transitory computer-readable storage medium, and a computer program product for performing fault diagnosis on a bearing. Background Art

[0002] With the rapid development of intelligent manufacturing, the operating safety and reliability of mechanical equipment has become the focus of the industry. As a key component of rotating machinery, the health of bearings (e.g. rolling bearings) has a vital impact on the smooth and efficient operation of the entire system. Therefore, it is necessary to monitor the condition and diagnose faults of bearings.

[0003] In the related art, data-driven fault diagnosis methods (e.g., machine learning, deep learning) have been widely used. However, in actual industrial environments, due to changes in operating speed, load, and environmental noise levels, the characteristics of vibration signals will change. This difference in data distribution will reduce the accuracy and generalization ability of deep learning models on actual test data, resulting in domain shift problems. In addition, the training of deep learning models requires a large amount of high-quality annotated data. Under actual conditions, it is a difficult task to obtain enough fault samples and generate corresponding labels for all working conditions. This requires huge human labor and expertise to complete, which is not conducive to implementation.

[0004] In order to address the above-mentioned problems of "domain offset and huge workload of data annotation", transfer learning methods are introduced in related technologies. However, transfer learning methods in existing technologies still have limitations, that is, it is difficult to achieve fault diagnosis when faced with data in unknown target domains (i.e., unknown working conditions).

[0005] Therefore, how to design a new solution to solve the defects in the above-mentioned prior art has become a problem that needs to be solved urgently. Summary of the invention

[0006] The present invention provides a method, an apparatus, an electronic device, a non-transitory computer-readable storage medium and a computer program product for diagnosing bearing faults, so as to solve the defects in the prior art.

[0007] The present invention provides a method for diagnosing a bearing fault, comprising:

[0008] Acquire target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing requiring fault diagnosis under target operating conditions;

[0009] Inputting the target bearing data into a preset bearing fault diagnosis model, and outputting a fault diagnosis category of the target bearing through the preset bearing fault diagnosis model;

[0010] Wherein, the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data;

[0011] The preset training framework includes a main branch and a preset number K of auxiliary branches;

[0012] Each group of training data in the at least one group of training data includes a type of labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, a domain label of the labeled source domain sample data, and a domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches;

[0013] The data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the labeled source domain sample data and the preset number K types of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers.

[0014] The present invention also provides a device for diagnosing bearing faults, comprising:

[0015] The data acquisition module is configured to: acquire target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing requiring fault diagnosis under target working conditions;

[0016] A diagnosis module is configured to: input the target bearing data into a preset bearing fault diagnosis model, and output a fault diagnosis category of the target bearing through the preset bearing fault diagnosis model;

[0017] Wherein, the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data;

[0018] The preset training framework includes a main branch and a preset number K of auxiliary branches;

[0019] Each group of training data in the at least one group of training data includes a type of labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, a domain label of the labeled source domain sample data, and a domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches;

[0020] The data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the labeled source domain sample data and the preset number K types of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers

[0021] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, a method for bearing fault diagnosis as described in any one of the above is implemented.

[0022] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for diagnosing bearing faults as described in any one of the above is implemented.

[0023] The present invention also provides a computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method for diagnosing faults of a bearing as described in any one of the above is implemented.

[0024] As described above, the method for bearing fault diagnosis provided by the embodiment of the present invention adopts a joint learning strategy of the main branch and the auxiliary branch. Specifically, first, the auxiliary branch can adopt a hybrid feature alignment strategy and an entropy minimization method to generate high-confidence pseudo-labels, and the main branch can use the generated high-confidence pseudo-labels to learn general knowledge; second, the main branch and the auxiliary branch adopt a convolutional neural network based on secondary neurons, which can better capture the nonlinear and high-order features in the data; third, the main branch can realize classifier weight decomposition based on domain labels, that is, the classifier on the main branch can be decomposed into a general feature classifier and a specific feature classifier to explore the common knowledge between different domains, so as to better improve the generalization ability of the model in unknown target domains.

[0025] The preset bearing fault diagnosis model obtained through training (i.e., the main branch in the preset training framework) is used for intelligent fault diagnosis under unknown target operating conditions, which effectively solves the problems of complex and changeable rolling bearing operating conditions, lack of high-quality labeled data, and unknown target domain data for fault diagnosis in current actual industrial scenarios. It provides a reference method for rolling bearing fault diagnosis under actual industrial conditions. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0027] Figure 1 This is one of the flow charts of the method for diagnosing bearing faults provided by the embodiment of the present invention;

[0028] Figure 2 is a schematic diagram of the structure of the preset training framework provided in an embodiment of the present invention;

[0029] Figure 3 is a schematic diagram of the structure of a secondary neuron provided by an embodiment of the present invention;

[0030] Figure 4 This is a second flow chart of a method for diagnosing bearing faults provided by an embodiment of the present invention;

[0031] Figure 5 is the trade-off parameter provided by the embodiment of the present invention Schematic diagram of network search results;

[0032] Figure 6 is a schematic structural diagram of a device for bearing fault diagnosis provided by an embodiment of the present invention;

[0033] Figure 7 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0034] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0035] Summary of the invention concept:

[0036] Research has found that fault data in the target domain is a crucial resource for promoting positive knowledge transfer from the source domain, whether in the form of a small number of labeled samples or sufficient unlabeled samples. These target domain fault data can provide valuable information to help the model better adapt to the characteristics and distribution of the target domain. However, in actual engineering, the target domain data is often invisible, and transfer learning methods focus more on minimizing the distribution difference between the source domain and the target domain, while paying less attention to changes outside the known domain. Therefore, existing transfer learning methods are difficult to achieve good diagnostic results when facing data from unknown target domains.

[0037] In view of this, in the present invention, a solution for bearing fault diagnosis as described in the following embodiment is proposed.

[0038] Example:

[0039] The scheme for bearing fault diagnosis of the present invention is described below in conjunction with the accompanying drawings.

[0040] Figure 1 FIG. 1 is a flow chart of a method for diagnosing a bearing fault according to an exemplary embodiment of the present invention. This embodiment can be applied to electronic devices (eg, servers or cloud computing platforms), such as Figure 1 As shown, the method for bearing fault diagnosis includes the following steps:

[0041] S110, obtaining target bearing data.

[0042] The target bearing data is data characterizing the operating state of the target bearing that needs to be diagnosed for fault under target operating conditions.

[0043] The operating status data may be a vibration signal of the bearing.

[0044] The present invention does not limit the acquisition method. For example, an electronic device (eg, a server or a cloud computing platform) as an execution subject may communicate with a server storing the “target bearing data” to acquire the “target bearing data”.

[0045] S120, inputting the target bearing data into a preset bearing fault diagnosis model, and outputting a fault diagnosis category of the target bearing through the preset bearing fault diagnosis model.

[0046] Wherein, the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data.

[0047] The preset training framework (i.e., a semi-supervised domain generalization network based on auxiliary branches) includes a main branch and a preset number K of auxiliary branches. The present invention does not limit the value of the preset number K, for example, it can be 2, 3, or 4.

[0048] Each of the at least one set of training data includes a type of labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, a domain label of the labeled source domain sample data, and a domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data. For example, when K is 2, each set of training data includes 2 types of unlabeled source domain sample data.

[0049] It should be noted that, during the training phase, the main branch can calculate the classifier weight corresponding to the output based on the “domain label”. The specific details will be described below and will not be repeated here.

[0050] There is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches. That is, in the training phase, an auxiliary branch takes a corresponding type of unlabeled source domain sample data as input; Figure 2 The preset training framework shown includes 2 (i.e., K=2) auxiliary branches; wherein, the input corresponding to one auxiliary branch comes from the unlabeled source domain 2, and the input corresponding to the other auxiliary branch comes from the unlabeled source domain 3; the sample data from the labeled source domain 1 is also input into the two auxiliary branches respectively at the same time.

[0051] It should be noted that in Figure 2 In this example, the labeled source domain and the unlabeled source domain are mixed and sorted, that is, the target source domain 1, the unlabeled source domain 2, and the unlabeled source domain 3. Optionally, the unlabeled source domains can also be sorted separately, that is, the unlabeled source domain 1 and the unlabeled source domain 2; in this case, the input corresponding to one auxiliary branch comes from the unlabeled source domain 1, and the input corresponding to the other auxiliary branch comes from the unlabeled source domain 2; the sample data from the labeled source domain are also input into the two auxiliary branches at the same time.

[0052] The data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the labeled source domain sample data and the preset number K types of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers.

[0053] The “determined based on a preset allocation rule” can be based on random sampling, selecting the labeled source domain sample data and each type of unlabeled source domain sample data in each group of training data from the total sample data pool, so that the data volume ratio is different. Setting the training data in this way can enhance the generalization ability of the “preset bearing fault diagnosis model” obtained through training.

[0054] Each set of training data is each batch of training data, and the data volume M represents the total amount of data contained in a batch of data. The present disclosure does not limit this, for example, M can be 128.

[0055] As described above, the method for bearing fault diagnosis provided by the embodiment of the present invention adopts a joint learning strategy of the main branch and the auxiliary branch. Specifically, first, the auxiliary branch can adopt a hybrid feature alignment strategy and an entropy minimization method to generate high-confidence pseudo-labels, and the main branch can use the generated high-confidence pseudo-labels to learn general knowledge; second, the main branch and the auxiliary branch adopt a convolutional neural network based on secondary neurons, which can better capture the nonlinear and high-order features in the data; third, the main branch can realize classifier weight decomposition based on domain labels, that is, the classifier on the main branch can be decomposed into a general feature classifier and a specific feature classifier to explore the common knowledge between different domains, so as to better improve the generalization ability of the model in unknown target domains.

[0056] It should be noted that, in an embodiment of the present invention, the network structure of the main branch in the preset training framework is the same as the network structure of the auxiliary branch; and the preset bearing fault diagnosis model is based on the training of the main branch, so the network structure of the preset bearing fault diagnosis model is the same as the network structure of the main branch, and what is adjusted in the training stage are the parameters of the network level.

[0057] In view of this, in the above Figure 1 Based on the embodiment, as an optional implementation method, refer to Figure 2 The main branch shown describes the preset bearing fault diagnosis model.

[0058] As an alternative example, refer to Figure 2 The preset bearing fault diagnosis model includes a cascaded feature extractor and a classifier. The feature extractor includes a cascaded first convolution unit, a first maximum pooling layer (Maxpool 1), a second convolution unit, a second maximum pooling layer (Maxpool 2), a third convolution unit, a third maximum pooling layer (Maxpool 3), a fourth convolution unit, and a global average pooling unit. The classifier includes a flattening layer and a fully connected unit.

[0059] As an alternative example, refer to Figure 2, the first convolution unit includes a first convolution layer (QCnv 1), a batch normalization (BN) layer and an activation layer ReLU; the second convolution unit includes a second convolution layer (QCnv 2), a batch normalization (BN) layer and an activation layer ReLU; the third convolution unit includes a third convolution layer (QCnv 3), a batch normalization (BN) layer and an activation layer ReLU; the fourth convolution unit includes a fourth convolution layer (QCnv 4), a batch normalization (BN) layer and an activation layer ReLU; the global average pooling unit includes a global average pooling layer (GAP) and a flattening (Flatten) layer; the fully connected unit includes a fully connected layer and an activation layer Softmax.

[0060] As an optional example, the first convolution layer, the second convolution layer, the third convolution layer and the fourth convolution layer are all secondary convolution layers.

[0061] The secondary convolutional layer is composed of Figure 3 The secondary neuron structure shown. Figure 3 , given an input vector , the output of the secondary neuron As shown in the following formula:

[0062]

[0063] In the formula, , , represents the weight, represents the weight vector, is the bias. It is worth noting that It is just a distinction mark and has no actual meaning; Representation output The final output is given by and The weighted calculation is obtained. n represents the input vector X The dimension of p represents the input vector X The sequence number of the element in .

[0064] From the formula, we can see that quadratic neurons are superior to traditional neurons, mainly in the following aspects: (1) The nonlinear mapping of traditional neurons is only provided by the activation function, while quadratic neurons introduce power functions, thus having additional nonlinear mapping capabilities; (2) The representation of traditional neurons is a linear function, while the representation of quadratic neurons is a polynomial function. Polynomial functions have stronger complex function representation capabilities than linear functions.

[0065] As described above, the embodiment of the present invention utilizes secondary convolution based on secondary neurons to replace traditional convolution, and improves fault diagnosis performance by utilizing the powerful feature representation capability of secondary convolution.

[0066] As an optional example, the model parameters of the preset bearing fault diagnosis model are shown in Table 1.

[0067]

[0068] Table 1 Model parameters of the preset bearing fault diagnosis model

[0069] Among them, the convolution kernel parameter of the first convolution layer QConv1 is 64, the step size is 1, the corresponding activation function is ReLU, the input parameter is (-1,1,1024), and the output parameter is (-1,16,961). Among them, it is necessary to explain the meaning of the input parameter (-1,1, 1024), "-1" represents the batch size, "1" represents the number of channels, and "1024" represents the data dimension. Since the parameters of the "first convolution layer QConv1" are consistent with the principle of the parameter setting mode of the other remaining levels, the explanation of the specific parameters of other levels can be determined by referring to Table 1 and the adaptability of the explanation of the "first convolution layer QConv1", which will not be repeated here.

[0070] For example, the convolution kernel parameter of the second convolution layer is 16 and the step size is 1; the convolution kernel parameter of the third convolution layer is 5 and the step size is 1; the convolution kernel parameter of the fourth convolution layer is 5 and the step size is 1; the kernel parameters of the first maximum pooling layer, the second maximum pooling layer, and the third maximum pooling layer are all 2 and the step size is 2; the kernel parameters of the global average pooling layer are all 4.

[0071] As an optional example, the main branch includes a cascaded feature extractor to be trained and a classifier to be trained; each auxiliary branch of the preset number K auxiliary branches includes a cascaded feature extractor to be trained and a classifier to be trained; the network structure of the feature extractor to be trained is the same as the network structure of the feature extractor; the network structure of the classifier to be trained is the same as the network structure of the classifier.

[0072] Preferably, when the preset number K takes a value of 2, the following can be obtained: Figure 2 The preset training framework shown.

[0073] Reference Figure 2 For example, the auxiliary branch semi-supervised domain generalization network (ABSDGN) proposed in the present invention adopts a joint learning strategy of auxiliary branches and main branches.

[0074] The auxiliary branch is used to generate pseudo labels based on limited annotated source domain data and unannotated source domain data. The data are respectively and 2 unlabeled source domain data Construct two domain adaptation tasks and generate pseudo labels as shown in the following formula:

[0075]

[0076] In the formula, and They are k The first i samples and the corresponding generated pseudo labels, It is k A feature extractor of auxiliary branches, It is k Auxiliary branch classifier.

[0077] In the above Figures 1 to 3 Based on the embodiment, as an optional implementation method, refer to Figure 4 The training step of training the preset bearing fault diagnosis model based on the preset training framework and at least one set of training data includes:

[0078] S410: Obtain the at least one set of training data.

[0079] Among them, each group of training data in the at least one group of training data includes a type of labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, the domain label of the labeled source domain sample data, and the domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data.

[0080] As an optional example, taking the preset number K as 2 as an example, in step S410, the training data can be obtained through the following steps.

[0081] I) Collect mechanical vibration signals under four different working conditions; II) Preprocess the collected mechanical vibration signals under four different working conditions to obtain a labeled source domain, two unlabeled source domains and one unknown target domain. Among them, one labeled source domain and two unlabeled source domains are involved in the training of the model; one unknown target domain can be used to test the trained model.

[0082] Specifically, a labeled source domain is represented as:

[0083]

[0084] The two unlabeled source domains are represented as:

[0085]

[0086] In the formula, m Indicates the amount of labeled source domain sample data in each set of training data; Indicates the first kunlabeled source domains (in the training phase, corresponding to the input k The number of samples in auxiliary branches; Indicates the first i samples, express The corresponding label; It means the k The first i samples.

[0087] The unknown target domain is represented as: , its data distribution and annotation source domain and unlabeled source domain The data is different and can be expressed by the following formula:

[0088]

[0089] In this example, optionally, the four different working conditions may correspond to different vibration frequencies, such as 65Hz, 70Hz, 75Hz, and 80Hz. The mechanical vibration signal (as data characterizing the health status of the bearing) collected under each working condition (one working condition can be considered to correspond to one source domain) may include 9 health levels (i.e., 9 category labels). Specifically, the 9 health levels include: normal, medium inner ring fault, severe inner ring fault, medium outer ring fault, severe outer ring fault, medium rolling element fault, severe rolling element fault, medium combination fault, and severe combination fault. Finally, data under four different working conditions are obtained, each of which has nine health states (i.e., the above 9 category labels), 500 samples in each category, and 1024 data points in each sample. In this way, when the preset number K is 2, 500×9=4500 sample data are used for training each source domain, and 3×4500=13500 sample data are totaled for the three source domains. As mentioned above, in the training stage, 13,500 sample data can be divided into multiple batches (i.e., multiple groups) and input into the preset training framework. The data volume of the labeled source domain sample data in each batch and the data volume of each type of unlabeled source domain sample data in the two types of unlabeled source domain sample data are determined based on a preset allocation rule, so that the data volume ratio between the labeled source domain sample data and each type of unlabeled source domain sample data in each group of training data is different, so as to enhance the generalization ability of the "preset bearing fault diagnosis model" obtained by training.

[0090] Optionally, the preprocessing methods for the collected mechanical vibration signals under four different working conditions are the same, that is, the collected vibration signals are divided into multiple signal segments according to a set sample length, and the maximum-minimum normalization method is used for data preprocessing.

[0091] S420. For each auxiliary branch of the preset number K auxiliary branches, the labeled source domain sample data in each group of training data and the unlabeled source domain sample data matching the auxiliary branch are input into the auxiliary branch, and the corresponding branch pseudo-label, branch fault diagnosis category prediction value, branch labeled feature and branch unlabeled feature are output through the auxiliary branch.

[0092] Reference Figure 2 Example (K=2), including labeled source domain 1 and unlabeled source domain 2 (corresponding to auxiliary branch 1, i.e. Figure 2 The branch where the “feature extractor 1” is shown) and the unlabeled source domain 3 (corresponding to the auxiliary branch 2, i.e. Figure 2 The branch where "Feature Extractor 2" is located).

[0093] exist Figure 2 In this example, the "Feature Extractor 1" in Auxiliary Branch 1 outputs the annotation features ( Figure 2 "labeled features") and branched unlabeled features ( Figure 2 The “unlabeled feature 2” shown in the figure); the “labeled feature” and “unlabeled feature 2” are used to calculate the hybrid feature alignment loss. The “classifier 1” in the auxiliary branch 1 outputs the branch pseudo label and the branch fault diagnosis category prediction value. Among them, the branch pseudo label (i.e. Figure 2 The “low confidence pseudo label 2” shown in the figure is used to purify the “high confidence pseudo label 2” based on the entropy loss; the branch fault diagnosis category prediction value is used to calculate the cross entropy loss with the true label 1 (that is, the “category true value label” corresponding to the labeled source domain sample data).

[0094] Similarly, the “Feature Extractor 2” in Auxiliary Branch 2 outputs the labeled features ( Figure 2 "labeled features") and branched unlabeled features ( Figure 2 The “labeled feature” and “unlabeled feature 3” are used to calculate the hybrid feature alignment loss. The “classifier 2” in the auxiliary branch 2 outputs the branch pseudo label and the branch fault diagnosis category prediction value. Among them, the branch pseudo label (i.e. Figure 2 The “low confidence pseudo label 3” shown in the figure is used to purify the “high confidence pseudo label 3” based on the entropy loss; the branch fault diagnosis category prediction value is used to calculate the cross entropy loss with the true label 1 (that is, the “category true value label” corresponding to the labeled source domain sample data).

[0095] S430, input the labeled source domain sample data and a preset number K of unlabeled source domain sample data in each group of training data into the main branch, and output through the main branch a general fault diagnosis category prediction value that matches the labeled source domain sample data, a general fault diagnosis category prediction value that matches the preset number K of unlabeled source domain sample data, a specific fault diagnosis category prediction value that matches the labeled source domain sample data, and a specific fault diagnosis category prediction value that matches the preset number K of unlabeled source domain sample data.

[0096] The main branch determines a general classifier weight and a preset number of K specific classifier weights based on the domain labels of the labeled source domain sample data and a preset number of K domain labels of unlabeled source domain sample data.

[0097] During the training phase, refer to Figure 2 The main branch can be divided into a general classifier in the classifier of the main branch based on the weight decomposition method of the domain label and a specific classifier (The number of specific classifiers is consistent with the number of unlabeled source domains).

[0098] Specifically, through domain generalization learning, a domain-specific classifier that performs well It can be expressed by the following formula:

[0099]

[0100] in, is the specific classifier of the kth unlabeled source domain; is the domain label correlation coefficient Combination mapping of is a domain-invariant feature classifier. Therefore, in order to obtain a universal feature classifier , just discard and You can get it.

[0101] Specifically, the weight decomposition method based on domain labels is as follows:

[0102]

[0103] Table 2 Algorithm for weight decomposition based on domain labels

[0104] Reference Figure 2 , the general fault diagnosis category prediction value that matches the labeled source domain sample data and the general fault diagnosis category prediction value that matches a preset number K of unlabeled source domain sample data can be used to calculate the cross entropy loss together with the high confidence pseudo label 2 and the true label 1.

[0105] Similarly, the specific fault diagnosis category prediction value that matches the labeled source domain sample data and the specific fault diagnosis category prediction value that matches a preset number K of unlabeled source domain sample data can be used to calculate the cross entropy loss together with the high confidence pseudo label 3 and the true label 1.

[0106] S440. Utilizing a preset comprehensive loss function, based on the category true value labels and corresponding branch pseudo-labels in each group of training data, branch fault diagnosis category prediction values, branch labeled features, branch unlabeled features, a preset number K of specific classifier weights, general fault diagnosis category prediction values ​​that match labeled source domain sample data, general fault diagnosis category prediction values ​​that match a preset number K of unlabeled source domain sample data, specific fault diagnosis category prediction values ​​that match labeled source domain sample data, and specific fault diagnosis category prediction values ​​that match a preset number K of unlabeled source domain sample data, obtain the function value of the comprehensive loss function.

[0107] S450. Based on the function value of the comprehensive loss function, the main branch and a preset number K of auxiliary branches are trained until a preset training completion condition is met, and the preset bearing fault diagnosis model is obtained from the main branch.

[0108] It should be noted that based on the above example (i.e., the case where K=2), according to the distribution of data under four different working conditions (i.e., the division of labeled source domain, unlabeled source domain, and target source domain), 12 semi-supervised domain generalization tasks, namely Tsak1~Task12, can be established as shown in Table 3.

[0109]

[0110] Table 3 Semi-supervised domain generalization tasks

[0111] Referring to Table 3, for each task, the above steps S410 to S450 can be executed for training; the difference between different tasks lies in "different data allocation situations for four different working conditions".

[0112] Preferably, when all 12 tasks are completed, the preset bearing fault diagnosis model can be considered to be optimal. Of course, whether all 12 tasks need to be executed depends on the situation, and the present invention does not limit this. For example, when only the first 6 tasks are executed, the output results of the preset bearing fault diagnosis model meet the requirements, and there is no need to execute subsequent tasks.

[0113] exist Figure 4 Based on the implementation mode, as an optional example, step S440 may include the following steps:

[0114] 1) Based on the category true value labels and the corresponding branch pseudo labels in each group of training data, the branch fault diagnosis category prediction values, the branch labeled features, the branch unlabeled features, the preset number K specific classifier weights, the general fault diagnosis category prediction values ​​of the matching labeled source domain sample data, the general fault diagnosis category prediction values ​​of the matching labeled source domain sample data, the specific fault diagnosis category prediction values ​​of the matching labeled source domain sample data, and the specific fault diagnosis category prediction values ​​of the matching unlabeled source domain sample data, respectively calculate the function value of the branch classifier cross entropy loss function, the function value of the hybrid feature alignment loss function, the function value of the total entropy loss function, the function value of the orthogonal constraint loss function, the function value of the main network general classification cross entropy loss function, and the function value of the main network specific classification cross entropy loss function.

[0115] In this example, optionally, based on the category truth label in each set of training data and the corresponding branch fault diagnosis category prediction value, calculating the function value of the branch classifier cross entropy loss function includes:

[0116] The function value of the cross entropy loss function of the branch classifier is calculated by the following calculation formula (1);

[0117] (1)

[0118] Wherein, K represents the preset number; m Indicates the amount of labeled source domain sample data in each set of training data; represents the cross entropy loss function; Indicates the first i Annotated source domain sample data; Indicates the corresponding The true value label of the category; Indicates k Auxiliary feature extractors in auxiliary branches; Indicates k Auxiliary classifiers in auxiliary branches; Indicates k The branch fault diagnosis category prediction value corresponding to the auxiliary branch.

[0119] In this example, in order to reduce the domain shift phenomenon and improve the quality of pseudo labels, a hybrid feature alignment (HFA) strategy is proposed by combining the maximum mean difference (MMD) and correlation alignment (CORAL). Among them, the maximum mean difference (MMD) focuses on the overall distribution of samples and aligns the distribution by measuring the mean difference between the labeled source domain and the unlabeled source domain in the reproducing kernel Hilbert space (RKHS); the correlation alignment (CORAL) focuses on the statistical characteristics of the samples and reduces the distribution difference by aligning the covariance matrix of the labeled source domain and the unlabeled source domain features.

[0120] Specifically, based on the branch labeled features and the branch unlabeled features corresponding to each set of training data, the function value of the hybrid feature alignment loss function is calculated, including:

[0121] The function value of the hybrid feature alignment loss function is calculated by the following calculation formulas (2) to (4);

[0122] (2)

[0123] (3)

[0124] (4)

[0125] in, represents the branch annotation feature; Indicates that the branch has no labeled features; Represents a batch of labeled source domain sample data; Represents a batch of unlabeled source domain sample data; represents the annotated source domain; Indicates k The unlabeled source domain corresponding to the auxiliary branches; represents the reproducing kernel Hilbert space; represents the covariance measure of the corresponding labeled source domain; represents the covariance measure corresponding to the unannotated source domain; Indicates the amount of source domain sample data with the smallest proportion in each set of training data; represents the F-norm.

[0126] As mentioned above, the proposed HFA strategy, by combining MMD and CORAL, achieves a more comprehensive distribution alignment in terms of both overall distribution and statistical properties, thereby improving the generalization ability of the model.

[0127] In this example, optionally, in order to further improve the quality of pseudo labels generated by the auxiliary branch, an entropy minimization strategy commonly used in semi-supervised learning is introduced.

[0128] Based on the branch pseudo labels corresponding to each set of training data, the function value of the total entropy loss function is calculated, including:

[0129] The function value of the total entropy loss function is calculated by the following calculation formula (5);

[0130] (5)

[0131] in, Indicates k The number of unlabeled source domain samples corresponding to the auxiliary branches; Represents the entropy value calculation function; Indicates k The auxiliary branch corresponds to j branch pseudo-labels.

[0132] In this example, optionally, in order to ensure that different The separation between them adopts the strategy of orthogonal constraints to promote different As much as possible, they are orthogonal to improve the generalization ability and performance of the model. Specifically, the function value of the orthogonal constraint loss function can be calculated based on the preset number K specific classifier weights corresponding to each set of training data, including:

[0133] The function value of the orthogonal constraint loss function is calculated by the following calculation formula (6);

[0134] (6)

[0135] in, Indicates that the main branch matches k Specific classifier weights for unlabeled source domains; represents the F-norm; Represents the identity matrix.

[0136] In this example, optionally, based on the general fault diagnosis category prediction value of the matching labeled source domain sample data corresponding to each group of training data and the general fault diagnosis category prediction value of the matching preset number K types of unlabeled source domain sample data, the function value of the general classification cross entropy loss function of the main network is calculated, including:

[0137] The function value of the general classification cross entropy loss function of the main network is calculated by the following calculation formula (7);

[0138] (7)

[0139] in, represents the general classifier weight; Represents the labeled source domain sample data of the input The corresponding category truth label; Represents the preset number K of unlabeled source domain sample data as input The corresponding branch pseudo labels; Represents the general fault diagnosis category prediction value of the matched labeled source domain sample data; It represents the prediction value of the general fault diagnosis category matching the preset number K types of unlabeled source domain sample data; represents the cross entropy loss function.

[0140] In this example, optionally, based on the specific fault diagnosis category prediction value of the matching labeled source domain sample data corresponding to each group of training data and the specific fault diagnosis category prediction value of the matching preset number K of unlabeled source domain sample data, the function value of the main network specific classification cross entropy loss function is calculated, including:

[0141] The function value of the main network specific classification cross entropy loss function is calculated by the following calculation formula (8);

[0142] (8)

[0143] in, Indicates that the main branch matches k Specific classifier weights for unlabeled source domains; Represents the labeled source domain sample data of the input The corresponding category truth label; Represents the preset number K of unlabeled source domain sample data as input The corresponding branch pseudo labels; Indicates that the main branch matches k A specific classifier for the unlabeled source domain outputs a prediction value for a specific fault diagnosis category for the labeled source domain sample data; Indicates that the main branch matches k A specific classifier for an unlabeled source domain, outputting a prediction value for a specific fault diagnosis category for the unlabeled source domain sample data; represents the cross entropy loss function.

[0144] 2) Using preset weights, the function values ​​of the branch classifier cross entropy loss function, the function value of the mixed feature alignment loss function, the function value of the total entropy loss function, the function value of the orthogonal constraint loss function, the function value of the main network general classification cross entropy loss function and the function value of the main network specific classification cross entropy loss function are weightedly fused to obtain the function value of the comprehensive loss function.

[0145] Optionally, the function value of the comprehensive loss function may be calculated by the following calculation formulas (9) and (10);

[0146] (9)

[0147] (10)

[0148] in, represents the total classification loss function on the main branch; express The trade-off parameters of Represents the hybrid feature alignment loss function The trade-off parameters of Represents the total entropy loss function trade-off parameters.

[0149] As an optional example, the method for determining the preset weights may include: optimizing the hyperparameters in the preset training framework (i.e., based on the auxiliary branch semi-supervised domain generalization network) to determine the best hyperparameters.

[0150] Hyperparameter optimization is mainly for Three trade-off parameters are used for optimization, among which The dynamic adjustment method is adopted, which increases with the number of iterations. Specifically,

[0151]

[0152] and are two hyperparameters, which determine the degree of hfa loss and entropy loss respectively. In order to better obtain the optimal trade-off parameters, the grid search method is used to find the trade-off parameters. to search for it.

[0153] Specifically, from two identical sets {0.001, 0.005, 0.01, 0.05, 0.1, 0.5, 1.0}, Two trade-off parameters are searched to obtain the best diagnostic performance on the unknown target domain. The combination is the optimal hyperparameter combination. Figure 5 It can be seen that The optimal combination is 0.5 and 0.005.

[0154] Based on the above embodiment, as an optional implementation, step S450 "training the main branch and a preset number K of auxiliary branches based on the function value of the comprehensive loss function until a preset training completion condition is met" may include:

[0155] First, the function value of the comprehensive loss function is transmitted to the main branch and a preset number K of auxiliary branches by means of gradient back propagation; secondly, the main branch and a preset number K of auxiliary branches adjust the network parameters of each network layer according to the function value of the comprehensive loss function; finally, the step of obtaining the function value of the comprehensive loss function to the step of adjusting the network parameters of each network layer are iteratively executed until the preset training completion condition is met.

[0156] Among them, the preset training completion condition may be that the function value of the comprehensive loss function converges, or the number of iterations reaches a preset threshold.

[0157] In summary, the preset training framework (i.e., the auxiliary branch semi-supervised domain generalization network) proposed in the present invention aims to obtain a feature extractor with strong generalization ability in the training stage. and classifier Therefore, the training process can be divided into two stages. In the first stage, the auxiliary branch generates pseudo labels using limited labeled source domain data and unlabeled source domain data, and adopts a hybrid feature alignment strategy, entropy minimization, and auxiliary branch classification loss minimization method to purify the generated pseudo labels. In the second stage, the main branch uses the generated high-quality pseudo labels to learn general knowledge, and adopts a weight decomposition method based on domain labels to increase the generalization performance of the model.

[0158] The preset bearing fault diagnosis model obtained through training (i.e., the main branch in the preset training framework) is used for intelligent fault diagnosis under unknown target operating conditions, which effectively solves the problems of complex and changeable rolling bearing operating conditions, lack of high-quality labeled data, and unknown target domain data for fault diagnosis in current actual industrial scenarios. It provides a reference method for rolling bearing fault diagnosis under actual industrial conditions.

[0159] The device for diagnosing bearing faults provided by the present invention is described below. The device for diagnosing bearing faults described below and the method for diagnosing bearing faults described above can be referenced to each other.

[0160] Figure 6 FIG. 1 is a schematic diagram of a structure of a device for bearing fault diagnosis provided by an exemplary embodiment of the present invention. Figure 6 As shown, the device for diagnosing bearing faults comprises:

[0161] The data acquisition module 610 is configured to: acquire target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing that needs to be fault diagnosed under the target working condition; the diagnosis module 620 is configured to: input the target bearing data into a preset bearing fault diagnosis model, and output the fault diagnosis category of the target bearing through the preset bearing fault diagnosis model; wherein the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data; the preset training framework includes a main branch and a preset number K of auxiliary branches; each set of training data in the at least one set of training data includes a labeled source domain sample data and a corresponding category truth label, a preset number K of unlabeled Source domain sample data, domain labels of the annotated source domain sample data, and domain labels of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K types of unlabeled source domains and the preset number K of auxiliary branches; the data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the annotated source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the annotated source domain sample data and the preset number K types of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers.

[0162] Figure 7 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 7As shown, the electronic device may include: a processor 710, a communication interface 720, a memory 730 and a communication bus 740, wherein the processor 710, the communication interface 720 and the memory 730 communicate with each other through the communication bus 740. The processor 710 may call the logic instructions in the memory 730 to execute a method for fault diagnosis of a bearing, the method comprising: obtaining target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing that needs to be fault diagnosed under the target working condition; inputting the target bearing data into a preset bearing fault diagnosis model, and outputting the fault diagnosis category of the target bearing through the preset bearing fault diagnosis model; wherein the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data; the preset training framework includes a main branch and a preset number K of auxiliary branches; each set of training data in the at least one set of training data includes a labeled source domain sample data and a corresponding category truth label , a preset number K of unlabeled source domain sample data, the domain labels of the labeled source domain sample data, and the domain labels of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches; the data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the labeled source domain sample data and the preset number K of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers.

[0163] In addition, the logic instructions in the above-mentioned memory 730 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present invention can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.

[0164] On the other hand, the present invention also provides a computer program product, which includes a computer program, which can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the method for bearing fault diagnosis provided by the above methods, the method comprising: obtaining target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing that needs to be fault diagnosed under target working conditions; inputting the target bearing data into a preset bearing fault diagnosis model, and outputting a fault diagnosis category for the target bearing through the preset bearing fault diagnosis model; wherein the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data; the preset training framework includes a main branch and a preset number K of auxiliary branches; the at least one set of training Each group of training data in the data includes a labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, a domain label of the labeled source domain sample data, and a domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches; the data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the labeled source domain sample data and the preset number K of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers.

[0165] On the other hand, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to execute the method for bearing fault diagnosis provided by the above-mentioned methods, the method comprising: obtaining target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing that needs to be fault diagnosed under target working conditions; inputting the target bearing data into a preset bearing fault diagnosis model, and outputting a fault diagnosis category for the target bearing through the preset bearing fault diagnosis model; wherein the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data; the preset training framework includes a main branch and a preset number K of auxiliary branches; each set of training data in the at least one set of training data includes a standard annotated source domain sample data and corresponding category true value labels, a preset number K of unlabeled source domain sample data, domain labels of the annotated source domain sample data, and domain labels of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches; the data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the annotated source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data are determined based on a preset allocation rule so that the data volume ratio between the annotated source domain sample data and the preset number K of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers.

[0166] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0167] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0168] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for bearing fault diagnosis, characterized in that: include: Acquire target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing requiring fault diagnosis under target operating conditions; Inputting the target bearing data into a preset bearing fault diagnosis model, and outputting a fault diagnosis category of the target bearing through the preset bearing fault diagnosis model; Wherein, the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data; The preset training framework includes a main branch and a preset number K of auxiliary branches, wherein the auxiliary branches are used to generate pseudo labels by adopting a hybrid feature alignment strategy and an entropy minimization method; Each group of training data in the at least one group of training data includes a type of labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, a domain label of the labeled source domain sample data, and a domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches; The data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data are determined based on a preset allocation rule, so that the data volume ratio between the labeled source domain sample data and the preset number K types of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers; For each auxiliary branch of the preset number K of auxiliary branches, the auxiliary branch is used to input the labeled source domain sample data in each set of training data and the unlabeled source domain sample data matching the auxiliary branch, and the auxiliary branch is used to output the corresponding branch pseudo label, branch fault diagnosis category prediction value, branch labeled feature and branch unlabeled feature; The main branch is used to input the labeled source domain sample data and a preset number K of unlabeled source domain sample data in each group of training data, and the main branch is used to output a general fault diagnosis category prediction value that matches the labeled source domain sample data, a general fault diagnosis category prediction value that matches the preset number K of unlabeled source domain sample data, a specific fault diagnosis category prediction value that matches the labeled source domain sample data, and a specific fault diagnosis category prediction value that matches the preset number K of unlabeled source domain sample data; wherein the main branch determines a general classifier weight and a preset number K of specific classifier weights based on the domain labels of the labeled source domain sample data and the domain labels of the preset number K of unlabeled source domain sample data.

2. The method according to claim 1, characterized in that The preset bearing fault diagnosis model includes a cascaded feature extractor and a classifier; The feature extractor includes a cascaded first convolution unit, a first maximum pooling layer, a second convolution unit, a second maximum pooling layer, a third convolution unit, a third maximum pooling layer, a fourth convolution unit and a global average pooling unit; The classifier includes a flattening layer and a fully connected unit.

3. The method according to claim 2, characterized in that The first convolution unit includes a first convolution layer, a batch normalization layer and an activation layer ReLU; The second convolution unit includes a second convolution layer, a batch normalization layer and an activation layer ReLU; The third convolution unit includes a third convolution layer, a batch normalization layer and an activation layer ReLU; The fourth convolution unit includes a fourth convolution layer, a batch normalization layer and an activation layer ReLU; The global average pooling unit includes a global average pooling layer and a flattening layer; The fully connected unit includes a fully connected layer and an activation layer Softmax; The first convolution layer, the second convolution layer, the third convolution layer and the fourth convolution layer are all secondary convolution layers; The convolution kernel parameter of the first convolution layer is 64 and the step size is 1; The convolution kernel parameter of the second convolution layer is 16 and the step size is 1; The convolution kernel parameter of the third convolution layer is 5 and the step size is 1; The convolution kernel parameter of the fourth convolution layer is 5 and the step size is 1; The kernel parameters of the first maximum pooling layer, the second maximum pooling layer, and the third maximum pooling layer are all 2 and the step size is 2; The kernel parameter of the global average pooling layer is 4.

4. The method according to claim 2, characterized in that: The main branch includes a cascade of a feature extractor to be trained and a classifier to be trained; Each auxiliary branch of the preset number K of auxiliary branches includes a cascaded feature extractor to be trained and a classifier to be trained; The network structure of the feature extractor to be trained is the same as the network structure of the feature extractor; The network structure of the classifier to be trained is the same as the network structure of the classifier.

5. The method according to any one of claims 1 to 4, characterized in that The step of training the preset bearing fault diagnosis model based on the preset training framework and at least one set of training data comprises: Acquire the at least one set of training data; Utilizing a preset comprehensive loss function, based on the category true value labels and corresponding branch pseudo labels in each group of training data, branch fault diagnosis category prediction values, branch labeled features, branch unlabeled features, a preset number K of specific classifier weights, a universal fault diagnosis category prediction value that matches labeled source domain sample data, a universal fault diagnosis category prediction value that matches a preset number K of unlabeled source domain sample data, a specific fault diagnosis category prediction value that matches labeled source domain sample data, and a specific fault diagnosis category prediction value that matches a preset number K of unlabeled source domain sample data, the function value of the comprehensive loss function is obtained; Based on the function value of the comprehensive loss function, the main branch and a preset number K of auxiliary branches are trained until a preset training completion condition is met, and the preset bearing fault diagnosis model is obtained from the main branch.

6. The method according to claim 5, characterized in that Using a preset comprehensive loss function, based on the category true value label and the corresponding branch pseudo label in each group of training data, the branch fault diagnosis category prediction value, the branch labeled feature, the branch unlabeled feature, the preset number K specific classifier weights, the general fault diagnosis category prediction value of the matching labeled source domain sample data, the general fault diagnosis category prediction value of the matching preset number K unlabeled source domain sample data, the specific fault diagnosis category prediction value of the matching labeled source domain sample data, and the specific fault diagnosis category prediction value of the matching preset number K unlabeled source domain sample data, the function value of the comprehensive loss function is obtained, including: Based on the category true value labels and corresponding branch pseudo labels in each group of training data, branch fault diagnosis category prediction values, branch labeled features, branch unlabeled features, a preset number of K specific classifier weights, a general fault diagnosis category prediction value that matches labeled source domain sample data, a general fault diagnosis category prediction value that matches a preset number of K unlabeled source domain sample data, a specific fault diagnosis category prediction value that matches labeled source domain sample data, and a specific fault diagnosis category prediction value that matches a preset number of K unlabeled source domain sample data, respectively calculate the function value of the branch classifier cross entropy loss function, the function value of the hybrid feature alignment loss function, the function value of the total entropy loss function, the function value of the orthogonal constraint loss function, the function value of the main network general classification cross entropy loss function, and the function value of the main network specific classification cross entropy loss function; Using preset weights, the function values ​​of the branch classifier cross entropy loss function, the function value of the mixed feature alignment loss function, the function value of the total entropy loss function, the function value of the orthogonal constraint loss function, the function value of the main network general classification cross entropy loss function and the function value of the main network specific classification cross entropy loss function are weightedly fused to obtain the function value of the comprehensive loss function.

7. The method according to claim 6, characterized in that Based on the category true value label in each set of training data and the corresponding branch fault diagnosis category prediction value, the function value of the branch classifier cross entropy loss function is calculated, including: The function value of the cross entropy loss function of the branch classifier is calculated by the following calculation formula (1); (1) Wherein, K represents the preset number; m Indicates the amount of labeled source domain sample data in each set of training data; represents the cross entropy loss function; Indicates the first i Annotated source domain sample data; Indicates the corresponding The true value label of the category; Indicates k Auxiliary feature extractors in auxiliary branches; Indicates k Auxiliary classifiers in auxiliary branches; Indicates k The branch fault diagnosis category prediction value corresponding to the auxiliary branch; Based on the branch labeled features and the branch unlabeled features corresponding to each set of training data, the function value of the hybrid feature alignment loss function is calculated, including: The function value of the hybrid feature alignment loss function is calculated by the following calculation formulas (2) to (4); (2) (3) (4) in, represents the branch annotation feature; Indicates that the branch has no labeled features; Represents a batch of labeled source domain sample data; Represents a batch of unlabeled source domain sample data; represents the annotated source domain; Indicates k The unlabeled source domain corresponding to the auxiliary branches; represents the reproducing kernel Hilbert space; represents the covariance measure of the corresponding labeled source domain; represents the covariance measure corresponding to the unannotated source domain; Indicates the amount of source domain sample data with the smallest proportion in each set of training data; represents the F-norm; Based on the branch pseudo labels corresponding to each set of training data, the function value of the total entropy loss function is calculated, including: The function value of the total entropy loss function is calculated by the following calculation formula (5); (5) in, Indicates k The number of unlabeled source domain samples corresponding to the auxiliary branches; Represents the entropy value calculation function; Indicates k The auxiliary branch corresponds to j branch pseudo labels; Based on the preset number K of specific classifier weights corresponding to each set of training data, the function value of the orthogonal constraint loss function is calculated, including: The function value of the orthogonal constraint loss function is calculated by the following calculation formula (6); (6) in, Indicates that the main branch matches k Specific classifier weights for unlabeled source domains; represents the F-norm; represents the identity matrix; Based on the general fault diagnosis category prediction value of the matching labeled source domain sample data corresponding to each group of training data and the general fault diagnosis category prediction value of the matching preset number K of unlabeled source domain sample data, the function value of the general classification cross entropy loss function of the main network is calculated, including: The function value of the general classification cross entropy loss function of the main network is calculated by the following calculation formula (7); (7) in, represents the general classifier weight; Represents the labeled source domain sample data of the input The corresponding category truth label; Represents the preset number K of unlabeled source domain sample data as input The corresponding branch pseudo labels; Represents the general fault diagnosis category prediction value of the matched labeled source domain sample data; It represents the prediction value of the general fault diagnosis category matching the preset number K types of unlabeled source domain sample data; represents the cross entropy loss function; Based on the specific fault diagnosis category prediction value of the matching labeled source domain sample data corresponding to each group of training data and the specific fault diagnosis category prediction value of the matching preset number K of unlabeled source domain sample data, the function value of the main network specific classification cross entropy loss function is calculated, including: The function value of the main network specific classification cross entropy loss function is calculated by the following calculation formula (8); (8) in, Indicates that the main branch matches k Specific classifier weights for unlabeled source domains; Represents the labeled source domain sample data of the input The corresponding category truth label; Represents the preset number K of unlabeled source domain sample data as input The corresponding branch pseudo labels; Indicates that the main branch matches k A specific classifier for the unlabeled source domain outputs a prediction value for a specific fault diagnosis category for the labeled source domain sample data; Indicates that the main branch matches k A specific classifier for an unlabeled source domain, outputting a prediction value for a specific fault diagnosis category for the unlabeled source domain sample data; represents the cross entropy loss function.

8. The method according to claim 7, characterized in that The method uses preset weights to weightedly fuse the function values ​​of the branch classifier cross entropy loss function, the function value of the mixed feature alignment loss function, the function value of the total entropy loss function, the function value of the orthogonal constraint loss function, the function value of the main network general classification cross entropy loss function, and the function value of the main network specific classification cross entropy loss function to obtain the function value of the comprehensive loss function, including: The function value of the comprehensive loss function is calculated by the following calculation formulas (9) and (10); (9) (10) in, represents the total classification loss function on the main branch; express The trade-off parameters of Represents the hybrid feature alignment loss function The trade-off parameters of Represents the total entropy loss function trade-off parameters.

9. The method according to claim 5, characterized in that The function value based on the comprehensive loss function, training the main branch and a preset number K of auxiliary branches until a preset training completion condition is met, includes: The function value of the comprehensive loss function is transmitted to the main branch and a preset number K of auxiliary branches by gradient back propagation; The main branch and a preset number K of auxiliary branches adjust network parameters of each network layer according to the function value of the comprehensive loss function; Iterate the steps of obtaining the function value of the comprehensive loss function to adjusting the network parameters of each network layer until a preset training completion condition is met.

10. A device for diagnosing bearing faults, characterized in that: include: The data acquisition module is configured to: acquire target bearing data; wherein the target bearing data is data characterizing the operating state of the target bearing requiring fault diagnosis under target working conditions; A diagnosis module is configured to: input the target bearing data into a preset bearing fault diagnosis model, and output a fault diagnosis category of the target bearing through the preset bearing fault diagnosis model; Wherein, the preset bearing fault diagnosis model is trained based on a preset training framework and at least one set of training data; The preset training framework includes a main branch and a preset number K of auxiliary branches, wherein the auxiliary branches are used to generate pseudo labels by adopting a hybrid feature alignment strategy and an entropy minimization method; Each group of training data in the at least one group of training data includes a type of labeled source domain sample data and a corresponding category true value label, a preset number K of unlabeled source domain sample data, a domain label of the labeled source domain sample data, and a domain label of each type of unlabeled source domain sample data in the preset number K of unlabeled source domain sample data; there is a one-to-one mapping relationship between the preset number K of unlabeled source domains and the preset number K of auxiliary branches; The data volume M of each group of training data in the at least one group of training data is the same, and the data volume of the labeled source domain sample data in each group of training data and the data volume of each type of unlabeled source domain sample data in the preset number K types of unlabeled source domain sample data are determined based on a preset allocation rule, so that the data volume ratio between the labeled source domain sample data and the preset number K types of unlabeled source domain sample data contained in each group of training data is different; K and M are positive integers; For each auxiliary branch of the preset number K of auxiliary branches, the auxiliary branch is used to input the labeled source domain sample data in each set of training data and the unlabeled source domain sample data matching the auxiliary branch, and the auxiliary branch is used to output the corresponding branch pseudo label, branch fault diagnosis category prediction value, branch labeled feature and branch unlabeled feature; The main branch is used to input the labeled source domain sample data and a preset number K of unlabeled source domain sample data in each group of training data, and the main branch is used to output a general fault diagnosis category prediction value that matches the labeled source domain sample data, a general fault diagnosis category prediction value that matches the preset number K of unlabeled source domain sample data, a specific fault diagnosis category prediction value that matches the labeled source domain sample data, and a specific fault diagnosis category prediction value that matches the preset number K of unlabeled source domain sample data; wherein the main branch determines a general classifier weight and a preset number K of specific classifier weights based on the domain labels of the labeled source domain sample data and the domain labels of the preset number K of unlabeled source domain sample data.

Citation Information

Patent Citations

  • Rolling bearing unknown fault detection method based on cross-domain relevance representation

    CN116150635A

  • Multi-classifier fine-grained bearing fault diagnosis field adaptive method and system

    CN117871101A