Deep-sea sensor signal fault diagnosis method and system based on diffusion contrast learning

By combining the diffusion model and the contrastive learning network, the deep-sea submersible signal is denoised and characterized, which solves the problem of low accuracy of signal anomaly detection in the deep-sea environment in the existing technology and achieves more efficient and stable anomaly detection. Effect.

CN118797352BActive Publication Date: 2025-01-24SHANDONG UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411266215.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-11
Publication Date
2025-01-24
Estimated Expiration
2044-09-11

AI Technical Summary

Technical Problem

The prior art has low accuracy in sensing signal abnormality detection in deep-sea environments, and is susceptible to noise and external working environments. The diffusion model has poor adaptability in various environments, and key information may be lost during the reconstruction process.

Method used

Combining the diffusion model and the comparison learning network, noise reduction and data enhancement of the deep -sea submersible signal through the diffusion model, and using a comparison learning network to train the encoder parameters to achieve the signal feature extraction and abnormal detection.

Benefits of technology

It improves the accuracy and real-time performance of anomaly detection, enables the model to adapt to anomaly detection tasks in various environments, reduces the overall size of the model, and improves the detection speed and stability of the algorithm.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118797352B_ABST
    Figure CN118797352B_ABST
Patent Text Reader

Abstract

The present invention belongs to the technical field of time series signal anomaly detection, and provides a deep-sea sensor signal fault diagnosis method and system based on diffusion-type contrast learning. The technical scheme is as follows: a deep-sea submersible signal anomaly detection method based on a diffusion model and contrast learning network is designed. The method combines the diffusion model with the contrast learning network, adaptively selects superimposed noises of different distributions according to different operating environments, performs noise reduction and data enhancement on deep-sea signals through the diffusion model, and uses the contrast learning network to train encoder parameters, and then uses the trained encoder to extract features of the signal, and finally realizes fault diagnosis of the sensor signal through the detection network. Corresponding strategies can be adopted for signals under different working environments, which improves the stability and generalization ability of the algorithm, and effectively improves the accuracy and real-time performance of anomaly detection, providing important technical support for the safe and stable operation of deep-sea submersibles.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of time series signal anomaly detection, and in particular to a deep-sea sensor signal fault diagnosis method and system based on diffusion-type contrast learning. Background Art

[0002] The statements in this section merely provide background information related to the present invention and do not necessarily constitute prior art.

[0003] Deep-sea submersibles usually work in extreme deep-sea environments. Especially when manned deep-sea submersibles are performing missions, timely and accurate fault diagnosis is essential to ensure the safety of personnel and equipment. However, the deep-sea environment is complex and changeable. Submersible signals are easily interfered and abnormal during transmission, resulting in signal quality degradation or transmission interruption. Secondly, there are many interference factors on sensor signals in different working environments, including diving depth, seawater salinity, seawater temperature, etc. Traditional deep-sea submersible signal anomaly detection methods are mainly based on signal processing technology and statistical methods, such as spectrum analysis, wavelet transform, autocorrelation function, etc. Although these methods can detect signal anomalies to a certain extent, they are not accurate and are easily affected by noise and external operating environment. With the development of deep learning technology, the application of machine learning and neural networks in signal processing and anomaly detection has gradually attracted attention.

[0004] The deep learning models currently used for anomaly detection mainly include autoencoders, variational autoencoders, generative adversarial networks, etc. These models can learn the distribution characteristics of normal samples and generate corresponding reconstruction results based on the input samples, and distinguish abnormal information by calculating the abnormal scores of each area. However, the reconstruction ability of these models is limited and they cannot reconstruct complex signal features well. The diffusion model has a strong image and audio generation capability. In the field of time series anomaly detection, the diffusion model is proposed to effectively smooth normal pattern samples while amplifying the irregularity of abnormal samples, which means that the diffusion model has a more sensitive perception of the abnormal part between the reconstructed sample and the original sample. However, due to the complexity of the deep-sea environment, the signals collected by sensors in different environments have different characteristics, and the diffusion model is difficult to adapt to the anomaly detection tasks in various environments. Secondly, the reconstruction process of the diffusion model is the process of adding noise and denoising the original sample, and some key information may be lost in this process, resulting in a decrease in the anomaly detection performance of the model. Summary of the invention

[0005] In order to solve at least one technical problem existing in the above-mentioned background technology, the present invention provides a deep-sea sensor signal fault diagnosis method and system based on diffusion-type contrast learning, which combines the diffusion model with the contrast learning network, applies the diffusion model and the contrast learning network to the task of time series anomaly detection, effectively improves the accuracy and real-time performance of anomaly detection, and provides important technical support for the safe and stable operation of deep-sea submersibles.

[0006] In order to achieve the above object, the present invention adopts the following technical solution:

[0007] A first aspect of the present invention provides a deep-sea sensor signal fault diagnosis method based on diffusion contrast learning, comprising the following steps:

[0008] Acquire deep-sea sensor signal data in several operating environments;

[0009] The signal feature extraction network is trained based on deep-sea sensor signal data under several operating environments to obtain a trained signal feature extraction network; wherein the construction process of the signal feature extraction network includes:

[0010] Adaptively select superimposed noises of different distributions according to sensor signal data in different operating environments;

[0011] Combined with the selected superimposed noise, the diffusion model is used to generate enhanced data corresponding to the original signal for each signal batch under different operating environments, and the enhanced data generated by different batches under different operating environments are taken as enhanced data pairs;

[0012] The encoding network extracts the feature vectors of the enhanced data pairs, maps the feature vectors to the latent space of the contrastive learning network through the nonlinear network, calculates the contrastive loss function through the latent features, and uses the contrastive loss function to optimize the parameters of the encoding network and the nonlinear mapping network;

[0013] The features of the signal to be tested are extracted based on the trained signal feature extraction network, and fault diagnosis is performed based on the extracted features of the signal to be tested.

[0014] Furthermore, after obtaining the deep-sea sensor signal data, the data is preprocessed to obtain a training data set, including:

[0015] Filter out high-frequency noise in the original signal of the collected deep-sea sensor signal in the time domain;

[0016] Perform mean-variance normalization on multiple types of signals after filtering out high-frequency noise;

[0017] Perform splicing in the time dimension to obtain a spliced ​​signal set;

[0018] Perform slicing operations on the signal set and concatenate the signal slices in the time dimension to obtain the final data set;

[0019] The data set is divided into positive samples and negative samples to form a training data set, wherein the positive samples include sensor signals without abnormal states; and the negative samples include sensor signals containing abnormal states.

[0020] Furthermore, the adaptively selecting superimposed noises of different distributions according to the sensor signal data in different operating environments specifically includes:

[0021] Calculate the mean and variance of each column of the sensor signal data set under different operating environments;

[0022] The mean and variance of each column are averaged as the superimposed noise distribution after the diffusion model in the operating environment.

[0023] Furthermore, the generating of enhanced data corresponding to the original signal for each signal batch under different operating environments by using the diffusion model includes:

[0024] Noise is gradually added to the original input signal until the signal is pure noise, and the data after superimposing noise is obtained;

[0025] The noise generated by the diffusion process and the randomly selected steps are input into the Unet network to generate observation noise data, and the loss function is calculated with the noise superimposed at the corresponding steps in the diffusion process to update the Unet network parameters;

[0026] The Unet network based on the updated network parameters generates enhanced data corresponding to the original signal.

[0027] Furthermore, the calculation process of the contrast loss function includes:

[0028] Calculate the similarity of each pair of enhanced data based on the latent features of each pair of enhanced data in a batch;

[0029] Calculate the similarity probability between each pair of augmented data in a batch;

[0030] Based on the similarity and similarity probability of each pair of enhanced data in a batch, the contrast loss function of each pair of enhanced data is calculated using the noise contrast estimation loss;

[0031] The loss function of all data in the entire batch is obtained by taking the average of the contrast loss functions of all enhanced data pairs in each batch.

[0032] Furthermore, the operating environment includes diving depth, seawater salinity and seawater temperature.

[0033] Furthermore, feature extraction is performed on the signal to be tested based on the trained signal feature extraction network. When fault diagnosis is performed based on the extracted features of the signal to be tested, the extracted features are input into the signal detection network composed of convolutional layers and linear layers to obtain a probability vector corresponding to the signal. The cross-entropy loss function is calculated by the probability vector and the preset label, and the signal detection network is further optimized by the cross-entropy loss function.

[0034] A second aspect of the present invention provides a deep-sea submersible sensor signal fault diagnosis system based on contrastive learning, comprising:

[0035] A data acquisition module, which is used to acquire deep-sea sensor signal data under several operating environments;

[0036] A feature extraction module is used to train a sensor signal fault diagnosis model based on deep-sea sensor signal data under a number of operating environments to obtain a trained sensor signal fault diagnosis model; wherein the construction process of the sensor signal fault diagnosis model includes:

[0037] Adaptively select superimposed noises of different distributions according to sensor signal data in different operating environments;

[0038] Combined with the selected superimposed noise, the diffusion model is used to generate enhanced data corresponding to the original signal for each signal batch under different operating environments, and the enhanced data generated by different batches under different operating environments are taken as enhanced data pairs;

[0039] The encoding network extracts the feature vectors of the enhanced data pairs, maps the feature vectors to the latent space of the contrastive learning network through the nonlinear network, calculates the contrastive loss function through the latent features, and uses the contrastive loss function to optimize the parameters of the encoding network and the nonlinear mapping network;

[0040] The fault diagnosis module is used to extract features of the signal to be tested based on the trained signal feature extraction network, and perform fault diagnosis based on the extracted features of the signal to be tested.

[0041] Furthermore, the system also includes a data preprocessing module, which is used to preprocess the data after acquiring the deep-sea sensor signal data to obtain a training data set, including:

[0042] Filter out high-frequency noise in the original signal of the collected deep-sea sensor signal in the time domain;

[0043] Perform mean-variance normalization on multiple types of signals after filtering out high-frequency noise;

[0044] Perform splicing in the time dimension to obtain a spliced ​​signal set;

[0045] Perform slicing operations on the signal set and concatenate the signal slices in the time dimension to obtain the final data set;

[0046] The data set is divided into positive samples and negative samples to form a training data set, wherein the positive samples include sensor signals without abnormal states; and the negative samples include sensor signals containing abnormal states.

[0047] Furthermore, in the feature extraction module, adaptively selecting superimposed noises of different distributions according to sensor signal data in different operating environments specifically includes:

[0048] Calculate the mean and variance of each column of the sensor signal data set under different operating environments;

[0049] The mean and variance of each column are averaged as the superimposed noise distribution after the diffusion model in the operating environment.

[0050] Compared with the prior art, the present invention has the following beneficial effects:

[0051] 1. Aiming at the complexity of anomaly detection tasks in deep-sea environments, the method of the present invention combines the diffusion model with the contrastive learning network, applies the diffusion model and the contrastive learning network to the task of time series anomaly detection, performs noise reduction and data enhancement on deep-sea submersible signals through the diffusion model, and uses the contrastive learning network to train the encoder parameters. Finally, the trained encoder is used to extract the features of the signal, and the detection network composed of convolutional layers and linear layers is used to detect anomalies of the signal, so that the model can adapt to anomaly detection tasks in various environments, while reducing the overall scale of the model and improving the detection speed of the algorithm.

[0052] 2. In the present invention, different noise distribution parameters are selected in the diffusion model according to different operating environments to reduce the interference of the external environment on the signal and improve the stability and versatility of the algorithm.

[0053] Advantages of additional aspects of the present invention will be given in part in the following description, and in part will become obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] The accompanying drawings in the specification, which constitute a part of the present invention, are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute improper limitations on the present invention.

[0055] Figure 1 is a flow chart of a deep-sea sensor signal fault diagnosis method based on diffusion-type contrast learning provided by an embodiment of the present invention;

[0056] Figure 2It is an overall data flow diagram of deep-sea sensor signal fault diagnosis based on diffusion-type contrast learning provided by an embodiment of the present invention;

[0057] Figure 3 is a structural diagram of a diffusion model provided by an embodiment of the present invention;

[0058] Figure 4 is a comparative learning network structure diagram provided by an embodiment of the present invention;

[0059] Figure 5 is a schematic diagram of a feature extraction network provided by an embodiment of the present invention;

[0060] Figure 6 is a schematic diagram of a signal detection network provided by an embodiment of the present invention;

[0061] Figure 7 This is the Unet network structure provided by the embodiment of the present invention. DETAILED DESCRIPTION

[0062] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.

[0063] It should be noted that the following detailed descriptions are all illustrative and intended to provide further explanation of the present invention. Unless otherwise specified, all technical and scientific terms used herein have the same meanings as those commonly understood by those skilled in the art to which the present invention belongs.

[0064] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit exemplary embodiments according to the present invention. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that when the terms "comprising" and / or "including" are used in this specification, it indicates the presence of features, steps, operations, devices, components and / or combinations thereof.

[0065] The overall design idea of ​​the present invention is as follows: This method combines the diffusion model with the contrastive learning network, and applies the diffusion model and the contrastive learning network to the task of time series anomaly detection. Specifically, this method uses the diffusion model to perform noise reduction and data enhancement on deep-sea signals, and selects different noise parameters for signal characteristics under different environments; at the same time, the contrastive learning network is used to learn the signal characteristics under different environments and train the encoder parameters. Through this method, the model can comprehensively learn the sensor signal characteristics under various environments, so that the model can adapt to the anomaly detection tasks under various environments; finally, the trained encoder is used to realize the feature extraction of the signal, and the anomaly detection of the signal is realized through the detection network, avoiding the problem of poor real-time performance caused by the huge parameters of the diffusion model and the contrastive learning model. In summary, the method of the present invention can adopt corresponding strategies for signals under different working environments, improve the stability and generalization ability of the algorithm, and effectively improve the accuracy and real-time performance of anomaly detection, providing important technical support for the safe and stable operation of deep-sea submersibles.

[0066] Embodiment 1

[0067] This embodiment provides a deep-sea sensor signal fault diagnosis method based on diffusion contrast learning, including the following parts:

[0068] Firstly, the distribution of superimposed noise required by the diffusion model is calculated according to the distribution of sensor data under different operating environments. After the forward diffusion and reverse denoising processes, the enhanced data pairs of the corresponding signals are output. After processing in this way, the features of the data can be more comprehensively extracted in the feature extraction network to avoid the influence of external factors.

[0069] Next, the enhanced data generated by the diffusion model is passed through the encoding network of the contrastive learning network to extract the features of the enhanced data, and the extracted feature vectors are mapped to projection vectors through a nonlinear mapping network. The projection vectors of the data in a batch are calculated according to the above method, and the contrast loss function between the two projection vectors is calculated. The parameters of the encoder and the nonlinear mapping network are adjusted using the average value of the contrast loss function under the data batch to obtain the encoding network parameters under the required classification mode. The contrastive learning network can learn the characteristics of various signals in different operating environments at a deeper level and more effectively diagnose faults in the signals.

[0070] Finally, the encoder parameters are frozen and used as the feature extraction module of the signal detection network to extract features of the signal to be tested. The extracted features are input into the detection module composed of the convolutional layer and the linear layer to obtain the probability vector of the signal prediction. The cross entropy loss function is calculated for the probability vector and the preset label. The parameters of the detection module are adjusted through the loss function. This method reduces the complexity of the model, simplifies the model structure, and further improves the speed of the signal detection network.

[0071] like Figure 1 and Figure 2 As shown, the specific implementation process includes the following steps:

[0072] Step 1: Obtain deep-sea sensor signal data under several operating environments;

[0073] In this embodiment, when constructing a deep-sea sensor signal dataset, the deep-sea sensor signal dataset consists of a length of T The one-dimensional time series consists of T Represents the number of sampling points of the sensor signal in a certain period of time. The shape of each sensor signal is [ T ×1], T The value of can be determined according to the actual situation. For example, the shape of each sensor signal is [17000×1], and there are 9 sensor signals in total.

[0074] Step 2: Preprocess the acquired deep-sea sensor signal data, including:

[0075] Step 201: The collected original signal is filtered out of high-frequency noise in the original signal through an SG filter in the time domain to retain the original characteristics of the signal.

[0076] Step 202: N The sensor signals are normalized by mean variance respectively to obtain the normalized deep-sea sensor signal data, as shown in formula (1):

[0077] (1),

[0078] In the formula, N is the sensor signal type, where represents the mean value of the sensor signal, represents the variance of the sensor signal, Indicates passing i The data samples after adding noise.

[0079] Step 203: Concatenate in the time dimension to obtain a shape of [ T × N ]Signal collection.

[0080] Step 204: Use the sliding window method to slice the signal set, select the sliding window width as W, and the step as 1, so that each time the window slides, the shape is [ W × N ] signal slices, and the signal slices are spliced ​​in the time dimension to obtain the final data set, which has the shape of [ T-N+ 1 ×W×N ], for example, select the sliding window width as , the step is 1, so that each sliding window has a shape of [32 × 9], and concatenate the signal slices in the time dimension to get the final data set, which has a shape of [16968 × 32 × 9].

[0081] Step 205: Divide the data set into positive samples and negative samples, where positive samples are sensor signals without abnormal conditions; negative samples are sensor signals with abnormal conditions. Due to the different operating environments in the deep sea, factors such as seawater depth, salinity, and temperature have a significant impact on sensor signals, so the final complete data set is composed of the above data sets under different operating environments.

[0082] The dataset is divided into three parts equally, each part is divided into training set, test set and validation set, which are recorded as train1~3, test1~3 and val1~3 respectively. Train1~2, test1~2 and val1~2 have no labels, while train3, test3 and val3 have labels. The labels contain two kinds of information: 1. Whether the signal contains abnormalities, and 2. Environmental information of the signal such as diving depth, seawater salinity, seawater temperature, etc.

[0083] Step 3: Perform feature extraction based on the preprocessed data set to obtain signal features under different environments;

[0084] The feature extraction network diagram is as follows Figure 5 As shown, this embodiment takes different diving depths as an example, and specifically includes the following steps:

[0085] Step 301: inputting data of different diving depths into a diffusion model, and selecting distribution parameters of noise according to different diving depths;

[0086] The diffusion model includes a forward process and a reverse process. The forward process is the process of adding noise to the signal, which gradually adds noise to the input signal until it becomes pure noise. This process can be regarded as a Markov process, as shown in formula (2) and formula (3):

[0087] (2),

[0088] (3),

[0089] in represents the original data sample, Indicates that in a given hour The joint probability distribution of Indicates passing t -1 step of noise-added data sample, I is the diagonal covariance matrix,

[0090] Represents a predefined noise level parameter, which is determined by time Increment, definition , if Gaussian noise is used , then from formula (3) we can get .

[0091] The noise distribution superimposed in the forward process of the diffusion model is not fixed, but different noise distribution parameters are selected according to the distribution of sensor signals at different depths. The method is to calculate the normalized mean and variance of each sensor signal for data at different depths, and average the mean and variance of all sensor signals at the depth as the distribution parameters of the noise. The specific process is:

[0092] After the mean-variance normalization described in step 2, it is concatenated in the time dimension into [ T × N ], and calculate the mean for each column in the signal set and variance Finally, yes and The average value is taken as the distribution of the superimposed noise of the signal passing through the diffusion model at this depth: , as shown in formula (4) and formula (5):

[0093] (4),

[0094] (5),

[0095] in this case , and then gradually remove the noise through the reverse process until the signal is restored.

[0096] Step 302: Generate enhanced data corresponding to the original signal for each signal batch at different diving depths through a diffusion model, specifically including:

[0097] Step 3021: The diffusion model structure diagram is as follows Figure 3 As shown, the noise discriminator selects Unet, and the Unet network structure is as follows Figure 7As shown, it is used to generate the corresponding enhanced data for the signal. A certain batch of train1 data is input into the diffusion model, and the distribution parameters of the superimposed noise are set by the method described in step 301.

[0098] Step 3022: gradually add noise to the input data until the signal is pure noise. The time step is set to 10. The original data is recorded as , the data after superimposing noise is recorded as ,in .

[0099] Step 3023: Randomly select the number of steps n , the noise generated by the diffusion process and n The input Unet network generates observation noise data, and the loss function is calculated by superimposing the noise at the corresponding number of steps in the diffusion process, and the Unet network parameters are updated. The loss function is shown in formula (6):

[0100] (6),

[0101] in Represents the backward process, and this loss function represents the noise generated by the backward network The parameter with the highest probability of occurrence .

[0102] Step 3024: Repeat steps 3022 to 3023 until the loss function converges, and use the trained diffusion model to generate corresponding enhanced data for the original data.

[0103] Step 3025: Input the test1 data into the adjusted diffusion model for testing to detect the model performance.

[0104] Step 3026: Input the train2 data into the diffusion model to obtain generated data , select another batch of data from different operating environments to input the diffusion model and generate data .Will As an enhanced data pair related to the original signal, multiple enhanced data pairs can be obtained by selecting the data input diffusion model under different operating environments. , where D is a different depth category.

[0105] Step 303: inputting the enhanced data pair into a contrastive learning network, using the contrastive learning network to train encoder parameters, and then using the trained encoder to extract features of the signal;

[0106] The contrastive learning network includes data enhancement, encoder, projection head, and the contrastive learning network structure diagram is as follows: Figure 4As shown in Figure 1, the original data is enhanced to obtain a pair of enhanced data. The features are extracted by the encoder and mapped to projection vectors by the projection head, and the maximum similarity of the projection vectors is calculated.

[0107] In this embodiment, the data enhancement part of the contrastive learning network is replaced by a diffusion model. The data of different operating environments are input into the diffusion model, and the distribution parameters of the noise are selected according to different operating environments. The diffusion model generates enhanced data related to the original signal for each signal batch under different operating environments. The enhanced data are combined in pairs to train the input contrastive learning network.

[0108] The specific steps include:

[0109] Step 3031: Extract the features of the enhanced data pairs through the encoding network , the extracted features are mapped to ;

[0110] In this embodiment, the encoding network adopts a GRU encoding network.

[0111] Step 3032: Pass Calculate the contrast loss function and use it to optimize the parameters of the GRU encoding network and the nonlinear mapping network.

[0112] The calculation process of the contrast loss function in the feature extraction network is as follows:

[0113] First, the similarity of the enhanced data pairs of each signal in a batch is calculated by the cosine similarity function, as shown in formula (7):

[0114] (7),

[0115] in They represent the projection vectors of the features extracted by the encoding network and mapped by the nonlinear mapping network. .

[0116] Next, the similarity probability between the two enhanced data is calculated by the Softmax function, as shown in formula (8):

[0117] (8),

[0118] in represents a tuning parameter that can scale the input and expand the range of cosine similarity. N Indicates the batch size, Indicates that the batch of data does not contain signals i The rest of the signal k For the signal i The cosine similarity of .

[0119] Next, the noise contrast estimation loss (NCE) is used to calculate the contrast loss function of each pair of enhanced data, as shown in formula (9):

[0120] (9),

[0121] Finally, the loss function of all data in the entire batch is the average of the contrast loss functions of all enhanced data pairs in the batch, as shown in formula (10):

[0122] (10),

[0123] in for Enhance the loss of data swapping positions.

[0124] Step 3033: Repeat the process of step 3031 to step 3032 until the contrast loss function converges.

[0125] Step 3034: Use the trained GRU encoding network as a feature extraction module of the signal detection network, wherein the GRU encoding network is composed of a total of 6 layers of GRU networks. After training, it can more effectively extract the features of various signals in different operating environments.

[0126] Step 3035: Input the test2 data into the adjusted feature training network to test the model's detection performance for abnormal signals. If the requirements are met, freeze the GRU encoding network parameters and use the encoding network as a feature extraction module for the signal detection network.

[0127] Step 4: Perform fault diagnosis based on the extracted features of the signal to be tested.

[0128] After the data to be tested is input into the signal detection network, the feature extraction module first extracts features from the data to be tested, and then the deep features of the extracted signal are input into the detection module composed of convolutional layers and linear layers to obtain the probability vector corresponding to the signal. The cross entropy loss function is calculated by the probability vector and the preset label, and the model parameters are optimized by this loss function.

[0129] Among them, the feature extraction module of the detection network is the encoding network in the trained feature extraction network, and the label is the probability vector representing the positive samples and negative samples in the data set.

[0130] Build and train the signal detection network. The signal detection network diagram is as follows: Figure 6As shown in the figure, it consists of a feature extraction module and a detection module, where the feature extraction module is the GRU encoding network in the trained feature extraction network, and the detection module consists of three convolutional layers and one fully connected layer. The number of convolutional layer channels is 64, 32, and 16 respectively; the convolution kernel size is 3×3.

[0131] The specific steps include:

[0132] Step 401: Input the train3 data into the feature extraction module to extract the input signal features.

[0133] Step 402: Input the extracted signal features into the detection module to obtain the probability vector corresponding to the signal, calculate the cross entropy loss function through the probability vector and the preset label, and optimize the detection module parameters through the cross entropy loss function. The signal detection network cross entropy loss function is calculated as shown in formula (11):

[0134] (11),

[0135] in Indicates i The true probability distribution of samples is Indicates i The predicted probability distribution of samples.

[0136] Step 403: Repeat the process of step 401 to step 402 until the cross entropy loss function converges.

[0137] Step 404: Input the test3 data into the signal detection model to test the model performance. Send the test set signal into the signal detection network for reasoning, and finally obtain the probability vector corresponding to the signal, which represents the type of label corresponding to the signal, and calculate the recognition accuracy of the model for abnormal signals.

[0138] Embodiment 2

[0139] This embodiment provides a deep-sea submersible sensor signal fault diagnosis system based on contrast learning, including:

[0140] A data acquisition module, which is used to acquire deep-sea sensor signal data under several operating environments;

[0141] A feature extraction module is used to train a sensor signal fault diagnosis model based on deep-sea sensor signal data under a number of operating environments to obtain a trained sensor signal fault diagnosis model; wherein the construction process of the sensor signal fault diagnosis model includes:

[0142] Adaptively select superimposed noises of different distributions according to sensor signal data in different operating environments;

[0143] Combined with the selected superimposed noise, the diffusion model is used to generate enhanced data corresponding to the original signal for each signal batch under different operating environments, and the enhanced data generated by different batches under different operating environments are taken as enhanced data pairs;

[0144] The encoding network extracts the feature vectors of the enhanced data pairs, maps the feature vectors to the latent space of the contrastive learning network through the nonlinear network, calculates the contrastive loss function through the latent features, and uses the contrastive loss function to optimize the parameters of the encoding network and the nonlinear mapping network;

[0145] The fault diagnosis module is used to extract features of the signal to be tested based on the trained signal feature extraction network, and perform fault diagnosis based on the extracted features of the signal to be tested.

[0146] The system also includes a data preprocessing module, which is used to preprocess the data after acquiring the deep-sea sensor signal data to obtain a training data set, including:

[0147] Filter out high-frequency noise in the original signal of the collected deep-sea sensor signal in the time domain;

[0148] Perform mean-variance normalization on multiple types of signals after filtering out high-frequency noise;

[0149] Perform splicing in the time dimension to obtain a spliced ​​signal set;

[0150] Perform slicing operations on the signal set and concatenate the signal slices in the time dimension to obtain the final data set;

[0151] The data set is divided into positive samples and negative samples to form a training data set, wherein the positive samples include sensor signals without abnormal states; and the negative samples include sensor signals containing abnormal states.

[0152] Among them, in the feature extraction module, the adaptive selection of superimposed noises with different distributions according to the sensor signal data in different operating environments specifically includes:

[0153] Calculate the mean and variance of each column of the sensor signal data set under different operating environments;

[0154] The mean and variance of each column are averaged as the superimposed noise distribution after the diffusion model in the operating environment.

[0155] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A deep-sea sensor signal fault diagnosis method based on diffusion contrast learning, characterized in that: The steps include: Acquire deep-sea sensor signal data in several operating environments; The signal feature extraction network is trained based on the deep-sea sensor signal data under several operating environments to obtain the trained signal feature extraction network. Specifically, after obtaining the deep-sea sensor signal data, the data is preprocessed to obtain a training data set, including: Filter out high-frequency noise in the original signal of the collected deep-sea sensor signal in the time domain; Perform mean-variance normalization on multiple types of signals after filtering out high-frequency noise; Perform splicing in the time dimension to obtain a spliced ​​signal set; Perform slicing operations on the signal set and concatenate the signal slices in the time dimension to obtain the final data set; The data set is divided into positive samples and negative samples to form a training data set, wherein the positive samples include sensor signals without abnormal states; the negative samples include sensor signals containing abnormal states; The construction process of the signal feature extraction network includes: According to the sensor signal data in different working environments, the superimposed noise with different distributions is adaptively selected, including: Calculate the mean and variance of each column of the sensor signal data set under different operating environments; The mean and variance of each column are averaged as the superimposed noise distribution of the diffusion model in the operating environment; In combination with the selected superimposed noise, enhanced data corresponding to the original signal is generated for each signal batch under different operating environments through a diffusion model, and enhanced data generated in different batches under two different operating environments are used as enhanced data pairs; the generation of enhanced data corresponding to the original signal for each signal batch under different operating environments through a diffusion model includes: Noise is gradually added to the original input signal until the signal is pure noise, and the data after superimposing noise is obtained; The noise generated by the diffusion process and the randomly selected steps are input into the Unet network to generate observation noise data, and the loss function is calculated with the noise superimposed at the corresponding steps in the diffusion process to update the Unet network parameters; The Unet network based on the updated network parameters generates enhanced data corresponding to the original signal; The encoding network extracts the feature vectors of the enhanced data pairs, maps the feature vectors to the latent space of the contrastive learning network through the nonlinear network, calculates the contrastive loss function through the latent features, and uses the contrastive loss function to optimize the parameters of the encoding network and the nonlinear mapping network; The calculation process of the contrast loss function includes: Calculate the similarity of each pair of enhanced data based on the latent features of each pair of enhanced data in a batch; Calculate the similarity probability between each pair of augmented data in a batch; Based on the similarity and similarity probability of each pair of enhanced data in a batch, the contrast loss function of each pair of enhanced data is calculated using the noise contrast estimation loss; The loss function of all data in the entire batch is obtained by taking the average of the contrast loss functions of all enhanced data pairs in each batch; The features of the signal to be tested are extracted based on the trained signal feature extraction network, and fault diagnosis is performed based on the extracted features of the signal to be tested.

2. The deep-sea sensor signal fault diagnosis method based on diffusion contrast learning as claimed in claim 1 is characterized in that: The operating environment includes diving depth, seawater salinity and seawater temperature.

3. The deep-sea sensor signal fault diagnosis method based on diffusion contrast learning as claimed in claim 1, characterized in that: Based on the trained signal feature extraction network, features of the signal to be tested are extracted. When fault diagnosis is performed based on the extracted features of the signal to be tested, the extracted features are input into the signal detection network composed of convolutional layers and linear layers to obtain the probability vector corresponding to the signal. The cross-entropy loss function is calculated by the probability vector and the preset label, and the signal detection network is further optimized by the cross-entropy loss function.

4. A deep-sea sensor signal fault diagnosis system based on diffusion contrast learning, adopting a deep-sea sensor signal fault diagnosis method based on diffusion contrast learning as claimed in any one of claims 1 to 3, characterized in that: include: A data acquisition module, which is used to acquire deep-sea sensor signal data under several operating environments; The feature extraction module is used to train the sensor signal fault diagnosis model based on the deep-sea sensor signal data under several operating environments to obtain the trained sensor signal fault diagnosis model. Specifically, after obtaining the deep-sea sensor signal data, the data is preprocessed to obtain a training data set, including: Filter out high-frequency noise in the original signal of the collected deep-sea sensor signal in the time domain; Perform mean-variance normalization on multiple types of signals after filtering out high-frequency noise; Perform splicing in the time dimension to obtain a spliced ​​signal set; Perform slicing operations on the signal set and concatenate the signal slices in the time dimension to obtain the final data set; The data set is divided into positive samples and negative samples to form a training data set, wherein the positive samples include sensor signals without abnormal states; the negative samples include sensor signals containing abnormal states; The construction process of the sensor signal fault diagnosis model includes: According to the sensor signal data in different working environments, the superimposed noise with different distributions is adaptively selected, including: Calculate the mean and variance of each column of the sensor signal data set under different operating environments; The mean and variance of each column are averaged as the superimposed noise distribution of the diffusion model in the operating environment; In combination with the selected superimposed noise, enhanced data corresponding to the original signal is generated for each signal batch under different operating environments through a diffusion model, and enhanced data generated in different batches under two different operating environments are used as enhanced data pairs; the generation of enhanced data corresponding to the original signal for each signal batch under different operating environments through a diffusion model includes: Noise is gradually added to the original input signal until the signal is pure noise, and the data after superimposing noise is obtained; The noise generated by the diffusion process and the randomly selected steps are input into the Unet network to generate observation noise data, and the loss function is calculated with the noise superimposed at the corresponding steps in the diffusion process to update the Unet network parameters; The Unet network based on the updated network parameters generates enhanced data corresponding to the original signal; The encoding network extracts the feature vectors of the enhanced data pairs, maps the feature vectors to the latent space of the contrastive learning network through the nonlinear network, calculates the contrastive loss function through the latent features, and uses the contrastive loss function to optimize the parameters of the encoding network and the nonlinear mapping network; The fault diagnosis module is used to extract features of the signal to be tested based on the trained signal feature extraction network, and perform fault diagnosis based on the extracted features of the signal to be tested.

5. The deep-sea sensor signal fault diagnosis system based on diffusion contrast learning as claimed in claim 4, characterized in that: In the feature extraction module, according to the sensor signal data in different operating environments, the superimposed noise with different distributions is adaptively selected, specifically including: Calculate the mean and variance of each column of the sensor signal data set under different operating environments; The mean and variance of each column are averaged as the superimposed noise distribution after the diffusion model in the operating environment.

Citation Information

Patent Citations

  • Deep sea submersible fault diagnosis method and system based on diffusion model domain adaptation

    CN118468144A

  • Mechanical fault intelligent diagnosis method under class unbalanced dataset

    WO2023044979A1