A mechanical fault diagnosis method based on multi-source information self-integrated neural network
By constructing a hybrid expert network and a hybrid expert model with a learnable distance metric, the problems of output inconsistency and domain differences in multi-source domain adaptation methods are solved, achieving more efficient fault diagnosis and improving the accuracy and adaptability of mechanical fault diagnosis.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- 苏州大珩数智科技有限公司
- Filing Date
- 2025-02-20
- Publication Date
- 2026-04-28
AI Technical Summary
Existing multi-source domain adaptation methods in fault diagnosis suffer from several drawbacks: output weighting depends on extensive domain-level operations, output combinations lack consistency, knowledge distillation struggles to extract accurate knowledge, multi-adversarial learning cannot fully resolve conflicts, feature selection cannot capture sufficient information, and weighted learning is difficult to adapt to different degrees of domain differences, leading to increased complexity and computational requirements.
A method based on multi-source information self-integration neural network is adopted. By constructing a hybrid expert network and using a learnable distance metric hybrid expert model, the method combines point-to-point distance metric, multi-task learning loss, joint training loss and multi-layer maximum mean difference to achieve cross-domain feature alignment and fault diagnosis.
It improves the accuracy and efficiency of fault diagnosis, can effectively integrate multi-source information, handle complex and nonlinear domain drift, ensure the consistency of feature representation in low-level and high-level modes, and enhance the adaptability and robustness of the model in different devices and environments.
Smart Images

Figure CN120145139B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of transfer learning technology, specifically relating to a mechanical fault diagnosis method based on a multi-source information self-integration neural network. Background Technology
[0002] In the operation and maintenance management of industrial systems, fault diagnosis (FD) plays a central role. This technology identifies and locates faults by monitoring and analyzing equipment operating data, which is crucial for ensuring efficient equipment operation and timely maintenance. Fault diagnosis involves not only fault identification and classification but also in-depth analysis of the causes and locations of faults. In the context of industrial automation and intelligent manufacturing, advancements in fault diagnosis technology are of significant importance for improving production efficiency, reducing maintenance costs, and preventing major accidents.
[0003] As industrial systems become increasingly complex, traditional fault diagnosis methods that rely on human experience face numerous challenges. For example, for complex mechanical equipment, it is often difficult to accurately diagnose and locate faults based solely on engineers' experience and intuitive judgment. Therefore, researchers and engineers have begun to seek more efficient and automated fault diagnosis methods to adapt to the increasingly complex industrial application needs.
[0004] Intelligent Fault Diagnosis (IFD), as an emerging technological approach, is gradually changing the traditional fault diagnosis model. It utilizes advanced machine learning and data analysis techniques, such as Artificial Neural Networks (ANN), Support Vector Machines (SVM), and Deep Neural Networks (DNN), to extract valuable information from massive amounts of equipment operation data to achieve automated fault detection and diagnosis. These technologies make the fault diagnosis process no longer dependent on the subjective experience of individual engineers, but based on data-driven objective analysis, thereby improving the accuracy and efficiency of fault diagnosis.
[0005] By building an end-to-end automated fault diagnosis system, IFD can not only monitor equipment status in real time, but also predict potential faults, providing a scientific basis for equipment maintenance and production decisions.
[0006] Currently, a Multi-Source Domain Adaptation (MDA) system analysis method is employed. By integrating data from different devices and environments, it provides a more comprehensive and in-depth perspective for understanding and analyzing faults. MDA, by integrating data from different devices and components, can more comprehensively capture fault signals and perform fault diagnosis. Although MDA theoretically provides a broader perspective for fault diagnosis, it still faces some technical challenges in practice.
[0007] Current multi-source domain selection and fusion methods have limitations. Output weighting relies on extensive domain-level operations, output combination simply merges outputs directly, and output alignment lacks guarantees to ensure consistent outputs across all source domains. Knowledge distillation may struggle to extract accurate knowledge from noise sources, multi-adversarial learning may not fully resolve conflicts, and feature selection may not capture sufficient informative features. Furthermore, weighted learning may still be difficult to adapt to varying degrees of domain differences, and multi-stage alignment may introduce additional complexity and computational requirements.
[0008] Therefore, a mechanical fault diagnosis method based on a multi-source information self-integration neural network is urgently needed. Summary of the Invention
[0009] To address the shortcomings of existing technologies, this invention provides a mechanical fault diagnosis method based on a multi-source information self-integration neural network.
[0010] To address the aforementioned technical problems, the present invention provides the following technical solution:
[0011] This invention provides a mechanical fault diagnosis method based on a multi-source information self-integration neural network, comprising the following steps:
[0012] S1: Select samples sequentially from each source domain, calculate the set of point-to-point distances relative to multiple source domains using the selected samples, and construct a sample group including positive and negative sample pairs based on the set of point-to-point distances.
[0013] S2: Establish a first loss function to reduce the point-to-point distance metric for positive sample pairs and increase the point-to-point distance metric for negative sample pairs, and obtain the point-to-point distance metric by training with the first loss function;
[0014] S3: Establish a second loss function that includes multi-task learning loss and joint training loss. Combine the source domain point-pair set distance metric with the second loss function to train a hybrid expert network that includes a shared feature extractor and a domain-specific feature extractor.
[0015] S4: Establish a third loss function to align low-level and high-level features across domains through multi-layer maximum mean difference, and use the third loss function to align the input and output features of the hybrid expert network;
[0016] S5: Train the hybrid expert network after aligning features to obtain a learnable distance metric hybrid expert model, and use the learnable distance metric hybrid expert model to perform cross-domain fault diagnosis of industrial machinery.
[0017] Preferably, the negative sample pair construction step in step S1 includes:
[0018] S11: Sort the point-to-point distances corresponding to each source domain in the point-to-point distance set in ascending order of value to obtain the sorting result;
[0019] S12: The selected sample and its source domain are used as positive sample pairs, and the minimum point pair distance value selected from the sorting results (excluding the source domain) is used as negative sample pairs.
[0020] Preferably, the expression for the first loss function in step S2 is:
[0021] L(W,x,y,S)=y·d(x,S)+(1-y)·max(0,md(x,S));
[0022] Where L(W, x, y, S) is the first loss function, W is the learnable weight matrix, y is the label of the sample group, d(x, S) represents the point-to-point distance metric between sample x and source domain S, and m is the boundary parameter controlling the maximum point-to-point distance metric of negative sample pairs.
[0023] Preferably, the expression for the output of the shared feature extractor in step S3 is:
[0024] z = G s (x′);
[0025] Where z represents the output feature of the shared feature extractor, x' represents the input sample belonging to the target domain, and G... s For shared feature extraction operations;
[0026] The expression for the output of the domain-specific feature extractor is:
[0027]
[0028] Among them, G p (z) represents the comprehensive output feature of the domain-specific feature extractor, where N is the number of source domains, i is the source domain index, and S... i For the i-th source domain, α(z, S) i ) represents the input z for the domain S iconfidence level This refers to the domain feature extraction operation of the i-th domain-specific feature extractor.
[0029] Preferably, the expression for the multi-task learning loss in step S3 is:
[0030]
[0031] Among them, L mtl The loss function is for multi-task learning, where i is the sample index in the source domain, F is the classification operation, and n is the number of samples. i Let be the total number of samples in the i-th source domain. For the j-th sample in the i-th source domain, Let N be the label value of the j-th sample from the i-th source domain, and N be the number of source domains. For the domain feature extraction operation of the i-th domain-specific feature extractor, G s For shared feature extraction operations;
[0032] The expression for the joint training loss is:
[0033]
[0034] Among them, L joint For joint training losses, G p For the extraction operation of the domain-specific feature extractor of the overall hybrid expert network, N is the number of source domains, n i Let F be the total number of samples in the i-th source domain, and F be the classification operation. Let G be the label value of the j-th sample in the i-th source domain. s For shared feature extraction operations, Let j be the j-th sample from the i-th source domain.
[0035] Preferably, the expression for the third loss function in step S4 is:
[0036]
[0037] Among them, L mmd For the third loss function, The loss function is for low-level feature alignment. Here, MMD represents the maximum mean difference in the kernel Hilbert space, T is the target domain, and G is the high-level feature alignment loss function. s For shared feature extraction operations, For the domain feature extraction operation of the i-th domain-specific feature extractor, S i Let i be the i-th source domain.
[0038] Preferably, the expression for the comprehensive loss function used in step S5 for the learnable distance metric hybrid expert model is:
[0039] L=λL joint +(1-λ)L mtl +λL mmd +L psd ;
[0040] Where L is the comprehensive loss function, and λ is the hyperparameter controlling the balance among loss terms. joint For joint training loss, L mtl For multi-task learning loss, L mmd For the third loss function, L psd This is the first loss function used for the distance metric of the training point pair set.
[0041] Compared with the prior art, the present invention has the following beneficial effects:
[0042] This invention first constructs a hybrid expert network. A shared feature extractor efficiently extracts domain-invariant features across all domains from the original vibration signal. These basic features are then further processed by the corresponding experts into domain-specific features. In the gating mechanism of the MoE-specific feature extractor, a linear transformation layer is trained using positive and negative sample pairs. The weights of this layer serve as the projection matrix for calculating the Mahalanobis distance of the point pair set. For each target domain sample, the learned distance metric calculates its proximity to each source domain. Domain-specific features from multiple experts are flexibly weighted and integrated to obtain comprehensive features. These comprehensive features are then used by a classifier for fault type prediction. Secondly, the LDMMoE model is trained. This invention employs a multi-level maximum mean discrepancy (MMD) method to achieve domain alignment, which can handle complex and nonlinear domain drift at multiple levels, ensuring consistency of features between the source and target domains in both low-level and high-level representations. The model training process employs a comprehensive loss function that combines point-to-set distance (PSD) metric learning loss, multi-task learning loss, joint training loss, and MMD loss. This comprehensive approach enables the model to learn and optimize more effectively, achieving a balance between gated output matching and independent task learning. Furthermore, this invention uses dynamically adjusted hyperparameters to help the model focus on different training tasks in the early and later stages of training.
[0043] This invention proposes a Learnable Distance Metric Mixture-of-Experts (LDMMoE) model for fault diagnosis of industrial machinery. The core of this model is training a learnable point-to-pair distance metric within a hybrid expert network, enabling automatic integration of multi-source information to enhance fault diagnosis accuracy. To address the challenges posed by MDA methods, this invention employs a learnable PSD metric to integrate multi-source diagnostic information, effectively fusing multiple source domains. Furthermore, to handle conflicting or noisy information from different sources, this invention inputs the domain-invariant features of samples into the expert network corresponding to their respective domains. Each expert is trained specifically for a particular domain. Additionally, this invention designs a tradeoff parameter between the maximum mean difference criterion and classification error that varies with the training process, aiming to find a balance between domain alignment and task learning. Attached Figure Description
[0044] Figure 1 This is a flowchart of a mechanical fault diagnosis method based on a multi-source information self-integration neural network provided by the present invention. Detailed Implementation
[0045] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention. The following embodiments are used to illustrate this invention but should not be used to limit the scope of this invention.
[0046] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0047] To better understand this invention, some related technologies appearing in this invention will be explained below.
[0048] Traditional machine learning methods:
[0049] Traditional machine learning methods have been used in fault diagnosis for some time, and these methods typically rely on carefully designed feature extraction techniques. For example, algorithms such as decision trees, random forests, and support vector machines are widely used in fault diagnosis, especially on small datasets. The key to these methods lies in manually selecting and extracting features, such as spectral analysis and time-domain statistics. However, this approach often depends on expert knowledge and experience and is difficult to adapt to scenarios with large amounts of data and high complexity. In addition, traditional methods have relatively limited generalization and adaptability, which may lead to performance degradation in rapidly evolving industrial environments.
[0050] Deep learning methods:
[0051] The rise of deep learning technology in IDF marks a shift from traditional machine learning methods to more advanced data processing approaches. Traditional machine learning methods, such as support vector machines and decision trees, typically require experts to perform feature engineering through complex methods, including extracting, selecting, and constructing features from raw data. This manual process is not only time-consuming and labor-intensive but also highly susceptible to limitations imposed by expert knowledge and experience, resulting in poor model generalization and adaptability. For example, when dealing with data exhibiting high dimensionality and complex patterns, traditional methods often struggle to capture key fault characteristics.
[0052] In contrast, deep learning methods overcome these limitations by automatically learning features from data. Deep learning models such as Convolutional Neural Networks (CNNs) and Recurrent Neural Networks (RNNs) can directly process raw data and automatically extract complex and meaningful features. For example, CNNs, through their convolutional layers, can effectively capture spatial features in image or waveform data, which is crucial for analyzing multidimensional data collected by sensors. Similarly, RNNs and their variants, such as Long Short-Term Memory (LSTM) networks, show unique advantages in processing time-series data, capturing temporal dependencies in the data, which is essential for understanding and diagnosing faults in dynamic and nonlinear industrial systems.
[0053] Another advantage of deep learning models is their ability to handle large-scale datasets and learn more complex and abstract feature representations from them. This is particularly important in fault diagnosis, as industrial environments typically generate vast amounts of operational and maintenance data. Deep learning models, such as Deep Belief Networks (DBNs), Convolutional Autoencoders (Autoencoders), and Generative Adversarial Networks (GANs), can extract key information from this large dataset, thereby providing more accurate and detailed fault diagnosis.
[0054] Transfer learning methods:
[0055] While deep learning methods have made significant progress in intelligent fault diagnosis, they face several challenges in supervised learning models. First, deep learning models typically require large amounts of labeled data for training to ensure sufficient generalization ability. However, in practical industrial applications, acquiring large-scale, high-quality labeled data is often time-consuming and costly. Furthermore, the performance of deep learning models can significantly degrade when faced with new environments that differ from the distribution of the training data, limiting the models' applicability and flexibility.
[0056] Transfer learning offers effective solutions in these areas. By leveraging knowledge learned on one task (the source task), transfer learning enables models to quickly adapt to new, related tasks (the target task), even if the target task has limited data. The key to this approach is finding commonalities between the source and target tasks and using these commonalities to guide the learning process for the target task.
[0057] Furthermore, transfer learning can mitigate the risk of model overfitting. Under limited data conditions, deep learning models may overlearn specific features from the training data, leading to a decline in their generalization ability on new data. Transfer learning, by introducing knowledge already learned on related tasks, can improve the model's stability and accuracy on new tasks. Another advantage of transfer learning in fault diagnosis is its ability to handle differences between different operating conditions or equipment types. In industrial environments, even equipment of the same type may exhibit different data characteristics under different operating conditions. Transfer learning can help models learn these differences and maintain efficient fault diagnosis performance under new operating conditions.
[0058] Domain adaptation methods in transfer learning
[0059] Domain adaptation (DA) is an important branch of transfer learning that focuses on addressing the problem of data distribution differences between the source and target domains. Within the transfer learning framework, it is typically assumed that the data distributions of the source and target domains are different. This distributional difference affects the model's performance in the target domain because the model is trained on source domain data. Domain adaptation aims to improve the model's generalization ability in the target domain by reducing the distributional differences between the two domains.
[0060] The basic concepts of domain adaptation include: Source domain (S): The dataset on which the model was originally trained, including the feature space X. S and tag space Y S Target domain (T): The new dataset to which the model is applied, possessing the feature space X. T In unsupervised domain adaptation, the label space Y of the target domain... T It is usually unknown.
[0061] The core task of domain adaptation is to find a mapping function F that can map the feature spaces of the source and target domains to a common feature representation, thereby reducing the distribution differences between domains.
[0062] To achieve this goal, domain adaptation primarily employs one of the following strategies:
[0063] Discrepancy-based methods: These methods achieve domain adaptation by quantifying and minimizing the feature differences between the source and target domains. Commonly used techniques include Maximum Mean Discrepancy (MMD) and Correlation Alignment (CORAL). These methods improve the model's generalization ability in the target domain by reducing the statistical differences between the two domains in the feature space.
[0064] Adversarial learning-based methods: Inspired by generative adversarial networks (GANs), these methods train an adversarial network to learn feature representations of the source and target domains, making it impossible for the discriminator to distinguish between the data of the two domains. This strategy forces the feature extractor to generate more generalized feature representations to fool the discriminator, thereby reducing the differences between domains.
[0065] Reconstruction-based methods attempt to simultaneously learn the classification task in the source domain and the reconstruction task in the target domain. This strategy typically involves an autoencoder structure that reconstructs the target domain data to ensure that the learned features are meaningful for both the source and target domains. This helps extract more representative features that are applicable to both domains.
[0066] Self-training-based methods utilize the model's predictions in the source domain to generate pseudo-labels for the target domain data. These pseudo-labels are then used for further training or fine-tuning of the model, allowing it to better adapt to the target domain. As the training process progresses, the quality of the pseudo-labels gradually improves, thereby enhancing the model's performance in the target domain.
[0067] Each strategy has its own characteristics and application scenarios. In the field of IDF, choosing the appropriate domain adaptation method is crucial to improving the accuracy and robustness of the model under different devices and operating conditions.
[0068] Besides the aforementioned domain adaptation strategies, domain adaptation can also be divided into Single-Source Domain Adaptation (SDA) and Multi-Source Domain Adaptation (MDA) based on the number of data sources. In Single-Source Domain Adaptation, the model learns from only one source domain S and attempts to transfer this knowledge to a target domain T. The main challenge in this case is that there may be significant differences in data distribution between the source and target domains. The goal of Single-Source Domain Adaptation is to find a mapping function F. S This makes the representation of the source domain data in the feature space as close as possible to the representation of the target domain data.
[0069] Multi-source domain adaptation considers multiple source domains S1, S2, ..., S n Simultaneous learning and transfer of this knowledge to the target domain T has the advantage of leveraging rich information from multiple source domains to improve the model's generalization ability in the target domain. The goal of multi-source domain adaptation is to find a series of mapping functions. This ensures that the representations of all source domains in the feature space are as similar as possible to the target domain.
[0070] The advantage of MDA lies in its ability to utilize data from multiple source domains, providing the model with richer information and more diverse data perspectives, thereby helping to improve the model's generalization ability and robustness in the target domain. This approach is particularly suitable for scenarios where a single data source cannot provide sufficient information to cover all possible situations. However, the challenge of MDA lies in effectively integrating the different feature distributions and potentially contradictory information from multiple source domains. Furthermore, MDA needs to handle the potential differences and conflicts between data from different source domains, which places higher demands on algorithm design and computational resource management. In summary, MDA provides a powerful tool for domain adaptation in complex environments, but it also requires more refined strategies and techniques to cope with its complexity.
[0071] The following is combined with Figure 1 Embodiments of the present invention are described.
[0072] This invention provides a mechanical fault diagnosis method based on a multi-source information self-integration neural network, comprising:
[0073] S1: Select samples sequentially from each source domain, calculate the set of point-to-point distances relative to multiple source domains using the selected samples, and construct a sample group including positive and negative sample pairs based on the point-to-point distance set; wherein, the construction steps of negative sample pairs in step S1 include:
[0074] S11: Sort the point-to-point distances corresponding to each source domain in the point-to-point distance set in ascending order of value to obtain the sorting result;
[0075] S12: The selected sample and its source domain are used as positive sample pairs, and the minimum point pair distance value selected from the sorting results (excluding the source domain) is used as negative sample pairs.
[0076] To assess the similarity or difference between two data points, common metrics include Euclidean distance and cosine distance. However, when dealing with multiple source domains, a more suitable approach is to compare a data point with a set of points, which leads to the Pair-to-Set Distance (PSD): given a data point x∈X and a set of source domains. The PSD between x and S can be defined as:
[0077]
[0078] Where a is the target coefficient to be solved, if S T S is nonsingular. The solution is expressed in closed-form as (S T S) -1 S T x; however, when S T When S approaches singularity or its inverse is numerically unstable, ridge regression is used to introduce a small constant λ to ensure the stability of the solution: Where I is the identity matrix.
[0079] To improve the accuracy of PSD calculation, a projection matrix P is introduced to project the sample into the desired space, and the corresponding PSD is redefined as:
[0080]
[0081] in, For the objective coefficient solution, M = P T P, defined in this formula as d(x, S), is considered as x and The Mahalanobis distance between them must be constant, and the matrix M must be a positive semi-definite matrix.
[0082] Based on the above, matrix M plays a crucial role in calculating d(x, S). An effective M should minimize the PSD between x and S when x∈S, while... To increase its PSD, this goal requires increasing the training set {S1, S2, ..., S}. N We learn an optimal M from the data, thereby achieving a learnable PSD metric.
[0083] To facilitate the learning of M, positive and negative sample pairs are created. Initially, M is set as the identity matrix I, and then, from any source domain S... i Select a sample x from the pool, calculate the PSD of each source domain, and then construct a positive sample pair, denoted as... in Represents x relative to S i The optimal coefficient vector is calculated using a formula that introduces a constant λ for the target coefficient. Furthermore, the PSD values are sorted in ascending order, and the smallest PSD values are selected to form negative sample pairs, labeled as... in Represents x relative to the j-th source domain S j The optimal coefficient vector is obtained by repeating this process for all samples in all source domains, thereby obtaining a series of positive and negative sample pairs that represent the similarity or difference between the samples and the source domains.
[0084] S2: Establish a first loss function to reduce the point-to-point distance metric for positive sample pairs and increase the point-to-point distance metric for negative sample pairs, and obtain the source domain point-to-point distance metric by training with the first loss function; wherein, the expression of the first loss function in step S2 is:
[0085] L(W,x,y,S)=y·d(x,s)+(1-y)·max(0,md(x,S));
[0086] Where L(W, x, y, S) is the first loss function, W is the learnable weight matrix, y is the label of the sample group, d(x, S) represents the point-to-point distance metric between sample x and source domain S, and m is the boundary parameter controlling the maximum point-to-point distance metric of negative sample pairs.
[0087] To optimize M during the training of the entire network, a linear transformation layer x→xW is introduced. T Where W is a learnable weight matrix, this layer is used to adjust the input pairs. Perform mapping.
[0088] The PSD with the projection matrix is then calculated as follows: Where l is the linear transformation layer, therefore, we define M = W T W.
[0089] To train W in l, a contrastive loss function is designed to encourage small PSD for positive sample pairs and large PSD for negative sample pairs. The contrastive loss function is defined as shown in the formula above, where y is the label of the sample pair, 1 for positive samples and 0 for negative samples.
[0090] The overall loss function Lpsd for PSD metric learning is given by the following equation:
[0091]
[0092] The objective function for PSD metric learning is:
[0093]
[0094] sttrace(M) = 1, M ≥ 0;
[0095] The requirement that trace(M) = 1 normalizes the PSD metric to be between 0 and 1, which simplifies the comparison of similarity between different samples and source domains and prevents the PSD metric from being too large or too small due to the size of matrix M. It also makes it easier to define the boundary parameter m as 1.
[0096] To keep the trace of M equal to 1, no specific measures are needed during training; simply divide M by its trace before calculating the PSD metric. Therefore, d(x, S) should be redefined as:
[0097]
[0098] Furthermore, because M is defined as W T Since M is the row vector of W, the Gram matrix of M is inherently positive semi-definite. Therefore, no additional constraints are needed to force M to be a positive semi-definite matrix. This inherent positive semi-definiteness provides simplicity and theoretical robustness for metric learning methods.
[0099] S3: Establish a second loss function that includes multi-task learning loss and joint training loss. Combine the source domain point-pair set distance metric with the second loss function to train a hybrid expert network that includes a shared feature extractor and a domain-specific feature extractor. The expression for the output of the shared feature extractor in step S3 is as follows:
[0100] z = G s (x′);
[0101] Where z represents the output feature of the shared feature extractor, x' represents the input sample belonging to the target domain, and G... s For shared feature extraction operations;
[0102] The expression for the output of the domain-specific feature extractor is:
[0103]
[0104] Among them, G p (z) represents the comprehensive output feature of the domain-specific feature extractor, where N is the number of source domains, i is the source domain index, and S... i For the i-th source domain, α(z, S) i ) represents the input z for the domain S i confidence level This refers to the domain feature extraction operation of the i-th domain-specific feature extractor.
[0105] The expression for the multi-task learning loss in step S3 is as follows:
[0106]
[0107] Among them, L mtl The loss function is multi-task learning loss, where j is the sample index in the source domain, F is the classification operation, and n is the number of samples. i Let be the total number of samples in the i-th source domain. For the j-th sample in the i-th source domain, Let N be the label value of the j-th sample from the i-th source domain, and N be the number of source domains. For the domain feature extraction operation of the i-th domain-specific feature extractor, G s For shared feature extraction operations;
[0108] The expression for the joint training loss is:
[0109]
[0110] Among them, L joint For joint training losses, G p For the extraction operation of the domain-specific feature extractor of the overall hybrid expert network, N is the number of source domains, n i Let F be the total number of samples in the i-th source domain, and F be the classification operation. Let G be the label value of the j-th sample in the i-th source domain. s For shared feature extraction operations, Let j be the j-th sample from the i-th source domain.
[0111] In this stage, for the input sample x∈T of the target domain, it is first pre-processed by the shared feature extractor of the deep convolutional neural network (CNN), and then the domain-specific features are obtained by the MoE-specific feature extractor.
[0112] To facilitate the training of the MoE-specific feature extractor using source domain data, we employed two different loss functions: multi-task learning loss and joint training loss.
[0113] Multi-task learning loss focuses on individually optimizing each expert network for its assigned subtask. The multi-task learning loss term enables expert networks to be trained independently, enhancing their individual diversity and specialization.
[0114] In contrast, the joint training loss aims to optimize all expert models using the ensemble output. This loss term fine-tunes the entire hybrid expert network to align with the predictions of the gating mechanism, thereby improving the overall performance of the MoE-specific feature extractor.
[0115] S4: Establish a third loss function to align low-level and high-level features across domains using multi-layer maximum mean difference, and align the output features of the hybrid expert network using this third loss function; wherein, the expression for the third loss function in step S4 is:
[0116]
[0117] Among them, L mmd For the third loss function, The loss function is for low-level feature alignment. Here, MMD represents the maximum mean difference in the kernel Hilbert space, T is the target domain, and G is the high-level feature alignment loss function. s For shared feature extraction operations, For the domain feature extraction operation of the i-th domain-specific feature extractor, S i Let i be the i-th source domain.
[0118] In this stage, the goal of domain alignment is to minimize the domain gap between the source and target domains.
[0119] The maximum mean difference (MMD) is a widely used technique for achieving domain alignment. The initial alignment loss function is configured according to the traditional MoE network feature alignment, and the initial steps involve aligning the input features (i.e., domain-invariant features).
[0120] While the MMD loss function mentioned above helps reduce domain drift in the early stages of the network, it may not be sufficient to align the final feature representations, which may still contain domain-specific information that could affect classifier performance.
[0121] To address this issue, the concept of multi-layer MMD is introduced, which aligns low-level and high-level features across domains. This approach enables the network to reduce domain drift at multiple stages. However, when processing the integrated output of MoE, it is difficult to prevent instability introduced by the PSD metric between source and target domain samples. Therefore, the output features of each expert are aligned individually through a multi-layer alignment loss function.
[0122] S5: Train the hybrid expert network after aligning the output features to obtain a learnable distance metric hybrid expert model, and use the learnable distance metric hybrid expert model to perform cross-domain fault diagnosis of industrial machinery.
[0123] In step S5, the expression for the comprehensive loss function used for the learnable distance metric hybrid expert model is:
[0124] L=λL joint +(1-λ)L mtl +λL mmd +L psd ;
[0125] Where L is the comprehensive loss function, and λ is the hyperparameter controlling the balance among loss terms. joint For joint training loss, L mtl For multi-task learning loss, L mmd For the third loss function, L psd This is the first loss function used for the distance metric of the training point pair set.
[0126] In this invention, a comprehensive loss function is used to train the model. This function consists of four parts: PSD metric and learning loss term L. psd MoE Multi-Task Learning Loss Item L mtl MoE Joint Training Loss Term L joint and MMD loss term L mmd .
[0127] Here, λ > 0 is a hyperparameter that controls the trade-off between different loss terms. The value of λ changes dynamically during training.
[0128]
[0129] Where p changes from 0 to 1 during training, and ζ adjusts the rate of change. Under this setting, λ is close to 0 at the beginning of training and gradually approaches 1 as training progresses. This dynamic adjustment of λ has two main purposes:
[0130] In the initial training phase, the PSD metric is not yet fully trained, and the integrated MoE output may lack its rationality. At this stage, the comprehensive loss focuses on the individual losses of each expert, and the expert network is optimized to perform well in its assigned subtasks. As training progresses, the MoE integrated output becomes more meaningful and reliable, so the comprehensive loss increasingly emphasizes the joint loss of the integrated output, and the expert network is optimized to match the predictions of the gating model.
[0131] In the initial stages of training, reducing MMD loss may not be particularly effective because the extracted features may lack meaning or representativeness for either domain. To strike a balance between domain alignment and task learning, early focus should be placed on enhancing features for the classification task. As training progresses, L... mmd The increase in the tradeoff parameters indicates a shift in focus towards improving the transferability of features for better generalization to the target domain. Notably, PSD metric learning is performed simultaneously with the backbone network, and their parameters are independent of each other; therefore, there is no need to perform L... psd The item settings are subject to trade-offs.
[0132] This invention provides a mechanical fault diagnosis method based on a multi-source information self-integration neural network. First, a hybrid expert network is constructed: a shared feature extractor efficiently extracts domain-invariant features across all domains from the original vibration signal. These basic features are then further processed by the corresponding experts into domain-specific features. In the gating mechanism of the MoE-specific feature extractor, a linear transformation layer is trained using positive and negative sample pairs. The weights of this layer serve as the projection matrix for calculating the Mahalanobis distance of the point pair set. For each target domain sample, the learned distance metric calculates its proximity to each source domain. Domain-specific features from multiple experts are flexibly weighted and integrated to obtain comprehensive features. These comprehensive features are then used by a classifier for fault type prediction.
[0133] Secondly, we trained the LDMMoE model: We employed a multi-level maximum mean difference (MMD) method for domain alignment, which handles complex and non-linear domain shifts at multiple levels, ensuring consistency of features between the source and target domains in both low-level and high-level representations. The model training process used a comprehensive loss function that combined PSD metric learning loss, multi-task learning loss, joint training loss, and MMD loss. This comprehensive approach allows the model to learn and optimize more effectively, achieving a balance between gated output matching and independent task learning. Furthermore, we used dynamically adjusted hyperparameters to help the model focus on different training tasks in the early and later stages of training.
[0134] The LDMMoE model trained by this invention consists of three basic components: 1) CNN shared feature extractor: This part aims to extract domain-invariant features and task-related information from multiple source and target domains; 2) MoE-specific feature extractor: This is a collection of multiple experts, each of whom focuses on learning the feature distribution for a single source domain and integrates their outputs through a learnable PSD metric; 3) Classifier: As the final prediction layer, it is essentially a multi-layer perceptron (MLP) that uses the combined features generated by the MoE components to predict the system state label.
[0135] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A mechanical fault diagnosis method based on a multi-source information self-integration neural network, characterized in that, Includes the following steps: S1: Select samples sequentially from each source domain, calculate the set of point-to-point distances relative to multiple source domains using the selected samples, and construct a sample group including positive and negative sample pairs based on the set of point-to-point distances. S2: Establish a first loss function to reduce the point-to-point distance metric for positive sample pairs and increase the point-to-point distance metric for negative sample pairs. The point-to-point distance metric is obtained by training with this first loss function. The expression for the first loss function is: ; in, For the first loss function, For learnable weight matrix, Labels for the sample groups, Indicates sample and source domain The distance metric between point pairs. To control the boundary parameters of the maximum point pair distance metric for negative sample pairs; S3: Establish a second loss function that includes multi-task learning loss and joint training loss. Combine the source domain point-pair set distance metric with the second loss function to train a hybrid expert network that includes a shared feature extractor and a domain-specific feature extractor. S4: A third loss function is established to align low-level and high-level features across domains using multi-layer maximum mean difference. This third loss function aligns the input and output features of the hybrid expert network. The expression for the third loss function is: ; ; ; in, For the third loss function, The loss function is for low-level feature alignment. For high-level feature alignment loss function, This represents the maximum mean difference in the reproducing kernel Hilbert space. For the target domain, For shared feature extraction operations, For the first Domain feature extraction operations of a domain-specific feature extractor. For the first One source domain; S5: Train the hybrid expert network after feature alignment to obtain a learnable distance metric hybrid expert model. Use this model for cross-domain fault diagnosis of industrial machinery. The expression for the comprehensive loss function used in the learnable distance metric hybrid expert model is: ; in, For the comprehensive loss function, To control the hyperparameters for balancing the loss terms, Losses due to joint training For multi-task learning loss, For the third loss function, This is the first loss function used for the distance metric of the training point pair set.
2. The mechanical fault diagnosis method based on a multi-source information self-integration neural network according to claim 1, characterized in that, The steps for constructing negative sample pairs in step S1 include: S11: Sort the point-to-point distances corresponding to each source domain in the point-to-point distance set in ascending order of value to obtain the sorting result; S12: The selected sample and its source domain are used as positive sample pairs, and the minimum point pair distance value selected from the sorting results (excluding the source domain) is used as negative sample pairs.
3. The mechanical fault diagnosis method based on a multi-source information self-integration neural network according to claim 1, characterized in that, The expression for the output of the shared feature extractor in step S3 is: ; , To share the output features of the feature extractor, For input samples belonging to the target domain, For shared feature extraction operations; The expression for the output of the domain-specific feature extractor is: ; in, The comprehensive output features of the domain-specific feature extractor For the number of source domains, The source domain index value, For the first One source domain, Indicates input For domain confidence level For the first Domain feature extraction operations of a domain-specific feature extractor.
4. The mechanical fault diagnosis method based on a multi-source information self-integration neural network according to claim 1, characterized in that, The expression for the multi-task learning loss in step S3 is: ; in, For multi-task learning loss, This is the sample index value in the source domain. For classification operations, For the first The total number of samples in each source domain For the first The first source domain One sample, For the first The first source domain The label value of each sample, For the number of source domains, For the first Domain feature extraction operations of a domain-specific feature extractor. For shared feature extraction operations; The expression for the joint training loss is: ; in, Losses due to joint training For the extraction operation of the domain-specific feature extractor of the overall hybrid expert network, For the number of source domains, For the first The total number of samples in each source domain For classification operations, For the first The first source domain The label value of each sample, For shared feature extraction operations, For the first The first source domain One sample.
Citation Information
Patent Citations
Medicine for treating cognitive decline and preparation method thereof
CN110974880A
Bearing fault diagnosis method under variable load based on subdomain adaptive adversarial network
CN115099270A