A bearing fault diagnosis method across devices in a few-sample scenario
By constructing a dual-channel fusion fault diagnosis model and a LoRA low-rank adaptive fine-tuning unit, the problems of scarce samples and large equipment differences in rolling bearing fault diagnosis are solved, achieving efficient cross-equipment fault identification and improving the model's adaptability and identification accuracy.
Patent Information
- Application Number
- CN202611420407.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-14
- Publication Date
- 2026-11-10
AI Technical Summary
In rolling bearing fault diagnosis, existing deep learning methods require sufficient labeled samples and require that the training data and the application scenario data have the same feature space. This makes it difficult to meet the fault identification accuracy requirements in actual industrial environments. Furthermore, traditional transfer learning methods have a large number of parameters and low fine-tuning efficiency, making it difficult to adapt to the lightweight deployment requirements of industrial sites.
A dual-channel fusion fault diagnosis model is constructed, including signal preprocessing, dual-channel feature extraction, and fusion classification modules. The SwinTransformer network and GRU gated recurrent unit network are used for feature extraction, and LoRA low-rank adaptive fine-tuning unit is introduced for cross-domain transfer training. Only the parameters of LoRA low-rank adaptive fine-tuning unit are fine-tuned to reduce computational cost.
It significantly improves the model's adaptability and feature representation capabilities on different devices, reduces training computation costs, effectively alleviates the problem of insufficient samples, and improves fault identification accuracy and anti-interference robustness.
Smart Images

Figure CN123069121A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of bearing fault diagnosis technology, and in particular to a bearing fault diagnosis method for cross-device scenarios with few samples. Background Technology
[0002] In the field of rolling bearing fault diagnosis technology, intelligent diagnosis methods based on deep learning have been widely studied and applied. However, such methods usually require sufficient labeled samples to complete model training, and the training data and the application scenario data must have the same feature space and data distribution in order to achieve the ideal diagnostic effect.
[0003] In actual industrial production environments, rolling bearings are mostly in a long-term healthy operating state, and effective samples under fault conditions are very scarce. At the same time, vibration data collected on site generally lacks corresponding labels, and manual labeling requires a lot of time and manpower, which directly makes it difficult for deep diagnostic models to be fully trained based on real-world scenario data, and the fault identification accuracy cannot meet the actual engineering needs.
[0004] To address the problem of insufficient labeled fault samples, transfer learning has been introduced into the field of bearing fault diagnosis. Transfer learning effectively reduces the target domain's dependence on large-scale labeled data by transferring feature knowledge trained on the source domain dataset to the target domain, improving the model's learning performance in data-scarce scenarios. However, most current transfer diagnosis methods focus on different operating conditions of the same equipment, and there are still significant limitations in few-sample diagnosis techniques for cross-equipment scenarios. Furthermore, existing transfer learning methods generally employ distribution alignment strategies to mitigate inter-domain distribution shifts, often neglecting the optimization of model parameter efficiency. This results in drawbacks such as large parameter counts, long training cycles, and low fine-tuning efficiency, making it difficult to adapt to the lightweight deployment requirements of industrial sites. In complex operating conditions with few samples and across multiple equipment, the significant domain shift problem caused by heterogeneous data remains unresolved. Existing diagnostic methods struggle to simultaneously achieve diagnostic accuracy, generalization ability, and computational efficiency, failing to fully meet the application needs of real-world industrial scenarios. Summary of the Invention
[0005] The purpose of this invention is to address the problems of scarce fault labeling samples, large differences in data distribution among different devices, large number of parameters and low fine-tuning efficiency of traditional transfer learning methods in actual industrial scenarios for rolling bearings, and to propose a bearing fault diagnosis method based on a few samples across devices.
[0006] To achieve the above objectives, this invention provides a bearing fault diagnosis method for cross-device scenarios with few samples, comprising the following steps: S1. Constructing a dual-channel fusion fault diagnosis model: The fault diagnosis model includes a signal preprocessing module, a dual-channel feature extraction module, and a fusion classification module connected in sequence; the signal preprocessing module is equipped with a Hilbert transform unit and a Gram angle difference field GADF conversion unit; the dual-channel feature extraction module includes a parallel spatial feature extraction branch and a temporal feature extraction branch, the spatial feature extraction branch adopts a SwinTransformer network with embedded CBAM attention mechanism, and the temporal feature extraction branch adopts a GRU gated recurrent unit network; the fusion classification module is embedded with a LoRA low-rank adaptive fine-tuning unit; S2. Model cross-domain transfer training: Select a bearing vibration dataset with sufficient labeled samples as the source domain, pre-train the dual-channel feature extraction module of the fault diagnosis model to obtain a pre-trained model; freeze all backbone network parameters of the pre-trained model, and retain only the parameters of the LoRA low-rank adaptive fine-tuning unit as trainable state; use a small number of labeled bearing vibration samples in the target domain to fine-tune the LoRA low-rank adaptive fine-tuning unit to obtain a fault diagnosis model adapted to the target equipment. S3. Preprocessing of vibration signal to be diagnosed: Obtain the original vibration signal of the target device to be diagnosed, and input the original vibration signal into the signal preprocessing module for processing; The original vibration signal is processed by the Hilbert transform unit and the Gram angle difference field GADF conversion unit to obtain the analytical time sequence signal and the two-dimensional feature image respectively; S4. Dual-channel feature extraction and fusion: The two-dimensional feature image is input into the spatial feature extraction branch to extract the spatial features of the fault signal; the analytical time-series signal is input into the time-series feature extraction branch to extract the time-series features of the fault signal; the spatial features and time-series features are fused using multimodal features to obtain spatiotemporal fusion features; S5. Fault Classification Diagnosis Output: The spatiotemporal fusion features are input into the fusion classification module. After the classification layer is processed by the LoRA low-rank adaptive fine-tuning unit, the fault type diagnosis result of the corresponding bearing is output.
[0007] Furthermore, in step S1, the Swin Transformer network with embedded CBAM attention mechanism sequentially performs hierarchical feature extraction through window multi-head self-attention (W-MSA) and sliding window multi-head self-attention (SW-MSA), and sequentially connects the channel attention module and the spatial attention module in the feature extraction process to adaptively adjust the channel weights and spatial weights of the fault features.
[0008] Furthermore, in step S1, the GRU gated cyclic unit network adopts a two-layer stacked gated cyclic unit structure to extract the temporal characteristics of the fault vibration signal.
[0009] Furthermore, in step S2, the weight update method of the LoRA low-rank adaptive fine-tuning unit is as follows: The weights of the pre-trained model are denoted as... We introduce low-rank matrices A and B, where matrix A is initialized with a zero-mean Gaussian distribution and matrix B is initialized with all zeros. Freezing the original weights during fine-tuning training , For the input dimension, For the output dimension, only matrices A and B are updated. The updated weights after training are: .
[0010] Furthermore, the dimensions of matrix B and matrix A are respectively... and , Let be the rank of the hyperparameter, and much smaller and .
[0011] Furthermore, in step S3, the processing procedure of the Gram angle difference field GADF conversion unit is as follows: the time series data of the original vibration signal is scaled to the range of [-1,1] or [0,1], the scaled values are converted into angle cosine values, the time nodes are converted into polar coordinate radii, and the time series is mapped to polar coordinate form; based on the angle difference in polar coordinates, sine function encoding is performed to generate a two-dimensional feature image.
[0012] Furthermore, in step S3, the specific processing procedure of the Hilbert transform unit is as follows: performing convolution operation on the original vibration signal time series to obtain the Hilbert transform result, extracting three types of dynamic features: instantaneous amplitude, instantaneous phase, and instantaneous frequency, and constructing an analytical signal.
[0013] Furthermore, in step S3, the original vibration signal is augmented using an overlap sampling method, with each sample having a signal length of 1024 and an overlap rate of 0.8.
[0014] Furthermore, in step S5, the spatiotemporal fusion features are first concatenated by a fully connected classifier to obtain the concatenated features, and then normalized and predicted by the Softmax function to output the probability distribution of various faults, thereby obtaining the fault diagnosis result.
[0015] The present invention employs the above-mentioned bearing fault diagnosis method for cross-device scenarios based on a small sample size, and its beneficial effects are as follows: (1) The present invention constructs a cross-machine bearing fault diagnosis framework that combines multi-domain feature fusion and LoRA fine-tuning strategy, which effectively alleviates the problem of insufficient samples and significantly improves the adaptability of the model on different devices. (2) The present invention constructs a spatial and temporal dual-branch network architecture, which simultaneously mines bearing fault features from the image dimension and the temporal dimension, respectively. The fault information representation is strengthened by the multi-domain feature fusion strategy, which effectively improves the feature expression ability and anti-interference robustness of the model under complex working conditions. (3) The present invention introduces a low-rank adaptive fine-tuning strategy to perform lightweight control on the cross-domain feature transfer process. Only a small number of trainable parameters need to be updated to achieve feature distribution alignment between different devices, which can significantly reduce training computation costs and effectively suppress overfitting problems in small sample scenarios. Attached Figure Description
[0016] Figure 1 This is a flowchart of a bearing fault diagnosis method for cross-device scenarios based on a few samples, according to an embodiment of the present invention. Figure 2 This is a structural diagram of the LoRA model of a bearing fault diagnosis method across devices in a few-sample scenario according to an embodiment of the present invention; Figure 3 This is a t-SNE visualization result of a cross-machine experiment of a bearing fault diagnosis method for cross-devices in a few-sample scenario according to an embodiment of the present invention; wherein, (a) is the t-SNE diagram of A→B, (b) is the t-SNE diagram of B→A; ib represents inner ring fault, ob represents outer ring fault, tb represents rolling element fault, and normal represents no fault; Figure 4 This is an experimental result diagram of different transfer models for a bearing fault diagnosis method across devices in a few-sample scenario according to an embodiment of the present invention; Detailed Implementation
[0017] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to specific embodiments and the accompanying drawings. It should be understood that these descriptions are merely exemplary and not intended to limit the scope of the invention. Furthermore, descriptions of well-known structures and techniques are omitted in the following description to avoid unnecessarily obscuring the concept of the invention.
[0018] Example 1: A bearing fault diagnosis method for multiple devices in a few-sample scenario according to the present invention includes the following steps: S1. Construct a dual-channel fusion fault diagnosis model, such as Figure 1 As shown: The fault diagnosis model includes a signal preprocessing module, a dual-channel feature extraction module, and a fusion classification module connected in sequence; The signal preprocessing module is equipped with a Hilbert transform unit and a Gram angle difference field GADF conversion unit; The dual-channel feature extraction module (feature extraction layer) includes a parallel spatial feature extraction branch and a temporal feature extraction branch. The spatial feature extraction branch employs a Swing Transformer network with embedded CBAM attention mechanism. This Swing Transformer network sequentially performs hierarchical feature extraction through windowed multi-head self-attention (W-MSA) and sliding windowed multi-head self-attention (SW-MSA), and then connects to the channel attention module and spatial attention module in the feature extraction process, adaptively adjusting the channel and spatial weights of the fault features. The temporal feature extraction branch employs a GRU gated recurrent unit network, which uses a two-layer stacked gated recurrent unit structure to extract the temporal features of the fault vibration signal.
[0019] The model extracts spatial features of fault vibration signals through the Swin-CBAM model channels. The combination of SwinTransformer and CBAM channels effectively enhances the model's feature perception capability. Temporal features of the fault vibration signals are extracted through two layers of gated recurrent unit (GRU) channels. This two-layer stacked GRU channel structure offers advantages such as simple structure, fast convergence, and strong modeling capability for long sequences, effectively improving feature extraction capability and model depth, and better capturing long-term dependencies in time-series data. The dual-channel model ultimately extracts the spatiotemporal features of the signal to achieve multimodal feature fusion and classification.
[0020] The fusion classification module (fault classification layer) is embedded with a LoRA low-rank adaptive fine-tuning unit.
[0021] S2. Model cross-domain transfer training: Select a bearing vibration dataset with sufficient labeled samples as the source domain, pre-train the dual-channel feature extraction module of the fault diagnosis model to obtain a pre-trained model; freeze all backbone network parameters of the pre-trained model, and retain only the parameters of the LoRA low-rank adaptive fine-tuning unit as trainable state. Use a small number of labeled bearing vibration samples from the target domain to fine-tune the LoRA low-rank adaptive fine-tuning unit to obtain a fault diagnosis model adapted to the target equipment.
[0022] This invention employs a transfer learning framework to achieve cross-device transfer of fault diagnosis models. A single data domain can be defined as... It consists of three core elements: input features Output tags and their joint probability distribution ; Represents the feature space, Represents the tag space.
[0023] Cross-device domain adaptation presupposes that the input features and label category spaces of the source and target domain datasets must be consistent, but the data distributions of the two domains inherently differ. The goal of domain adaptation is to learn a mapping function. To minimize the prediction error in the target domain, the target can be represented as .
[0024] ; In the formula, A function that measures the difference between the model's predictions and the true labels; It represents the mathematical expectation.
[0025] This invention addresses the high computational and storage costs of fine-tuning the model during target domain training after initial training in the source domain. To reduce the number of parameters and effectively decrease computational resource consumption, Low-Rank Adaptation (LoRA) technology is introduced. Its core lies in integrating low-rank matrices A and B as trainable parameters into the model's fault classification layer, significantly improving parameter tuning efficiency. The LoRA model structure and its components are as follows: Figure 2 As shown.
[0026] exist Figure 2 In the middle, pre-trained weights The updated weights are obtained through the training and inference phases of the LoRA model, and the expression for these weights is as follows: ; In the formula, For the input dimension, The dimension of the output.
[0027] The output feature vector after LoRA transformation for: .
[0028] In this low-rank decomposition framework, the dimensions of matrix B and matrix A are respectively... and ,and much smaller and When initializing the parameters, both matrices A and B need to be initialized, but they differ in that A is distributed using a zero-mean Gaussian distribution, while B is a matrix of all zeros. This ensures that... This ensures that the model is completely consistent with the pre-trained model at the starting point of training. Substituting the above low-rank decomposition form into the formula... The derivation results are as follows: .
[0029] S3. Preprocessing of Vibration Signal to be Diagnosed: Acquire the original vibration signal of the target device to be diagnosed, and input the original vibration signal into the signal preprocessing module for processing; the original vibration signal is processed by the Hilbert transform unit and the Gramm angle difference field GADF conversion unit to obtain the analytical time-series signal and the two-dimensional feature image. The original vibration signal is augmented using an overlap sampling method, with each sample having a signal length of 1024 and an overlap rate of 0.8.
[0030] Hippel transform signal: This method transforms a time-domain signal into an analytic signal, which is beneficial for capturing the instantaneous information of the signal and providing support for the model to learn instantaneous features.
[0031] Gram Angular Difference Field (GADF): The GADF algorithm, based on the sine value calculation of the angle difference and encoding of this angle information, can highly sensitively capture the characteristics of local fluctuations and non-stationary signals in time series. Its core advantage lies in its accurate capture of local features and global short-term dynamic evolution processes, as well as its excellent ability to identify features of transient fault signals.
[0032] The specific processing procedure of the Gram angle difference field GADF conversion unit is as follows: Given a time series data GADF will use time series data Scale to the interval [-1, 1] or [0, 1], then convert to polar coordinates. Specifically: Will Scale to the interval [-1, 1]: ; Will Scale to the interval [0, 1]: ; Therefore, the scaled values are converted to angle cosines, and the time nodes are converted to radii, so that they can be converted into a time series in polar coordinates. .
[0033] ; ; In the formula, The cosine of the angle, As a time node, A constant factor for generating space for regularized polar coordinate systems.
[0034] After the above transformation, the original one-dimensional time series data can be converted into a symmetrical two-dimensional feature image of colored points and lines. When GAF is based on a sine function, it generates a Gram angular difference field (GADF), as shown in the following equation: ; In the formula, For unit vectors [1, 1, ... ,1]; for The transpose of .
[0035] This method first transforms a one-dimensional time series into a two-dimensional graph through polar coordinate transformation and then performs trigonometric function encoding. The signal features are then expressed using the angle difference relationship to extract features.
[0036] The specific processing procedure of the Hilbert transform unit is as follows: Let the original vibration signal time series be... The signal is processed using the Hilbert transform, resulting in the analytic signal: ; in, The imaginary unit, for Hilbert transform, To analyze the instantaneous amplitude of the signal, It is the instantaneous phase.
[0037] ; In the formula, This indicates that Cauchy is at his peak. To be in relation to the current moment The separate integration variables are used to iterate over the entire timeline.
[0038] The core mechanism of this method lies in performing a convolution operation on the signal to capture its instantaneous characteristics. The instantaneous amplitude expression of the analytical signal is as follows: ; The instantaneous phase expression of the analytic signal is: ; The instantaneous frequency expression of the analytical signal is: ; The three formulas above all represent the dynamic characteristics of the signal after the Hibernate transform. This transform can significantly enhance the model's ability to model and learn the dynamic characteristics of rolling bearing fault vibration signals. By characterizing the time-series transformation pattern of the non-stationary characteristics of the vibration signal, the model's accuracy in extracting fault features can be effectively improved.
[0039] S4. Dual-channel feature extraction and fusion: Input the two-dimensional feature image into the spatial feature extraction branch to extract the spatial features of the fault signal; input the analytical time-series signal into the time-series feature extraction branch to extract the time-series features of the fault signal; perform multimodal feature fusion on the spatial and time-series features to obtain spatiotemporal fusion features; S5. Fault Classification Diagnosis Output: The spatiotemporal fusion features are input into the fusion classification module. After the classification layer is processed by the LoRA low-rank adaptive fine-tuning unit, the fault type diagnosis result of the corresponding bearing is output.
[0040] The spatiotemporal fusion features are first concatenated by a fully connected classifier to obtain the concatenated features, and then normalized and predicted by the Softmax function to output the probability distribution of various faults, thus obtaining the fault diagnosis results.
[0041] Example 2, Experimental Verification: The fault diagnosis method was validated using the CWRU and Jiangnan University (JNU) datasets. It was also compared with several commonly used fault diagnosis methods with good performance in transfer learning. Specifically, the model's performance was jointly verified using diagnostic methods including Wide First Layer Deep Convolutional Neural Network (WDCNN), Variance Difference Representation (VDR), Multi-Scale Hybrid Convolutional Neural Network (MSMCNN), and Multi-Channel Signal (MSiT). The Wide First Layer Deep Convolutional Neural Network is a one-dimensional deep learning model that employs a hierarchical feature extraction strategy of "wide kernel pre-denoising + small kernel deep abstraction".
[0042] 1. Experimental setup: CWRU Dataset: This dataset is a faulty bearing dataset from Case Western Reserve University. The experimental setup mainly consists of torque sensors, a three-phase induction motor, and a force gauge. Sensors acquired fault signals from both the fan and drive ends. The test bearing on the drive end was an SKF-6205, with sampling frequencies of 12 kHz and 48 kHz. Different types of faults were generated by single-point EDM. Bearing faults were located on the inner ring, outer ring, and rolling elements, with fault diameters of 0.007 inch, 0.014 inch, and 0.021 inch, respectively. Vibration signals were acquired under three operating conditions (0–2 HP), and data augmentation was performed using overlay sampling. Each sample was 1024 bytes long, with an overlap ratio of 0.8.
[0043] JNU Dataset: This bearing dataset is a dedicated research dataset for rolling bearing fault diagnosis and predictive maintenance. Vibration signals for this dataset were acquired using a bearing fault test bench, which consists of a signal recorder, an accelerometer, and an amplifier. The signal sampling frequency is 50kHz. To simulate typical failure modes in actual bearing operation, micro-dimples of 0.3mm × 0.05mm are precisely machined on the surfaces of easily failing components of the rolling bearing (outer ring, inner ring, and rolling elements) using wire electrical discharge machining (EDM) to reproduce the failure characteristics of the bearing components.
[0044] Two sets of experimental tasks were designed. First, the JNU dataset and the CWRU dataset were represented as dataset A and dataset B, respectively. The two experimental designs were A→B and B→A, respectively. To ensure the validity of the experimental results, in both sets of experiments, the source domain dataset contained a large number of labeled samples, while the target domain dataset contained only a small number of labeled samples (for model fine-tuning), with the rest being unlabeled. Details of the sample size for these two sets of experimental tasks are shown in Table 1. The sample size was calculated as the product of the number of samples selected for a given work condition and the number of work conditions. Each sequence was also divided into subsequences of length 1024. This not only ensured sample diversity but also prevented overfitting.
[0045] Table 1 Fault Diagnosis Task Division
[0046] The equipment used in the experiment consisted of an NVIDIA GeForce RTX4060 GPU and an Intel Core i5-12490F CPU for model training. This embodiment utilizes Python within the PyTorch framework to build the network model. During model training, the Adam optimizer was used, and the mini-batch size was set to 32. The model was first pre-trained in the source domain with a learning rate of... The learning rate is set to 0.0003, decayed by 15% every 10 epochs, the optimal model parameters are selected, fine-tuned with a small number of target domain samples, and finally validated on the target domain test set.
[0047] 2. Evaluation indicators: This embodiment uses precision, recall, and F1 score to jointly reflect the model's true performance. Their definitions are as follows: ; ; ; In the formula, This indicates a true case, meaning a positive sample is predicted as positive. This indicates a false positive, meaning a negative sample is predicted as a positive sample. This indicates a false negative, meaning a positive sample is predicted as a negative sample.
[0048] 3. Ablation experiment: To verify that the model's overall generalization ability in cross-machine transfer learning improves after the introduction of the LoRA fine-tuning mechanism, thus proving the effectiveness of the LoRA mechanism, an ablation experiment was designed to obtain the impact of different fine-tuning methods on the model's transfer capability. The effects of different fine-tuning strategies on bearing fault diagnosis are shown in Table 2.
[0049] Table 2. Fault diagnosis results of different fine-tuning methods
[0050] Table 2 shows the impact of different fine-tuning strategies on bearing fault diagnosis. It can be seen that the Swin-CBAM+GRU model, without introducing LoRA and with the entire model participating in training, achieves high accuracy, demonstrating a certain degree of generalization ability; however, it also has the highest number of parameters. When a fine-tuned fully connected classifier is added and the feature extraction layer is frozen, the number of parameters decreases by about 50%, but the accuracy remains low, indicating poor generalization. The third set of experiments, using the method of this invention, shows that freezing the backbone network while simultaneously employing the LoRA strategy improves the model's accuracy in the target domain by 20% compared to the first set of experiments, while significantly reducing the number of parameters and improving model efficiency.
[0051] 4. Cross-machine fault diagnosis performance verification of Swin-CBAM+GRU+LoRA: To verify the performance of the proposed Swin-CBAM+GRU+LoRA model across the source and target domains, the fault diagnosis tasks shown in Table 1 were input into the model. Each experiment was conducted 20 times, and the average value of the experimental results was calculated. The experimental results are shown in Table 3.
[0052] Table 3. Fault diagnosis results of the Swin-CBAM+GRU+LoRA model in different cross-machine tasks.
[0053] As shown in Table 3, the Swin-CBAM+GRU+LoRA model achieves accuracy, recall, and F1 score all above 90% in cross-machine transfer tasks, indicating that the proposed model demonstrates excellent cross-domain transfer performance. The results for task B→A are better than those for task A→B, possibly because the CRWU dataset is less affected by environmental factors during data collection and uses a more standardized collection method, which facilitates the model's learning and adaptation of signal features in the target domain. The relatively lower results in the other group indicate that the JNU dataset samples have greater variability and insufficient signal features, resulting in incomplete feature learning of the target domain. In conclusion, the model proposed in this invention demonstrates excellent transfer performance in cross-device task scenarios, effectively alleviating the challenge of scarce data samples.
[0054] To more intuitively demonstrate the model's classification ability in the target domain across machine tasks, the t-SNE method will be used to visualize the model's results, such as... Figure 3 As shown.
[0055] from Figure 3 It can be seen from this that Figure 3 Figure (a) shows the experimental results from A to B. The various faults in the figure show obvious and clear clusters, indicating that the model has strong generalization ability. Figure 3 The experimental results for B→A shown in Figure (b) indicate that the four types of faults have slight overlap, but the overall structure still maintains a clear and distinct clustering. In summary, this demonstrates that the model can successfully transfer and learn fault features from the source domain and adapt to the target domain, fully validating the generalization ability of the proposed model in handling cross-machine fault diagnosis tasks and effectively solving the small sample size problem.
[0056] 5. Comparison of the generalizability of various bearing fault diagnosis methods: Through experiments on various fault diagnosis tasks listed in Table 1, the constructed Swin-CBAM+GRU+LoRA model was compared with several cutting-edge diagnostic methods in the field, and the experimental results were compared to verify the model's generalization ability and robustness in complex scenarios. To ensure the reliability and stability of the experimental results, each model was run five times independently on different diagnostic tasks corresponding to the two datasets, and the arithmetic mean of the five test results was used as the final evaluation result. The experimental results are as follows: Figure 4 As shown.
[0057] Figure 4Experimental results show that the proposed Swin-CBAM+GRU+LoRA model in this invention has a significant advantage in average accuracy compared to four traditional bearing fault diagnosis methods—WDCNN, MSMCNN, VDR, and MSiT—in cross-machine fault diagnosis tasks, achieving an accuracy of over 90%, while the others are all below 90%. This indicates that the fault diagnosis method proposed in this invention possesses excellent robustness and generalization ability, effectively alleviating the drawback of scarce rolling bearing fault samples.
[0058] Therefore, this invention adopts the aforementioned bearing fault diagnosis method for cross-device scenarios with few samples, constructing a cross-machine bearing fault diagnosis framework that combines multi-domain feature fusion and LoRA fine-tuning strategy. This effectively alleviates the problem of insufficient samples and significantly improves the model's adaptability to different devices. A spatial and temporal dual-branch network architecture is constructed to simultaneously mine bearing fault features from the image dimension and temporal dimension, respectively. The fault information representation is strengthened through the multi-domain feature fusion strategy, effectively improving the model's feature expression ability and anti-interference robustness under complex working conditions. A low-rank adaptive fine-tuning strategy is introduced to perform lightweight control of the cross-domain feature transfer process. Only a small number of trainable parameters need to be updated to achieve feature distribution alignment between different devices, which can significantly reduce training computation costs and effectively suppress overfitting problems in small sample scenarios.
[0059] It is worth noting that all contents not described in detail in this invention are existing technologies and are well known to those skilled in the art.
[0060] 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 preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the technical solutions of the present invention, and these modifications or equivalent substitutions cannot cause the modified technical solutions to deviate from the spirit and scope of the technical solutions of the present invention.
Claims
1. A bearing fault diagnosis method for cross-device scenarios with few samples, characterized in that, Includes the following steps: S1. Constructing a dual-channel fusion fault diagnosis model: The fault diagnosis model includes a signal preprocessing module, a dual-channel feature extraction module, and a fusion classification module connected in sequence; the signal preprocessing module is equipped with a Hilbert transform unit and a Gram angle difference field GADF conversion unit; the dual-channel feature extraction module includes a parallel spatial feature extraction branch and a temporal feature extraction branch, the spatial feature extraction branch adopts a Swing Transformer network with embedded CBAM attention mechanism, and the temporal feature extraction branch adopts a GRU gated recurrent unit network; the fusion classification module is embedded with a LoRA low-rank adaptive fine-tuning unit; S2. Model cross-domain transfer training: Select a bearing vibration dataset with sufficient labeled samples as the source domain, pre-train the dual-channel feature extraction module of the fault diagnosis model to obtain a pre-trained model; freeze all backbone network parameters of the pre-trained model, and retain only the parameters of the LoRA low-rank adaptive fine-tuning unit as trainable state; use a small number of labeled bearing vibration samples in the target domain to fine-tune the LoRA low-rank adaptive fine-tuning unit to obtain a fault diagnosis model adapted to the target equipment. S3. Preprocessing of vibration signal to be diagnosed: Obtain the original vibration signal of the target device to be diagnosed, and input the original vibration signal into the signal preprocessing module for processing; The original vibration signal is processed by the Hilbert transform unit and the Gram angle difference field GADF conversion unit to obtain the analytical time sequence signal and the two-dimensional feature image respectively; S4. Dual-channel feature extraction and fusion: Input the two-dimensional feature image into the spatial feature extraction branch to extract the spatial features of the fault signal; The analyzed time-series signal is input into the time-series feature extraction branch to extract the time-series features of the fault signal; Multimodal feature fusion is performed on the spatial features and temporal features to obtain spatiotemporal fusion features; S5. Fault Classification Diagnosis Output: The spatiotemporal fusion features are input into the fusion classification module. After the classification layer is processed by the LoRA low-rank adaptive fine-tuning unit, the fault type diagnosis result of the corresponding bearing is output.
2. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S1, the Swin Transformer network with embedded CBAM attention mechanism sequentially performs hierarchical feature extraction through window multi-head self-attention (W-MSA) and sliding window multi-head self-attention (SW-MSA), and sequentially connects the channel attention module and the spatial attention module in the feature extraction process to adaptively adjust the channel weights and spatial weights of the fault features.
3. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S1, the GRU gated cyclic unit network adopts a two-layer stacked gated cyclic unit structure to extract the temporal characteristics of the fault vibration signal.
4. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S2, the weight update method of the LoRA low-rank adaptive fine-tuning unit is as follows: The weights of the pre-trained model are denoted as... , For the input dimension, To define the output dimension, we introduce low-rank matrices A and B, where matrix A is initialized using a zero-mean Gaussian distribution and matrix B is initialized using an all-zero matrix. Freezing the original weights during fine-tuning training Only matrices A and B are updated. The updated weights after training are: 。 5. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 4, characterized in that, The dimensions of matrix B and matrix A are respectively and , Let be the rank of the hyperparameter, and much smaller and .
6. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S3, the processing procedure of the Gram angular difference field GADF conversion unit is as follows: the time series data of the original vibration signal is scaled to the range of [-1,1] or [0,1], the scaled values are converted into angular cosine values, and the time nodes are converted into polar coordinate radii, thus completing the mapping from time series to polar coordinate form; A two-dimensional feature image is generated by encoding the angle difference in polar coordinates using a sine function.
7. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S3, the Hilbert transform unit's processing procedure is as follows: performing convolution operation on the original vibration signal time series to obtain the Hilbert transform result, extracting three types of dynamic features: instantaneous amplitude, instantaneous phase, and instantaneous frequency, and constructing an analytical signal.
8. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S3, the original vibration signal is augmented using an overlap sampling method, with each sample having a signal length of 1024 and an overlap rate of 0.
8.
9. The bearing fault diagnosis method for cross-device scenarios based on few samples as described in claim 1, characterized in that, In step S5, the spatiotemporal fusion features are first concatenated by a fully connected classifier to obtain the concatenated features, and then normalized and predicted by the Softmax function to output the probability distribution of various faults, thus obtaining the fault diagnosis results.
