A small sample condition multi-detection device fault identification system and method
By constructing time-domain and frequency-domain graphs, and combining graph variational autoencoders and Transformer layers to dynamically adjust weights, the problems of sharp drop in feature extraction dimensionality and pattern confusion in fault diagnosis of multiple detection devices under small sample conditions are solved, achieving efficient fault identification and classification.
Patent Information
- Application Number
- CN202510563570.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-30
- Publication Date
- 2026-01-23
- Estimated Expiration
- 2045-04-30
AI Technical Summary
Under small sample conditions, traditional multi-detection device fault diagnosis methods are difficult to effectively mine the topological correlations of time and frequency domain features, and deep learning methods rely on large-scale labeled data, resulting in a sharp drop in feature extraction dimensionality and confusion of fault modes.
By constructing time-domain and frequency-domain graphs, features are extracted using graph structure building modules. Feature fusion and learning are performed by combining graph variational autoencoders, GraphSAGE, and Transformer layers. Weights are dynamically adjusted, and the K-nearest neighbor rule and contrastive learning are used to improve feature recognition capabilities.
It significantly improves the accuracy and robustness of fault identification for multiple detection devices under small sample conditions, reduces the dependence on data, and enhances the model's generalization ability and fault classification accuracy under small sample conditions.
Smart Images

Figure CN120493095B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of multi-detection device fault diagnosis, and particularly relates to a multi-detection device fault identification system and method under small sample conditions. BACKGROUND
[0002] With the development of intelligent industrial equipment, mechanical system fault diagnosis technology has become a core link to ensure production safety. As a key component of power transmission, the cooperative diagnosis of the multi-detection device signals of the gear box is of great significance for early fault warning.
[0003] Although traditional data-driven methods have made progress under sufficient sample conditions, they still have two technical bottlenecks in the face of small sample difficulties in actual industrial scenarios: 1. Deep learning methods rely on large-scale labeled data for feature learning, but the cost of obtaining early fault samples of the gear box is high and the working conditions are single. When the training samples are less than 50 groups / class, traditional CNN, RNN and other models are prone to local optimization, and the feature extraction dimension decreases sharply, leading to confusion of fault patterns. 2. Existing feature-level fusion methods use simple concatenation or static weighting strategies, which fail to effectively mine the topological association of time and frequency domain features.
[0004] In summary, as one of the core methods of multi-channel signal processing, feature-level fusion currently lacks a reasonable feature selection and weight distribution mechanism, making it difficult to reflect complex relationships and feature differences. SUMMARY
[0005] The purpose of the present application is to overcome the defects of the prior art and provide a multi-detection device fault identification system under small sample conditions, comprising:
[0006] The graph structure construction module extracts time domain features from the time domain signals of the multi-detection device of the gear box, performs Fourier transform on the time domain signals of the multi-detection device of the gear box to extract frequency domain features, constructs time domain graphs and frequency domain graphs based on the K-neighborhood rule according to the time domain features and the frequency domain features, splices the time domain graphs and the frequency domain graphs to obtain positive graphs, and compares the neighborhood node sets of the time domain graphs and the frequency domain graphs to filter out neighborhood nodes unique to the frequency domain graphs to construct negative graphs;
[0007] The feature fusion module inputs the positive graphs, the negative graphs and the frequency domain graphs into the graph variational autoencoder, respectively, and generates latent distribution through multi-layer GraphSAGE encoding in the graph variational autoencoder, re-parameterization sampling, multi-layer GraphSAGE decoding reconstruction and channel weight dynamic weighting fusion processing to obtain a fusion node feature matrix;
[0008] The fusion feature graph construction module calculates the edge weight of the fused features based on the K-neighborhood rule according to the fusion node feature matrix, and constructs an adjacency matrix with edge weight according to the edge weight of the fused features;
[0009] The feature learning module inputs the fusion node feature matrix and the adjacent matrix with edge weight into the alternately stacked GraphSAGE and Transformer layer, the GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features, the Transformer layer allows the edge weight to participate in the scaled dot-product attention calculation and dynamically adjusts the weight influence combined with the gating mechanism, and outputs the node features after feature learning;
[0010] The fault identification module inputs the node features after feature learning into a global average pooling layer to aggregate into a global feature vector after pooling, extracts high-level nonlinear features from the global feature vector after pooling through a multilayer perceptron, and inputs the high-level nonlinear features into a Softmax classifier to obtain fault category probabilities.
[0011] Further, in the graph structure construction module, time domain features are extracted from the time domain signals of the multiple detection devices of the gear box, the time domain signals of the multiple detection devices of the gear box are subjected to Fourier transform to extract frequency domain features, and the specific method for constructing the time domain graph and the frequency domain graph based on the K nearest neighbor rule according to the time domain features and the frequency domain features is as follows:
[0012] Let the time domain signals of the multiple detection devices of the gear box be X={x1,x2,...,x i};
[0013] Extract time domain features from the time domain signals of the multiple detection devices of the gear box, and each sample x i generates a time domain feature vector d t , where d represents the time domain feature dimension, and R is a real number, wherein the time domain features include mean, variance, peak value, peak-to-peak value, root mean square, waveform factor, kurtosis, and pulse factor;
[0014] Perform Fourier transform FFT on the time domain signals, i.e., perform Fourier transform on each sample x i to obtain a frequency spectrum F i =FFT(x i )∈R X , where X is the frequency spectrum resolution, and the following frequency domain features are constructed: frequency spectrum amplitude: frequency spectrum amplitude=|F i |; frequency band energy: divide the frequency band and calculate the energy of each frequency band; frequency domain statistics: spectral centroid, spectral bandwidth, and spectral flatness. Then, the frequency domain feature vector d f is obtained according to the frequency domain features, where d represents the frequency domain feature dimension, and the frequency domain features include the frequency spectrum amplitude, the frequency band energy, and the frequency domain statistics;
[0015] The Euclidean distance is used to calculate the feature space distance between node i and node j:
[0016]
[0017] wherein D t (i,j) is the time domain feature distance matrix, D f (i,j) is the frequency domain feature distance matrix;
[0018] Based on K-Nearest Neighbor, the time domain graph G t =(V,E t ) and the frequency domain graph G f =(V,E f ) are constructed, V is a node set, each node V i in the node set V corresponds to a detection signal sample x i of a gearbox, E t is an edge set of the time domain graph, E f is an edge set of the frequency domain graph;
[0019] Based on the time domain feature distance matrix D t , the adjacency matrix A t of the time domain graph is constructed, and based on the frequency domain feature distance matrix D f , the adjacency matrix A f of the frequency domain graph is constructed, as follows:
[0020]
[0021] wherein Topk represents selecting the K nodes with the smallest distance as neighbors from D t (i,:) or D f (i,:) for each node i, and the symbol: represents all elements corresponding to a row or a column.
[0022] Further, in the graph structure construction module, the time domain graph and the frequency domain graph are spliced to obtain a positive graph, and the specific method of comparing the neighborhood node set of the time domain graph with the neighborhood node set of the frequency domain graph and screening out the neighborhood nodes unique to the frequency domain graph to construct a negative graph is as follows:
[0023] The time domain graph and the frequency domain graph are spliced into a positive graph G pos =(V,E pos ), E pos is an edge set of the positive graph, and the specific method is as follows: the time domain graph and the frequency domain graph are spliced into a positive graph G pos =(V,E pos ), E pos is an edge set of the positive graph, and the specific method is as follows: the feature vector of the positive graph is The edge set E pos of the positive graph is E t ∩E f , the adjacency matrix A pos of the positive graph is A f ∩A t ;
[0024] By comparing the differences in neighboring nodes between the time-domain and frequency-domain graphs, a negative graph G is constructed by selecting neighboring nodes unique to the frequency domain. neg =(V,E) neg E neg The set of edges for the negative graph is determined as follows: For each node i, the set of neighboring nodes N of node i in the time-domain graph is... t (i)={j∣A t (i,j)=1}, the set of neighboring nodes N of node i in the frequency domain graph. f (i)={j∣A f (i,j)=1}, the set of neighborhood nodes N of the negative graph neg (i) is the set of neighborhood nodes N in the frequency domain. f (i) The set of neighboring nodes N relative to the time domain t (i) A unique set of neighboring nodes, node characteristics of the negative graph Negative graph adjacency matrix A neg as follows:
[0025]
[0026] Furthermore, in the feature fusion module, the positive image, negative image, and frequency domain image are respectively input into the graph variational autoencoder. The graph variational autoencoder performs multi-layer GraphSAGE encoding to generate the latent distribution, reparameterized sampling, multi-layer GraphSAGE decoding and reconstruction, and dynamic weighted fusion processing of channel weights to obtain the fused node feature matrix. The specific method is as follows:
[0027] Multi-layer graph convolution is performed on the positive graph, negative graph, and frequency domain graph respectively to gradually aggregate neighborhood information. The specific steps are as follows:
[0028]
[0029] in, These are the positive graph node features, negative graph node features, and frequency domain graph node features output after neighborhood aggregation and nonlinear transformation, respectively. For the input positive graph node features, negative graph node features, and frequency domain graph node features, W (l) Here, σ represents the learnable multi-layer graph convolution weights, σ is the activation function, and i represents the node v. i The serial number, N pos (i), N neg (i), N f (i) are nodes v i In the positive, negative, and frequency domain graphs, the set of neighborhood nodes, j represents node v. ithe order of the field node of i; AGGREGATE represents neighbor feature aggregation, aggregating all neighbor features of node i to generate an aggregated vector to capture local neighborhood information; CONCAT represents feature concatenation, concatenating the features of the node itself with the aggregated neighbor features to form a more rich joint representation;
[0030] Then the mean and covariance matrix of the latent variable are calculated independently for each graph by the multi-layer GraphSAGE encoder Encoder, as follows:
[0031] Positive graph:
[0032] Negative graph:
[0033] Frequency domain graph:
[0034] Covariance matrix:
[0035] where, is the node feature matrix of the positive graph after neighborhood aggregation and nonlinear transformation, d pos is the feature dimension of the positive graph, is the node feature matrix of the negative graph after neighborhood aggregation and nonlinear transformation, d neg is the feature dimension of the negative graph, is the node feature matrix of the frequency domain graph after neighborhood aggregation and nonlinear transformation, d f is the feature dimension of the frequency domain graph, E pos , E neg , E f are the edge sets of the positive graph, negative graph and frequency domain graph respectively, is the mean of the latent variable of the positive graph, N is the number of nodes, d z is the latent space dimension, μ neg is the mean of the latent variable of the negative graph, μ f is the mean of the latent variable of the frequency domain graph, is the logarithmic variance of the latent variable of the positive graph, is the logarithmic variance of the latent variable of the negative graph, is the logarithmic variance of the latent variable of the time domain graph, is the variance of the d z th dimension on the diagonal of the covariance matrix of the latent variable, Ender is the multi-layer GraphSAGE encoder;
[0036] Then the latent variable is sampled from the posterior distribution of the positive graph, negative graph and frequency domain graph, as follows:
[0037]
[0038] where, ⊙ denotes element-wise multiplication, ∈ ~ N(0, I) denotes noise sampled from standard normal distribution, is an identity matrix, z pos is the latent variable of the positive graph, z neg is the latent variable of the negative graph, z f is the latent variable of the frequency domain graph, exp converts the log variance to variance;
[0039] Then the latent variables z pos , z neg , z f are respectively reconstructed into the original features using the multi-layer GraphSAGE decoder Decoder, and the reconstructed frequency domain graph feature matrix F l is the channel number:
[0040]
[0041] The channel weight is calculated, and the formula is as follows:
[0042]
[0043] where, α l is the weight of the frequency domain graph feature matrix in channel l, ε is a very small positive number, is the mean square error of the lth channel, s l represents the standard deviation of the node feature of the lth channel, s l = std(F l );
[0044] The multi-graph reconstructed features are weighted and fused based on the weights of the c channels to obtain the fused node feature matrix F fused :
[0045]
[0046] The mean square error L recon of the reconstructed features of the positive graph, the negative graph and the frequency domain graph and the original features is calculated, which measures the difference between the reconstructed features and the original features:
[0047]
[0048] The regularization latent space, L KL is a regularization term, which constrains the posterior distribution to be close to the standard normal distribution:
[0049]
[0050] Based on the contrast loss L contrast , the similarity between the positive graph and the frequency domain graph is enhanced, and the association between the negative graph and the positive graph and the frequency domain graph is inhibited:
[0051]
[0052] wherein sim denotes cosine similarity;
[0053] Total loss L total is:
[0054] L total = L recon + βL KL + γL contrast
[0055] wherein β is a first hyper-parameter; γ is a second hyper-parameter, and the first hyper-parameter β and the second hyper-parameter γ are respectively used for controlling the strength of regularization and contrastive learning;
[0056] The training is performed according to the following steps: forward propagation is: inputting node features and adjacency matrices of positive graphs, negative graphs and frequency domain graphs, an encoder generating mean and variance, reparameterization sampling obtaining latent variables, a decoder reconstructing features, calculating fusion weights and outputting a fusion feature matrix F fused ; back propagation is: calculating total loss, updating parameters of the encoder, the decoder and channel weights.
[0057] Further, in the fusion feature map construction module, a specific method for calculating edge weights of fused features based on K-neighborhood rule according to the fusion node feature matrix is as follows:
[0058] First, the Euclidean distance matrix of the fusion features is calculated:
[0059]
[0060] wherein D fused (i,j) is the Euclidean distance between nodes i and j in the fusion node feature matrix F fused , fi is the fusion feature vector of node i, fn,i is the nth feature value of the ith node in the fusion node feature matrix F fused , and fn,j is the nth feature value of the jth node in the fusion node feature matrix F fused .
[0061] The neighbor set is selected based on K-neighborhood:
[0062] N fused (i) = {j | D fused (i,j) ≤ TopK(D fused (i,:), K)
[0063] wherein Nfused (i) is a fusion node feature matrix F fused The set of the K nearest neighbors of node i, TopK(D fused (i) is a fusion node feature matrix F fused The threshold of the K smallest distances of all sample distances of node i;
[0064] The edge weight W fused (i,j) based on the Euclidean distance is calculated as follows:
[0065]
[0066] Where η is a bandwidth parameter used to control the weight decay rate;
[0067] The adjacency matrix A fused (i,j)∈R N×N Only the top K neighbors of each node are retained, and the rest of the edge weights are 0:
[0068]
[0069] Further, in the feature learning module, the fusion node feature matrix and the adjacency matrix with edge weights are input into the alternately stacked GraphSAGE and Transformer layers. The specific method for GraphSAGE layer to update node representation by weighted aggregation of neighborhood features is as follows:
[0070] The fusion node feature matrix F fused ∈R N×d and the adjacency matrix A fused (i,j)∈R N×N with edge weights are input into the alternately stacked GraphSAGE and Transformer layers.
[0071] First, position information is added to the node features:
[0072]
[0073] Where PE(i,2k) is the kth-dimensional position encoding of node i.
[0074] For the GraphSAGE layer, each layer updates the node representation by weighted aggregation of neighbor features:
[0075]
[0076] Where H (l) ∈R N×d is the node feature of the lth layer, W self and W neighrespectively, and sigma is an activation function.
[0077] Further, in the feature learning module, the Transformer layer allows the edge weight to participate in the scaled dot-product attention calculation and dynamically adjusts the weight influence combined with the gating mechanism, and the specific method of outputting the node features after feature learning is:
[0078] For the Transformer layer, the weighted adjacency matrix A fused (i,j) is added to the attention calculation as a bias term:
[0079]
[0080] A = H (l) W A , B = H (l) W B , and C = H (l) W C
[0081] where A, B, and C are query matrix, key matrix, and value matrix respectively, W A , W B , and W C are the first learnable projection matrix, the second learnable projection matrix, and the third learnable projection matrix respectively; epsilon is a small positive number; log(A fused (i,j) + epsilon) is used to convert the edge weight into an attention bias;
[0082] In the Transformer layer, the influence of the edge weight is dynamically adjusted using the gating coefficient:
[0083] G = sigma(W g ·H (l) ), H (l+1) = G o Attention(A, B, C) + (1-G) o H (l)
[0084] where W g is a learnable gating parameter matrix; G is a gating coefficient matrix;
[0085] After processing by alternately stacking GraphSAGE and the Transformer layer, the node features H (L) ∈R N×d after feature learning are output, where N is the number of nodes, d is the feature dimension, and L is the total number of feature learning layers.
[0086] Further, in the fault identification module, the node features learned by feature learning are input into a global average pooling layer to aggregate into a pooled global feature vector, and after a multi-layer perceptron extracts high-level nonlinear features from the pooled global feature vector, the high-level nonlinear features are input into a Softmax classifier to obtain a specific method for obtaining fault class probability:
[0087] The node features H learned by feature learning are input into a global average pooling layer to aggregate into a pooled global feature vector h (L) ∈R N×d The input average pooling layer converts the features of each node into a global feature vector at the graph level:
[0088]
[0089] wherein, is the feature vector of the i-th node, h global is the pooled global feature vector;
[0090] The pooled global feature vector h global is input into an MLP for feature extraction, and in the MLP, a fully connected layer and a nonlinear activation function are used to further extract high-level features:
[0091] h mlp =ReLU(W mlp ·h global +b mlp )
[0092] wherein, is the weight matrix of the MLP, b mlp is the bias vector of the MLP, d hidden is the dimension of the hidden layer, is the high-level nonlinear feature vector output by the MLP;
[0093] The high-level nonlinear feature vector h mlp output by the MLP is input into a Softmax classifier to map the high-level nonlinear feature vector h mlp to a class probability distribution:
[0094]
[0095] wherein, is the weight matrix of the Softmax classifier, b cls ∈R M is the bias vector of the Softmax classifier, p m ∈R M , p m is the probability of the m-th fault class, and M is the number of fault classes;
[0096] Then the difference between the predicted probability and the true label is calculated by a loss function:
[0097]
[0098] where L cls is the cross-entropy loss; y∈{0,1} M is the one-hot encoding of the true label.
[0099] A small sample condition multi-detection device fault identification method, comprising:
[0100] Extract time domain features from the time domain signals of the multi-detection device of the gear box, perform Fourier transform on the time domain signals of the multi-detection device of the gear box to extract frequency domain features, construct a time domain graph and a frequency domain graph based on the K nearest neighbor rule according to the time domain features and the frequency domain features, splice the time domain graph and the frequency domain graph to obtain a positive graph, and compare the neighborhood node sets of the time domain graph and the frequency domain graph to filter out the neighborhood nodes unique to the frequency domain graph to construct a negative graph.
[0101] Input the positive graph, the negative graph and the frequency domain graph into a graph variational autoencoder, and generate a latent distribution through multi-layer GraphSAGE coding in the graph variational autoencoder, perform reparameterization sampling, multi-layer GraphSAGE decoding reconstruction and channel weight dynamic weighted fusion processing, and obtain a fusion node feature matrix.
[0102] According to the fusion node feature matrix, the edge weight of the fused features is calculated based on the K nearest neighbor rule, and an adjacency matrix with edge weight is constructed according to the edge weight of the fused features.
[0103] The fusion node feature matrix and the adjacency matrix with edge weight are input into an alternately stacked GraphSAGE and Transformer layer, the GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features, the Transformer layer allows the edge weight to participate in the scaling dot product attention calculation and dynamically adjusts the weight influence combined with the gating mechanism, and outputs the node features learned by features.
[0104] The node features learned by features are input into a global average pooling layer to aggregate into a global feature vector after pooling, high-level nonlinear features are extracted from the global feature vector after pooling through a multilayer perceptron, and the high-level nonlinear features are input into a Softmax classifier to obtain fault category probabilities.
[0105] A computer program product comprising computer programs / instructions that, when executed by a processor, implement the small sample condition multi-detection device fault identification method described above.
[0106] The beneficial effects of the present application are:
[0107] 1. The present application significantly improves the accuracy and robustness of multi-detection device fault identification under small sample conditions through multi-graph fusion, contrastive learning and dynamic weight design, while reducing data dependence, and has high industrial application value.
[0108] 2. The positive and negative contrast graphs are constructed by the topological complementarity of time domain graphs and frequency domain graphs, which innovatively realizes the bidirectional mapping of time-frequency feature space, uses the positive graph to retain the cross-modal common features, the negative graph to strengthen the frequency domain unique features, and the neighborhood difference contrast learning to make the model have abnormal sensitivity under small samples, thereby improving the fault classification precision.
[0109] 3. The K-nearest neighbor relationship based on graph structure reduces the dependence on a large number of labeled data, and combines graph variational autoencoder and contrastive learning to improve the generalization of the model under a small number of samples.
[0110] 4. The channel weight mechanism based on variational graph autoencoder breaks through the limitation of traditional static fusion: the weight distribution guided by reconstruction error makes the important feature channel gain improved, and the latent space contrast loss function effectively decouples normal and fault modes.
[0111] 5. In the GraphSAGE-Transformer hybrid architecture, the gated attention mechanism improves the contribution of key neighborhood nodes, the position encoding is combined with the dynamic edge weight to solve the problem of periodic shift of rotating machinery signals, the weighted adjacency matrix is introduced into the Transformer to enhance the attention to key neighbor nodes, improve the accuracy of fault identification, and reduce the risk of overfitting through an alternating stacking structure.
[0112] 6. Joint optimization of reconstruction loss, KL divergence and contrast loss ensures the collaborative optimization of the model in feature learning and classification tasks.
[0113] 7. The K-nearest neighbor graph only depends on local similarity and can be constructed without a large number of samples, reducing the data requirement; through latent variable generation, the generalization ability of the model to data distribution is enhanced, and the small sample overfitting problem is alleviated; by using positive / negative graph contrast, discriminative features are learned from limited samples to reduce dependence on labeled data; self-adaptive adjustment of multi-graph feature weight avoids manual design and improves model flexibility under small samples; global pooling + MLP structure has small parameter quantity, which is suitable for small sample training and avoids overfitting caused by complex models. BRIEF DESCRIPTION OF DRAWINGS
[0114] Figure 1 The system block diagram for the present application for multi-detection device fault identification under small sample conditions;
[0115] Figure 2 The schematic diagram of the graph structure in the present application;
[0116] Figure 3The application discloses a small sample condition multi-detection device fault identification equipment.
[0117] Figure 4 The F1 score of each channel in the embodiment 1 of the application. DETAILED DESCRIPTION
[0118] In order to make the technical problems, technical solutions and beneficial effects of the present application clearer, the following will be further described in detail in combination with the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and not to limit the present application.
[0119] Embodiment 1
[0120] Reference Figure 1 And Figure 3 A small sample condition multi-detection device fault identification system, comprising:
[0121] A graph structure construction module extracts time domain features from time domain signals of the multi-detection device of the gear box, performs Fourier transform on the time domain signals of the multi-detection device of the gear box to extract frequency domain features, constructs a time domain graph and a frequency domain graph based on a K nearest neighbor rule according to the time domain features and the frequency domain features, splices the time domain graph and the frequency domain graph to obtain a positive graph, and compares neighborhood node sets of the time domain graph and the frequency domain graph to filter out neighborhood nodes unique to the frequency domain graph to construct a negative graph.
[0122] A feature fusion module inputs the positive graph, the negative graph and the frequency domain graph into a graph variational autoencoder respectively, and generates a latent distribution through multi-layer GraphSAGE coding in the graph variational autoencoder, performs reparameterization sampling, multi-layer GraphSAGE decoding reconstruction and channel weight dynamic weighted fusion processing, and obtains a fusion node feature matrix.
[0123] A fusion feature graph construction module calculates edge weights of fused features based on a K nearest neighbor rule according to the fusion node feature matrix, and constructs an adjacency matrix with edge weights according to the edge weights of the fused features.
[0124] A feature learning module inputs the fusion node feature matrix and the adjacency matrix with edge weights into alternately stacked GraphSAGE and Transformer layers, the GraphSAGE layer updates node representation by weighted aggregation of neighborhood features, the Transformer layer enables the edge weights to participate in scaling dot product attention calculation and dynamically adjusts the weight influence combined with a gating mechanism, and outputs node features after feature learning.
[0125] The fault recognition module inputs the node features learned by the feature learning into a global average pooling layer to aggregate the global feature vectors after pooling, extracts high-level nonlinear features from the global feature vectors after pooling through a multilayer perceptron, inputs the high-level nonlinear features into a Softmax classifier, and obtains the fault category probability.
[0126] (1) Collect the time domain signals of the gear box multi-detection device, including the data of the speed control, motor and acceleration detection device. Normalize the collected data.
[0127] (2) In the graph structure construction module, time domain features are extracted from the gear box multi-detection device time domain signals, the gear box multi-detection device time domain signals are subjected to Fourier transform to extract frequency domain features, and time domain graphs and frequency domain graphs are constructed based on the K nearest neighbor rule according to the time domain features and the frequency domain features. The specific method for constructing the negative graph by comparing the neighborhood node sets of the time domain graph and the frequency domain graph and screening out the neighborhood nodes unique to the frequency domain graph is:
[0128] Let the gear box multi-detection device time domain signals be X = {x1, x2,..., xN} ∈ RN×T, where N is the number of samples, T is the length of the time domain signal, and R is the real number. i}.
[0129] Extract time domain features from the gear box multi-detection device time domain signals, and each sample x i generates a time domain feature vector d t , where d represents the dimension of the time domain feature, and R is a real number. The time domain features include mean, variance, peak value, peak-to-peak value, root mean square (RMS), waveform factor, kurtosis, and pulse factor.
[0130] Perform Fourier transform FFT on the time domain signals, i.e., perform Fourier transform on each sample x i to obtain the frequency spectrum F i = FFT(x i ) ∈ RN×T X (X is the frequency spectrum resolution), and construct the following frequency domain features: spectral amplitude: spectral amplitude = |F i |; frequency band energy: divide the frequency band (such as the gear mesh frequency band), and calculate the energy of each frequency band; frequency domain statistics: spectral centroid, spectral bandwidth, and spectral flatness. Then, according to the frequency domain features, a frequency domain feature vector d f is obtained, where d represents the dimension of the frequency domain feature.
[0131] The Euclidean distance is used to calculate the feature space distance between node i and node j:
[0132]
[0133] where Dt (i,j) is the time domain feature distance matrix, D f (i,j) is the frequency domain feature distance matrix;
[0134] Based on K-Nearest Neighbor, the time domain graph G t = (V, E t ) and the frequency domain graph G f = (V, E f ) are constructed, V is the node set, each node V i in the node set V corresponds to a gearbox detection signal sample x i , E t is the edge set of the time domain graph, E f is the edge set of the frequency domain graph. For the edge set E t = {(v i ,v j ) | v j ∈ TopK(D t (i,:))} of the time domain graph, if K = 3, the time domain nearest neighbors of node v1 are v3, v5, and v7; for the edge set E f = {(v i ,v j ) | v j ∈ TopK(D f (i,:))} of the frequency domain graph, if K = 3, the frequency domain nearest neighbors of node v1 are v2, v4, and v6. TopK represents selecting the K nodes with the smallest distance as neighbors from D t (i,:) or D f (i,:), and the symbol : represents all elements corresponding to the row or column.
[0135] Based on the time domain feature distance matrix D t , the adjacency matrix A t of the time domain graph is constructed, and based on the frequency domain feature distance matrix D f , the adjacency matrix A f of the frequency domain graph is constructed, as follows:
[0136]
[0137] The time domain graph and the frequency domain graph are spliced into a positive graph G pos = (V, E pos ), E pos is the edge set of the positive graph, and the specific method is as follows: the positive graph feature vector The edge set E pos of the positive graph is E t ∩ E f , and the adjacency matrix A pos of the positive graph is A f ∩ A t ;
[0138] By comparing the neighborhood node differences of the time domain graph and the frequency domain graph, the neighborhood nodes unique to the frequency domain are screened to construct the negative graph G neg = (V, E eng ), E neg is the edge set of the negative graph, and the specific method is as follows: for each node i, the neighborhood node set N t (i) of node i in the time domain graph is {j | A t (i,j) = 1}, and the neighborhood node set N f (i) of node i in the frequency domain graph is {j | A f (i,j) = 1}, so the neighborhood node set N neg (i) of the negative graph is a set of neighborhood nodes unique to the frequency domain N f (i) relative to the neighborhood node set N t (i) of the time domain. The node feature of the negative graph is The adjacency matrix A neg of the negative graph is as follows:
[0139]
[0140] The schematic diagram of the graph structure generation is shown in Figure 2 .
[0141] Through the above steps, the extraction method of time domain and frequency domain features is determined, the complementary graph structure is constructed, the basis is provided for subsequent fusion, and the feature diversity is enhanced. By highlighting the frequency domain specific neighborhood through the negative graph, the contrast learning effect is enhanced, which helps the model to distinguish normal and abnormal patterns and improves the discrimination ability under small samples.
[0142] (3) In the feature fusion module, the positive graph, the negative graph, and the frequency domain graph are respectively input into the graph variational autoencoder. In the graph variational autoencoder, the latent distribution is generated through multi-layer GraphSAGE encoding, reparameterization sampling, multi-layer GraphSAGE decoding reconstruction, and channel weight dynamic weighting fusion processing. The specific method for obtaining the fused node feature matrix is as follows:
[0143] The positive graph, the negative graph, and the frequency domain graph are respectively subjected to multi-layer graph convolution, and the neighborhood information is gradually aggregated. The specific steps are as follows:
[0144]
[0145] Among them, are the positive graph node features, the negative graph node features, and the frequency domain graph node features output after neighborhood aggregation and nonlinear transformation, respectively, are the input positive graph node features, the negative graph node features, and the frequency domain graph node features, and W (l)where W is the learnable multi-layer graph convolution weights, σ is the activation function, i is the node v i the order of node v pos (i), N neg (i), N f (i) are the order of node v i the set of domain nodes in the positive graph, negative graph, and frequency domain graph, j is the order of node v pos AGGREGATE denotes neighbor feature aggregation, which aggregates all neighbor features of node i to generate an aggregated vector to capture local neighborhood information; CONCAT denotes feature concatenation, which concatenates the features of the node itself with the aggregated neighbor features to form a more rich joint representation;
[0146] Then the mean and covariance matrix of the latent variable are calculated independently for each graph by the multi-layer GraphSAGE encoder Encoder, as follows:
[0147] Positive graph:
[0148] Negative graph:
[0149] Frequency domain graph:
[0150] Covariance matrix:
[0151] where, is the positive graph node feature matrix after neighborhood aggregation and nonlinear transformation, d pos is the feature dimension of the positive graph, is the negative graph node feature matrix after neighborhood aggregation and nonlinear transformation, d neg is the feature dimension of the negative graph, is the frequency domain graph node feature matrix after neighborhood aggregation and nonlinear transformation, d f is the feature dimension of the frequency domain graph, E pos , E neg , E f are the edge sets of the positive graph, negative graph, and frequency domain graph, respectively, is the mean of the positive graph latent variable, N is the number of nodes, d z is the latent space dimension, μ neg is the mean of the negative graph latent variable, μ f is the mean of the frequency domain graph latent variable, is the log variance of the positive graph latent variable, is the log variance of the negative graph latent variable, is the log variance of the time domain graph latent variable, is the d zThe Encoder is a multi-layer GraphSAGE encoder;
[0152] Then the latent variables are sampled from the posterior distribution of the positive graph, the negative graph and the frequency domain graph, as follows:
[0153]
[0154]
[0155] where denotes element-wise multiplication, ∈ ~ N(0, I) denotes noise sampled from the standard normal distribution, is the identity matrix, and z pos is the latent variable of the positive graph, z neg is the latent variable of the negative graph, and z f is the latent variable of the frequency domain graph, and exp converts the logarithmic variance into variance;
[0156] Then the latent variables z pos , z neg , and z f are respectively reconstructed into the original features using a multi-layer GraphSAGE decoder Decoder, and the reconstructed frequency domain graph feature matrix F is output, where l is the channel number:
[0157]
[0158] The channel weight is calculated as follows:
[0159]
[0160] where α l is the weight of the frequency domain graph feature matrix in the lth channel, ε is a very small positive number, is the mean square error of the lth channel, s l represents the standard deviation of the node features of the lth channel, and s l = std(F l );
[0161] The multi-graph reconstructed features are weighted and fused based on the weights of the c channels to obtain the fused node feature matrix F fused :
[0162]
[0163] The mean square error L recon between the reconstructed features of the positive graph, the negative graph and the frequency domain graph and the original features is calculated, which measures the difference between the reconstructed features and the original features:
[0164]
[0165] Regularization latent space, L KL is a regularization term, which constrains the posterior distribution to be close to the standard normal distribution:
[0166]
[0167] Based on the contrastive loss L contrast , which enhances the similarity between the positive graph and the frequency domain graph and suppresses the association between the negative graph and the positive graph and the frequency domain graph:
[0168]
[0169] where sim denotes the cosine similarity;
[0170] Total loss L total is:
[0171] L total =L recon +βL KL +γL contrast
[0172] where β is a first hyperparameter; γ is a second hyperparameter, and the first hyperparameter β and the second hyperparameter γ are respectively used to control the strength of regularization and contrastive learning;
[0173] The training is performed according to the following steps: forward propagation is: input the node features and adjacency matrices of the positive graph, the negative graph and the frequency domain graph, the encoder generates the mean and variance, the latent variable is obtained by reparameterization sampling, the decoder reconstructs the features, the fusion weight is calculated, and the fusion feature matrix F fused is output; back propagation is: the total loss is calculated, and the parameters of the encoder, the decoder and the channel weight are updated.
[0174] By multi-layer neighborhood aggregation, local and global graph structures are captured, the contributions of different modalities are dynamically learned, manual weight setting is avoided, the sensitivity of the model to abnormal patterns is enhanced by the negative graph, and the robustness and accuracy of gear box fault detection and other tasks can be effectively improved. Based on the latent variable generation and dynamic weighted fusion of the graph variational autoencoder, noise interference is reduced, the robustness of feature representation is improved, and it is suitable for data scarce scenes.
[0175] In the fusion feature graph construction module, the edge weight of the fused feature is calculated based on the K-nearest neighbor rule according to the fused node feature matrix, and the specific method for constructing the adjacency matrix with edge weight according to the edge weight of the fused feature is:
[0176] Fusion node feature matrix F fusesd ∈R N×d , N is the number of nodes, and d is the dimension of the fused features.
[0177] First, the Euclidean distance matrix of fusion features is calculated:
[0178]
[0179] where D fused (i,j) is the Euclidean distance between nodes i and j in the fusion node feature matrix F fused , is the fusion feature vector of node i, is the nth feature value of the ith node in the fusion node feature matrix F fused , is the nth feature value of the jth node in the fusion node feature matrix F fused .
[0180] Select the neighbor set based on K-nearest neighbors:
[0181] N fused (i) = {j | D fused (i,j) ≤ TopK(D fused (i,:), K)}
[0182] where N fused (i) is the set of the nearest K neighbors of node i in the fusion node feature matrix F fused , and TopK(D fused (i,:), K) is the threshold of the smallest K distances among all sample distances of node i in the fusion node feature matrix F fused .
[0183] Calculate the edge weight W fused (i,j) based on Euclidean distance, the smaller the distance, the larger the weight, representing the similarity between nodes, the calculation method is as follows:
[0184]
[0185] where η is a bandwidth parameter used to control the weight decay rate (can be set as the mean of all distances).
[0186] Construct the adjacency matrix A fused (i,j) ∈ R N×N , only keep the weight of the first K neighbors of each node, and the rest of the edge weight is 0:
[0187]
[0188] (5) In the feature learning module, the node feature matrix and the adjacent matrix with edge weight are input into the alternately stacked GraphSAGE and Transformer layer, the GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features, and the Transformer layer allows the edge weight to participate in the scaled dot-product attention calculation and dynamically adjusts the weight influence combined with the gating mechanism, and the specific method of outputting the node features after feature learning is:
[0189] The node feature matrix F fused ∈R N×d and the adjacent matrix A fused (i,j)∈R N×N are fused.
[0190] First, position information is added to the node feature to enhance the model's perception of node order:
[0191]
[0192] where PE(i,2k) is the kth-dimensional position encoding of node i.
[0193] For the GraphSAGE layer, each layer updates the node representation by weighted aggregation of neighbor features:
[0194]
[0195] where H (l) ∈R N×d is the node feature of the lth layer, W self and W neigh are the first learnable parameter matrix and the second learnable parameter matrix respectively, and sigma is the activation function.
[0196] For the Transformer layer, the weighted adjacent matrix A fused (i,j) is added as a bias term to the attention calculation:
[0197]
[0198] A=H (l) W A , B=H (l) W B , C=H (l) W C
[0199] where A, B, and C are the query matrix, key matrix, and value matrix respectively, W A , W B , and W Crespectively are a first learnable projection matrix, a second learnable projection matrix and a third learnable projection matrix; ε is a very small positive number (such as 1e -5 ), preventing taking logarithm of zero; log(A fused (i,j)+ε) is used to convert edge weight into attention bias, the higher the weight, the higher the attention score.
[0200] In the Transformer layer, the influence of edge weight is dynamically adjusted using the gating coefficient (Sigmoid function):
[0201] G=σ(W g ·H (l) ),H (l+1) =G⊙Attention(A,B,C)+(1-G)⊙H (l)
[0202] Where W g is a learnable gating parameter matrix; G is a gating coefficient matrix (value between 0 and 1), the higher the weight, the greater the feature update amplitude. The gating mechanism decides how much information is retained from the edge weight according to the current feature state.
[0203] After feature learning (alternating stack of GraphSAGE and Transformer layer processing), the output is the node feature H (L) ∈R N×d , N is the number of nodes, d is the feature dimension, and L is the total number of feature learning layers (such as the number of alternating stack of GraphSAGE and Transformer).
[0204] GraphSAGE and Transformer are alternately stacked, combining local neighborhood aggregation and global attention mechanism, fully mining node relationship and improving feature learning efficiency.
[0205] (6) In the fault identification module, the node feature after feature learning is input into the global average pooling layer to aggregate into the pooled global feature vector, and the high-level nonlinear features are extracted from the pooled global feature vector by the multilayer perceptron, and then the high-level nonlinear features are input into the Softmax classifier. The specific method for obtaining the fault class probability is:
[0206] The node feature H (L) ∈R N×d after feature learning is input into the average pooling layer to convert the feature of each node into a global feature vector at the graph level:
[0207]
[0208] Where, is the feature vector of the i-th node, h global is the global feature vector after pooling.
[0209] is the global feature vector after pooling h global is input into the MLP (Multi-Layer Perceptron) for feature extraction, and high-level features are further extracted through fully connected layers and nonlinear activation functions in the MLP:
[0210] h mlp = ReLU(W mlp · h global + b mlp )
[0211] where, is the weight matrix of the MLP, b mlp is the bias vector of the MLP, d hidden is the dimension of the hidden layer, is the high-level nonlinear feature vector output by the MLP.
[0212] The high-level nonlinear feature vector h mlp output by the MLP is input into the Softmax classifier to map the high-level nonlinear feature vector h mlp to a class probability distribution:
[0213]
[0214] where, is the weight matrix of the Softmax classifier, b cls ∈ R M is the bias vector of the Softmax classifier, p m ∈ R M , p m is the probability of the m-th class of failure, and M is the number of classes of failures;
[0215] Then, the difference between the predicted probability and the true label is calculated through the loss function:
[0216]
[0217] where, L cls is the cross-entropy loss; y ∈ {0, 1} M is the one-hot encoding of the true label. One-Hot encoding is a method of converting categorical data into binary vectors. Its core idea is to assign a unique vector to each category, with only one position being 1 (representing "activation") and the rest being 0.
[0218] Global pooling combined with MLP compresses node-level features into high-level representations, reducing the number of parameters and adapting to small sample classification requirements.
[0219] As shown in Figure 4 Channel 1, Channel 2, Channel 3, all channels (based on dynamic weighted fusion of Channel 1, Channel 2, Channel 3, i.e. F fused ) is the final output after dynamic fusion of the three, in this embodiment, the Spectra-Quest mechanical fault simulation test bench is used to collect gearbox data, the data source of this embodiment is the gearbox data of Huazhong University of Science and Technology, the multi-sensor data of the gearbox is obtained by speed control sensor, motor sensor and acceleration sensor, 11 kinds of fault state data are collected, including tooth missing, tooth breaking (including 20, 25, 30, 35, 40Hz) under five loads and normal gear under 20Hz load. In order to verify the effectiveness of the method proposed in the application, the fault samples in the training set are set to 1, 3, 5, 10 and 20 for each fault state, and the normal samples are 30; The samples of each fault type in the test set are 30. 1, 3, 5, 10, 20 five training sets correspond to Figure 4 n1-n5. In the field of deep learning, F1 score is the harmonic mean of precision and recall, which is used to comprehensively reflect the identification ability of the model to positive examples (such as fault classes). In small sample classification, data imbalance often occurs, and F1 score is relatively insensitive to data imbalance, which can more objectively reflect the comprehensive performance of the model on minority and majority classes. From Figure 4 It can be seen that compared with using data of any channel for model training, the method proposed in the application maintains the highest F1 score.
[0220] Embodiment 2
[0221] A small sample condition multi-detection device fault identification method, comprising:
[0222] Extracting time domain features from the time domain signals of the multi-detection device of the gear box, performing Fourier transform on the time domain signals of the multi-detection device of the gear box to extract frequency domain features, constructing a time domain graph and a frequency domain graph based on the K nearest neighbor rule according to the time domain features and the frequency domain features, splicing the time domain graph and the frequency domain graph to obtain a positive graph, and comparing the neighborhood node sets of the time domain graph and the frequency domain graph to filter out the neighborhood nodes unique to the frequency domain graph to construct a negative graph;
[0223] Inputting the positive graph, the negative graph and the frequency domain graph into the graph variational autoencoder, and generating a latent distribution through multi-layer GraphSAGE coding in the graph variational autoencoder, reparameterization sampling, multi-layer GraphSAGE decoding reconstruction and channel weight dynamic weighted fusion processing to obtain a fusion node feature matrix;
[0224] According to the fusion node feature matrix, the edge weight of the fused feature is calculated based on the K nearest neighbor rule, and an adjacency matrix with edge weight is constructed according to the edge weight of the fused feature;
[0225] The fusion node feature matrix and the adjacency matrix with edge weight are input into the GraphSAGE and the Transformer layer stacked alternately, the GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features, the Transformer layer enables the edge weight to participate in the scaling dot product attention calculation and dynamically adjusts the weight influence combined with the gating mechanism, and outputs the node features after feature learning;
[0226] The node features after feature learning are input into the global average pooling layer to be aggregated into a global feature vector after pooling, high-level nonlinear features are extracted from the global feature vector after pooling through a multilayer perceptron, and then the high-level nonlinear features are input into a Softmax classifier to obtain a fault class probability.
[0227] Embodiment 3
[0228] A computer program product comprising computer programs / instructions which, when executed by a processor, implement the small sample condition multi-detection device fault identification method in embodiment 2.
[0229] The contents not described in detail in the specification belong to the prior art known to those skilled in the art. Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer usable program code.
[0230] The present application is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of flows and / or blocks in the flowcharts and / or block diagrams can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device that implements the functions specified in the flowcharts and / or block diagrams. Figure 1 The device that implements the functions specified in one flow or multiple flows and / or blocks Figure 1 The device that implements the functions specified in one flow or multiple flows and / or blocks
[0231] These computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture including instructions which implement the flow Figure 1 one or more flow or blocks Figure 1 one or more flow or blocks
[0232] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the flow Figure 1 one or more flow or blocks Figure 1 one or more flow or blocks
[0233] Finally, it should be noted that the above examples are merely used to illustrate the technical solutions of the present application, but not to limit the protection scope thereof. Although the present application has been described in detail with reference to the above examples, those skilled in the art should understand that, after reading the present application, they can make various changes, modifications or equivalent replacements to the specific embodiments of the present application. However, these changes, modifications or equivalent replacements are all within the protection scope of the present application as claimed.
Claims
1. A fault identification system for multiple detection devices under small sample conditions, characterized in that, include: The graph structure construction module extracts time-domain features from the time-domain signals of the multiple detection devices in the gearbox, performs Fourier transform on the time-domain signals of the multiple detection devices in the gearbox to extract frequency-domain features, constructs time-domain graphs and frequency-domain graphs based on the K-nearest neighbor rule according to the time-domain features and frequency-domain features, stitches the time-domain graphs and frequency-domain graphs to obtain a positive graph, compares the neighbor node sets of the time-domain graph and the frequency-domain graph and selects the neighbor nodes unique to the frequency-domain graph to construct a negative graph; The feature fusion module inputs the positive image, negative image, and frequency domain image into the graph variational autoencoder. In the graph variational autoencoder, the latent distribution is generated through multi-layer GraphSAGE encoding, reparameterized sampling, multi-layer GraphSAGE decoding and reconstruction, and dynamic weighted fusion of channel weights to obtain the fused node feature matrix. The feature map fusion construction module calculates the edge weights of the fused features based on the K-nearest neighbor rule according to the feature matrix of the fused nodes, and constructs an adjacency matrix with edge weights based on the edge weights of the fused features. The feature learning module takes the fused node feature matrix and the adjacency matrix with edge weights as inputs to the alternately stacked GraphSAGE and Transformer layers. The GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features, and the Transformer layer makes the edge weights participate in the scaling dot product attention calculation and dynamically adjusts the influence of the weights by combining a gating mechanism, and outputs the node features after feature learning. The fault identification module inputs the node features learned through feature learning into a global average pooling layer to aggregate them into a pooled global feature vector. After extracting high-level nonlinear features from the pooled global feature vector through a multilayer perceptron, the high-level nonlinear features are input into a Softmax classifier to obtain the fault category probability. Specifically, in the graph structure construction module, time-domain features are extracted from the time-domain signals of the multiple detection devices of the gearbox, and frequency-domain features are extracted by performing Fourier transform on the time-domain signals of the multiple detection devices of the gearbox. The specific method for constructing the time-domain graph and frequency-domain graph based on the K-nearest neighbor rule according to the time-domain features and frequency-domain features is as follows: The time-domain signal of the gearbox multi-detection device is denoted as... ; Extracting time-domain features from the time-domain signals of the gearbox multi-detection device, for each sample Generate temporal feature vectors , Represents the temporal feature dimension. For real numbers, the time-domain features include mean, variance, peak value, peak-to-peak value, root mean square, waveform factor, kurtosis, and impulse factor; Fourier transform of time-domain signal That is, for each sample Perform a Fourier transform to obtain the spectrum. , X To achieve spectral resolution, the following frequency domain features are constructed: Spectral amplitude: Spectral amplitude = Frequency band energy: Divide the frequency bands and calculate the energy of each band; Frequency domain statistics: spectral centroid, spectral bandwidth, spectral flatness, and then obtain the frequency domain feature vector based on the frequency domain characteristics. , This represents the dimension of frequency domain features, which include spectral amplitude, frequency band energy, and frequency domain statistics. Use Euclidean distance to pair nodes and nodes Calculate the feature space distance between them: in, The time-domain feature distance matrix, Frequency domain feature distance matrix; Constructing a time-domain graph based on K-nearest neighbors With frequency domain diagram , For a set of nodes, node set Each node in A detection signal sample corresponding to a gearbox , Let the set of edges of the time-domain graph be . Let be the set of edges of the frequency domain graph; Based on time-domain feature distance matrix Constructing the adjacency matrix of the time-domain graph Based on the frequency domain feature distance matrix Constructing the adjacency matrix of the frequency domain graph As shown below: in, This indicates that for each node ,from or Choose the one with the smallest distance. K Each node is a neighbor. The symbol represents all elements in the corresponding row or column.
2. The fault identification system for multiple detection devices under small sample conditions according to claim 1, characterized in that: In the graph structure construction module, the positive graph is obtained by concatenating the time-domain graph and the frequency-domain graph. The specific method for constructing the negative graph by comparing the neighborhood node sets of the time-domain graph and the frequency-domain graph and selecting the neighborhood nodes unique to the frequency-domain graph is as follows: The time-domain plot and frequency-domain plot are concatenated into a positive plot. , The set of edges of a normal graph is obtained by using the eigenvectors of the normal graph. The set of edges of a normal graph = The adjacency matrix of the positive graph ; By comparing the differences in neighboring nodes between the time-domain and frequency-domain graphs, a negative graph is constructed by selecting neighboring nodes unique to the frequency domain. , The set of edges for the negative graph is determined as follows: For each node... Nodes in the time domain graph The set of neighboring nodes Nodes in the frequency domain graph The set of neighboring nodes The set of neighborhood nodes of a negative graph The set of neighborhood nodes in the frequency domain Neighborhood node set relative to the time domain A unique set of neighboring nodes, node characteristics of a negative graph. Negative graph adjacency matrix as follows: 。 3. The fault identification system for multiple detection devices under small sample conditions according to claim 2, characterized in that: In the feature fusion module, the positive image, negative image, and frequency domain image are respectively input into the graph variational autoencoder. The graph variational autoencoder performs multi-layer GraphSAGE encoding to generate the latent distribution, reparameterized sampling, multi-layer GraphSAGE decoding and reconstruction, and dynamic weighted fusion of channel weights to obtain the fused node feature matrix. The specific method is as follows: Multi-layer graph convolution is performed on the positive graph, negative graph, and frequency domain graph respectively to gradually aggregate neighborhood information. The specific steps are as follows: in, These are the positive graph node features, negative graph node features, and frequency domain graph node features output after neighborhood aggregation and nonlinear transformation, respectively. , , The input consists of positive graph node features, negative graph node features, and frequency domain graph node features. For learnable multi-layer graph convolution weights, For activation function, For nodes The serial number, They are nodes The set of neighborhood nodes in positive graphs, negative graphs, and frequency domain graphs. For nodes The sequence number of the domain node; This represents the aggregation of neighbor features, which includes nodes. The features of all neighbors are summarized to generate an aggregate vector, which is used to capture local neighborhood information; The representation feature concatenation combines the node's own features with the aggregated features of its neighbors to form a richer joint representation; Then through a multi-layer GraphSAGE encoder Calculate the mean and covariance matrix of the latent variables independently for each graph, using the following formulas: Positive image: Negative image: Frequency domain diagram: Covariance matrix: in, This is the feature matrix of the positive graph nodes after neighborhood aggregation and nonlinear transformation. For the feature dimensions of the positive graph, This is the feature matrix of the negative graph nodes after neighborhood aggregation and nonlinear transformation. For the feature dimension of the negative image, This is the frequency domain graph node feature matrix after neighborhood aggregation and nonlinear transformation. For the feature dimensions of the frequency domain plot, , , These are the edge sets of the positive graph, negative graph, and frequency domain graph, respectively. The mean of the latent variables in the positive graph. N For the number of nodes, As a potential spatial dimension, The mean of the latent variables in the negative plot. The mean of the latent variables in the frequency domain plot. The log-variance of the latent variables in the positive graph. For the log-variance of the latent variables in the negative plot, The log-variance of the latent variables in the time-domain plot. The first element on the diagonal of the covariance matrix of the latent variables Variance in each dimension It is a multi-layer GraphSAGE encoder; Then, latent variables are sampled from the posterior distributions of the positive, negative, and frequency domain plots, as shown in the following formula: Here, ⊙ represents element-wise multiplication. This represents noise sampled from a standard normal distribution. It is the identity matrix. For the latent variables of the positive graph, For latent variables of the negative graph, For latent variables in the frequency domain plot, Convert logarithmic variance to variance; Next, we will examine the latent variables. , , Using multi-layer GraphSAGE decoders respectively Reconstruct the original features and output the reconstructed frequency domain feature matrix. , Channel number: The channel weights are calculated using the following formula: in, The characteristic moments of the frequency domain plot in the channel The weight, It is a very small positive number. It is the first Mean square error of each channel , Indicates the first Standard deviation of node characteristics for each channel ; based on The weights of each channel are used to weight and fuse the multi-graph reconstruction features to obtain the fused node feature matrix. : 。 4. The fault identification system for multiple detection devices under small sample conditions according to claim 3, characterized in that: Calculate the mean square error between the reconstructed features and the original features of the positive, negative, and frequency domain plots. To measure the difference between the reconstructed features and the original features: Regularization potential space, As a regularization term, it constrains the posterior distribution to approximate the standard normal distribution: Based on contrast loss This enhances the similarity between the positive graph and the frequency domain graph, and suppresses the correlation between the negative graph and the positive graph, as well as the frequency domain graph. Where sim represents cosine similarity; Total loss for: in, β This is the first hyperparameter; γ The second hyperparameter, the first hyperparameter β Second hyperparameter γ These are used to control the strength of regularization and contrastive learning, respectively. Training is performed as follows: Forward propagation involves inputting node features and adjacency matrices from the positive graph, negative graph, and frequency domain graph; the encoder generates the mean and variance; reparameterization sampling is used to obtain latent variables; the decoder reconstructs features; fusion weights are calculated; and the fusion feature matrix is output. Backpropagation involves calculating the total loss and updating the parameters of the encoder, decoder, and channel weights.
5. The fault identification system for multiple detection devices under small sample conditions according to claim 4, characterized in that: In the fused feature map construction module, the specific method for calculating the edge weights of the fused features based on the K-nearest neighbor rule according to the fused node feature matrix, and constructing the adjacency matrix with edge weights based on the edge weights of the fused features, is as follows: First, calculate the Euclidean distance matrix of the fused features: in, For the fusion node feature matrix Middle node and The Euclidean distance between them For nodes The fused feature vector, For the fusion node feature matrix The first in The node of the first 1 eigenvalue, For the fusion node feature matrix The first in The node of the first One eigenvalue; Selecting a neighbor set based on K-nearest neighbors: in, For the fusion node feature matrix Middle node The set of the K nearest neighbors, For the fusion node feature matrix Middle node The threshold of the K smallest distances among all sample distances; Calculate edge weights based on Euclidean distance The formula is as follows: in, This is a bandwidth parameter used to control the weight decay rate; Construct a weighted adjacency matrix Only the first few nodes are retained. K The weights of the neighbors are 0, and the weights of the remaining edges are 0: 。 6. The fault identification system for multiple detection devices under small sample conditions according to claim 5, characterized in that: In the feature learning module, the fused node feature matrix and the adjacency matrix with edge weights are input into alternating stacked GraphSAGE and Transformer layers. The GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features. The Transformer layer allows the edge weights to participate in the scaling dot product attention calculation and dynamically adjusts the influence of the weights using a gating mechanism. The specific method for outputting the node features after feature learning is as follows: The weighted feature maps are input into alternately stacked GraphSAGE and Transformer layers, specifically the fused node feature matrix. and weighted adjacency matrix , For nodes and Edge weights; First, add location information to the node features: in, For nodes The 3D positional encoding; For each GraphSAGE layer, the node representation is updated by weighted aggregation of neighbor features: in, For the first l Layer node characteristics, and These are the learnable first parameter matrix and the learnable second parameter matrix, respectively. For activation functions; For the Transformer layer, the weighted adjacency matrix will be... Added as a bias term in attention calculation: ,B= ,C= in, B, C, and D represent the query matrix, key matrix, and value matrix, respectively. , and These are the first learnable projection matrix, the second learnable projection matrix, and the third learnable projection matrix, respectively. It is the minimum value; Used to convert edge weights into attention biases; In the Transformer layer, gating coefficients are used to dynamically adjust the impact of edge weights: in, For learnable gating parameter matrix; This is the gating coefficient matrix; After alternating stacking GraphSAGE and Transformer layers, the output is the node features learned through feature processing. , For the number of nodes, For feature dimension, This represents the total number of layers for feature learning.
7. The fault identification system for multiple detection devices under small sample conditions according to claim 6, characterized in that: In the fault identification module, the node features learned through feature learning are input into a global average pooling layer to aggregate into a pooled global feature vector. After extracting high-level nonlinear features from the pooled global feature vector using a multilayer perceptron, the high-level nonlinear features are input into a Softmax classifier to obtain the fault category probability. The specific method is as follows: Node features learned through feature learning Input the average pooling layer, which transforms the features of each node into a graph-level global feature vector: in, For the first The feature vector of each node This is the global feature vector after pooling; The pooled global feature vector The input is processed by an MLP for feature extraction. Specifically, the MLP uses fully connected layers and non-linear activation functions to further extract high-level features. in, Here is the weight matrix of the MLP. This is the bias vector of the MLP. For the hidden layer dimension, This represents the high-level nonlinear feature vector output by the MLP. The high-level nonlinear eigenvectors output by the MLP Input to the Softmax classifier to process high-level nonlinear feature vectors Mapping to class probability distribution: in, This is the weight matrix of the Softmax classifier. This is the bias vector for the Softmax classifier. This is a class probability vector, representing whether a sample belongs to a class. The probability of a type of failure. The number of fault categories; Then, the difference between the predicted probability and the true label is calculated using the loss function: in, Cross-entropy loss; For the first The probability of a type of failure; One-hot encoding for the actual label.
8. A method for fault identification system of multiple detection devices under small sample conditions according to any one of claims 1 to 7, characterized in that, include: Time-domain features are extracted from the time-domain signals of the multi-detection device of the gearbox. Fourier transform is performed on the time-domain signals of the multi-detection device of the gearbox to extract frequency-domain features. Based on the time-domain features and frequency-domain features, a time-domain graph and a frequency-domain graph are constructed according to the K-nearest neighbor rule. The time-domain graph and the frequency-domain graph are stitched together to obtain a positive graph. The neighborhood node sets of the time-domain graph and the frequency-domain graph are compared and the unique neighborhood nodes of the frequency-domain graph are selected to construct a negative graph. The positive graph, negative graph, and frequency domain graph are respectively input into the graph variational autoencoder. The graph variational autoencoder performs multi-layer GraphSAGE encoding to generate the latent distribution, reparameterized sampling, multi-layer GraphSAGE decoding and reconstruction, and dynamic weighted fusion of channel weights to obtain the fused node feature matrix. The edge weights of the fused features are calculated based on the K-nearest neighbor rule according to the feature matrix of the fused nodes, and an adjacency matrix with edge weights is constructed based on the edge weights of the fused features. The fused node feature matrix and the adjacency matrix with edge weights are input into the alternately stacked GraphSAGE and Transformer layers. The GraphSAGE layer updates the node representation by weighted aggregation of neighborhood features, and the Transformer layer makes the edge weights participate in the scaling dot product attention calculation and dynamically adjusts the weight influence with the gating mechanism, outputting the node features after feature learning. The node features learned through feature learning are input into a global average pooling layer to aggregate them into a pooled global feature vector. After extracting high-level nonlinear features from the pooled global feature vector through a multilayer perceptron, the high-level nonlinear features are input into a Softmax classifier to obtain the fault category probability.
9. A computer program product, characterized in that, It includes a computer program that, when executed by a processor, implements the fault identification method for multiple detection devices under small sample conditions as described in claim 8.