Fault Diagnosis Method and System Combining Multi-Scale Interactive Graph Convolution and Contrastive Pooling

The integration of multi-scale interactive graph convolution and contrastive pooling in fault diagnosis models addresses the limitations of existing methods by enhancing feature extraction and robustness in rotating machinery fault diagnosis.

CN116070131BActive Publication Date: 2025-07-15CHONGQING UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211606855.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-14
Publication Date
2025-07-15
Estimated Expiration
2042-12-14

AI Technical Summary

Technical Problem

The existing fault diagnosis method based on graph convolution network ignores the extraction of related information between multiple frequency scales of the signal, resulting in the loss of fault-related information. The robustness of the graph pooling method needs to be enhanced, limiting the accuracy and stability of fault diagnosis.

Method used

The fault diagnosis method of multi-scale interactive graph convolution and contrast pooling is adopted. By constructing a multi-scale interactive graph, multi-frequency scale related information is extracted using graph convolution network, and the self-attention pooling layer is enhanced through comparative learning to improve the accuracy and robustness of feature extraction and fault diagnosis.

Benefits of technology

The multi-frequency scale-related information is effectively extracted, which improves the accuracy and stability of fault diagnosis, enhances the robustness of the graph pooling method, and improves the accuracy of rotary machinery fault diagnosis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116070131B_ABST
    Figure CN116070131B_ABST
Patent Text Reader

Abstract

The present invention belongs to the technical field of fault diagnosis, and provides a fault diagnosis method and system combining multi-scale interactive graph convolution and contrastive pooling. The method includes obtaining the vibration signal of a rolling bearing and using a fault diagnosis model to obtain the fault type. The fault diagnosis model includes a multi-scale interactive graph, a graph convolutional network, and a contrastive learning enhanced self-attention pooling layer. The process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculating the node embedding vector and the adjacency matrix to construct a multi-scale interactive graph; based on the node embedding vector and the adjacency matrix, after extracting the graph data features using the graph convolutional layer of the graph convolutional network, passing through the contrastive learning enhanced self-attention pooling layer to coarsen the graph structure and reduce the dimensionality of the graph data features. The coarsened graph data is successively passed through the readout layer and the fully connected layer of the graph convolutional network to obtain the fault type. The present invention improves the accuracy and robustness of the graph convolutional network applied to the fault diagnosis of rotating machinery.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of fault diagnosis, and particularly relates to a fault diagnosis method and system combining multi-scale interactive graph convolution and contrastive pooling. Background Technique

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

[0003] Rotating machinery is widely used in many fields such as industrial production and national defense, such as fans, engines, steam turbines, etc. With the proposal of 5G technology and the development of the Internet of Things, the health status monitoring of mechanical equipment has entered the big data era, providing data support for fault diagnosis methods based on deep learning frameworks. Compared with traditional machine learning methods, the data processing method of deep learning networks combined with gradient descent algorithms is more suitable for extracting features with stronger generalization ability from massive data. Therefore, the fault diagnosis method based on deep learning framework has become a hot research field at present.

[0004] In the field of deep learning, some network frameworks such as autoencoders, convolutional neural networks, fully connected networks, etc. have been successfully applied to the fault diagnosis of rotating machinery and demonstrated their powerful fault classification ability in feature extraction. For deep learning methods, the factors affecting feature extraction and fault classification effects can mainly be attributed to two points: (1) the description method of input data, and (2) deep learning network parameters. For (1) the description method of input data, some studies directly use one-dimensional vibration signals as input and adopt convolutional or fully connected layers to extract signal features; some scholars first extract the time-domain features of vibration signals and then use the feature sequences as input to avoid the influence of noise in the original signal on feature extraction; some studies transform fault diagnosis into an image recognition task, convert one-dimensional vibration signals into two-dimensional matrices according to the time sequence relationship, and use two-dimensional convolution to extract signal features; some scholars use time-frequency analysis methods to obtain the time-frequency spectrogram of vibration signals as input, aiming to extract the fault information hidden in the time-frequency domain with the help of convolutional layers. For (2) deep learning network parameters, usually by changing the sizes of convolutional layers, fully connected layers and the layer depth, adding or deleting batch normalization and dropout modules, different feature extraction capabilities can be obtained. After a fault occurs in a rotating machinery, the waveform, frequency composition, etc. of its vibration signal will change accordingly. For the above two points, most studies use the original signal, or the corresponding time-domain, frequency-domain, and time-frequency domain information as network input, and combine convolutional layers and fully connected layers to achieve feature extraction and classification. However, the above studies ignore the extraction of information features related to the frequency domain scale in the signal (such as when the frequency composition changes due to a fault, the related information between different frequency scales will also change), which limits the further improvement of feature extraction and fault diagnosis performance. Therefore, in order to obtain more abundant feature extraction capabilities, some scholars try to model relevant information to further improve the accuracy and robustness of fault diagnosis.

[0005] As a commonly used tool for relevant information modeling, graph theory has been widely applied to fields such as natural language processing and image processing in recent years. Its powerful data representation ability has improved the performance of deep learning in different field tasks. And in recent years, with the proposal of graph convolutional networks, deep learning frameworks based on graph theory have also been successfully applied to the field of mechanical fault diagnosis. However, there are still two major problems in the current fault diagnosis methods based on graph convolutional networks: (1) Most studies construct interaction graphs of different sample segments and different sensing signals for data representation, but ignore the extraction of relevant information between multi-frequency scales of signals, which may lead to the loss of fault-related information; (2) The robustness of existing graph pooling methods needs to be enhanced, and there is still much room for improvement in the field of fault diagnosis. Summary of the Invention

[0006] To solve the technical problems existing in the above-mentioned background art, the present invention provides a fault diagnosis method and system combining multi-scale interactive graph convolution and contrastive pooling, which extracts fault features hidden in multi-frequency scale related information through a graph convolution network and the constructed multi-scale interactive graph; through the proposed contrastive learning enhanced self-attention pooling layer, hierarchical pooling is performed on graph data, and effective fault characterization information is extracted while reducing the dimensionality of features. Through the above operations, the accuracy and robustness of the graph convolution network applied to rotating machinery fault diagnosis are improved.

[0007] To achieve the above object, the present invention adopts the following technical solutions:

[0008] The first aspect of the present invention provides a fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling.

[0009] The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling includes:

[0010] Obtain the vibration signal of the rolling bearing, and use the fault diagnosis model to obtain the fault type;

[0011] The fault diagnosis model includes a multi-scale interactive graph, a graph convolution network, and a contrastive learning enhanced self-attention pooling layer;

[0012] The process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculating the node embedding vector and the adjacency matrix to construct a multi-scale interactive graph; based on the node embedding vector and the adjacency matrix, using the graph convolution layer of the graph convolution network to extract the graph data features, and then passing through the contrastive learning enhanced self-attention pooling layer to coarsen the graph structure and reduce the dimensionality of the graph data features. The coarsened graph data passes through the readout layer and the fully connected layer of the graph convolution network in sequence to obtain the fault type.

[0013] Further, the process of using the multi-scale interactive graph includes:

[0014] Use continuous wavelet transform to calculate the time-frequency spectrogram of the vibration signal, and normalize the spectrogram values to the range of [0, 1];

[0015] Determine the number of nodes N of the multi-scale interactive graph, and evenly divide the obtained time-frequency spectrogram into N segments along the frequency direction to obtain N strip spectrograms;

[0016] Flatten the obtained strip spectrogram into a one-dimensional vector to become the embedding feature of the corresponding node of the multi-scale interactive graph;

[0017] Set a threshold, calculate the cosine similarity of any two node embedding features, and when the cosine similarity is greater than the threshold, define the two nodes as neighbor nodes, otherwise the two nodes have no connection relationship, so as to obtain the adjacency matrix of the nodes;

[0018] According to the obtained adjacency matrix, an edge index matrix is obtained.

[0019] Furthermore, the graph convolutional network includes three graph convolutional layers and three readout layers. The output of each graph convolutional layer is connected to a contrastive learning enhanced self-attention pooling layer, and the output of each contrastive learning enhanced self-attention pooling layer is connected to a readout layer. The outputs of the three readout layers are jointly connected to a fully connected layer.

[0020] Furthermore, the training of the fault diagnosis model includes the training of the contrastive learning enhanced self-attention pooling layer:

[0021] The contrastive learning enhanced self-attention pooling layer includes parallel GCN+ and GCN-. By imposing a classification constraint on GCN+, the obtained positive sample attention score is positively correlated with the fault classification accuracy, and no constraint is imposed on GCN- so that the obtained negative sample attention score is independent of the node contribution degree;

[0022] The difference between the positive sample attention score and the negative sample attention score is used as the new positive sample attention score, while the negative sample attention score remains unchanged; the new positive sample attention score and the negative sample attention score, through the Top-k criterion and the masking operation, screen and retain the k nodes with the largest attention scores, while discarding the remaining nodes, respectively obtaining the positive pooling graph and the negative pooling graph; after multiple rounds of network training iterations, maximizing the difference between the positive sample attention score and the negative sample attention score, obtaining a more stable positive sample attention score, and obtaining the coarsened graph - positive pooling graph that best represents the original graph.

[0023] Even further, the Top-k criterion is: retain the nodes corresponding to the k largest attention scores in the node attention score sequence, and discard the remaining nodes.

[0024] Furthermore, the fault diagnosis model uses a classification loss function and a contrastive loss function to optimize the parameters of the fault diagnosis model during training.

[0025] Even further, the classification loss function is:

[0026]

[0027] The contrastive loss function is:

[0028]

[0029] where N s is the number of training samples; C is the number of fault categories; p j represents the true class probability of the jth sample; q jIt represents the probability value that the j-th sample of the prediction belongs to the c-th category; l1, l2, and l3 respectively represent the layer indices corresponding to the three pooling layers. It represents the positive sample attention score of the i-th sample output by the positive pooling network GCN+ of the (l + 1)-th layer. It represents the negative sample attention score of the i-th sample output by the negative pooling network GCN- of the (l + 1)-th layer; q +,i It represents the class probability of the i-th sample predicted by the method based on the positive pooling graph; q -,i It represents the class probability of the i-th sample predicted by the method based on the negative pooling graph.

[0030] The second aspect of the present invention provides a fault diagnosis system combining multi-scale interactive graph convolution and contrastive pooling.

[0031] The fault diagnosis system combining multi-scale interactive graph convolution and contrastive pooling includes:

[0032] A fault diagnosis module, which is configured to: acquire the vibration signal of the rolling bearing and obtain the fault type by using a fault diagnosis model;

[0033] A model construction and processing module, which is configured to: the fault diagnosis model includes a multi-scale interactive graph, a graph convolutional network, and a contrastive learning enhanced self-attention pooling layer; the process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculating the node embedding vector and the adjacency matrix, and constructing a multi-scale interactive graph; based on the node embedding vector and the adjacency matrix, after extracting the graph data features by using the graph convolutional layer of the graph convolutional network, passing through the contrastive learning enhanced self-attention pooling layer to coarsen the graph structure and reduce the dimensionality of the graph data features, and the coarsened graph data passes through the readout layer and the fully connected layer of the graph convolutional network in sequence to obtain the fault type.

[0034] The third aspect of the present invention provides a computer-readable storage medium.

[0035] A computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, it implements the steps in the fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling as described in the first aspect above.

[0036] The fourth aspect of the present invention provides a computer device.

[0037] A computer device includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, it implements the steps in the fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling as described in the first aspect above.

[0038] Compared with the prior art, the beneficial effects of the present invention are:

[0039] The present invention proposes a fault diagnosis framework based on a graph convolutional neural network. The framework uses three graph convolutional layers to extract the features of graph data, and sets three pooling layers to coarsen the graph structure and reduce the dimension of the features extracted by convolution. Three readout layers are used to read the pooled graph data as the input of the fully connected layer. Finally, the fault type of the output data is obtained with the help of the fully connected layer to complete the fault diagnosis task.

[0040] The multi-scale interaction graph proposed by the present invention innovatively divides the time-frequency spectrum into band spectra, and further transforms it into graph data to construct a data model representing multi-frequency scale related information. At the same time, the multi-scale interaction graph can be well embedded in the graph convolutional neural network, giving full play to the advantages of deep learning in big data processing, and mining the fault diagnosis knowledge hidden in the multi-frequency scale related information.

[0041] The contrast learning enhanced graph pooling layer proposed by the present invention innovatively applies the contrast learning framework to the graph pooling task. By virtue of the natural contradictory attributes of the positive pooling graph and the negative pooling graph in describing the original graph data, the graph pooling operation is transformed into a binary classification approximation task. While imposing classification constraints on the positive pooling graph, the difference between the positive and negative pooling graphs is continuously increased, so as to obtain a graph pooling result with higher robustness and positively correlated with the correct classification, effectively improving the accuracy and stability of fault diagnosis. Description of the Drawings

[0042] The specification drawings constituting a part of the present invention are used to provide a further understanding of the present invention. The schematic embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention.

[0043] Figure 1 It is a schematic diagram of the fault diagnosis model framework shown in the present invention;

[0044] Figure 2 It is a schematic diagram of multi-scale interaction graph modeling shown in the present invention;

[0045] Figure 3 It is a schematic diagram of the adjacency matrix, edge index matrix and node connection relationship shown in the present invention;

[0046] Figure 4 It is a schematic diagram of the adjacency matrix masking operation shown in the present invention;

[0047] Figure 5 It is a schematic diagram of the node embedding vector matrix mask shown in the present invention. Detailed Embodiments

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

[0049] It should be noted that the following detailed description is exemplary and is intended to provide further explanation of the present invention. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which the present invention pertains.

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

[0051] It should be noted that the flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of the methods and systems according to various embodiments of the present disclosure. It should be noted that each block in the flowchart or block diagram may represent a module, a program segment, or a part of code, and the module, program segment, or part of code may include one or more executable instructions for implementing the logical functions specified in each embodiment. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than marked in the accompanying drawings. For example, two consecutive blocks shown may actually be executed substantially in parallel, or they may sometimes be executed in the reverse order, depending on the functions involved. Similarly, it should be noted that each block in the flowchart and / or block diagram, and the combinations of blocks in the flowchart and / or block diagram, may be implemented using a dedicated hardware-based system for performing the specified functions or operations, or may be implemented using a combination of dedicated hardware and computer instructions.

[0052] Embodiment 1

[0053] This embodiment provides a fault diagnosis method that combines multi-scale interactive graph convolution and contrastive pooling. Taking the application of this method to a server as an example, it can be understood that this method can also be applied to a terminal, and can also be applied to a system including a terminal and a server, and is realized through the interaction between the terminal and the server. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, web servers, cloud communications, middleware services, domain name services, security services CDN, and big data and artificial intelligence platforms. The terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, etc., but is not limited thereto. The terminal and the server can be directly or indirectly connected through wired or wireless communication methods, and this application does not make any restrictions here. In this embodiment, the method includes the following steps:

[0054] Obtain the vibration signal of the rolling bearing, and use the fault diagnosis model to obtain the fault type;

[0055] The fault diagnosis model includes a multi-scale interactive graph, a graph convolutional network, and a contrastive learning enhanced self-attention pooling layer;

[0056] The process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculate the node embedding vector and the adjacency matrix, and construct a multi-scale interactive graph; based on the node embedding vector and the adjacency matrix, use the graph convolutional layer of the graph convolutional network to extract the graph data features, and then through the contrastive learning enhanced self-attention pooling layer, coarsen the graph structure and reduce the dimensionality of the graph data features. The coarsened graph data passes through the readout layer and the fully connected layer of the graph convolutional network in sequence to obtain the fault type.

[0057] The following describes this embodiment more clearly and completely with reference to the accompanying drawings:

[0058] The fault diagnosis model proposed in this embodiment includes: (1) a multi-scale interactive graph, (2) a graph convolutional network, and (3) a contrastive learning enhanced pooling layer. Figure 1 The overall network architecture of this embodiment is given.

[0059] 1. Multi-scale interactive graph

[0060] Figure 2 The figure shows the schematic diagram of multi-scale interactive graph modeling. The multi-scale interactive graph modeling mainly includes the following steps:

[0061] (1) Use continuous wavelet transform (CWT) to calculate the time-frequency spectrum diagram of the vibration signal, and normalize the spectrum diagram values to the range of [0, 1];

[0062] (2) Determine the number of nodes \(N\) in the multi-scale interaction graph, and evenly divide the obtained time-frequency spectrogram into \(N\) segments along the frequency direction to obtain \(N\) strip-shaped spectrograms;

[0063] (3) Flatten the obtained strip-shaped spectrogram into a one-dimensional vector to become the embedding feature of the corresponding node;

[0064] (4) Set a threshold \(\varepsilon\), calculate the cosine similarity of the embedding features of any two nodes. When the cosine similarity is greater than \(\varepsilon\), define the two nodes as neighbor nodes to each other; otherwise, there is no connection relationship between the two nodes. Obtain the adjacency matrix of the nodes according to the above processing;

[0065] (5) Obtain the edge index matrix according to the obtained adjacency matrix.

[0066] The formula involved in step (4) is as follows:

[0067]

[0068] Among them, represents the neighbor nodes of node \(v\); i ; \(x\) i , \(x\) j are the embedding vectors of node \(v\) i , node \(v\) j ; \(\varepsilon\)-radius(\(v\) i ) is the neighbor search function, and its return value \(\{v\) j , \(j\in N:\cos(x\) i , \(x\) j )\geq\varepsilon\}\) is the neighbor node set of node \(v\) i ; \(\cos(x\) i , \(x\) j ) represents the cosine similarity of \(x\) i , \(x\) j .

[0069] Since the constructed multi-scale interaction graph is an undirected and unweighted graph, its modeling only needs to consider the node embedding vector and the edge index matrix. Therefore, the description and construction of the graph have been realized through the above steps. To illustrate the corresponding relationship between the node connection relationship in the graph, the adjacency matrix, and the edge index matrix, this embodiment gives an illustration in Figure 3 .

[0070] 2. Graph Convolutional Network

[0071] The network framework of the fault diagnosis method proposed in this embodiment includes three graph convolutional layers (GCN1, GCN2, GCN3) for extracting features from the constructed multi-scale interaction graph; after each graph convolutional layer extracts features, it passes through a pooling layer for graph structure coarsening and feature dimensionality reduction (the pooling layer here is the contrastive learning enhanced graph pooling layer proposed in the present invention, and the specific function of this module will be introduced in detail in the next section); then, the coarsened graph is followed by a readout layer (Readout1, Readout2, Readout3), which converts the graph topology structure and node embedding vectors into data that can be directly processed by a fully connected layer (MLP); the fully connected layer (MLP) receives the data read out by the three readout layers, classifies the data for faults, and completes the fault diagnosis task. The formulas involved in the readout layer's processing of data are as follows:

[0072]

[0073] where r i represents the features read out by the i-th readout layer; N represents the number of nodes in the graph data to be processed by the readout layer; represents the embedding vector of the n-th node in the graph data after being processed by the i-th convolutional layer; max represents the operation of taking the maximum value; CONCAT represents the operation of concatenating row vectors. It can be seen from formula (2) that the readout layer actually takes the average value and the maximum value of all node embedding vectors of the graph data to be processed as the readout features and inputs them into the fully connected layer.

[0074] The fully connected layer in the network structure consists of three layers and is finally activated by the softmax function and output. The number of output nodes is the number of fault types, and the output of each node represents the probability value that the current data is this fault.

[0075] The calculation formulas of the above-mentioned three convolutional layers when participating in the forward propagation of the network are as follows:

[0076] H 0 = ReLU([A 0 XW0]) (3)

[0077] H 1 = ReLU([CSPool(A 0 ,H 0 )·W1]) (4)

[0078] H 2 = ReLU([CSPool(A 1 ,H 1 )·W2]) (5)

[0079] where H 0 , H 1 , H 2is the node embedding vector matrix after forward propagation; ReLU is a nonlinear activation unit; CSPool represents the contrastive learning enhanced pooling operation proposed in this embodiment, and the processing flow of this module will be specifically given in the next section; W0, W1, W2 represent the 1st, 2nd, and 3rd layer convolution kernels; X represents the node embedding vector matrix before pooling; A 0 , H 0 The adjacency matrix and node embedding vector matrix representing the original graph data; A 1 , H 1 Represents the adjacency matrix and node embedding vector matrix of the graph data after the first pooling layer and the second convolution layer.

[0080] 3. Contrastive Learning Enhanced Pooling Layer

[0081] like Figure 1 As shown in the contrastive learning enhanced self-attention pooling in , it mainly consists of two parallel graph convolutional networks (GCN + 、GCN - ). The purpose of this module is to use GCN + 、GCN - Get two sets of node attention scores, namely the positive sample attention score and the negative sample attention score, and give them to GCN + Classification constraints are imposed to make the positive sample attention score positively correlated with the fault classification accuracy (the greater the contribution of the node embedding vector to the correct fault classification, the higher its node attention score). At the same time, GCN - Constraints are imposed so that the obtained negative sample attention score is independent of the node contribution; then, the difference between the positive sample attention score and the negative sample attention score is taken as the new positive sample attention score, while the negative sample attention score remains unchanged; the positive sample attention score and the negative sample attention score are subjected to the Top-k criterion and mask operation to screen and retain the k nodes with the largest attention scores, and discard the remaining nodes to obtain the positive pooling graph and the negative pooling graph respectively; after multiple rounds of network training iterations, the difference between the positive sample attention score and the negative sample attention score is maximized to obtain a more stable positive sample attention score, so as to obtain the coarsened graph - the positive pooling graph - that best represents the original graph while reducing the dimension of the graph embedding vector.

[0082] The Top-k criterion in the pooling process is: retain the nodes corresponding to the largest k attention scores in the node attention score sequence, and discard the remaining nodes.

[0083] The mask operation in the pooling process targets the adjacency matrix and node embedding vector matrix of the graph data, such as Figure 4 , Figure 5As shown in the figure, this paper takes a graph data containing five nodes as an example. Suppose after Top-k screening, nodes 1, 3, and 5 are the top three nodes with the largest attention scores. Retain these three nodes and discard nodes 2 and 4. Since the graph data participates in the forward propagation of the neural network with the adjacency matrix and the node embedding vector matrix, the discarded nodes do not participate in the operation. Therefore, the masking operation actually covers the second row, fourth row, second column, and fourth column corresponding to nodes 2 and 4 in the adjacency matrix, as well as the second row and fourth row in the node embedding vector matrix, so that the discarded nodes do not participate in subsequent operations.

[0084] In the above contrastive learning enhanced self-attention pooling layer, the calculation formulas for the positive and negative attention scores are as follows:

[0085]

[0086] Among them, represents the positive and negative attention scores of the (l + 1)-th layer of the network; σ represents the sigmoid function; H l , A l respectively represent the node embedding vector matrix and the adjacency matrix of the graph data of the l-th layer.

[0087] The node screening formula based on the Top-k criterion is as follows:

[0088]

[0089] Among them, respectively represent the node index values corresponding to the largest k attention scores obtained after Topk-k screening; N represents the number of nodes in the original graph data; ratio pool represents the pooling ratio.

[0090] The formula for the above masking operation is as follows:

[0091]

[0092]

[0093] Among them is the adjacency matrix and the node embedding vector matrix of the positive pooling graph of the (l + 1)-th layer obtained by calculation; is the adjacency matrix and the node embedding vector matrix of the negative pooling graph of the (l + 1)-th layer obtained by calculation.

[0094] 4. Loss function

[0095] Based on the above modules, the present invention includes a total of two loss functions: classification loss L cls , contrastive loss L corThe calculation formulas of these two loss functions are as follows:

[0096]

[0097]

[0098] Among them, N s is the number of training samples; C is the number of fault categories; p j represents the true class probability of the j-th sample; q j represents the probability value that the j-th sample predicted by the present invention belongs to the c-th category; l1, l2, and l3 respectively represent the layer indices corresponding to the three pooling layers; represents the positive sample attention score of the i-th sample output by the positive pooling network GCN of the (l + 1)-th layer + ; represents the negative sample attention score of the i-th sample output by the negative pooling network GCN of the (l + 1)-th layer - ; q +,i represents the class probability of the i-th sample predicted by the method based on the positive pooling graph; q -,i represents the class probability of the i-th sample predicted by the method based on the negative pooling graph. Specifically, based on the above loss functions, each parameter is updated according to the following formula.

[0099]

[0100]

[0101] The training process of the method proposed in this embodiment is as follows.

[0102]

[0103] Based on the above training process, through the classification loss L cls , the network parameters except θ pool- learn the fault classification knowledge. At the same time, this loss function can also constrain that the positive sample attention score output by GCN + is positively correlated with the correct fault classification; through the contrast loss L cor , the similarity between the prediction result output based on the negative pooling graph and the prediction result output based on the positive pooling graph is reduced. Since the positive pooling graph is obtained based on the positive sample attention score, and the positive sample attention score is obtained by subtracting the negative sample attention score from the original positive sample attention score (see formula (6)), therefore, based on the contrast loss and formula (6), the gap between the attention scores of the positive and negative pooling outputs will be continuously increased, so that the output positive sample attention score is more stable and positively correlated with the correct fault classification.

[0104] Embodiment 2

[0105] This embodiment provides a fault diagnosis system that combines multi-scale interactive graph convolution and contrastive pooling.

[0106] The fault diagnosis system that combines multi-scale interactive graph convolution and contrastive pooling includes:

[0107] A fault diagnosis module, which is configured to: obtain the vibration signal of a rolling bearing and use a fault diagnosis model to obtain the fault type;

[0108] A model construction and processing module, which is configured to: the fault diagnosis model includes a multi-scale interactive graph, a graph convolutional network, and a contrastive learning enhanced self-attention pooling layer; the process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculating the node embedding vector and the adjacency matrix to construct a multi-scale interactive graph; based on the node embedding vector and the adjacency matrix, after extracting the graph data features using the graph convolutional layer of the graph convolutional network, passing through the contrastive learning enhanced self-attention pooling layer to coarsen the graph structure and reduce the dimensionality of the features of the graph data, and the coarsened graph data passes through the readout layer and the fully connected layer of the graph convolutional network in sequence to obtain the fault type.

[0109] It should be noted here that the above-mentioned fault diagnosis module and model construction and processing module have the same examples and application scenarios as the steps in Embodiment 1, but are not limited to the content disclosed in Embodiment 1 above. It should be noted that the above modules, as part of the system, can be executed in a computer system such as a set of computer-executable instructions.

[0110] Embodiment 3

[0111] This embodiment provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, it implements the steps in the fault diagnosis method that combines multi-scale interactive graph convolution and contrastive pooling as described in Embodiment 1 above.

[0112] Embodiment 4

[0113] This embodiment provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, it implements the steps in the fault diagnosis method that combines multi-scale interactive graph convolution and contrastive pooling as described in Embodiment 1 above.

[0114] Those skilled in the art should understand that the embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of hardware embodiments, software embodiments, or embodiments that combine software and hardware aspects. Moreover, the present invention can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk memories and optical memories, etc.) that contain computer-usable program code.

[0115] The present invention is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to embodiments of the present invention. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, as well as 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 devices to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in one flow Figure 1 one flow or multiple flows and / or blocks Figure 1 or multiple blocks.

[0116] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, such that the instructions stored in the computer-readable memory generate a manufactured article including instruction means that implement the functions specified in one flow Figure 1 one flow or multiple flows and / or blocks Figure 1 or multiple blocks.

[0117] These computer program instructions can also be loaded onto a computer or other programmable data processing device, such that a series of operation steps are executed on the computer or other programmable device to generate a computer-implemented process, so that the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one flow Figure 1 one flow or multiple flows and / or blocks Figure 1 or multiple blocks.

[0118] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware through a computer program. The program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above methods. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM), etc.

[0119] The above are only the preferred embodiments of the present invention and are not used to limit the present invention. For those skilled in the art, the present invention can have various changes and modifications. 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 fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling, characterized in that including: Obtain the vibration signal of the rolling bearing, and use the fault diagnosis model to obtain the fault type. The fault diagnosis model includes a multi-scale interaction graph, a graph convolutional network, and a contrast learning enhanced self-attention pooling layer. The process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculate the node embedding vector and the adjacency matrix, and construct a multi-scale interaction graph. Based on the node embedding vector and the adjacency matrix, after extracting the graph data features by the graph convolutional layer of the graph convolutional network, through the contrast learning enhanced self-attention pooling layer, the graph data features are coarsened in graph structure and feature dimension reduced. The coarsened graph data passes through the readout layer and the fully connected layer of the graph convolutional network in sequence to obtain the fault type.

2. The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling according to claim 1, characterized in that The process of constructing the multi-scale interaction graph includes: Use continuous wavelet transform to calculate the time-frequency spectrogram of the vibration signal, and normalize the spectrogram values to the range of [0, 1]. Determine the number of nodes N of the multi-scale interaction graph, and evenly divide the obtained time-frequency spectrogram into N segments along the frequency direction to obtain N strip-shaped spectrograms. Flatten the obtained strip-shaped spectrogram into a one-dimensional vector to become the embedding feature of the corresponding node of the multi-scale interaction graph. Set a threshold, calculate the cosine similarity of any two node embedding features. When the cosine similarity is greater than the threshold, define the two nodes as neighbor nodes, otherwise the two nodes have no connection relationship, and thus obtain the adjacency matrix of the nodes. According to the obtained adjacency matrix, obtain the edge index matrix.

3. The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling according to claim 1, wherein The graph convolutional network includes three graph convolutional layers and three readout layers. The output of each graph convolutional layer is connected to a contrast learning enhanced self-attention pooling layer, and the output of each contrast learning enhanced self-attention pooling layer is connected to a readout layer. The outputs of the three readout layers are jointly connected to a fully connected layer.

4. The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling according to claim 1, characterized in that, The training of the fault diagnosis model includes the training of the contrast learning enhanced self-attention pooling layer: The contrast learning enhanced self-attention pooling layer includes parallel GCN+ and GCN-. By imposing a classification constraint on GCN+, the obtained positive sample attention score is positively correlated with the fault classification accuracy, and no constraint is imposed on GCN-, so that the obtained negative sample attention score has nothing to do with the node contribution degree. Take the difference between the positive sample attention score and the negative sample attention score as the new positive sample attention score, while the negative sample attention score remains unchanged; pass the new positive sample attention score and the negative sample attention score through the Top-k criterion and the masking operation, screen and retain the k nodes with the largest attention scores, and discard the remaining nodes to obtain the positive pooling graph and the negative pooling graph respectively; after multiple rounds of network training iterations, maximize the difference between the positive sample attention score and the negative sample attention score to obtain a more stable positive sample attention score, and obtain the coarsened graph - positive pooling graph that can best represent the original graph.

5. The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling according to claim 4, characterized in that The Top-k criterion is: retain the nodes corresponding to the k largest attention scores in the node attention score sequence, and discard the remaining nodes.

6. The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling according to claim 1, characterized in that, The fault diagnosis model uses a classification loss function and a contrast loss function to optimize the parameters of the fault diagnosis model during the training process.

7. The fault diagnosis method combining multi-scale interactive graph convolution and contrastive pooling according to claim 6, characterized in that The classification loss function is: The contrast loss function is: Among them, is the number of training samples; is the number of fault categories; represents the true class probability of the th sample; represents the probability value that the predicted th sample belongs to the th class; respectively represent the layer indices corresponding to the three pooling layers; represents the positive sample attention score of the th sample output by the positive pooling network GCN+ of the th layer; represents the negative sample attention score of the th sample output by the negative pooling network GCN- of the th layer; represents the class probability of the th sample predicted by the method based on the positive pooling graph; represents the class probability of the th sample predicted by the method based on the negative pooling graph.

8. A fault diagnosis system that combines multi-scale interactive graph convolution and contrastive pooling, characterized in that, including: A fault diagnosis module, which is configured to: acquire the vibration signal of a rolling bearing and obtain the fault type by using a fault diagnosis model; A model construction and processing module, which is configured to: the fault diagnosis model includes a multi-scale interaction graph, a graph convolutional network, and a contrast learning enhanced self-attention pooling layer; The process of using the fault diagnosis model includes: based on the vibration signal of the rolling bearing, calculating the node embedding vector and the adjacency matrix, and constructing a multi-scale interaction graph; Based on the node embedding vector and the adjacency matrix, after extracting the graph data features by using the graph convolutional layer of the graph convolutional network, through the contrast learning enhanced self-attention pooling layer, the graph data features are coarsened in graph structure and the features are dimension-reduced. The coarsened graph data sequentially passes through the readout layer and the fully connected layer of the graph convolutional network to obtain the fault type.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by a processor, it implements the steps in the fault diagnosis method of joint multi-scale interaction graph convolution and contrast pooling according to any one of claims 1-7.

10. A computer device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps in the fault diagnosis method of joint multi-scale interaction graph convolution and contrast pooling according to any one of claims 1-7.