A rolling bearing fault diagnosis method based on physical perception contrast generative adversarial network

By combining the PAC-GAN generator and discriminator, the problem of rolling bearing fault diagnosis under small sample and high noise environment is solved, generating samples with high physical realism and achieving high accuracy and robust fault diagnosis effect.

CN122345485APending Publication Date: 2026-07-07SHENYANG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHENYANG UNIV
Filing Date
2026-05-13
Publication Date
2026-07-07

AI Technical Summary

Technical Problem

In small sample and high noise environments, existing rolling bearing fault diagnosis technologies suffer from poor physical authenticity of generated samples, insufficient feature discrimination power, and weak noise robustness, leading to a decrease in diagnostic accuracy.

Method used

We employ a Physically Aware Contrast Generative Adversarial Network (PAC-GAN) to construct a generator and a discriminator. We introduce spectral consistency loss and supervised contrast loss. The generator generates time-frequency images of faults that conform to physical laws, while the discriminator integrates a Convolutional Block Attention Module (CBAM) and a three-branch output structure to enhance the feature space structure and noise suppression capabilities.

Benefits of technology

It achieves high-precision and robust fault diagnosis under extremely small sample conditions, generates samples with high physical authenticity, can accurately distinguish similar fault types, suppress noise interference, and adapt to different industrial environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122345485A_ABST
    Figure CN122345485A_ABST
Patent Text Reader

Abstract

The application discloses a rolling bearing fault diagnosis method and device based on physical perception contrast generation adversarial network (PAC-GAN), and belongs to the technical field of rolling bearing fault diagnosis and deep learning. In view of the problems of low diagnosis precision and poor physical authenticity of generated samples of existing methods caused by the scarcity of fault samples and strong background noise interference in the industrial scene, the application converts one-dimensional vibration signals into high-fidelity time-frequency images by using a complex Morlet wavelet; a generator integrating spectral consistency loss is constructed, frequency domain physical priori is embedded into adversarial training, and it is ensured that the generated samples conform to the fault evolution mechanism; a discriminator integrating CBAM attention and three-branch output is designed, and supervised contrast learning is introduced to optimize the feature space structure. The average diagnosis precision of the application reaches 99.75% under the condition of 10-shot small samples, and the application shows excellent robustness and generalization ability under strong noise environment and cross-working condition, and the model is lightweight and suitable for real-time fault diagnosis of industrial edge devices.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of rolling bearing fault diagnosis and deep learning technology, specifically relating to a method and device for rolling bearing fault diagnosis in a small-sample, high-noise environment based on Physical Perception Contrast Generative Adversarial Network (PAC-GAN). Background Technology

[0002] As a core component of rotating machinery, rolling bearings directly determine the reliability, safety, and service life of the equipment. Statistics show that rolling bearing failure accounts for 30%-40% of rotating machinery malfunctions. Therefore, accurate and timely fault diagnosis of rolling bearings is crucial for preventing catastrophic accidents and reducing maintenance costs. Vibration signal analysis is currently the most commonly used and effective method for rolling bearing fault diagnosis. In recent years, deep learning-based intelligent fault diagnosis technology has made significant progress due to its powerful nonlinear modeling capabilities and adaptive feature learning mechanisms.

[0003] However, in real-world industrial scenarios, this technology faces two major challenges: First, the scarcity of fault samples. Industrial equipment typically operates normally for extended periods, resulting in a low probability of failure. Furthermore, fault data collection is costly and time-consuming, leading to an extremely limited number of fault samples. Traditional deep learning models are prone to overfitting under small sample conditions, significantly reducing diagnostic accuracy. Second, strong background noise interference. The complex industrial environment often drowns out vibration signals with intense background noise, resulting in weak fault characteristics and making it difficult for traditional models to effectively extract key fault information.

[0004] To address the small sample size problem, Generative Adversarial Networks (GANs) are widely used for data augmentation. However, existing GAN methods have the following shortcomings in bearing fault diagnosis: Firstly, the generated samples lack physical realism. Existing methods primarily pursue pixel-level similarity, ignoring the inherent frequency domain physical characteristics of vibration signals, leading to frequency distortion and artifacts in the generated samples, failing to accurately reflect the fault evolution mechanism. Secondly, the feature discrimination power is insufficient. Under extremely small sample conditions (such as 10-shot), traditional classifiers based on cross-entropy loss struggle to form clear decision boundaries, exhibiting poor ability to distinguish similar fault types (such as rolling element faults with different damage levels). Furthermore, robustness to noise is weak. Traditional convolutional neural networks treat all regions equally, failing to adaptively focus on fault-sensitive areas, resulting in a sharp decline in diagnostic performance under strong noise environments.

[0005] Therefore, there is an urgent need to develop a rolling bearing fault diagnosis method that can simultaneously solve the problems of small sample size and strong noise, and generate samples with high physical realism. Summary of the Invention

[0006] The purpose of this invention is to overcome the shortcomings of the prior art and provide a rolling bearing fault diagnosis method and device based on physical perception contrast generative adversarial network, which can achieve high-precision and high-robust fault diagnosis in small sample and high noise environments.

[0007] To achieve the above objectives, the present invention adopts the following technical solution:

[0008] A method for diagnosing rolling bearing faults based on Physically Aware Contrastive Generative Adversarial Network (PAC-GAN) includes the following steps:

[0009] Step S1: Collect one-dimensional vibration signals of rolling bearings under different health conditions, preprocess the signals and convert them into a 64×64×3 three-channel time-frequency image through complex Morlet wavelet continuous wavelet transform, and construct a small sample dataset containing normal state and multiple fault states.

[0010] Step S2: Construct a Physically Perceived Contrastive Generative Adversarial Network (PAC-GAN) model, which includes a generator and a discriminator. The generator adopts a fully transposed convolutional architecture to generate time-frequency images of faults that conform to physical laws based on the input random noise and fault category labels. The discriminator uses a deep convolutional network as its backbone, integrating a block convolutional attention module (CBAM) and a three-branch output structure to simultaneously achieve sample authenticity discrimination, fault category classification, and feature embedding extraction.

[0011] Step S3: Construct a multi-objective joint loss function to train the PAC-GAN model. The loss function includes adversarial loss, classification loss, spectral consistency loss, and supervised contrast loss. The spectral consistency loss is used to constrain the consistency between generated samples and real samples in the frequency domain energy distribution, and the supervised contrast loss is used to optimize the feature space structure and enhance intra-class compactness and inter-class separability.

[0012] Step S4: Use the trained PAC-GAN model to generate time-frequency images of faults of the specified categories, and augment the original small sample dataset to obtain an enhanced dataset;

[0013] Step S5: Train the fault classifier using the augmented dataset. Convert the rolling bearing vibration signal to be diagnosed into a time-frequency image and input it into the trained classifier to output the fault diagnosis result.

[0014] Furthermore, the specific parameters of the complex Morlet wavelet continuous wavelet transform described in step 1 are: bandwidth parameter f b =3.0, center frequency f c =1.0, and the scale sequence adopts a logarithmic distribution from 1 to 64.

[0015] Furthermore, the generator network structure described in step 2 is specifically as follows:

[0016] Input layer: A 100-dimensional random noise vector is concatenated with a 10-dimensional one-hot encoded fault category label to obtain a 110-dimensional input vector;

[0017] Projection layer: The input vector is projected and reshaped into a 4×4×512 feature cube through a fully connected layer;

[0018] Transposed convolution block 1: Contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with an output size of 4×4×512;

[0019] Transposed convolution block 2: contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with a stride of 2, padding of 1, and an output size of 8×8×256;

[0020] Transposed convolution block 3: contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with a stride of 2, padding of 1, and an output size of 16×16×128;

[0021] Transposed convolution block 4: contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with a stride of 2, padding of 1, and an output size of 32×32×64;

[0022] Output layer: Contains a 4×4 transposed convolutional layer and a Tanh activation function, with a stride of 2 and padding of 1, outputting a time-frequency image with a size of 64×64×3.

[0023] Furthermore, the discriminator network structure described in step 2 is specifically as follows:

[0024] Input layer: Receives a 64×64×3 time-frequency image;

[0025] First convolutional layer: 4×4 convolutional layer, stride 2, padding 1, output size 32×32×64, using LeakyReLU activation function;

[0026] Second convolutional layer: 4×4 convolutional layer, stride of 2, padding of 1, output size of 16×16×128, using LeakyReLU activation function;

[0027] CBAM module: Integrated after the second convolutional layer, it includes a channel attention submodule and a spatial attention submodule. The multilayer perceptron compression ratio of the channel attention submodule is r=16, and the spatial attention submodule uses a 7×7 convolutional kernel.

[0028] The third convolutional layer is a 4×4 convolutional layer with a stride of 2, padding of 1, and an output size of 8×8×256. It uses the LeakyReLU activation function.

[0029] Fourth convolutional layer: 4×4 convolutional layer with stride of 2, padding of 1, output size of 4×4×512, using LeakyReLU activation function;

[0030] Global average pooling layer: compresses the 4×4×512 feature map into a 512-dimensional feature vector;

[0031] Three-branch output layer:

[0032] Adversarial branch: Fully connected layer + Sigmoid activation function, outputting a 1-dimensional scalar representing the probability that a sample is real;

[0033] Classification branch: Fully connected layer + Softmax activation function, outputting a 10-dimensional vector representing the probability of the fault category;

[0034] Embedding branch: Fully connected layer, outputting a 128-dimensional feature vector, used to calculate supervised contrastive loss.

[0035] Furthermore, the formula for calculating the spectral consistency loss mentioned in step 3 is as follows:

[0036] ;

[0037] Where x represents the real time-frequency image, G(z) represents the time-frequency image generated by the generator, and F(⋅) represents the two-dimensional fast Fourier transform. Indicates taking the amplitude spectrum. Describing the L1 norm, It represents the mathematical expectation.

[0038] Furthermore, the formula for calculating the supervised comparison loss in step 3 is as follows:

[0039] ;

[0040] Where I represents the set of indices of all samples in a batch, P(i) represents the set of indices of all samples belonging to the same category as sample i, A(i) represents the set of indices of all samples in a batch except sample i, and z i Let represent the feature vector of sample i after L2 normalization, ⋅ represent the dot product operation, and τ=0.07 is the temperature parameter.

[0041] Furthermore, the multi-objective joint loss function mentioned in step 3 is specifically as follows:

[0042] Total discriminant loss:

[0043] ;

[0044] Total generator loss:

[0045] ;

[0046] Among them, L adv To combat the losses, L cls For classification loss, the weight coefficient λ cls =1.0, λ sup =1.0, λ spec =2.0.

[0047] Furthermore, the fault classifier described in step 5 adopts the discriminator classification branch of PAC-GAN, directly uses the augmented dataset to fine-tune the discriminator, freezes the parameters of the first four convolutional layers and the CBAM module, and only updates the parameters of the fully connected layers.

[0048] The rolling bearing fault diagnosis method and device based on Physically Aware Contrastive Generative Adversarial Network (PAC-GAN) proposed in this invention have the following advantages compared with the prior art:

[0049] 1. Compared with the prior art, the present invention has the following beneficial effects: High physical realism sample generation: The present invention introduces spectral consistency loss in the generator, embeds the frequency domain physical prior of the vibration signal into the adversarial training process, forces the generated sample to be consistent with the real sample in the frequency domain energy distribution, effectively suppresses frequency distortion and artifacts, and ensures that the generated sample conforms to the physical mechanism of fault evolution.

[0050] 2. This invention integrates a supervised contrastive learning mechanism into the discriminator. By constructing positive and negative sample pairs to explicitly optimize the feature space structure, it significantly enhances intra-class compactness and inter-class separation, and can still accurately distinguish similar fault types under the condition of 10-shot extremely small sample size.

[0051] 3. The present invention embeds a convolutional block attention module (CBAM) in the discriminator, which can adaptively focus on the fault-sensitive frequency channel and time region, effectively suppress background noise interference, and maintain high diagnostic accuracy even in a strong noise environment (σ=0.5);

[0052] 4. This invention guides the model to learn general fault frequency patterns through physical constraints, rather than specific surface features of the dataset, and can achieve high-precision diagnosis without fine-tuning under conditions of different bearing types and speeds.

[0053] 5. This invention adopts a relatively lightweight convolutional network architecture, with only 29% of the number of parameters of ResNet18, and its inference speed is close to SimpleCNN, which can meet the real-time requirements of industrial edge devices. Attached Figure Description

[0054] Figure 1 This is an overall flowchart of the rolling bearing fault diagnosis method based on physical perception contrast generative adversarial network of the present invention;

[0055] Figure 2 This is a diagram of the overall architecture of the PAC-GAN model of this invention.

[0056] Figure 3 This is a confusion matrix diagram of the present invention on the CWRU dataset.

[0057] Figure 4 This is a comparison chart of the diagnostic accuracy of ResNet18 at different noise levels.

[0058] Figure 5 This is a comparison chart of the diagnostic accuracy of the present invention under different noise levels.

[0059] Figure 6 This is a comparison chart of the cross-domain diagnostic accuracy of ResNet18 on the JNU dataset.

[0060] Figure 7 This is a comparison chart of the cross-domain diagnostic accuracy of the present invention on the JNU dataset. Detailed Implementation

[0061] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments.

[0062] like Figure 1 As shown, the rolling bearing fault diagnosis method based on physical perception contrast generative adversarial network provided by the present invention specifically includes the following steps;

[0063] Step S1: Use an accelerometer to collect one-dimensional vibration signals of the rolling bearing under different health conditions, with a sampling frequency of 12kHz. This embodiment uses two publicly available standard bearing datasets for verification;

[0064] The CWRU dataset contains four basic states: normal state (NOR), inner ring fault (IRF), outer ring fault (ORF), and rolling element fault (ROF). Each fault state is further divided into three damage levels: 0.178 mm, 0.356 mm, and 0.534 mm, for a total of 10 healthy states.

[0065] Label Fault Type Fault Diameter (mm) Training Samples (Shots) Testing Samples 0 Normal 0 10 100 1 ROF 0.178 10 100 2 ROF 0.356 10 100 3 ROF 0.534 10 100 4 IRF 0.178 10 100 5 IRF 0.356 10 100 6 IRF 0.534 10 100 7 ORF 0.178 10 100 8 ORF 0.356 10 100 9 ORF 0.534 10 100

[0066] NU dataset: contains four states: normal state, inner ring fault, outer ring fault, and rolling element fault, covering three speed conditions: 600rpm, 800rpm, and 1000rpm.

[0067] like Figure 3As shown, a complex Morlet wavelet is used as the mother wavelet for continuous wavelet transform, converting a one-dimensional vibration signal into a two-dimensional time-frequency image. The mathematical expression for the complex Morlet wavelet is:

[0068] ;

[0069] Wherein, the bandwidth parameter f b =3.0, center frequency f c =1.0, and the scale sequence adopts a logarithmic distribution from 1 to 64. This parameter setting achieves an optimal balance between time resolution and frequency resolution, clearly capturing the transient impact characteristics of bearing failure;

[0070] The two-dimensional time-frequency matrix obtained by continuous wavelet transform is normalized, the pixel values ​​are scaled to the range of [-1,1], and copied into a three-channel format, uniformly adjusted to a 64×64 pixel pseudo-RGB image. This size preserves sufficient time-frequency details while ensuring the computational efficiency of the network;

[0071] Following the 10-shot small sample setting, 10 samples are randomly selected from each health state as the training set, and the remaining samples are used as the test set. For the CWRU dataset, the training set contains 100 samples and the test set contains 1000 samples; for the JNU dataset, the training set contains 40 samples and the test set contains 800 samples.

[0072] Step S2: As Figure 2 As shown, the PAC-GAN model constructed in this invention mainly consists of two parts: a generator and a discriminator.

[0073] Generator Design: The generator employs a fully transposed convolutional architecture, mapping a 100-dimensional random noise vector and a 10-dimensional fault category label to a 64×64×3 time-frequency image. All transposed convolutional kernels are 4×4 in size and designed with integer strides to mitigate "checkerboard" artifacts. Batch normalization layers are used to accelerate training convergence and enhance stability, and the output layer uses the Tanh activation function to constrain pixel values ​​within the range of [-1, 1].

[0074] Discriminator Design: The discriminator uses a deep convolutional network as its backbone, and its core innovation lies in the integration of the CBAM module and the three-branch output structure;

[0075] The CBAM module is embedded between the second and third convolutional layers. This location allows for calibration during the transition from low-level to high-level features, effectively filtering background noise and forcing the network to focus on fault-related key regions. The channel attention submodule generates channel attention weights through global average pooling and global max pooling, while the spatial attention submodule generates spatial attention weights through 7×7 convolutions.

[0076] Three-branch output structure: The discriminator is divided into three independent fully connected branches after the global average pooling layer;

[0077] Adversarial branch: Outputs the probability of samples being true or false, used for adversarial training;

[0078] Classification branch: Outputs the probability of the fault category, used for classification tasks;

[0079] Embedding branch: Outputs a 128-dimensional feature vector, used to calculate the supervised contrastive loss.

[0080] Step S3: Loss Function Construction: This invention uses a multi-objective joint loss function for training, specifically including;

[0081] Combat loss L adv The standard adversarial loss of ACGAN is used to drive the generator to generate realistic samples, while driving the discriminator to accurately distinguish between real and fake samples.

[0082] Classification loss L cls Cross-entropy loss is used to drive the discriminator to correctly classify real and generated samples, while spectral consistency loss L... spec The loss function performs two-dimensional fast Fourier transforms on both real and generated samples, and calculates the L1 distance between their amplitude spectra. This loss forces the generated samples to have the same frequency domain energy distribution as the real samples, ensuring physical authenticity.

[0083] Supervised comparison loss L sup This loss constructs positive and negative sample pairs using label information, bringing similar samples closer together and distancing dissimilar samples further apart in the embedding space. This loss explicitly optimizes the feature space structure, significantly improving feature discrimination power even with small sample sizes.

[0084] Training parameter settings:

[0085] Optimizer: The Adam optimizer was used, with an initial learning rate of 0.0002, β1=0.5, and β2=0.999.

[0086] Batch size: 64;

[0087] Number of training rounds: 500;

[0088] Training strategy: Train the generator once for every training iteration of the discriminator;

[0089] Loss weight: λ cls =1.0, λ sup =1.0, λ spec =2.0. The higher weighting of the spectral consistency loss emphasizes the importance of the physical authenticity of the generated samples.

[0090] Step S4: After training, use the generator to generate time-frequency images of faults for the specified categories. For each healthy state, generate 90 high-quality samples, which are then merged with the original 10 training samples to obtain an augmented dataset of 100 samples per category.

[0091] Step S5: Fine-tune the PAC-GAN discriminator using the augmented dataset. During fine-tuning, freeze the parameters of the first four convolutional layers and the CBAM module, and only update the parameters of the fully connected layers. After fine-tuning, convert the rolling bearing vibration signal to be diagnosed into a time-frequency image according to the method in step S1, and input it into the fine-tuned discriminator to obtain the fault diagnosis result.

[0092] On the CWRU dataset with a 10-shot setting, the method of this invention achieved an average diagnostic accuracy of 99.75%, with 100% accurate identification in 7 categories. Figure 4 and Figure 5 As shown, there are only a few misclassifications among rolling element failures with different degrees of damage, which is due to the high similarity of vibration modes among different degrees of damage in similar components.

[0093] like Figure 6 and Figure 7 As shown, under different intensities of Gaussian white noise interference, the diagnostic accuracy of the method of the present invention decreases significantly less than that of ResNet18. When the noise intensity σ=0.5, the method of the present invention can still maintain a diagnostic accuracy of over 90%, while the accuracy of ResNet18 has dropped to below 70%.

[0094] The model trained on the CWRU dataset was directly applied to the JNU dataset without any fine-tuning. The diagnostic accuracy of the method in this invention reached 99.61%, slightly higher than ResNet18's 99.58%. This indicates that the method in this invention learns general physical characteristics of faults, rather than dataset-specific surface features.

[0095] The method of this invention has 3.24M parameters, which is only 29% of ResNet18 (11.18M); the computational complexity is 0.67 GFLOPs, which is about 37% of ResNet18 (1.81 GFLOPs); and the single-sample inference time is 3.1ms, which is significantly faster than ResNet18's 5.8ms.

[0096] The above experimental results fully verify the excellent performance of the method of the present invention in small sample and high noise environment, as well as the feasibility of deployment on industrial edge devices.

[0097] The above description is merely a preferred embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for diagnosing rolling bearing faults based on physical perception contrastive generative adversarial networks, characterized in that, Includes the following steps: Step S1: Collect one-dimensional vibration signals of rolling bearings under different health conditions, preprocess the signals and convert them into a 64×64×3 three-channel time-frequency image through complex Morlet wavelet continuous wavelet transform, and construct a small sample dataset containing normal state and multiple fault states. Step S2: Construct a Physically Perceived Contrastive Generative Adversarial Network (PAC-GAN) model, which includes a generator and a discriminator. The generator adopts a fully transposed convolutional architecture to generate time-frequency images of faults that conform to physical laws based on the input random noise and fault category labels. The discriminator uses a deep convolutional network as its backbone, integrating a block convolutional attention module (CBAM) and a three-branch output structure to simultaneously achieve sample authenticity discrimination, fault category classification, and feature embedding extraction. Step S3: Construct a multi-objective joint loss function to train the PAC-GAN model. The loss function includes adversarial loss, classification loss, spectral consistency loss, and supervised contrast loss. The spectral consistency loss is used to constrain the consistency between generated samples and real samples in the frequency domain energy distribution, and the supervised contrast loss is used to optimize the feature space structure and enhance intra-class compactness and inter-class separability. Step S4: Use the trained PAC-GAN model to generate time-frequency images of faults of the specified categories, and augment the original small sample dataset to obtain an enhanced dataset; Step S5: Train the fault classifier using the augmented dataset. Convert the rolling bearing vibration signal to be diagnosed into a time-frequency image and input it into the trained classifier to output the fault diagnosis result.

2. The rolling bearing fault diagnosis method based on physical perception contrastive generative adversarial network according to claim 1, characterized in that, Step S1 specifically includes: Step S1.1: The original one-dimensional vibration signal is segmented using a sliding window overlapping sampling strategy, with a window length of 1024 data points and an overlap length of 512 data points; Step S1.2: Perform continuous wavelet transform using complex Morlet wavelet as the mother wavelet, where the bandwidth parameter f b =3.0, center frequency f c =1.0, the scale sequence adopts a logarithmic distribution from 1 to 64; Step S1.3: Normalize the two-dimensional time-frequency matrix obtained by continuous wavelet transform, copy it into a three-channel format, and uniformly adjust it into a 64×64 pixel pseudo-RGB image; Step S1.4: Following the 10-shot small sample setting, randomly select 10 samples for each health state as the training set, and use the remaining samples as the test set.

3. The rolling bearing fault diagnosis method based on physical perception contrastive generative adversarial network according to claim 1, characterized in that, The network structure of the generator in step S2 is as follows: Input layer: A 100-dimensional random noise vector is concatenated with a 10-dimensional one-hot encoded fault category label to obtain a 110-dimensional input vector; Projection layer: The input vector is projected and reshaped into a 4×4×512 feature cube through a fully connected layer; Transposed convolution block 1: Contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with an output size of 4×4×512; Transposed convolution block 2: contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with a stride of 2, padding of 1, and an output size of 8×8×256; Transposed convolution block 3: contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with a stride of 2, padding of 1, and an output size of 16×16×128; Transposed convolution block 4: contains a 4×4 transposed convolutional layer, a batch normalization layer and a ReLU activation function, with a stride of 2, padding of 1, and an output size of 32×32×64; Output layer: Contains a 4×4 transposed convolutional layer and a Tanh activation function, with a stride of 2 and padding of 1, outputting a time-frequency image with a size of 64×64×3.

4. The rolling bearing fault diagnosis method based on physical perception contrast-based generative adversarial networks according to claim 1, characterized in that, The network structure of the discriminator in step S2 is as follows: Input layer: Receives a 64×64×3 time-frequency image; First convolutional layer: 4×4 convolutional layer, stride 2, padding 1, output size 32×32×64, using LeakyReLU activation function; Second convolutional layer: 4×4 convolutional layer, stride of 2, padding of 1, output size of 16×16×128, using LeakyReLU activation function; CBAM module: Integrated after the second convolutional layer, it includes a channel attention submodule and a spatial attention submodule. The multilayer perceptron compression ratio of the channel attention submodule is r=16, and the spatial attention submodule uses a 7×7 convolutional kernel. The third convolutional layer is a 4×4 convolutional layer with a stride of 2, padding of 1, and an output size of 8×8×256. It uses the LeakyReLU activation function. Fourth convolutional layer: 4×4 convolutional layer with stride of 2, padding of 1, output size of 4×4×512, using LeakyReLU activation function; Global average pooling layer: compresses the 4×4×512 feature map into a 512-dimensional feature vector; Three-branch output layer: Adversarial branch: Fully connected layer + Sigmoid activation function, outputting a 1-dimensional scalar representing the probability that a sample is real; Classification branch: Fully connected layer + Softmax activation function, outputting a 10-dimensional vector representing the probability of the fault category; Embedding branch: Fully connected layer, outputting a 128-dimensional feature vector, used to calculate supervised contrastive loss.

5. The rolling bearing fault diagnosis method based on physical perception contrast-based generative adversarial networks according to claim 1, characterized in that, The formula for calculating the spectral consistency loss in step S3 is as follows: ; Where x represents the real time-frequency image, G(z) represents the time-frequency image generated by the generator, and F(⋅) represents the two-dimensional fast Fourier transform. Indicates taking the amplitude spectrum. Describing the L1 norm, It represents the mathematical expectation.

6. The rolling bearing fault diagnosis method based on physical perception contrast-based generative adversarial networks according to claim 1, characterized in that, The formula for calculating the supervised comparison loss in step S3 is as follows: ; Where I represents the set of indices of all samples in a batch, P(i) represents the set of indices of all samples belonging to the same category as sample i, A(i) represents the set of indices of all samples in a batch except sample i, and z i Let represent the feature vector of sample i after L2 normalization, ⋅ represent the dot product operation, and τ=0.07 is the temperature parameter.

7. The rolling bearing fault diagnosis method based on physical perception contrast-based generative adversarial networks according to claim 1, characterized in that, The multi-objective joint loss function in step S3 is specifically as follows: Total discriminant loss: ; Total generator loss: ; Among them, L adv To combat the losses, L cls For classification loss, the weight coefficient λ cls =1.0, λ sup =1.0, λ spec =2.

0.

8. The rolling bearing fault diagnosis method based on physical perception contrastive generative adversarial network according to claim 1, characterized in that, The specific parameters for model training in step S3 are as follows: The Adam optimizer was used with an initial learning rate of 0.0002, β1=0.5, and β2=0.

999. Batch size is 64, training rounds are 500; For each iteration of the discriminator training, the generator is trained once.

9. The rolling bearing fault diagnosis method based on physical perception contrastive generative adversarial network according to claim 1, characterized in that, In step S5, the fault classifier adopts the discriminator classification branch of PAC-GAN, and the discriminator is fine-tuned directly using the augmented dataset. The parameters of the first four convolutional layers and the CBAM module are frozen, and only the parameters of the fully connected layers are updated.