Mechanical fault diagnosis method and device based on feature and decision double fusion network, model construction method, product and storage medium
Through the dual fusion network of features and decisions, combined with frequency domain information learning and low-rank decision fusion, the generalization ability and robustness problems of mechanical fault diagnosis under variable speed conditions are solved, and fault diagnosis effects with high accuracy and stability are achieved.
Patent Information
- Application Number
- CN202510719337.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-30
- Publication Date
- 2025-09-09
AI Technical Summary
Existing mechanical fault diagnosis technology has poor generalization ability and robustness under variable speed conditions. It mainly relies on single sensor data and ignores multi-perspective decision information, resulting in insufficient adaptability and robustness.
A mechanical fault diagnosis method based on a dual fusion network of features and decisions is adopted. The global and local frequency domain features of multiple sensors are extracted through the frequency domain information learning module, and the features are fused using the cross-attention mechanism. Combined with the low-rank decision fusion and adaptive weight optimization strategy, the loss function is dynamically adjusted to improve the diagnostic accuracy.
It achieves high stability and reliability fault diagnosis under variable speed conditions, significantly improving the overall performance and adaptability of the model, especially maintaining high accuracy under conditions of few samples.
Smart Images

Figure CN120611342A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of mechanical health status monitoring and fault diagnosis, and more specifically, relates to a mechanical fault diagnosis method, model building method, product, device and storage medium based on a feature and decision dual fusion network. Background Art
[0002] Mechanical equipment plays a critical role in industries ranging from manufacturing to transportation. Due to harsh working environments and variable operating conditions, core components of mechanical equipment, such as bearings and gears, are prone to failure. Accurate fault diagnosis is crucial to maintaining productivity, ensuring safety, and minimizing operating costs. In actual production, mechanical equipment often operates at different speeds, such as during startup and shutdown. The monitoring signals collected in this situation have strong non-stationary and nonlinear characteristics, which makes it very difficult to establish a mapping relationship between signal characteristics and fault modes. Therefore, it is crucial to develop mechanical fault diagnosis technology that can effectively handle variable speeds.
[0003] In recent years, research on mechanical fault diagnosis technology under variable speed conditions has mainly focused on order tracking technology and its derivative methods. However, this method usually requires expensive equipment, skilled technicians and high computing resources. There are also many studies based on nonlinear signal analysis methods, among which time-frequency analysis is the most widely used method, which can accurately identify signal frequency components and track their changes over time. For example, Zhao et al. proposed an iterative adaptive critical mode decomposition method to estimate instantaneous frequency for planetary gearbox fault diagnosis. Jiang et al. proposed an iterative adaptive Vold-Kalman filter for accurate instantaneous frequency estimation and fault dynamic feature extraction. However, this method relies on a large amount of expert knowledge to determine the fault category, which seriously limits its application in industrial scenarios.
[0004] With the rise of artificial intelligence technology, deep learning technology has demonstrated its powerful feature extraction capabilities in the field of fault diagnosis. Therefore, intelligent fault diagnosis under variable speed conditions has gradually become a research hotspot in the past five years. For example, Guo et al. proposed a deep nonlinear ordered cyclic convolutional network for fault diagnosis of induction motor drive systems. The network extracts features by designing a nonlinear order cyclic spectrum analysis layer, converting the measurement signal into an angular domain signal, thereby effectively alleviating the impact of speed fluctuations. Yang et al. proposed a feature fusion generative adversarial network with deeply embedded category information to solve the fault diagnosis problem under limited sample conditions. Although these methods have achieved remarkable results, the following problems still exist:
[0005] (1) Mainstream methods mainly rely on data from a single sensor as input, which limits the generalization ability of the model under variable speed conditions.
[0006] (2) Most methods based on multi-sensor fusion ignore the decision-making information from multiple perspectives, which leads to poor adaptability and robustness of the methods.
[0007] Therefore, the existing fault diagnosis technology still has obvious defects under variable speed conditions and is difficult to meet actual industrial needs. Summary of the Invention
[0008] In response to the above-mentioned defects or improvement needs of the prior art, the present invention provides a mechanical fault diagnosis method based on a dual fusion network of features and decisions, the purpose of which is to solve the technical problems of poor generalization ability and robustness of existing fault diagnosis technologies, and to be widely applicable to various constant speed and variable speed working conditions.
[0009] To achieve the above objectives, according to one aspect of the present invention, a method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network is provided, comprising:
[0010] Step 1: Use the frequency domain information learning module to extract the global frequency domain features and local frequency domain features of the spectrum samples of each of the multiple sensors; use the cross-attention mechanism to fuse the global and local features, and input each fused feature into an independent preliminary decision classifier to obtain the initial classification decision vector for each sensor;
[0011] Step 2: Input the initial classification decision vectors from different sensors into the low-rank decision fusion device to obtain the fused decision vector;
[0012] Step 3: Select the initial classification decision vector with the highest accuracy, multiply it by the scaling factor α, and add it to the fused decision vector in step 4 to obtain the final diagnosis result;
[0013] Step 4: Adjust the weights between the classification losses of each sensor and construct the total loss function of the model;
[0014] Step 5: Train and optimize the frequency domain information learning module based on the total loss function of the model to obtain a mechanical fault diagnosis model.
[0015] Furthermore, in step 1, the frequency domain information learning module includes a plurality of frequency domain information learners corresponding to the number of sensors, each frequency domain information learner includes a global feature encoder, a local feature encoder and a cross attention mechanism, wherein:
[0016] The global feature encoder is composed of cascaded long short-term memory units, and the extracted global features are represented by X G express;
[0017] The local feature encoder is composed of a convolutional neural network, and the extracted local features are expressed as X L express;
[0018] The global feature X G and local features X L The mapping generates Q, K, and V, and the formula is as follows:
[0019] Q=X G W Q
[0020] K=X L W K
[0021] V=X L W V
[0022] Among them, Q is the query vector, K is the key vector, V is the value vector, and W Q 、W K 、W V It is a learnable matrix, which is optimized through the training process in step 5;
[0023] The attention coefficient matrix Attention(Q,K,V) is expressed by the following formula:
[0024]
[0025] Among them, the softmax function is a normalization function in multi-classification problems, d k Represents the characteristic dimension of the key vector K.
[0026] Furthermore, in step 2, the fused decision vector is obtained by inputting the initial classification decision into the low-rank decision fusion device, and its calculation formula is as follows:
[0027]
[0028] in, Represents the element product of the M-order tensor sequence, m = 1 ~ M, r represents the number of decomposition factors of the M-order tensor sequence, Represents the i-th decomposition factor of the M-order tensor sequence, i = 1 ~ r, z m It represents the mth initial decision vector of the input.
[0029] Furthermore, in step 3, the final diagnosis result z a The calculation formula is as follows:
[0030] z a=softmax[h+α·argmax(Accuracy(z m ,z))]
[0031] Among them, α represents the scaling factor, argmax(·) represents the maximum value return function, Accuracy(·) represents the accuracy calculation function, and z represents the true label.
[0032] Furthermore, the total loss function of the model in step 4 is constructed as follows:
[0033] Calculate the loss function of the initial classification results of different sensors; the calculation formula is as follows:
[0034] Loss function for initial classification of different sensors:
[0035]
[0036] The loss function of the final diagnosis:
[0037]
[0038] Calculate the training speed of the loss function for different sensors; the calculation formula is as follows:
[0039]
[0040] The total loss value is calculated by combining the initial and final diagnosis loss functions of the model with the training weights for weighted summation. The calculation formula is as follows:
[0041]
[0042] Where u represents the number of training iterations, represents the classification loss of the mth sensor in the uth iteration, z i represents the true label of the i-th sample, represents the initial classification result of the mth sensor, N is the number of training samples, Indicates the training speed of the mth sensor in the uth iteration. When u=0, is the weight of the classification loss in the mth sensor at the uth iteration;
[0043] In step 5, the initial and classification result losses are adaptively optimized based on the training speed of the sensor in each iteration.
[0044] Furthermore, step 4 also includes calculating the training weights of different sensors according to the training speed; the calculation formula is as follows:
[0045]
[0046] In step 5, the weights between the classification losses of the various sensors in step 4 are also adaptively optimized.
[0047] According to another aspect of the present invention, a mechanical fault diagnosis method based on a feature and decision dual fusion network is provided. During an offline training phase, in the mechanical fault diagnosis model construction method based on any of the above items, the sensor corresponding to the initial decision vector with the highest accuracy at the end of training is marked;
[0048] During online fault diagnosis, the initial classification decision vector corresponding to the marked sensor is used as the initial classification decision vector with the highest accuracy in step 5, and mechanical fault diagnosis is performed according to steps 1 to 5.
[0049] According to another aspect of the present invention, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of any of the methods described above.
[0050] According to another aspect of the present invention, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method described in any of the above items are implemented.
[0051] According to another aspect of the present invention, there is provided a mechanical fault diagnosis model program product obtained based on the mechanical fault diagnosis model construction method as described in any of the preceding items.
[0052] In general, the above technical solutions conceived by the present invention can achieve the following beneficial effects compared with the prior art:
[0053] 1. The present invention establishes a frequency domain information learning model, and obtains a comprehensive fault representation through global-local frequency domain feature learning and fusion, thereby achieving effective preliminary classification. On this basis, it integrates the complementary multi-view decision information of multiple sensors, thereby improving the stability and reliability of the final fault diagnosis.
[0054] 2. The present invention further designs a weight adaptive optimization strategy. By integrating weights calculated based on training speed into the loss function, it can dynamically adjust the loss weights during model training. By combining gradient information with model performance feedback, the overall performance of the model can be significantly improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] Figure 1 This is a flow chart of a variable speed machinery fault diagnosis method based on a feature and decision dual fusion network according to a preferred embodiment of the present invention.
[0056] Figure 2 It is a feature and decision dual fusion network of the preferred embodiment of the present invention.
[0057] Figure 3 2 is a schematic diagram of a frequency domain information learning module according to a preferred embodiment of the present invention.
[0058] Figure 4 This is a visual diagram of vibration signals of different fault types under variable speed conditions in a preferred embodiment of the present invention.
[0059] Figure 5 It is the average accuracy of the model of the preferred embodiment of the present invention under different numbers of training samples. DETAILED DESCRIPTION
[0060] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely for the purpose of explaining the present invention and are not intended to limit the present invention. In addition, the technical features involved in the various embodiments of the present invention described below may be combined with each other as long as they do not conflict with each other.
[0061] The present invention provides a variable speed mechanical fault diagnosis method based on a dual fusion network of features and decisions, such as Figure 1 As shown, the following steps are included:
[0062] Signal acquisition and preprocessing:
[0063] Collect multi-sensor monitoring signals from mechanical equipment: Install acceleration sensors at different locations on the surface of the mechanical equipment to collect vibration signals, and install sound sensors at a certain distance from the mechanical equipment to collect sound signals;
[0064] Preprocess the sensor monitoring signal and use a sliding window to sample the original signal. The process is as follows:
[0065] The original signal is sampled using a sliding window of sample length L, and then slides backward Data points intercept the original signal;
[0066] Perform fast Fourier transform on all segmented data to obtain the spectrum;
[0067] Model training:
[0068] Step 1: Construct a frequency domain feature learning module, such as Figure 2 As shown in the figure, global frequency domain features and local frequency domain features are extracted through the global feature encoder and the local feature encoder; the global and local features are fused by using the cross attention mechanism, and the fused features are input into an independent classifier to obtain the initial classification decision. The process is as follows:
[0069] Use long short-term memory neural network to build a global feature encoder;
[0070] Use convolutional neural networks to build local feature encoders;
[0071] Use cross-attention mechanism to fuse global and local features;
[0072] Generate query vector Q, key vector K and value vector V using global features and local features;
[0073] Calculate the attention coefficient matrix based on Q, K, and V vectors;
[0074] The attention coefficient matrix is flattened and input into the fully connected layer, normalized by the SoftMax function, and the preliminary classification decision is calculated;
[0075] Step 2: Input the initial classification results from different sensors into low-rank decision fusion (LDF) to obtain the decision vector;
[0076] Step 3: Dynamically select the initial classification decision of the sensor with the highest accuracy during training, multiply it by the scaling factor α, and add it to the decision vector in step 2 to obtain the final diagnosis result;
[0077] Step 4: Use the adaptive optimization strategy to adjust the weights between the classification losses of each sensor and construct the total loss function of the model. The process is as follows:
[0078] Calculate the loss function of the initial classification results of different sensors;
[0079] Calculate the training speed of loss functions for different sensors;
[0080] The training weights of different sensors can be pre-debugged and set; preferably, adaptive optimization can also be performed. If the training weights of different sensors are calculated according to the training speed, and the total loss function is calculated using the calculated training weights, the training weights can be adaptively optimized during the model training process;
[0081] The total loss function is calculated by scaling and summing the loss functions of the model's initial and final diagnosis results with the training weights.
[0082] Step 5: Divide the dataset, train and test the model
[0083] The dataset is divided into a training set and a validation set. The training set is used for model training, and the validation set is used for hyperparameter tuning and to mark the sensors with the highest accuracy at the end of training.
[0084] Online Diagnosis:
[0085] When the model is used for online fault diagnosis, the dynamic skip connection strategy cannot use label information to select the sensor with the highest accuracy. Therefore, the initial classification decision of the sensor with the highest accuracy in step 3 is replaced with the initial decision classification corresponding to the marked sensor in step 5 to perform online fault diagnosis of mechanical equipment monitoring data.
[0086] Further preferably, in step 1, the frequency domain information learning module is constructed by a global feature encoder, a local feature encoder and a cross attention mechanism, such as Figure 3 As shown in Figure 2, the global encoder is composed of three cascaded long short-term memory (LSTM) units, the hidden layer size is set to 256, and the extracted features are expressed as X. G Indicates; the local encoder consists of a six-layer convolutional neural network, and the extracted features are represented by X L Represents; the cross attention mechanism in step 4 converts the global feature X G and local features X L After adaptive linear mapping, Q, K, and V are generated. The formula is as follows:
[0087] Q=X G W Q
[0088] K=X L W K
[0089] V=X L W V
[0090] Among them, W Q 、W K 、W V is a learnable weight matrix;
[0091] It is understandable that the number of cascaded long short-term memory units, the size of the hidden layer, and the number of convolutional neural network layers can be adjusted and optimized according to actual conditions. The key to the present invention lies in the data processing flow and logic of the entire diagnostic model.
[0092] The attention coefficient matrix Attention(Q,K,V) is expressed by the following formula:
[0093]
[0094] The softmax function is a normalized exponential function in multi-classification problems, d k represents the characteristic dimension of the key vector;
[0095] Flatten the attention coefficient matrix and then input it into the fully connected layer to obtain the classification result. Figure 3 The specific parameters of the mid-frequency domain information learning module are shown in Table 1.
[0096] Table 1 Parameter settings of global feature encoder, local feature encoder and cross attention mechanism
[0097]
[0098] Note: The class num in Table 1 represents the total number of categories.
[0099] Preferably, in step 2, the final decision vector is obtained by inputting the initial classification decision into a low-rank decision fusion algorithm. The low-rank decision fusion algorithm can avoid the dimensionality curse problem caused by direct multiplication of tensors. If the initial decision is directly used for decision fusion, a multilinear function F will be formed:
[0100] F:Θ1×Θ2×…×Θ M →H
[0101] Among them, Θ1, Θ2,…, Θ M is the vector space of the initial decision, H is the vector space of the final decision, and M is the number of sensors;
[0102] The input tensor Z formed by the single sensor decision representation is calculated as follows:
[0103]
[0104] in, Indicates that the initial decision vector The outer product on, m=1,2,…,M,z m is the initial decision vector of the input, The dimension is d m The vector space of
[0105] Next, the vector Z is fed into a linear layer g(·) to obtain the tensor h;
[0106] h=g(Z;Ψ,b)=Ψ·Z+b
[0107] Where Ψ represents the weight of the linear layer, represents the bias of the linear layer, represents the output tensor, Indicates dimension d y This step will construct a high-dimensional vector, resulting in an exponential increase in the number of parameters.
[0108] To avoid this problem, LDF uses a low-rank factor to parameterize the linear layer g(·) instead of the weight Ψ;
[0109] For an M-order tensor There always exists an exact vector decomposition:
[0110]
[0111] The smallest R that makes this decomposition valid is called the rank of this tensor, i = 1, 2, ..., R. Set It is called r factorization and can be reconstructed k=1,…,d h , d h Indicates the dimension size of the output tensor h, represents the low-rank factor;
[0112] The r decomposition factors are reorganized into M sensor-specific low-rank factors to produce a low-rank version of the weight tensor Ψ:
[0113]
[0114] The decision fusion result h can be calculated by the following formula:
[0115]
[0116] in, Representing a tensor Element-wise product operation on .
[0117] In step 5, a dynamic skip connection strategy is constructed, and the highest accuracy decision during training is scaled and added to the decision vector, and normalized to obtain the final diagnosis result. The calculation formula is as follows:
[0118] z a =softmax[h+α·argmax(Accuracy(z m ,z))]
[0119] Among them, z a represents the label of the final decision, softmax represents the softmax normalization function, α represents the scaling factor, argmax(·) represents the maximum value return function, Accuracy(·) represents the accuracy calculation function, z m represents the predicted label of the mth sensor, and z represents the true label.
[0120] In step 4, the adaptive optimization strategy adaptively optimizes the initial and classification result losses based on the training speed of the sensor in each iteration; including:
[0121] Loss function of initial classification results of different sensors
[0122]
[0123] Loss function of the final diagnosis result
[0124]
[0125] Training speed of loss functions for different sensors:
[0126]
[0127] Training weights for different sensors:
[0128]
[0129] Total loss function:
[0130]
[0131] Where u represents the number of training iterations, denotes the classification loss of the mth sensor in the uth and u-1th iterations, respectively, and z i represents the true label of the i-th sample, represents the initial classification result of the mth sensor, N is the number of training samples, i=1,2,…,N, represents the cross entropy loss function, The label representing the final decision of the prediction, Indicates the training speed of the mth sensor in the uth iteration. When u=0, is the weight of the classification loss in the m-th sensor at the u-th iteration, and exp(.) represents the exponential operation. Represents the total loss value of the FDFNet model in the u-th iteration.
[0132] In the step (7.1), the sensor with the highest accuracy is obtained by training the validation set labels. In step (7.2), when the model is applied to online fault diagnosis, the sensor with the highest accuracy in step 5 is replaced by the sensor marked in step (7.1). The calculation formula is as follows:
[0133]
[0134] in, Indicates the sensor in online diagnosis The corresponding decision vector.
[0135] Reference Figures 1 to 4 A variable speed machinery fault diagnosis method based on a feature and decision dual fusion network comprises the following steps:
[0136] Step 1: Data Collection
[0137] The experimental data used in the present invention comes from the gearbox fault experimental platform. The platform is jointly provided by the School of Naval Architecture and Ocean Engineering of Huazhong University of Science and Technology and Hubei Yichang Weite Technology Co., Ltd. The platform consists of an electrical control part and a mechanical transmission part. The mechanical transmission part mainly includes a drive motor, a healthy gearbox, a fault simulation gearbox and a load motor. The electrical control part can display electrical parameters in real time and adjust the acceleration and deceleration time of the drive and load motors. Three vibration sensors are installed on the fault simulation gearbox to collect vibration signals in orthogonal directions, and a sound sensor is installed near the gearbox to collect sound signals. The sampling frequency of all sensor signals is 20kHz. The data set obtains vibration and sound data of three single faults (gear pitting, broken teeth, bearing outer ring damage), two composite faults (gear pitting & bearing outer ring damage, broken teeth & bearing outer ring damage) and normal state through the gearbox fault simulation experiment.
[0138] like Figure 4 Figures (1) to (6) show the vibration time domain waveforms and speed changes for the normal state, gear pitting, broken teeth, bearing outer ring damage, gear pitting and bearing outer ring damage, and broken teeth and bearing outer ring damage, respectively. The speed increases linearly from 200 r / min to 1000 r / min in the first 10 seconds and decreases linearly from 1000 r / min to 200 r / min from the 10th to the 20th second. The collected signal is divided into samples of length 3072, with 259 samples in each category.
[0139] Step 2: Use the Pytorch framework to build a deep learning network model. To demonstrate the advanced nature of the present invention, this example evaluates its performance through comparative experiments and defines the following model as a reference:
[0140] FDFNet: The fault diagnosis method of the present invention.
[0141] GTFE-Net: A Gramian time frequency enhancement CNN for bearing fault diagnosis. Source: GTFE-Net: A Gramian time frequency enhancement CNN for bearing fault diagnosis.
[0142] DRSN: A fault diagnosis method based on deep residual shrinkage networks, source paper Deep residual shrinkage networks for fault diagnosis.
[0143] MIXCNN: A fault diagnosis method for rotating machinery based on CNN with mixed information.
[0144] LiConvFormer: A lightweight fault diagnosis framework using separable multiscale convolution and broadcast self-attention.
[0145] DCA-BiGRU: A small sample fault diagnosis method based on attention mechanism, from the paper Fault diagnosis for small samples based on attention mechanism.
[0146] Step 3: Define evaluation metrics
[0147] The present invention uses the accuracy rate A to quantitatively analyze the classification performance of the model.
[0148]
[0149] Among them, TP represents the number of samples diagnosed as positive, FN represents the number of samples diagnosed as negative, FP represents the number of samples diagnosed as positive, and TN represents the number of samples diagnosed as negative.
[0150] Step 4: Training the model
[0151] The training set consists of 10, 15, 20, 25, 30, and 35 training samples per type. For each category, a corresponding number of samples are randomly selected from the dataset to form the training set (for example, 10 samples per category). 40% of the remaining dataset is allocated as a validation set, and 60% as a test set. The training set is then trained according to steps 1 through 5 to obtain a mechanical fault diagnosis model.
[0152] Step 5: Test the model
[0153] Input the test data into the mechanical fault diagnosis model and calculate the model accuracy based on the true labels using the formula in step 3. The test environment is: an AMD Ryzen 7 4800H CPU, an NVIDIA GeForce GTX 1650 GPU, and 16GB of RAM.
[0154] Step 6: Repeat the experiment
[0155] Repeat steps 4 and 5 to perform 10 completely independent experiments. Each experiment randomly re-partitions the training set, validation set, and test set, and resets the model weights.
[0156] Step 7: Analyze test results
[0157] Figure 5 The diagnostic accuracy of the model under different sample numbers is shown:
[0158] The FDFNet of the present invention achieved an accuracy of 80.01% with 10 training samples, and the accuracy was significantly improved to 99.81% with 35 training samples. As the number of training samples increased from 10 to 35, the standard deviation decreased from 1.98% to 0.10%, indicating that the stability and reliability of the model are significantly enhanced with the increase in sample size. Even with only 10 samples per class, FDFNet can still achieve fault diagnosis under variable speed conditions with an accuracy of 80.01%, and the standard deviation is only 1.98%, which is significantly better than other models. When the sample size reaches or exceeds 25, FDFNet can achieve a diagnostic accuracy of more than 95% (standard deviation ≤ 0.5%), which fully meets the requirements of high precision and low variance for fault diagnosis in industrial scenarios.
[0159] In addition, the present invention is compared with other fault diagnosis methods GTFE-Net, DRSN, MIXCNN, LiConvFormer, and DCA-BiGRU. Ten repeated experiments were carried out on the data set for comparison. Table 2 shows the diagnostic accuracy of all methods. The results show that the accuracy of the fault diagnosis method of the present invention is significantly higher than that of all other methods. Specifically, with the increase in the number of training samples, the diagnostic accuracy of FDFNet steadily increases, and it performs well under all sample numbers, especially under a smaller number of training samples, FDFNet can still maintain a high diagnostic accuracy, showing its superior generalization ability and robustness. In contrast, the performance of other methods under different sample numbers fluctuates greatly, and the overall diagnostic accuracy is low. This result further verifies the effectiveness and advancement of FDFNet in fault diagnosis under variable speed.
[0160] Table 2 Diagnostic accuracy of the compared methods under different numbers of training samples (%)
[0161]
[0162] It will be easily understood by those skilled in the art that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network, characterized in that: include: Step 1: Use the frequency domain information learning module to extract the global frequency domain features and local frequency domain features of the spectrum samples of multiple sensors; By using the cross-attention mechanism, global and local features are fused, and each fused feature is input into an independent preliminary decision classifier to obtain the initial classification decision vector for each sensor; Step 2: Input the initial classification decision vectors from different sensors into the low-rank decision fusion device to obtain the fused decision vector; Step 3: Select the initial classification decision vector with the highest accuracy, multiply it by the scaling factor α, and add it to the fused decision vector in step 4 to obtain the final diagnosis result; Step 4: Adjust the weights between the classification losses of each sensor and construct the total loss function of the model; Step 5: Train and optimize the frequency domain information learning module based on the total loss function of the model to obtain a mechanical fault diagnosis model.
2. The method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network according to claim 1, characterized in that: In step 1, the frequency domain information learning module includes a plurality of frequency domain information learners corresponding to the number of sensors, each frequency domain information learner includes a global feature encoder, a local feature encoder and a cross attention mechanism, in: The global feature encoder is composed of cascaded long short-term memory units, and the extracted global features are represented by X G express; The local feature encoder is composed of a convolutional neural network, and the extracted local features are expressed as X L express; The global feature X G and local features X L The mapping generates Q, K, and V, and the formula is as follows: Q=X G W Q K=X L W K V=X L W V Among them, Q is the query vector, K is the key vector, V is the value vector, and W Q 、W K 、W V It is a learnable matrix, which is optimized through the training process in step 5; The attention coefficient matrix Attention(Q,K,V) is expressed by the following formula: Among them, the softmax function is a normalization function in multi-classification problems, d k Represents the characteristic dimension of the key vector K.
3. The method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network according to claim 1, characterized in that: In step 2, the fused decision vector is obtained by inputting the initial classification decision into the low-rank decision fusion device, and its calculation formula is as follows: in, Represents the element product of the M-order tensor sequence, m = 1 ~ M, r represents the number of decomposition factors of the M-order tensor sequence, Represents the i-th decomposition factor of the M-order tensor sequence, i = 1 ~ r, z m It represents the mth initial decision vector of the input.
4. The method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network according to claim 3, characterized in that: In step 3, the final diagnosis result is a The calculation formula is as follows: z a =softmax[h+α·argmax(Accuracy(z m ,z))] Among them, α represents the scaling factor, argmax(·) represents the maximum value return function, Accuracy(·) represents the accuracy calculation function, and z represents the true label.
5. The method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network according to claim 1, wherein: The total loss function of the model in step 4 is constructed as follows: Calculate the loss function of the initial classification results of different sensors; the calculation formula is as follows: Loss function for initial classification of different sensors: The loss function of the final diagnosis: Calculate the training speed of the loss function for different sensors; the calculation formula is as follows: The total loss value is calculated by combining the initial and final diagnosis loss functions of the model with the training weights for weighted summation. The calculation formula is as follows: Where u represents the number of training iterations, represents the classification loss of the mth sensor in the uth iteration, z i represents the true label of the i-th sample, represents the initial classification result of the mth sensor, N is the number of training samples, Indicates the training speed of the mth sensor in the uth iteration. When u=0, is the weight of the classification loss in the mth sensor at the uth iteration; In step 5, the initial and classification result losses are adaptively optimized based on the training speed of the sensor in each iteration.
6. The method for constructing a mechanical fault diagnosis model based on a feature and decision dual fusion network according to claim 5, characterized in that: Step 4 also includes calculating the training weights of different sensors based on the training speed; the calculation formula is as follows: In step 5, the weights between the classification losses of the various sensors in step 4 are also adaptively optimized.
7. A mechanical fault diagnosis method based on a feature and decision dual fusion network, characterized in that: During the offline training phase, in the method for constructing a mechanical fault diagnosis model according to any one of claims 1 to 6, the sensor corresponding to the initial decision vector with the highest accuracy at the end of the training is marked; During online fault diagnosis, the initial classification decision vector corresponding to the marked sensor is used as the initial classification decision vector with the highest accuracy in step 5, and mechanical fault diagnosis is performed according to steps 1 to 5.
8. A computer device comprising a memory, a processor, and a computer program stored in the memory, wherein: The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 7.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A mechanical fault diagnosis model program product obtained based on the mechanical fault diagnosis model construction method according to any one of claims 1 to 6.
Citation Information
Cited By
TBM electric drive system fault diagnosis method of adaptive sparse fusion network
CN120871819A