An intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph
Through the intelligent diagnostic method of dynamic causal knowledge graph and dual-channel attention mechanism, the accuracy problem of the diagnostic system under complex operating conditions is solved, real-time adaptation and efficient fault identification of operating conditions are achieved.
Patent Information
- Application Number
- CN202510429136.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-08
- Publication Date
- 2025-07-29
- Estimated Expiration
- 2045-04-08
AI Technical Summary
The existing diagnostic systems are difficult to adjust the model in real time under complex operating conditions, resulting in a decrease in diagnostic accuracy and the inability to accurately distinguish operating condition response from fault signs. In addition, machine learning methods have poor diagnosis results when there is insufficient data or operating conditions change beyond the range.
An intelligent diagnostic method based on dynamic causal knowledge graph is adopted, and a driving causal graph and a system causal graph are constructed through sliding windows to traverse data, causal correction weights and stability weights are extracted, and a dual-channel attention mechanism is embedded to build a multi-layer timing causal network for real-time diagnosis.
It significantly improves diagnostic accuracy and generalization capabilities, can dynamically adapt to operating conditions, provide explainable fault propagation paths, and enhances the robustness of the model and the ability to identify complex faults.
Smart Images

Figure CN119939375B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of equipment status diagnosis, and specifically to an intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph. Background Art
[0002] Diagnostic systems play a crucial role in equipment operation status monitoring, fault prediction, and providing alarm or maintenance suggestions. However, the change of equipment working conditions has become an important factor affecting its performance and accuracy. During actual operation, under different loads of the equipment, parameters such as temperature, vibration, and pressure will fluctuate significantly. In the prior art, most traditional diagnostic models are constructed based on fixed patterns and parameters, lacking the flexible adaptation ability to working condition changes. When the working conditions change greatly, it is difficult for these models to accurately distinguish whether the parameter fluctuations are normal working condition responses or fault symptoms. For example, in the wind power generation scenario, a large change in wind speed will cause fluctuations in the generator load. Traditional diagnostic models may misjudge normal increased vibration as a fault, or fail to timely identify the real faults masked by working condition changes. This lack of ability to identify working condition fluctuations greatly reduces the diagnostic accuracy, fails to meet the requirements for accurate fault judgment in practical applications, and may even lead to incorrect maintenance suggestions or missed key faults in complex working conditions, bringing potential risks to equipment operation.
[0003] Therefore, diagnostic systems need to have the ability to adjust and update models in real time, or adopt advanced methods such as machine learning to automatically adapt to these changes. However, under the existing technical conditions, real-time adjustment of models faces challenges in computing resources and algorithm complexity, and many systems are difficult to achieve accurate model updates while ensuring real-time performance. Although machine learning methods have a certain adaptive ability, when the data is insufficient or the working condition changes exceed the coverage range of the training data, their diagnostic effects will be severely affected. For example, when the equipment enters a completely new working condition mode, the machine learning model may not be able to accurately judge due to the lack of corresponding data training, resulting in diagnostic errors. It can be seen that traditional methods have obvious limitations in dealing with complex and changeable working conditions. Their diagnostic logic relying on historical data and fixed patterns is difficult to continuously maintain high accuracy in dynamically changing working conditions.
[0004] Thus, there is an urgent need for more advanced technical means to overcome the dilemma of low diagnostic accuracy in the prior art. Summary of the Invention
[0005] In order to avoid and overcome the technical problems existing in the prior art, the present invention provides an intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph. The present invention can effectively improve the diagnostic accuracy.
[0006] To achieve the above object, the present invention provides the following technical solutions:
[0007] An intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph, comprising the following diagnosis steps:
[0008] S1. Obtain the time series data of the driving variables and system variables, traverse all the time series data in the way of a sliding window, and obtain the initial causal strength of the time series data within each window;
[0009] S2. Use the initial causal strength to construct a driving causal graph between the driving variables and system variables within each window, and a system causal graph between the system variables and system variables;
[0010] S3. Extract the causal strength of different driving variables on each system variable from the driving causal graph, and obtain the causal correction weights of different degrees of the driving variables on different system variables under this causal strength through reverse normalization, and then input the causal correction weights into the causal channel attention mechanism to obtain the corresponding channel attention correction weights;
[0011] S4. Extract the causal stability weights between the system variables from the system causal graph, and then input the causal stability weights into the causal time attention mechanism to obtain the corresponding time attention correction weights;
[0012] S5. Input the channel attention correction weights and time attention correction weights into the diagnosis framework for training to obtain a prediction model;
[0013] S6. Obtain the real-time time series data, and input the real-time time series data into the prediction model to predict the corresponding system state.
[0014] As a further solution of the present invention: The specific steps of step S1 are as follows:
[0015] S11. Obtain the time series data of the driving variables and system variables;
[0016] S12. Set the window size as and the sliding step as and slide them in turn; the time period corresponding to each window can be expressed as
[0017]
[0018]
[0019] where can represent the start time of the current window;
[0017] S13. Based on the delay embedding theory, set the current lag time as and combine the window to construct the -dimensional embedding vector within the time period :
[0018]
[0019] ;
[0019] Among them, Represents the time sub-variation; Represents the th variable within the time period of the dimensional embedding vector; Represents the variable within the time period of the time series data; Represents the variable within the time period of the time series data; Represents the variable within the time period of the time series data;
[0020] S14. Obtain KNN through the algorithm k nearest neighbors and form the following nearest neighbor set:
[0021] ;
[0022] In the formula, represents the within the time period obtained through KNN algorithm k nearest neighbor set formed by the nearest neighbors; represents obtained through KNN algorithm the 1st dimensional embedding vector; represents KNN obtained through algorithm the 2nd obtained through KNN algorithm k the dimensional embedding vector;
[0023] S15. Project onto the lag time after the th variable dimensional embedding vector The projection process is as follows:
[0024] ;
[0025] In the formula, represents the within the time period projected onto Dimensional embedding vector The formed set, which represents within the time period Inside Through KNN Obtained by the algorithm k The nearest neighbor set composed of the nearest neighbors, Represents within the time period The Variable Of Dimensional embedding vector;
[0026] Represents Projected onto After that, Through KNN The first obtained by the algorithm Dimensional embedding vector; Represents Projected onto After that, Through KNN The second obtained by the algorithm Dimensional embedding vector; Represents Projected onto After that, Through KNN The k One Dimensional embedding vector;
[0027] S16. According to whether the change of the variable During the projection process under the current lag time causes the change of the variable To construct Model and Model; The model assumes that the change of the variable Will not cause the change of the variable That is, there is no causal relationship between the variable And the variable And the variable There is no causal relationship; The model assumes that the change of the variable Will cause the change of the variable That is, there is a causal relationship between the variable And the variable There is a causal relationship;
[0028] S17. Combining the area under the curve To define The calculation result of the model is To define The calculation result of the model is To define from the variable to the variable The causal strength for ; where represents KNN the radius value of the algorithm;
[0029] S18. Construct a set of lag times and calculate, according to the content of steps S13 to S17, the causal strength from the variable to the variable at different lag times within each time period , and select the maximum value among them to obtain the maximum causal strength from the variable to the variable within each time period ;
[0030] ;
[0031] In the formula, represents the maximum causal strength from the variable to the variable ; represents the operation of taking the maximum value; represents at the lag time , the causal strength from the variable to the variable ; represents at the lag time which is the maximum lag time , the causal strength from the variable to the variable ;
[0032] S19. Calculate, according to the content of steps S13 to S18, the maximum causal strength between each driving variable and each system variable, and the maximum causal strength between each system variable within each time period , and use the maximum causal strength as the initial causal strength between each variable.
[0033] As a further solution of the present invention: The specific content of step S2 is as follows:
[0034] S21. Using the initial causal strength between the driving variable and the system variable as the edge weight, construct a driving causal graph between each driving variable and each system variable within each time period ;
[0035] S22. Using the initial causal strength between the system variables as the edge weight, construct a system causal graph between each system variable within each time period , that is, the system causal graph between each system variable within each window.
[0036] As a further solution of the present invention: The specific steps of step S3 are as follows:
[0037] S31. Calculate the causal correction weights between each driving variable and each system variable in each time period according to the driving causal diagram; within each time period;
[0038] S32. Replace the values of the current system variable at the starting moment in each time period with all its values in that time period, and then apply global average pooling along the time dimension to average pool the system variables over the entire cycle. The result is expressed as follows:
[0039] ;
[0040] In the formula, represents the value of the system variable at the starting moment in the th time period i.e., the th window; represents the number of time periods in the entire cycle i.e., the number of windows; represents the average pooling value of the system variable ;
[0041] S33. Based on the causal channel attention mechanism, use the average pooling value and obtain the scores of the corresponding channels through the scoring function. The scoring function is expressed as follows:
[0042] ;
[0043] In the formula, represents the th channel in the causal channel attention mechanism; represents the th element of the query vector ; represents the score of the channel in the causal channel attention mechanism;
[0044] S34. Calculate the channel weights of each channel in the causal channel attention mechanism;
[0045] S35. Combine the channel weights and calculate the initial attention weights of each channel in each window in the causal channel attention mechanism, and store them in the initial attention weight matrix;
[0046] ;
[0047] In the formula, represents the initial weight of the channel in the causal channel attention mechanism; Indicates the channel in the causal channel attention mechanism when in the first window ; Indicates The initial attention weight; Indicates when in the th window, the channel in the causal channel attention mechanism ; Indicates The initial attention weight; Indicates when in the th window, the channel in the causal channel attention mechanism ; Indicates The initial attention weight;
[0048] S36. Embed the causal correction weight into the corresponding channel and align it with the time position to obtain the corrected channel attention correction weight for each channel in the causal channel attention mechanism, and store the channel attention correction weight in the channel attention matrix;
[0049] ;
[0050] In the formula, Indicates all time periods That is, the causal correction weight matrix formed by arranging in sequence the causal correction weights between the th driving variable and the th system variable within all windows; Indicates the Hadamard product; Indicates the causal correction weight between the driving variable and the system variable within the first window; Indicates that when in the first window, the channel attention correction weight of the channel affected by ; Indicates the th window, the causal correction weight between the driving variable and the system variable ; Indicates that when in the th window, the channel attention correction weight of the channel affected by ; Indicates the th window, the causal correction weight between the driving variable and the system variable ; Indicates that when in the When there are channels affected Channel attention correction weights.
[0051] As a further aspect of the present invention: The calculation formula of the causal correction weight is expressed as follows:
[0052] ;
[0053] In the formula, represents the causal correction weight between the th driving variable and the th system variable within the time period; represents the total number of driving variables, ; represents the total number of all variables, ; represents the initial causal weight between and and within the time period; represents the natural constant.
[0054] As a further aspect of the present invention: The calculation formula of the channel weight is expressed as follows:
[0055] ;
[0056] In the formula, represents the initial weight of the channel in the causal channel attention mechanism; represents the normalization exponential function; represents the exponential function with the natural constant as the base.
[0057] As a further aspect of the present invention: The specific content of step S4 is as follows:
[0058] S41. Calculate the causal stability weights between each system variable in adjacent windows according to the system causal diagram;
[0059] S42. Based on the causal time attention mechanism, for the data of the channel in each window, apply a linear layer to generate the corresponding weight vector;
[0060] S43. Use the softmax function to normalize each weight vector respectively;
[0061] ;
[0062] In the formula, denote through softmax the normalized value processed by the function; denote the weight vector of;
[0063] S44. Embed the causal stability weights of each window into the causal temporal attention mechanism to obtain the temporal attention correction weights of each channel in each window ; denote the th window's causal stability weight.
[0064] As a further solution of the present invention: the calculation formula of the causal stability weight is expressed as follows:
[0065] ;
[0066] In the formula, denote the causal stability weight between each system variable in the window corresponding to the time period and the window adjacent to this window; denote the window corresponding to the time period ; denote the window corresponding to the time period ;
[0067] As a further solution of the present invention: the calculation formula of the weight vector is expressed as follows:
[0068] ;
[0069] In the formula, and both denote the learnable parameters corresponding to the initial attention weights .
[0070] As a further solution of the present invention: the diagnostic framework adopts a multi-layer temporal causal network, and its training process is as follows:
[0071] S41. Input the channel attention correction weight and the temporal attention correction weight into the multi-layer temporal causal network to obtain the corresponding channel causal feature and temporal causal feature;
[0072] S42. Use the channel causal feature and the temporal causal feature to train the multi-layer temporal causal network, and train to obtain a prediction model that meets the prediction accuracy requirements.
[0073] Compared with the prior art, the beneficial effects of the present invention are:
[0074] 1. The present invention systematically solves the problem of diagnostic deviation under complex working conditions by traversing data through a sliding window, constructing a double causal graph (a driving causal graph and a system causal graph), extracting double causal parameters (a correction weight and a stability weight), and embedding a dual-channel attention mechanism. Its advantages lie in decoupling the dynamic influence of working condition variables from the internal fluctuations of the system, combining the attention mechanism to correct the feature extraction deviation in real time, significantly improving the diagnostic accuracy and generalization ability, and providing interpretability for the fault propagation path.
[0075] 2. Construct a high-dimensional embedding vector through the delay embedding theory, and quantify the causal relationship by combining the KNN algorithm and the AUC index. Use the delay embedding of time series to capture the dynamic evolution, and quantify the strength of the causal relationship through nearest neighbor search and hypothesis testing ( model) to ensure the objectivity and verifiability of the causal relationship, providing a reliable data basis for subsequent graph construction.
[0076] 3. Based on the initial causal strength, construct a driving causal graph and a system causal graph, which respectively reflect the influence of working condition variables on system variables and the interaction between system variables. The driving causal graph focuses on the influence of working condition disturbances on diagnostic features, and the system causal graph captures the internal stability of the system, providing a structured knowledge representation for subsequent parameter extraction and effectively separating the contributions of different factors to the diagnostic results.
[0077] 4. Obtain the causal correction weight through inverse normalization and integrate it into the channel attention mechanism. Its advantage lies in the dynamic weight adjustment strategy: exponential decay normalization based on causal strength, suppressing the channels greatly affected by working conditions, highlighting stable features, solving the problem that traditional fixed weights cannot adapt to working condition changes, and enhancing the robustness of the model to interference.
[0078] 5. Perform exponential normalization based on the maximum causal strength, with a clear weight calculation method. The greater the maximum causal strength, the stronger the influence of the working condition on this channel. Reverse weighting is achieved through the exponent, meeting the diagnostic requirement of "suppressing strong interference channels" and ensuring the rationality and interpretability of the correction weight.
[0079] 6. Dynamically adjust the channel weights through learnable parameters, highlighting the features highly correlated with faults, avoiding the subjectivity of manual feature selection, and improving the feature utilization efficiency.
[0080] 7. Quantify the system fluctuations through the structural difference (SHD) of adjacent window causal graphs, combined with time weight adjustment, making the model pay more attention to the moment of sudden change of the system state and enhancing the ability to capture dynamic faults. SHD directly reflects the structural changes of the causal relationship and is normalized by dividing by the maximum possible number of edges to ensure the comparability and numerical stability of the stability weight.
[0081] 8. The multi - layer Temporal Causal Network (TCN) is adopted as the diagnosis framework, combined with channel - time series feature fusion. Its advantages lie in the co - modeling of spatio - temporal features: the dilated convolution of TCN captures long - distance dependencies, the residual connection supports the training of deep networks, and the dual - channel feature fusion integrates the channel information after condition correction and the time trend, enhancing the recognition ability of complex fault patterns and ensuring the efficiency and accuracy of the diagnosis model. BRIEF DESCRIPTION OF THE DRAWINGS
[0082] Figure 1 This is the diagnostic flowchart of the present invention.
[0083] Figure 2 This is the process of projecting in the manifold space in the present invention onto process diagram.
[0084] Figure 3 This is the process diagram for obtaining causal parameters in the present invention.
[0085] Figure 4 This is the dynamic causal knowledge graph in the present invention.
[0086] Figure 5 This is the comparison chart of the diagnostic accuracy rates of each diagnostic framework in the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0087] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0088] Please refer to Figures 1 - 5 , the diagnostic method of the present invention includes the following content.
[0089] I. Calculate the initial causal strength
[0090] Obtain the time - series data of the driving variable and the system variable. The data set of the time - series variable is defined as , and is composed of continuous time - series variables. Each variable is represented as a time - series with a time length of , where represents the value of the variable at the time step . The causal structure is represented by the graph , where includes contemporaneous lags (lag time is 0) and time - series lags (from lag time 1 to ) relationship
[0091] Taking the rolling bearing fault diagnosis system as an example, in the experiment process, multiple sensors of different types are used to collect data from the faulty bearing. The types of sensors include: three-axis vibration acceleration sensors (X-axis direction, Y-axis direction, Z-axis direction of the bearing), vibration velocity sensors, vibration displacement sensors, pressure sensors, temperature sensors, rotational speed sensors, torque sensors, etc. The time-series data, driving variables, and system variables in the rolling bearing fault diagnosis system are as follows:
[0092] Driving variables: In the rolling bearing fault diagnosis system, the driving variables refer to the variables that reflect the changes in the working conditions themselves, such as the collected rotational speed signal ( ) and torque signal ( ) and pressure signal ( ), etc. They can characterize the changes in the working conditions themselves and can also be presented by the sensors in the form of time-series data of voltage values.
[0093] System variables: In the rolling bearing fault diagnosis system, the system variables refer to the vibration signals of the sensors that can commonly reflect the fault response characteristics of different faulty bearings, including three-axis vibration acceleration time-series data ( ), as well as vibration velocity ( ) and vibration displacement ( ), etc. The time-series data of these system variables often have the ability to characterize different faults.
[0094] Time-series data: It includes the equal-length time-series data of voltage values obtained by different sensors at the same sampling frequency and the same time. They are respectively denoted as: (Vibration acceleration in the X-axis direction), (Vibration acceleration in the Y-axis direction), (Vibration acceleration in the Z-axis direction), (Vibration velocity), (Vibration displacement), (Pressure), (Temperature), (Rotational speed), (Torque), etc.
[0095] In view of the indivisible characteristics of the fault dynamic system, the present invention adopts the CMC algorithm to infer the causal relationship. The sliding window method is used to estimate the causal strength between different windows, and the maximum causal strength is determined by testing at different lag times. The window size is set as , and the sliding step size is . In the present invention, and are equal and slide in turn. The time period corresponding to each window can be expressed as , which can represent the start time of the current window. During the entire cycle is divided into H windows in total, that is, it contains H time periods in total .
[0096] According to the delay embedding theory, set the current lag time as , for the time series data , it can be constructed in the delay embedding space C as follows:
[0097] ;
[0098] In the delay embedding space, set the embedding dimension as , the time delay interval as , and construct the time series to represent the -dimensional embedding vector. Among them, represents the time sub-variation; represents the th variable in the time period within the -dimensional embedding vector; represents the time series data of the variable in the time period ; represents the time series data of the variable in the time period ; represents the time series data of the variable in the time period .
[0099] Using the constructed time series and , respectively form the corresponding manifold spaces and . For any point , its KNN nearest neighbors can be found in the delay embedding space through the algorithm, and the set composed of these nearest neighbors is defined as follows:
[0100] ;
[0101] Among them, represents the nearest neighbor set composed of nearest neighbors obtained through the algorithm in the time period KNN , and k is the number of nearest neighbors; express pass KNN The first one obtained by the algorithm dimensional embedding vector; express pass KNN The second one obtained by the algorithm dimensional embedding vector; express pass KNN The algorithm obtains the k indivual dimensional embedding vector. express Projection to back, pass KNN The first one obtained by the algorithm dimensional embedding vector; express Projection to back, pass KNN The second one obtained by the algorithm dimensional embedding vector; express Projection to back, pass KNN The algorithm obtains the k indivual dimensional embedding vector.
[0102] Projection to The process can be expressed as:
[0103] ;
[0104] According to the dynamic causal framework, arrive The causal strength of Model and The distance between model indices is defined using the area under the curve ( ) to evaluate the model performance, and its causal model is described as follows:
[0105] Based on the current lag time Variables during the down-projection process Does the change of the variable cause Changes, build Model and Model; Model assumptions variables Changes in the variable changes, i.e. variables and variables There is no causal relationship between them; Model hypothesis variable The change of will cause the change of variable and variable That is, there is a causal relationship between variable
[0106] Combined with the area under the curve , define The calculation result of the model is , define The calculation result of the model is , define the causal strength from variable to variable as ; where represents KNN The radius value of the algorithm.
[0107] Variable at different lag times for The maximum causal strength of is expressed as:
[0108] ;
[0109] In the formula, represents the maximum causal strength from variable to variable ; represents the operation of taking the maximum value; represents at the lag time when, from variable to variable The causal strength of represents at the lag time is the maximum lag time when, from variable to variable The causal strength of
[0110] Calculate the maximum causal strength between each driving variable and each system variable, and the maximum causal strength between each system variable in each time period according to the above content, and use the maximum causal strength as the initial causal strength between each variable.
[0111] After obtaining the initial causal strength, a knowledge graph can be further constructed. The present invention constructs multiple knowledge graphs based on different fault types, uses the sensor category as the node and the causal relationship as the edge, and each fault type is represented by a unique graph pattern. By quantifying the influence of operating condition variables (such as speed, torque, and load) on different sensor signals, the fault characteristics of different fault types under different operating conditions can be deeply understood.
[0112] II. Constructing a Knowledge Graph
[0113] To further study the interaction between variables in the dynamic causal knowledge graph, the present invention divides variables into two groups: and , where contains driving variables, contains system variables. Based on these two types of variables, the causal knowledge graph is divided into two types: the dominant causal graph (i.e., the driving causal graph) and the system causal graph . contains and , and captures the dynamic influence of driving variables on system variables through continuous dynamic causal modeling; while only contains , and models the dynamic causal relationship between system variables to capture the overall fluctuations of the causal system. Finally, by constructing a causally complete knowledge graph, causal interpretability can be provided for the model through the dynamic causal state changes between variables.
[0114] III. Obtaining Causal Parameters
[0115] In diagnostic scenarios with complex operating condition changes, the model performance is usually significantly limited. Further analysis of the dynamic causal knowledge graph reveals two key causal parameters: the dominant causal strength and the system causal mutation index . These two parameters help quantify the impact of fault states and operating condition changes on the fault dynamic system. By incorporating these dynamic influences into the model, causal correction can be performed, thereby reducing the diagnostic bias caused by operating condition changes. The process of obtaining these two causal parameters is as Figure 3 shown.
[0116] As Figure 3 shown, there are three consecutive fixed-length time slices in the dynamic causal knowledge graph. The blue causal edges and the variables they connect form , and the green causal edges and the variables they connect form . Calculate the causal strength between and within the time window, and take the maximum causal strength as .
[0117] The process of obtaining the causal parameter is as follows: Figure 3 in consists of two driving variables and three system variables. In the window corresponding to the time period , the driving variable The impacts on each system variable are respectively , and 0. Therefore, within this window, the impacts on these system variables are different. When using operating condition variables (such as speed, torque, load, etc.) as driving variables, larger weights should be assigned to the system variables that are less affected by them in order to correct the impacts of the driving variables. Therefore, for the driving variable , on the system variable , the causal correction weight in the current window is defined as:
[0118] ;
[0119] In the formula, represents the causal correction weight between the -th driving variable and the -th system variable within the time period ; represents the causal correction weight between the driving variable and the system variable in the -th window. represents the total number of driving variables, ; represents the total number of all variables, ; represents the initial causal weight between and within the time period ; represents the natural constant.
[0120] Use the value of the current system variable at the starting moment in each time period to replace all the values of this variable within this time period, that is, the same causal correction weight is assigned to all time points within the same window. The final causal parameter within the entire cycle is expressed as:
[0121] ;
[0122] where the index set is defined as:
[0123] ;
[0124] where, represents the causal correction weight between the driving variable and the system variable in the first window. Indicates the causal correction weight between the driving variable and the system variable in the second window. Indicates the th window, the causal correction weight between the driving variable and the system variable in it. Indicates the causal correction weight between the driving variable and the system variable in the first window. Indicates the causal correction weight between the driving variable and the system variable in the second window. Indicates the th window, the causal correction weight between the driving variable and the system variable in it. Indicates the causal correction weight between the driving variable and the system variable in the first window. Indicates the causal correction weight between the driving variable and the system variable in the second window. Indicates the th window, the causal correction weight between the driving variable and the system variable in it.
[0125] The acquisition process of another causal parameter is as follows. Figure 3 in contains three system variables . Among them, is obtained by calculating the structural Hamming distance (SHD) between the current window and the previous or next window. In this embodiment, the calculation is performed with the next window. This distance measures the causal state transition within each window and quantifies the causal stability weight between consecutive time windows:
[0126] ;
[0127] where represents the maximum possible change in the edges in the system causal graph and is used to normalize the SHD. This normalization ensures a stable range for the variation index and enhances the stability of subsequent calculations. All time points within the same window share the same variation index.
[0128] The dynamic causal knowledge graph constructed by merging the dominant causal graph and the system causal graph is as Figure 4 shown. The dynamically changing system causal graph outputs causal parameters . In the dominant causal graph, the same windows are aggregated. The same dominant causal graph windows are aggregated to simplify the calculation. Finally, causal parameters are obtained according to the dynamically changing dominant causal graph.
[0129] IV. Dual Causal Attention Correction Module
[0130] To address the impact of fault mechanisms and changes in operating conditions on the diagnosis process, the present invention adopts a parallel method to embed and into the causal channel attention mechanism and the causal time attention mechanism respectively. The attention weights are adjusted to consider the influence of multi-source data and the deviation of fault feature extraction caused by changes in operating conditions, so as to obtain the ability to extract stable spatio-temporal causal features and improve the interpretability of the causal correction model.
[0131] The causal channel attention mechanism mainly focuses on the time series fault data from different channels, extracts a set of system variables , and then inputs them into the diagnosis model. To capture the representative features of each channel, global average pooling is applied along the time dimension to obtain:
[0132] ;
[0133] wherein, represents the value of the system variable at the starting moment in the th time period , that is, in the th window; represents the number of time periods in the full cycle , that is, the number of windows; represents the average pooling value of the system variable .
[0134] Next, the scoring function is calculated:
[0135] ;
[0136] wherein, represents the th channel in the causal channel attention mechanism; represents the th element of the query vector ; represents the score of the channel in the causal channel attention mechanism. As a scaling factor for numerical stability. To model the relative importance of each channel, an attention mechanism is applied. Each channel The initial weight of is calculated by the following formula:
[0137] ;
[0138] In the formula, represents the channel in the causal channel attention mechanism. The initial weight of represents the normalized exponential function; represents the exponential function with the natural constant as the base.
[0139] Furthermore, the initial attention weight of each channel can be expressed as:
[0140] ;
[0141] Finally, the causal parameter is embedded into the corresponding channel and aligned with the time position. The weight parameter of the driving variable is defined as , and the channel attention of the channel affected by can be expressed as:
[0142] ;
[0143] In the formula, represents the causal correction weight matrix composed of the causal correction weights arranged in sequence between all time periods i.e., between the th driving variable and the th system variable in all windows; represents the Hadamard product; represents the causal correction weight between the driving variable and the system variable in the first window; represents the channel attention correction weight of the channel affected by in the first window; represents the th window; represents the causal correction weight between the driving variable and the system variable represents the th window; affected by Channel attention correction weight; Denote the th window, the causal correction weight between the driving variable and the system variable ; Denote at the th window, the channel affected by Channel attention correction weight.
[0144] The core of the causal temporal attention mechanism is to evaluate the importance of each time point within each channel. For the temporal data of channel , apply a simple linear layer to generate a weight vector to reflect the importance of each time point.
[0145] ;
[0146] In the formula, and both represent the learnable parameters corresponding to the initial attention weights .
[0147] Then, use the softmax function to normalize the weight vector to obtain the vector :
[0148] ;
[0149] In the formula, represents the normalized value processed by the function through softmax ; represents the weight vector of .
[0150] Similarly, is embedded into the temporal attention mechanism to adjust the weight bias. It should be noted that different time series channels share the same causal parameter . The correction result of the causal temporal attention mechanism for the system variable can be expressed as .
[0151] V. Network Architecture
[0152] In the dual-path structure, the channel attention correction weight and the temporal attention correction weight are first input into the multi-layer temporal causal network to extract the temporal causal features and the channel causal features. Then, the features of the two paths are fused to obtain richer spatio-temporal causal features, and finally, they are input into the fully connected layer for fault classification. The multi-layer temporal causal network is used as the backbone network to learn and fuse local fault features, so as to construct global features reflecting the process state. After being processed by the multi-layer temporal causal network, the features from the two paths are respectively represented as the channel causal feature and the temporal causal feature . Next, the output features of different paths are concatenated to form new spatio-temporal causal features. The concatenation is defined as follows:
[0153] ;
[0154] where, represents the i th input feature vector, represents the element of the first concatenated vector; represents the element of the second concatenated vector; represents the th element of the concatenated vector. represents the spatio-temporal causal feature formed after concatenation. Here, represents the number of concatenated vectors, is the concatenation function, which is used to concatenate vectors along the defined dimension. When there are only and input features, can be expressed as .
[0155] The training loss function of the diagnostic framework consists of the cross-entropy loss and the non-stationary data reconstruction loss. The final loss function is defined as follows:
[0156] ;
[0157] where, N is the total number of samples, M is the number of categories. and respectively represent the true probability and the predicted probability that the sample i belongs to the category j .
[0158] VI. Test Data
[0159] To validate the diagnostic performance of the proposed framework in a rolling bearing fault diagnosis system, it was compared with five other frameworks: a multi-convolutional neural network-long short-term memory network (MCNN-LSTM), an adaptive multi-attention one-dimensional convolutional neural network (MA1DCNN), a multi-domain pattern synthesis (MDPS), a quantum-inspired convolutional neural network (QCNN), and a wide-deep convolutional neural network (WDCNN). MA1DCNN, MDPS, QCNN, and WDCNN are single-signal fault diagnosis architectures, while MCNN-LSTM uses multiple signal inputs. To ensure fairness, a single-channel input is generated by uniformly sampling and fusing multiple sensor data. All frameworks were tested on the C1, C2, C3, C4, and C5 rolling bearing fault diagnosis datasets. The experiments were repeated 10 times under the same conditions and the results were averaged. Training was performed with an initial learning rate of 0.006, a batch size of 64, and 100 epochs. The same data preprocessing methods were used for all models.
[0160] The proposed method achieved 100% accuracy on the C1 dataset and performed well on C2 (99.33%) and C5 (96.64%), demonstrating excellent diagnostic capabilities. In contrast, the accuracy of MCNN-LSTM and MDPS on the C5 dataset dropped significantly, while the proposed method outperformed all other methods by 23.11%.
[0161] The present invention improves the interpretability of the model by performing dynamic causal modeling on multi-source time series data and constructing a dynamic causal knowledge graph. Two causal parameters are extracted from the graph. and , and embedding it into a diagnostic framework to correct diagnostic biases caused by varying operating conditions while capturing spatiotemporal causal features, thereby improving diagnostic accuracy and generalization. Experimental results demonstrate that this diagnostic framework outperforms existing methods in terms of diagnostic accuracy and generalization, providing an important reference for optimizing diagnosis under complex real-world operating conditions.
[0162] The above description is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can make equivalent replacements or changes according to the technical scheme and inventive concept of the present invention within the technical scope disclosed by the present invention, which should be covered by the protection scope of the present invention.
Claims
1. An intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph, characterized in that, It includes the following diagnostic steps: S1. Obtain the time-series data of the driving variables and system variables, traverse all the time-series data in the way of a sliding window, and obtain the initial causal strength of the time-series data within each window; In a rolling bearing fault diagnosis system, the driving variables refer to the variables reflecting the changes of the working conditions itself, including rotational speed signals, torque signals and pressure signals; the system variables refer to the sensor vibration signals that can commonly reflect the fault response characteristics of different faulty bearings, including three-axis vibration acceleration time-series data, vibration velocity and vibration displacement; S2. Use the initial causal strength to construct a driving causal graph between the driving variables and system variables within each window, and a system causal graph between the system variables and system variables; S3. Extract the causal strength of different driving variables on each system variable from the driving causal graph, and obtain the causal correction weights of different degrees of the driving variables on different system variables under this causal strength through reverse normalization, and then input the causal correction weights into the causal channel attention mechanism to obtain the corresponding channel attention correction weights; S4. Extract the causal stability weights between the system variables from the system causal graph, and then input the causal stability weights into the causal time attention mechanism to obtain the corresponding time attention correction weights; S5. Input the channel attention correction weights and time attention correction weights into the diagnostic framework for training to obtain a prediction model; S6. Obtain the real-time time-series data, and input the real-time time-series data into the prediction model to predict the corresponding system state.
2. The intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph according to claim 1, wherein The specific content of step S2 is as follows: S21. Construct a driving causal graph between each driving variable and each system variable within each time period, with the initial causal strength between the driving variable and the system variable as the edge weight. within each driving variable and each system variable; S22. Construct a system causal graph among system variables in each time period, with the initial causal strength between system variables as the edge weight. among the system variables within each time period.
3. The intelligent diagnosis method for complex working conditions based on a dynamic causal knowledge graph according to claim 2, wherein, The diagnostic framework adopts a multi-layer time-series causal network, and its training process is as follows: S41. Input the channel attention correction weights and time attention correction weights into the multi-layer time-series causal network to obtain the corresponding channel causal features and time-series causal features; S42. Use the channel causal features and time-series causal features to train the multi-layer time-series causal network, and train to obtain a prediction model that meets the prediction accuracy requirements.
Citation Information
Patent Citations
Trigger point detection for online root cause analysis and system fault diagnosis
US20240054043A1
Deep Learning Method Integrating Prior Knowledge for Fault Diagnosis
US20240184678A1