Air compressor fault diagnosis method and system and electronic equipment

By using the Transformer model and multi-head attention module to analyze and feature extraction of multimodal timing data of air compressors, the problem of insufficient accuracy and real-time fault diagnosis in the prior art is solved, and more efficient and reliable faults are achieved diagnosis.

CN119467390APending Publication Date: 2025-02-18HUADIAN TIBET ENERGY CO LTD +1
View PDF 0 Cites 4 Cited by

Patent Information

Application Number
CN202411614826.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-13
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

Existing industrial equipment fault diagnosis methods have improved in terms of accuracy and real-time performance, especially the experience-based diagnosis has false positives or missed reports. The signal processing method is sensitive to noise, and machine learning-based methods require a large amount of labeled data and high Calculate the cost.

Method used

The Transformer model is used to combine the multi-head attention module to preprocess and feature extraction of the multi-modal timing data of the air compressor, train the fault diagnosis model for diagnosis, and provide an explanation of the diagnostic results through attention scores.

Benefits of technology

It improves the accuracy and reliability of fault diagnosis, can better handle fault data of complex space-time dependencies, provide more comprehensive and transparent diagnostic results, and reduces downtime and production losses caused by equipment failures.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119467390A_ABST
    Figure CN119467390A_ABST
Patent Text Reader

Abstract

The invention relates to an air compressor fault diagnosis method and system and electronic device.The air compressor fault diagnosis method comprises the steps that current operation parameters of an air compressor are obtained, the current operation parameters are preprocessed, and input data are obtained, the operation parameters comprise a vibration parameter, a temperature parameter, an input pressure, an output pressure and a working current of the motor; according to the historical operation parameters and historical fault type data of the air compressor, a Transform model is trained to obtain a fault diagnosis model, the fault diagnosis model comprises multiple attention modules, and the multiple attention modules are used for calculating attention scores; and the state of the air compressor is diagnosed according to the input data and the fault diagnosis model, a diagnosis result is obtained, target data concerned during diagnosis is obtained according to the attention score, and supplementary interpretation is conducted on the diagnosis result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of industrial equipment fault diagnosis, and in particular to an air compressor fault diagnosis method, system and electronic equipment. Background Art

[0002] Fault diagnosis of air compressors in hydropower stations is conducive to timely discovery and resolution of related problems, thereby ensuring the safety of the hydropower station.

[0003] Existing industrial equipment fault diagnosis methods mainly include diagnosis based on experience and rules, signal processing technology, and diagnosis based on machine learning and neural networks. However, diagnosis based on experience relies on the subjective judgment of operators, which is prone to false positives or false negatives; signal processing methods are difficult to effectively extract global features when facing complex working conditions, and are sensitive to noise and easily disturbed by the environment, resulting in a decrease in the accuracy of fault diagnosis; diagnosis methods based on machine learning and neural networks require a large amount of labeled data, and the model results lack interpretability, and the training and computing costs are high, making it difficult to meet the needs of real-time diagnosis.

[0004] The accuracy and real-time performance of existing fault diagnosis methods still need to be improved. Summary of the invention

[0005] The embodiments of the present application provide an air compressor fault diagnosis method, system and electronic device to at least solve the problem that the accuracy and real-time performance of the existing fault diagnosis methods in the related art need to be improved.

[0006] In a first aspect, an embodiment of the present application provides an air compressor fault diagnosis method, comprising:

[0007] Acquire current operating parameters of the air compressor, and pre-process the current operating parameters to obtain input data, wherein the operating parameters include vibration parameters, temperature parameters, input pressure and output pressure, and working current of the motor;

[0008] According to the historical operating parameters and historical fault type data of the air compressor, a Transformer model is trained to obtain a fault diagnosis model, wherein the fault diagnosis model includes a multi-head attention module, and the multi-head attention module is used to calculate an attention score;

[0009] The state of the air compressor is diagnosed according to the input data and the fault diagnosis model to obtain a diagnosis result, and the target data concerned during diagnosis is obtained according to the attention score to provide a supplementary explanation for the diagnosis result.

[0010] In one embodiment, the training of the Transformer model to obtain the fault diagnosis model based on the historical operating parameters and historical fault type data of the air compressor includes:

[0011] Acquire historical operating parameters and historical fault type data of the air compressor, and pre-process the historical operating parameters to obtain training data;

[0012] A Transformer model is obtained, and based on the training data and historical fault type data, the Transformer model is iteratively trained through a cross entropy loss function or a mean square error loss function in combination with an Adam optimizer to obtain the fault diagnosis model.

[0013] In one embodiment, preprocessing the operating parameters includes:

[0014] Normalizing the operating parameters to reduce the impact between different dimensions;

[0015] Perform data alignment on the normalized operating parameters to ensure the consistency of the time series;

[0016] The operating parameters after data alignment are filtered to remove high-frequency noise in the operating parameters.

[0017] In one embodiment, the fault diagnosis model includes an encoder layer, a linear layer and an output module,

[0018] The encoder layer is used to obtain the spatiotemporal dependency of the input data, perform feature extraction on the input data, and obtain high-dimensional features based on the extracted features;

[0019] The linear layer is used to convert the high-dimensional features output by the encoder layer to the target dimension;

[0020] The output module is used to perform fault diagnosis according to the characteristics of the target dimension output by the linear layer and output the diagnosis result.

[0021] In one embodiment, the encoder layer includes a multi-head attention module and a feed-forward neural network module,

[0022] The multi-head attention module is used to obtain the spatiotemporal dependency of the input data, perform feature extraction on the input data, and calculate the attention score;

[0023] The feedforward neural network module is used to process the feature vector output by the multi-head attention module to obtain high-dimensional features.

[0024] In one embodiment, the fault diagnosis model further includes a vector layer and a position encoding layer.

[0025] The vector layer is used to convert the input data into a digital vector, and the position encoding layer is used to add position information to the digital vector.

[0026] In one embodiment, the method further includes: sending the diagnosis result to a user terminal, so that the user can make a maintenance decision based on the diagnosis result.

[0027] In a second aspect, an embodiment of the present application provides an air compressor fault diagnosis system, the system being deployed on an edge computing device, the system comprising:

[0028] Data module: used to obtain the current operating parameters of the air compressor, and pre-process the current operating parameters to obtain input data, wherein the operating parameters include vibration parameters, temperature parameters, input pressure and output pressure, and the working current of the motor;

[0029] Training module: used to train the Transformer model to obtain a fault diagnosis model based on the historical operating parameters and historical fault type data of the air compressor, wherein the fault diagnosis model includes a multi-head attention module, and the multi-head attention module is used to calculate the attention score;

[0030] Diagnostic module: used to diagnose the state of the air compressor according to the input data and the fault diagnosis model to obtain a diagnosis result, and to obtain the target data concerned during diagnosis according to the attention score to provide a supplementary explanation for the diagnosis result.

[0031] In a third aspect, an embodiment of the present application provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the air compressor fault diagnosis method as described in the first aspect above is implemented.

[0032] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the air compressor fault diagnosis method as described in the first aspect above.

[0033] An air compressor fault diagnosis method, system and electronic device provided in the embodiments of the present application have at least the following technical effects.

[0034] This application provides a more comprehensive and accurate fault diagnosis by fusing and analyzing multimodal data and comprehensively analyzing multi-source information. The multi-head attention module captures the long-range dependencies between data globally and automatically discovers potential key features. This enables the fault diagnosis model to better handle fault data with complex spatiotemporal dependencies, improve the accuracy and reliability of fault diagnosis, and thus detect and warn of potential faults in a timely manner, avoiding downtime and production losses caused by equipment failures. At the same time, the attention score is used to supplement the explanation of the diagnostic results to improve the transparency and interpretability of the diagnostic results, thereby enhancing the credibility and practicality of the fault diagnosis model.

[0035] Details of one or more embodiments of the present application are set forth in the following drawings and description to make other features, objects, and advantages of the present application more readily apparent. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0037] Figure 1 is a flow chart of an air compressor fault diagnosis method shown in an embodiment of the present application;

[0038] Figure 2 is a structural schematic diagram of a fault diagnosis model according to an exemplary embodiment;

[0039] Figure 3 is a schematic diagram of a process of a multi-head attention module according to an exemplary embodiment;

[0040] Figure 4 is a structural block diagram of an air compressor fault diagnosis system according to an embodiment of the present application;

[0041] Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0042] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application is described and illustrated below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application. Based on the embodiments provided in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application.

[0043] Obviously, the drawings described below are only some examples or embodiments of the present application. For ordinary technicians in this field, the present application can also be applied to other similar scenarios based on these drawings without creative work. In addition, it can also be understood that although the efforts made in this development process may be complicated and lengthy, for ordinary technicians in this field related to the content disclosed in this application, some changes in design, manufacturing or production based on the technical content disclosed in this application are just conventional technical means, and should not be understood as insufficient content disclosed in this application.

[0044] Reference to "embodiments" in this application means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those of ordinary skill in the art that the embodiments described in this application may be combined with other embodiments without conflict.

[0045] Unless otherwise defined, the technical terms or scientific terms involved in this application should be understood by people with ordinary skills in the technical field to which this application belongs. The words "one", "a", "a", "the" and the like involved in this application do not indicate a quantitative limitation, and may represent the singular or plural. The terms "include", "comprise", "have" and any of their variations involved in this application are intended to cover non-exclusive inclusions; for example, a process, method, system, product or device that includes a series of steps or modules (units) is not limited to the listed steps or units, but may also include steps or units that are not listed, or may also include other steps or units inherent to these processes, methods, products or devices. The words "connect", "connected", "coupled" and the like involved in this application are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The "multiple" involved in this application refers to two or more. "And / or" describes the association relationship of associated objects, indicating that there may be three relationships, for example, "A and / or B" can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the objects before and after are in an "or" relationship. The terms "first", "second", "third", etc. involved in this application are only used to distinguish similar objects and do not represent a specific ordering of the objects.

[0046] Traditional fault diagnosis methods mainly include diagnosis based on experience and rules, diagnosis based on thresholds, signal processing technology, and diagnosis based on machine learning and neural networks. These methods can solve the fault diagnosis problem to a certain extent, but they still have major defects:

[0047] (1) Diagnostic methods based on experience and rules

[0048] The diagnostic method based on experience and rules relies on the experience and intuition of the operator. In complex or changing environments, the diagnostic results obtained by this method are highly subjective and cannot guarantee the consistency and accuracy of the diagnostic results. Moreover, the experience of the diagnostician will directly affect the quality of the diagnostic results.

[0049] (2) Threshold-based diagnostic method

[0050] The threshold-based diagnostic method can only detect known, simple fault types. When a new type of fault or a complex fault occurs in the system, the accuracy of the threshold diagnostic method is low. It is also difficult to set an accurate threshold. If the threshold is set too high, the fault may not be discovered in time; if the threshold is set too low, a large number of false alarms will be generated, increasing maintenance costs and workload.

[0051] (3) Signal processing technology

[0052] Signal processing-based techniques, such as Fourier transform or wavelet transform, focus on feature extraction in the frequency domain or time domain, but these techniques usually rely on clear feature patterns and have limited effects on complex and variable fault types. In addition, signal processing techniques are sensitive to noise and are easily affected by environmental interference, resulting in reduced diagnostic accuracy.

[0053] (4) Diagnostic methods based on neural networks and machine learning

[0054] Neural network and machine learning techniques have made significant progress in fault diagnosis, but they still have the following defects:

[0055] ① A large amount of labeled data is required. The training of neural networks and machine learning models usually relies on a large amount of labeled data. The cost of data collection and labeling is high, and there is less sample data for rare faults. There is also a problem of data imbalance. The amount of fault data is relatively small compared to the amount of normal data, which may cause the model to tend to normal data during training, thereby reducing the ability to identify faults.

[0056] ② The complexity of feature engineering is high. Traditional machine learning methods, such as support vector machines and random forests, usually require manual design of features, and feature design requires professionals to have rich domain knowledge and experience, and the designed features are not necessarily optimal and may miss key information. In addition, the feature selection process is complex and time-consuming.

[0057] ③ The model has poor interpretability. Although deep neural networks have powerful learning capabilities, their "black box" nature makes their decision-making process opaque and lacks a clear explanation of the model's output results, which reduces users' trust in the model. Once an incorrect diagnosis occurs in industrial applications, it is difficult to trace and correct.

[0058] ④ High computing cost. Complex neural network models require a lot of computing resources and time, and have high hardware requirements, especially reliance on high-performance computing devices, which increases deployment costs. And in real-time diagnostic applications, it is difficult to meet the requirements of efficient processing.

[0059] Based on the above situation, the embodiments of the present application provide an air compressor fault diagnosis method, system and electronic device.

[0060] In a first aspect, an embodiment of the present application provides an air compressor fault diagnosis method. Figure 1 is a flow chart of an air compressor fault diagnosis method shown in an embodiment of the present application, such as Figure 1 As shown, including:

[0061] Step S101, obtaining current operating parameters of the air compressor, preprocessing the current operating parameters to obtain input data, the operating parameters include vibration parameters, temperature parameters, input pressure and output pressure, and the working current of the motor.

[0062] Optionally, the vibration parameter is a vibration parameter of the air compressor during operation, and the vibration parameter is obtained by an acceleration sensor. The temperature parameter is a temperature parameter of key components, such as bearings, motors, cylinders and other components. The input pressure and output pressure of the air compressor are used to determine whether there is leakage or blockage. The working current of the motor is used to determine whether the motor is overloaded or has an electrical fault. The current operating parameters are usually preprocessed by normalization and filtering.

[0063] In one example, the preprocessing of the operating parameters in step S101 includes:

[0064] Step S1011, normalizing the operating parameters to reduce the impact between different dimensions.

[0065] Optionally, normalizing the operating parameters can be expressed as:

[0066]

[0067] Among them, x i is the data vector of operating parameters, μ represents the mean, and σ represents the standard deviation.

[0068] Step S1012, aligning the normalized operating parameters to ensure the consistency of the time series. Optionally, interpolation or resampling is performed on data with different sampling rates to ensure the consistency of the time series.

[0069] Step S1013, filtering the data aligned operating parameters to remove high frequency noise in the operating parameters. Optionally, high frequency noise in the operating parameters is removed by a filter (such as a low pass filter) to retain valid fault information.

[0070] In this way, the multi-modal time series data of the air compressor is obtained, and the data is pre-processed to filter out interference data and improve data quality, which is conducive to the accurate diagnosis of the subsequent fault diagnosis model. It is more convenient for the subsequent fusion analysis of multi-modal data (such as vibration, temperature, pressure, etc.), and comprehensive analysis of multi-source information, so as to provide more comprehensive and accurate fault diagnosis.

[0071] Step S102, based on the historical operating parameters and historical fault type data of the air compressor, train the Transformer model to obtain a fault diagnosis model, the fault diagnosis model includes a multi-head attention module, and the multi-head attention module is used to calculate the attention score.

[0072] Optionally, the historical operating parameters of the air compressor include: vibration parameters, temperature parameters, input pressure and output pressure, and the working current of the motor. The historical fault type data is the fault type corresponding to the historical operating parameters. By setting a reasonable loss function and number of iterations, an optimizer is used to iteratively train the Transformer model with the goal of minimizing the loss to obtain a fault diagnosis model. Figure 2 is a schematic diagram of the structure of a fault diagnosis model according to an exemplary embodiment. Figure 2 As shown in the figure, the fault diagnosis model includes: input layer, vector layer, position encoding layer, multi-head attention module, feedforward neural network, linear layer, softmax layer and output layer.

[0073] In one example, the fault diagnosis model includes a vector layer and a position encoding layer, the vector layer is used to convert input data into a digital vector, and the position encoding layer is used to add position information to the digital vector.

[0074] Optionally, since the Transformer model has no built-in timing information, the temporal position of each input vector is injected through a position encoding layer, as follows:

[0075]

[0076] Among them, PE represents the position encoding, pos represents the position of the current character in the input data, i is equal to the dimension subscript of the character modulo 2, and d represents the dimension of the character.

[0077] Convert multi-dimensional time series data input into a high-dimensional vector. Specifically, it can be expressed as:

[0078] X∈RT×d

[0079] X represents a high-dimensional vector, where T is the number of time steps and the input data dimension of each time step is d. The data is input embedded, which can be specifically expressed as:

[0080] Z=XWE+P

[0081] Among them, Z represents the input embedded vector, X represents the high-dimensional vector, and W E represents the embedding matrix, and P represents the positional encoding, which is used to inject timing information.

[0082] In one example, the fault diagnosis model includes an encoder layer, a linear layer, and an output module.

[0083] The encoder layer is used to obtain the spatiotemporal dependencies of the input data, extract features from the input data, and obtain high-dimensional features based on the extracted features.

[0084] Optionally, the encoder layer contains multiple encoders stacked in series, and residual connections and normalization are performed during the encoding process. Residual connections are used to enhance the gradient propagation and information transfer of the model, alleviate gradient vanishing, and improve the training speed and accuracy of deep networks. Normalization is used to stabilize the model training process, reduce internal covariate shifts, speed up convergence, and enhance the model's ability to capture fault features by standardizing the input of each layer.

[0085] The linear layer is used to transform the high-dimensional features output by the encoder layer to the target dimension.

[0086] The output module is used to perform fault diagnosis based on the characteristics of the target dimension output by the linear layer and output the diagnosis results.

[0087] Optionally, the output module includes a Softmax layer and an output layer. The Softmax layer is used to convert the output of the linear layer into a probability distribution, so as to perform classification or generation tasks. After being processed by the encoder, the output is the extracted feature vector, which contains the state information of the air compressor at each time step. The Softmax layer makes fault judgments based on these features. The output layer is used to output the results of fault diagnosis.

[0088] In one example, the encoder layer includes a multi-head attention module and a feed-forward neural network module.

[0089] The multi-head attention module is used to obtain the spatiotemporal dependencies of the input data and perform feature extraction on the input data. The multi-head attention module is also used to calculate the attention score.

[0090] Optionally, the multi-head self-attention module is used to extract global and local features of multimodal time series data (such as vibration, temperature, pressure, current, etc.) of the air compressor of the hydropower station, thereby enhancing the modeling ability of complex data. Figure 3 is a schematic diagram of a multi-head attention module according to an exemplary embodiment. Figure 3 As shown in the figure, the calculation of the multi-head self-attention module is to transform the features of the input data through three linear layers Q, K, and V. Specifically, the feature-transformed Q, K, and V are combined through the scaled dot product attention calculation method, and then the results are combined and output through a linear layer. Figure 3 It is the process of extracting features through N self-attention heads at the same time. The data dimension will not change during the feature extraction process. After the calculation of the self-attention layer, global information will be added to the data.

[0091] The multi-head self-attention module is also used to calculate Query, Key, and Value, and calculate the attention score of each attention head based on the values ​​of Query, Key, and Value. The specific calculation formula is as follows:

[0092]

[0093] Where Q = ZW Q Represents the query vector Query, K = ZW K Represents the key vector Key, V = ZW V represents the value vector Value, Z represents the input embedded vector, W Q ,W K ,W V is a trainable weight matrix, and dk represents the dimension of the Key vector.

[0094] The feedforward neural network module is used to process the feature vector output by the multi-head attention module to obtain high-dimensional features.

[0095] Optionally, a feed-forward neural network is applied to the output at each time step, specifically expressed as:

[0096] FFN(x)=max(0,xW+b1)W2+b2

[0097] Among them, FFN(x) represents the output of the time step, x represents the input data, b1 and b2 represent bias parameters, and W1 and W2 represent weight parameters.

[0098] In this way, through the attention mechanism, the fault diagnosis model can adaptively extract key features from the data, thereby improving the accuracy and robustness of fault detection. Moreover, the attention mechanism captures the long-range dependencies between data globally and automatically discovers potential key features. This enables the fault diagnosis model to better handle fault data with complex spatiotemporal dependencies, and enables the model to perform well when processing complex long-time series data, especially on equipment such as hydropower station air compressors that require long-term monitoring. Compared with traditional signal processing methods, the Transformer model can better handle the complex relationships between multimodal data, adapt to changing working conditions, and significantly improve the accuracy and reliability of fault diagnosis. This allows for timely detection and early warning of potential faults, avoiding downtime and production losses caused by equipment failures.

[0099] In one example, step S102 includes:

[0100] Step S1021, obtaining historical operating parameters and historical fault type data of the air compressor, and preprocessing the historical operating parameters to obtain training data.

[0101] Optionally, preprocessing the historical operating parameters includes: normalizing the operating parameters to reduce the impact between different dimensions. Performing data alignment on the normalized operating parameters to ensure the consistency of the time series. Filtering the aligned operating parameters to remove high-frequency noise in the operating parameters. In this way, the multimodal time series data of the air compressor is obtained, and the data is preprocessed to filter the interference data, improve the data quality of the training data, and help improve the diagnostic accuracy of the fault diagnosis model.

[0102] Step S1022, obtaining a Transformer model, and based on the training data and historical fault type data, iteratively training the Transformer model through a cross entropy loss function or a mean square error loss function in combination with an Adam optimizer to obtain a fault diagnosis model.

[0103] Optionally, for classification tasks, the Transformer model is trained using a cross entropy loss function so that the model output is close to the actual fault category label. The cross entropy loss is expressed as:

[0104]

[0105] Among them, y is the true label, i represents the i-th data, and N represents the total amount of data. Represents the output probability distribution of the model.

[0106] For the fault prediction task, the mean square error loss function is used, which is specifically expressed as:

[0107]

[0108] Among them, y is the true label, i represents the i-th data, and N represents the total amount of data. Represents the output probability distribution of the model.

[0109] Use the Adam optimizer to perform gradient descent and update the parameters of the fault diagnosis model:

[0110]

[0111] Among them, θ is the parameter of the fault diagnosis model, η is the learning rate, represents the loss during training.

[0112] Continue to refer to Figure 1 , after step S102, step S103 is performed, as follows.

[0113] Step S103, diagnose the state of the air compressor according to the input data and the fault diagnosis model to obtain a diagnosis result, and obtain the target data concerned during diagnosis according to the attention score to provide a supplementary explanation for the diagnosis result.

[0114] Optionally, the abnormal data is identified according to the fault diagnosis model, and the fault type corresponding to the abnormal data is determined. Through the attention score matrix, the time steps and features that the model focuses on when making a diagnosis can be analyzed. The attention score can be expressed as:

[0115]

[0116] Among them, α ij represents the attention score, that is, the influence of the input data at time step i on time step j, Q = ZW Q Represents the query vector Query, K = ZW K represents the key vector Key, Z represents the input embedded vector, W Q ,W K is the trainable weight matrix, d k Indicates the dimension of the Key vector.

[0117] In this way, the fault diagnosis model uses attention scores to show the part of the input data that the model focuses on when performing fault diagnosis. This visual attention mechanism helps users understand the decision-making basis of the model, improves the transparency and explainability of the diagnosis process, and thus enhances the credibility and practicality of the fault diagnosis model. In actual fault diagnosis scenarios, it helps maintenance personnel quickly locate the source of the problem and take appropriate repair measures to ensure the normal operation of the air compressor.

[0118] In one example, the method further includes: sending the diagnosis result to a user terminal so that the user can make a maintenance decision based on the diagnosis result. Optionally, by feeding back the diagnosis result to the user, the user can monitor the equipment operation status and fault diagnosis result through the user interface and make a maintenance decision based on the diagnosis result, thereby ensuring the safety and stability of the air compressor operation.

[0119] In addition, the fault diagnosis model after training is deployed on the edge computing device to ensure that real-time fault diagnosis can be performed on site at the hydropower station, reduce data transmission delays, and improve real-time fault diagnosis. Compared with traditional neural networks that require a large amount of computing resources, the present invention is more flexible in practical applications and can adapt to equipment monitoring needs of different scales. In addition, the fault diagnosis model provided by this application can maintain adaptability to new fault types through continuous learning and updating, extend the normal operation time of the equipment, and reduce maintenance costs.

[0120] In summary, this application provides a more comprehensive and accurate fault diagnosis by fusing and analyzing multimodal data and comprehensively analyzing multi-source information. The attention mechanism is used to capture long-range dependencies between data globally and automatically discover potential key features. This enables the fault diagnosis model to better handle fault data with complex spatiotemporal dependencies, improve the accuracy and reliability of fault diagnosis, and thus detect and warn of potential faults in a timely manner, avoiding downtime and production losses caused by equipment failures. Compared with traditional machine learning and deep learning models, the Transformer model has significant advantages in parallel processing and computational efficiency, can process multimodal data, and provide efficient and real-time fault diagnosis. At the same time, the transparency and interpretability of the diagnostic results can be improved through attention scores, thereby enhancing the credibility and practicality of the fault diagnosis model.

[0121] In a second aspect, an embodiment of the present application provides an air compressor fault diagnosis system, which is deployed on an edge computing device. Figure 4 is a structural block diagram of an air compressor fault diagnosis system according to an embodiment of the present application, such as Figure 4 As shown, the system includes:

[0122] Data module 100: used to obtain current operating parameters of the air compressor, pre-process the current operating parameters to obtain input data, the operating parameters include vibration parameters, temperature parameters, input pressure and output pressure, and the working current of the motor.

[0123] Training module 200: used to train the Transformer model to obtain a fault diagnosis model based on the historical operating parameters and historical fault type data of the air compressor. The fault diagnosis model includes a multi-head attention module, which is used to calculate the attention score.

[0124] Diagnostic module 300: used to diagnose the state of the air compressor according to the input data and the fault diagnosis model to obtain the diagnosis result, and obtain the target data concerned during the diagnosis according to the attention score to provide supplementary explanation for the diagnosis result.

[0125] In one example, the training module 200 includes:

[0126] The historical operating parameters and historical fault type data of the air compressor are obtained, and the historical operating parameters are preprocessed to obtain training data.

[0127] Obtain the Transformer model, and based on the training data and historical fault type data, iteratively train the Transformer model through the cross entropy loss function or the mean square error loss function combined with the Adam optimizer to obtain the fault diagnosis model.

[0128] In one example, the data module 100 includes:

[0129] The operating parameters are normalized to reduce the impact between different dimensions.

[0130] The normalized running parameters were aligned to ensure the consistency of the time series.

[0131] The operating parameters after data alignment are filtered to remove high-frequency noise in the operating parameters.

[0132] In one example, the fault diagnosis model in the training module 200 includes an encoder layer, a linear layer, and an output module.

[0133] The encoder layer is used to obtain the spatiotemporal dependencies of the input data, extract features from the input data, and obtain high-dimensional features based on the extracted features.

[0134] The linear layer is used to transform the high-dimensional features output by the encoder layer to the target dimension.

[0135] The output module is used to perform fault diagnosis based on the characteristics of the target dimension output by the linear layer and output the diagnosis results.

[0136] In one example, the encoder layer of the fault diagnosis model in the training module 200 includes a multi-head attention module and a feedforward neural network module.

[0137] The multi-head attention module is used to obtain the spatiotemporal dependencies of the input data and perform feature extraction on the input data. The multi-head attention module is also used to calculate the attention score.

[0138] The feedforward neural network module is used to process the feature vector output by the multi-head attention module to obtain high-dimensional features.

[0139] In one example, the fault diagnosis model in the training module 200 further includes a vector layer and a position encoding layer, wherein the vector layer is used to convert input data into a digital vector, and the position encoding layer is used to add position information to the digital vector.

[0140] In one example, the system further includes: a device for sending the diagnosis result to a user terminal so that the user can make a maintenance decision based on the diagnosis result.

[0141] In summary, this application provides a more comprehensive and accurate fault diagnosis by fusing and analyzing multimodal data and comprehensively analyzing multi-source information. The attention mechanism is used to capture long-range dependencies between data globally and automatically discover potential key features. This enables the fault diagnosis model to better handle fault data with complex spatiotemporal dependencies, improve the accuracy and reliability of fault diagnosis, and thus detect and warn of potential faults in a timely manner, avoiding downtime and production losses caused by equipment failures. Compared with traditional machine learning and deep learning models, the Transformer model has significant advantages in parallel processing and computational efficiency, can process multimodal data, and provide efficient and real-time fault diagnosis. At the same time, the transparency and interpretability of the diagnostic results can be improved through attention scores, thereby enhancing the credibility and practicality of the fault diagnosis model.

[0142] In a third aspect, an embodiment of the present application provides an electronic device, Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. The electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the air compressor fault diagnosis method provided in the first aspect is implemented. Figure 5 The electronic device 60 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0143] The electronic device 60 may be in the form of a general-purpose computing device, for example, it may be a server device. The components of the electronic device 60 may include but are not limited to: at least one processor 61, at least one memory 62, and a bus 63 connecting different system components (including the memory 62 and the processor 61).

[0144] The bus 63 includes a data bus, an address bus, and a control bus.

[0145] The memory 62 may include a volatile memory, such as a random access memory (RAM) 621 and / or a cache memory 622 , and may further include a read-only memory (ROM) 623 .

[0146] The memory 62 may also include a program / utility 625 having a set (at least one) of program modules 624, such program modules 624 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0147] The processor 61 executes various functional applications and data processing by running the computer program stored in the memory 62, such as the air compressor fault diagnosis method provided in the first aspect of the present application.

[0148] The electronic device 60 may also communicate with one or more external devices 64 (e.g., keyboards, pointing devices, etc.). Such communication may be performed via an input / output (I / O) interface 65. Furthermore, the model-generated device 60 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 66. As shown, the network adapter 66 communicates with other modules of the model-generated device 60 via a bus 63. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the model-generated device 60, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID (RAID) systems, tape drives, and data backup storage systems.

[0149] It should be noted that although several units / modules or sub-units / modules of the electronic device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to an embodiment of the present invention, the features and functions of two or more units / modules described above can be embodied in one unit / module. Conversely, the features and functions of one unit / module described above can be further divided into multiple units / modules to be embodied.

[0150] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having a program stored thereon, and when the program is executed by a processor, the air compressor fault diagnosis method provided in the first aspect is implemented.

[0151] The readable storage medium may include but is not limited to: a portable disk, a hard disk, a random access memory, a read-only memory, an erasable programmable read-only memory, an optical storage device, a magnetic storage device or any suitable combination of the above.

[0152] In a possible implementation, the present invention can also be implemented in the form of a program product, which includes a program code. When the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps of the air compressor fault diagnosis method provided in the first aspect.

[0153] The program code for executing the present invention may be written in any combination of one or more programming languages, and may be executed entirely on a user device, partially on a user device, as an independent software package, partially on a user device and partially on a remote device, or entirely on a remote device.

[0154] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0155] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

Claims

1. A method for diagnosing air compressor faults, characterized in that: include: Acquire current operating parameters of the air compressor, and pre-process the current operating parameters to obtain input data, wherein the operating parameters include vibration parameters, temperature parameters, input pressure and output pressure, and working current of the motor; According to the historical operating parameters and historical fault type data of the air compressor, a Transformer model is trained to obtain a fault diagnosis model, wherein the fault diagnosis model includes a multi-head attention module, and the multi-head attention module is used to calculate an attention score; The state of the air compressor is diagnosed according to the input data and the fault diagnosis model to obtain a diagnosis result, and the target data concerned during diagnosis is obtained according to the attention score to provide a supplementary explanation for the diagnosis result.

2. The air compressor fault diagnosis method according to claim 1, characterized in that: The method of training a Transformer model to obtain a fault diagnosis model based on historical operating parameters and historical fault type data of the air compressor includes: Acquire historical operating parameters and historical fault type data of the air compressor, and pre-process the historical operating parameters to obtain training data; A Transformer model is obtained, and based on the training data and historical fault type data, the Transformer model is iteratively trained through a cross entropy loss function or a mean square error loss function in combination with an Adam optimizer to obtain the fault diagnosis model.

3. The air compressor fault diagnosis method according to claim 1 or 2, characterized in that: Preprocessing the operating parameters includes: Normalizing the operating parameters to reduce the impact between different dimensions; Perform data alignment on the normalized operating parameters to ensure the consistency of the time series; The operating parameters after data alignment are filtered to remove high-frequency noise in the operating parameters.

4. The air compressor fault diagnosis method according to claim 1, characterized in that: The fault diagnosis model includes an encoder layer, a linear layer and an output module. The encoder layer is used to obtain the spatiotemporal dependency of the input data, perform feature extraction on the input data, and obtain high-dimensional features based on the extracted features; The linear layer is used to convert the high-dimensional features output by the encoder layer to the target dimension; The output module is used to perform fault diagnosis according to the characteristics of the target dimension output by the linear layer and output the diagnosis result.

5. The air compressor fault diagnosis method according to claim 4, characterized in that: The encoder layer includes a multi-head attention module and a feedforward neural network module, The multi-head attention module is used to obtain the spatiotemporal dependency of the input data, perform feature extraction on the input data, and calculate the attention score; The feedforward neural network module is used to process the feature vector output by the multi-head attention module to obtain high-dimensional features.

6. The air compressor fault diagnosis method according to claim 4, characterized in that: The fault diagnosis model also includes a vector layer and a position encoding layer. The vector layer is used to convert the input data into a digital vector, and the position encoding layer is used to add position information to the digital vector.

7. The air compressor fault diagnosis method according to claim 1, characterized in that: The method further comprises: The diagnosis result is sent to a user terminal so that the user can make a maintenance decision based on the diagnosis result.

8. An air compressor fault diagnosis system, characterized in that: The system is deployed on an edge computing device, and the system includes: Data module: used to obtain the current operating parameters of the air compressor, and pre-process the current operating parameters to obtain input data, wherein the operating parameters include vibration parameters, temperature parameters, input pressure and output pressure, and the working current of the motor; Training module: used to train the Transformer model to obtain a fault diagnosis model based on the historical operating parameters and historical fault type data of the air compressor, wherein the fault diagnosis model includes a multi-head attention module, and the multi-head attention module is used to calculate the attention score; Diagnostic module: used to diagnose the state of the air compressor according to the input data and the fault diagnosis model to obtain a diagnosis result, and to obtain the target data concerned during diagnosis according to the attention score to provide a supplementary explanation for the diagnosis result.

9. An electronic device, characterized in that: include Memory, processor, and A computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the air compressor fault diagnosis method according to any one of claims 1 to 7 is implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the air compressor fault diagnosis method according to any one of claims 1 to 7 is implemented.

Citation Information

Cited By

  • Crown block fault prediction method and device, storage medium and electronic equipment

    CN120067868A

  • Overhead crane fault prediction method, device, storage medium and electronic device

    CN120067868B

  • Fault diagnosis method and device for air conditioner outdoor unit module and air conditioner

    CN120593351A

  • Fault diagnosis method and device for air conditioner outdoor unit module and air conditioner

    CN120593351B