Operation inspection equipment fault detection method and system based on improved deep learning model
By improving the deep learning model, combining EEMD decomposition, Resnet, dynamic Transformer encoder and ZOA optimization algorithm, the problem of insufficient real-time and accuracy of fault detection of operation and inspection equipment in the existing technology is solved, efficient and real-time fault detection is achieved, and the stability and reliability of the power system are improved.
Patent Information
- Application Number
- CN202411656520.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-19
- Publication Date
- 2025-03-07
AI Technical Summary
The calculation time of existing deep learning models in operation and inspection equipment failure detection is too long, resulting in the inability to achieve real-time detection and continuous update of the model, resulting in low reliability of fault detection and slow response.
The improved deep learning model is adopted to enhance fault characteristics through EEMD decomposition, local and global features are extracted in combination with Resnet and dynamic Transformer encoder, and hyperparameters are optimized using ZOA optimization algorithm to build an efficient fault detection system.
It improves the real-time and accuracy of fault detection of operation and inspection equipment, reduces false alarms and missed reports of fault detection, and enhances the stability and reliability of the power system.
Smart Images

Figure CN119577578A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of computer application technology, and in particular to intelligent operation and maintenance technology of power systems, and specifically to a method and system for detecting faults of operation and maintenance equipment based on an improved deep learning model. Background Art
[0002] With the rapid development of industrialization and informatization, the stability and reliability of the power system, as a key infrastructure of modern society, plays a vital role in ensuring people's livelihood and social development. As the core component of the power system, real-time monitoring of the operating status of power equipment is a key link in ensuring the safe and stable operation of the power system. Due to the extremely high requirements for the real-time and accuracy of power equipment fault detection, once the detection is delayed or falsely reported, it may cause a chain reaction, resulting in serious consequences such as large-scale power outages. Nowadays, how to accurately and timely detect faults based on the real-time operating parameters of power equipment and determine the fault type is an urgent problem to be solved.
[0003] Traditional fault detection methods mainly rely on manual inspections and automatic diagnosis based on empirical rules. Among them, manual inspections have disadvantages such as low efficiency, high cost, and detection results are easily affected by human factors. Although automatic diagnosis based on empirical rules has improved detection efficiency to a certain extent, it not only requires a lot of manpower investment, but also relies too much on past experience summaries and has poor rule adaptability. Faced with the continuous expansion of the scale of power systems, considering the variability and complexity of power system operating conditions, traditional fault detection methods are difficult to maintain sufficient high accuracy and rapid response capabilities.
[0004] Deep learning technology has made unprecedented breakthroughs in recent years. It has not only achieved remarkable results in the fields of computer vision and natural language processing, but also provided new ideas for fault detection of operation and maintenance equipment. Compared with traditional fault detection methods, deep learning methods can extract features from large-scale data by building multi-layer neural networks, model and predict the complex relationship between fault categories and operating parameters of power equipment, and greatly improve the accuracy and real-time performance of fault detection of operation and maintenance equipment.
[0005] The existing deep learning models still face some challenges in the practical application of fault detection in operation and maintenance equipment, such as insufficient model generalization ability and the inability to achieve real-time detection and continuous model updating due to the long calculation time. Therefore, how to design a deep learning model with strong adaptability and fast response speed to meet the requirements of high reliability and fast response for fault detection is an important direction of current technology development. Summary of the invention
[0006] The purpose of the present invention is to provide a method and system for operation and maintenance equipment fault detection based on an improved deep learning model, so as to solve the technical problem in the prior art that the deep learning model calculation takes too long, resulting in the inability to achieve real-time detection and continuous updating of the model, resulting in low reliability and slow response of operation and maintenance equipment fault detection.
[0007] In order to achieve the above object, the present invention adopts the following technical solutions: In a first aspect, the present application discloses a method for detecting faults of an operation and inspection equipment based on an improved deep learning model, comprising: Obtain the original data, use EEMD to decompose the original data for feature enhancement, obtain a decomposed signal, perform noise reduction on the decomposed signal, and obtain a noise-reduced feature signal; According to the denoised feature signal, a deep learning model is built based on Resnet and dynamic Transformer encoder to output the predicted probability of each fault category; Use the ZOA optimization algorithm to optimize the deep learning model hyperparameters, obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
[0008] Preferably, the obtaining of raw data comprises: Obtain smart grid stability datasets; The smart grid stability dataset is normalized to obtain a preprocessed dataset, which is then divided into a training set, a validation set, and a test set in a ratio of 7:2:1.
[0009] Preferably, the method of using EEMD to decompose the original data to perform feature enhancement to obtain a decomposed signal, and performing noise reduction on the decomposed signal to obtain a feature signal after noise reduction specifically includes: Perform EEMD decomposition on the original data to obtain multiple intrinsic mode functions; The modal function of the evidence is screened based on the adaptive noise reduction method to obtain the selected modal function of the evidence; The selected intrinsic modal functions are superimposed to obtain the denoised characteristic signal.
[0010] Preferably, the method of constructing a deep learning model based on Resnet and dynamic Transformer encoder according to the denoised feature signal to output the predicted probability of each fault category specifically includes: S201: extract local features using Resnet for the denoised feature signal; The denoised feature signal is used as the input signal and mapped to a high-dimensional space through a fully connected layer. Two residual blocks are used to deeply mine the local features of the data and capture the nonlinear relationship between the local features. A feature map containing the local correlation between the input signal features is generated based on the local features and the nonlinear relationship. S202: Use the dynamic Transformer encoder to extract global features; In the dynamic Transformer encoder, a dynamic attention bias term is introduced to generate a feature map containing the global features of the input signal; S203: performing weighted summation of local features and global features to obtain fusion features; The feature map containing the local correlation between the input signal features and the feature map containing the global features of the input signal are concatenated to obtain the feature map, the feature map is linearly mapped and normalized to obtain a two-dimensional weight vector, and the weights of the local features and the global features are adaptively adjusted based on the two-dimensional weight vector to obtain a fusion feature; S204: classification output layer; According to the number of fault types, the feature vector of the fusion feature is mapped to the corresponding dimension through the fully connected layer transformation, and then The predicted probability of each fault category is obtained through layer processing.
[0011] Preferably, the ZOA optimization algorithm is used to optimize the hyperparameters of the deep learning model to obtain the optimized model, the performance of the optimized model is evaluated, the optimal model is obtained, and the predicted probability of each fault category is output, specifically including: S301: Use the training set to input the deep learning model for model training, introduce an early stopping mechanism based on the fault detection accuracy on the validation set to prevent overfitting, and obtain a preliminary model; S302: Optimize the hyperparameters of the preliminary model using the ZOA optimization algorithm to obtain an optimized model; S303: The validation set is input into the optimization model, the model with the highest fault detection accuracy is the optimal model, and the predicted probability of each fault category of the model is output.
[0012] Preferably, the ZOA optimization algorithm is used to optimize the hyperparameters of the preliminary model. ZOA initially randomly generates 5 candidate solutions to form a population. , candidate solution Represents two hyperparameters to be optimized, including: S3021: Create and train a model corresponding to the candidate solution, and calculate the candidate solution in the objective function Fitness , the objective function is the fault detection accuracy of the model on the validation set; S3022: Find the solution with the best fitness in the current population, recorded as ;
[0013] S3023: Calculate the parameters a, A and C in the update formula:
[0014] Where t is the current iteration number and T is the maximum iteration number. Randomly generate two vectors and , calculate the update factor:
[0015]
[0016] S3024: Each solution is based on the optimal solution Update location:
[0017]
[0018] in is the distance vector from the current solution to the optimal solution; S3025: Boundary processing:
[0019] in and are the upper and lower bounds of the variable; S3026: Repeat the above steps until the maximum number of iterations is reached or the fitness is no longer significantly improved.
[0020] Preferably, the evaluation and optimization model performance is achieved by calculating the fault detection accuracy, precision, recall and F1 score of the test set on the optimal model:
[0021]
[0022]
[0023]
[0024] Among them, TP, TN, FP, and FN are true positive examples, true negative examples, false positive examples, and false negative examples, respectively.
[0025] In a second aspect, the present application discloses a fault detection system for operation and inspection equipment based on an improved deep learning model, comprising: A characteristic signal processing unit is used to obtain the original data, decompose the original data using EEMD to enhance the characteristics, obtain the decomposed signal, and perform noise reduction on the decomposed signal to obtain the characteristic signal after noise reduction; A model building unit is used to build a deep learning model based on Resnet and dynamic Transformer encoder according to the denoised feature signal, and output the predicted probability of each fault category; The model optimization unit is used to optimize the deep learning model hyperparameters using the ZOA optimization algorithm to obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
[0026] In the third aspect, the present application discloses an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the method for fault detection of operation and maintenance equipment based on an improved deep learning model as described above are implemented.
[0027] In a fourth aspect, the present application discloses a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the steps of the above-mentioned method for fault detection of operation and maintenance equipment based on an improved deep learning model.
[0028] Compared with the prior art, the present invention has the following beneficial effects: The present invention enhances the expressiveness of fault features by EEMD decomposition of the input signal, and uses an adaptive noise reduction method to screen and reconstruct the obtained intrinsic modal function, effectively reducing noise interference. The dynamic Transformer encoder structure proposed in the present invention helps to guide the model to focus on giving greater attention weight to key information, and has stronger global information analysis capabilities than the traditional Transformer encoder. The use of Resnet not only plays the role of CNN network feature extraction, but also effectively prevents potential model performance degradation and gradient disappearance problems. In addition, the dual-path parallel local feature and global feature extraction and fusion module can not only fully mine the fault information contained in the data, but also has a faster running speed than the serial structure, which is conducive to the real-time monitoring and updating of the model in practical applications, and improves the real-time performance of fault detection of operation and inspection equipment. Compared with the method of manually adjusting hyperparameters in traditional deep learning, the use of ZOA optimization algorithm can more accurately find the optimal hyperparameter combination to achieve the best model performance. The present invention can effectively reduce the false alarm and missed alarm of faults in fault detection tasks, and reduce the safety hazards caused by the failure to discover faults in time, so it has important value in improving the stability and reliability of the power system, and also has a driving role in the modernization of smart grids and industrial equipment. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0030] Figure 1 is a flow chart of the method of the present invention; Figure 2 is a flow chart of a method according to an embodiment of the present invention; Figure 3 This is a model network structure diagram of an embodiment of the present invention. DETAILED DESCRIPTION
[0031] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0032] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0033] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.
[0034] In the description of the embodiments of the present invention, it should be noted that if the terms "upper", "lower", "horizontal", "inner", etc. indicate an orientation or positional relationship based on the orientation or positional relationship shown in the drawings, or the orientation or positional relationship in which the product of the invention is usually placed when in use, it is only for the convenience of describing the present invention and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention. In addition, the terms "first", "second", etc. are only used to distinguish the description, and cannot be understood as indicating or implying relative importance.
[0035] In addition, if the term "horizontal" appears, it does not mean that the component must be absolutely horizontal, but can be slightly tilted. For example, "horizontal" only means that its direction is more horizontal than "vertical", which does not mean that the structure must be completely horizontal, but can be slightly tilted.
[0036] In the description of the embodiments of the present invention, it is also necessary to explain that, unless otherwise clearly specified and limited, the terms "set", "install", "connect", and "connect" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal connection of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0037] The present invention is further described in detail below in conjunction with the accompanying drawings: Based on the above problems, we proposed an improved deep learning model combined with a new optimization algorithm for fault detection of maintenance equipment, which has strong generalization performance and operation efficiency on data sets of different equipment.
[0038] See also Figure 1 The present application discloses a method for detecting faults of an operation and inspection equipment based on an improved deep learning model, comprising: S1: Obtain the original data, use EEMD to decompose the original data for feature enhancement, obtain the decomposed signal, perform noise reduction on the decomposed signal, and obtain the feature signal after noise reduction; S2: Based on the denoised feature signal, a deep learning model is built based on Resnet and dynamic Transformer encoder to output the predicted probability of each fault category; S3: Use the ZOA optimization algorithm to optimize the deep learning model hyperparameters, obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
[0039] In some embodiments, obtaining raw data includes: Obtain smart grid stability datasets; The smart grid stability dataset is normalized to obtain a preprocessed dataset, which is then divided into a training set, a validation set, and a test set in a ratio of 7:2:1.
[0040] In some embodiments, the method constructs a deep learning model based on Resnet and dynamic Transformer encoder according to the denoised feature signal, and outputs the predicted probability of each fault category, specifically including: S201: extract local features using Resnet for the denoised feature signal; The denoised feature signal is used as the input signal and mapped to a high-dimensional space through a fully connected layer. Two residual blocks are used to deeply mine the local features of the data and capture the nonlinear relationship between the local features. A feature map containing the local correlation between the input signal features is generated based on the local features and the nonlinear relationship. S202: Use the dynamic Transformer encoder to extract global features; In the dynamic Transformer encoder, a dynamic attention bias term is introduced to generate a feature map containing the global features of the input signal; S203: performing weighted summation of local features and global features to obtain fusion features; The feature map containing the local correlation between the input signal features and the feature map containing the global features of the input signal are concatenated to obtain the feature map, the feature map is linearly mapped and normalized to obtain a two-dimensional weight vector, and the weights of the local features and the global features are adaptively adjusted based on the two-dimensional weight vector to obtain a fusion feature; S204: classification output layer; According to the number of fault types, the feature vector of the fusion feature is mapped to the corresponding dimension through the fully connected layer transformation, and then The predicted probability of each fault category is obtained through layer processing.
[0041] In some embodiments, the deep learning model hyperparameters are optimized using the ZOA optimization algorithm to obtain an optimized model, the optimized model performance is evaluated, the optimal model is obtained, and the predicted probability of each fault category is output, specifically including: S301: Use the training set to input the deep learning model for model training, introduce an early stopping mechanism based on the fault detection accuracy on the validation set to prevent overfitting, and obtain a preliminary model; S302: Optimize the hyperparameters of the preliminary model using the ZOA optimization algorithm to obtain an optimized model; S303: The validation set is input into the optimization model, the model with the highest fault detection accuracy is the optimal model, and the predicted probability of each fault category of the model is output.
[0042] In some embodiments, a method for detecting faults in an operation and inspection equipment based on an improved deep learning model comprises: Step 1: Get the original data, use EEMD to decompose the original data for feature enhancement, get the decomposed signal, denoise the decomposed signal, and get the denoised feature signal.
[0043] The step 1 comprises the following sub-steps: Sub-step A1: Decompose the original signal using EEMD to obtain several intrinsic mode functions (IMFs). EEMD decomposition effectively overcomes the modal aliasing problem of traditional EMD decomposition by introducing white noise, preventing different frequency components from being mixed in the same IMF. The multiple IMFs finally obtained represent different frequency components of the original signal, which can enhance fault information and facilitate subsequent fault judgment.
[0044] Sub-step A2: Use adaptive noise reduction method to filter IMF. Coefficient, removal Noise IMFs with coefficients greater than 1.
[0045] Sub-step A3: Superimpose the screened IMFs to obtain the reconstructed characteristic signal.
[0046] Step 2: Based on the denoised feature signal, a deep learning model is built based on Resnet and dynamic Transformer encoder to output the predicted probability of each fault category.
[0047] Sub-step B1: Extract local features using Resnet. Map the input data to a high-dimensional space, and then extract local features through multiple residual blocks. The residual block consists of multiple convolutional layers, pooling layers, and batch normalization layers.
[0048] Sub-step B2: Extract global features using a dynamic Transformer encoder. The present invention introduces a bias term B in the multi-head attention mechanism, so that the attention calculation formula is adjusted to:
[0049] Among them, B is automatically generated according to the input data through a lightweight multi-layer perceptron, which plays the role of guiding the model to focus on key features when calculating attention weights. The Resnet network and the dynamic Transformer encoder work in parallel to extract local and global features of the reconstructed signal at the same time.
[0050] Sub-step B3: Adaptive weighted feature fusion. Concatenation of local features and global features get By introducing a linear map and Get the weight vector :
[0051] By updating the learnable parameters while training the model and , adaptively adjust the weights of local features and global features so that the fused features contain more effective fault information. The weighted sum of local features and global features is used as the final fused feature:
[0052] Sub-step B4: Use a fully connected network and According to the fusion features, the input data is mapped to the dimension corresponding to the fault category through a fully connected network, and then used The function obtains the predicted probability of each failure.
[0053] Step 3: Use the new optimization algorithm ZOA to tune hyperparameters. Using the global search capability of the ZOA algorithm, find the optimal combination of all hyperparameters to achieve the best model performance, obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
[0054] [Example] The following is combined with Figure 2 and attached Figure 3 , the embodiments are described in detail (see Figure 2 This is the full flow chart of this application, attached Figure 3 It should be emphasized that the following description is merely exemplary and is not intended to limit the scope of the present invention and its application.
[0055] Step 1: Data collection and preprocessing of inspection equipment: The step 1 comprises the following sub-steps: Sub-step A1: Data preparation. The present invention uses the smart grid stability data set of the kaggle platform, which includes the power system time constants (tau1, tau2, tau3, tau4), active power output (P1, P2, P3, P4), admittance values (g1, g2, g3, g4), power system stability index and corresponding power system stability classification (including stable and unstable states) of 4 nodes.
[0056] Sub-step A2: Data preprocessing. Perform normalization on the data uniformly, the formula is as follows:
[0057] Then the dataset is divided into training set, validation set, and test set in a ratio of 7:2:1.
[0058] Step 2: Feature enhancement and noise reduction: The step 2 comprises the following sub-steps: Sub-step B1: In order to fully explore the characteristic information of the input signal and eliminate noise interference, the input signal is first decomposed by EEMD to obtain multiple intrinsic mode functions (IMFs). These IMFs reflect the dynamic changes of the characteristic variables of the power system at different frequencies and time scales. The final raw data is expressed as:
[0059] in is the kth IMF, N is the total number of IMFs, is the residual term after decomposition.
[0060] Sub-step B2: Screening IMF based on adaptive noise reduction method. Since the smart grid is a complex system, it contains a lot of interference factors such as environmental noise, electromagnetic interference, sensor measurement errors, etc. Therefore, eliminating these interference factors can truly reflect the operation status of the grid and improve the reliability of fault detection. The method used is as follows: First, calculate the energy density of each IMF component With average period , and calculate the product of the two :
[0061]
[0062]
[0063] Where N is the length of each IMF, is the amplitude of the jth IMF component, is the total number of extreme points of the jth IMF component. Then calculate coefficient:
[0064] We think The IMF components mainly contain noise, and these IMFs are removed to achieve the effect of feature extraction and enhancement and eliminate noise interference.
[0065] Sub-step B3: Signal reconstruction. After completing IMF screening, reconstruct the retained IMF of each feature to obtain the denoised feature signal , the reconstruction process is to superimpose the selected IMFs:
[0066] Step 3: Feature fusion network based on attention guidance; The step 3 comprises the following sub-steps: Sub-step C1: Local feature extraction module based on ResNet (Residual Network). This module first maps the input signal to a high-dimensional space through a fully connected layer to enhance the expressiveness of the features. Then, two residual blocks are used to deeply explore the local features of the data and capture the complex nonlinear relationships between the features, such as the coupling relationship between the time constant and the power output, and the impact of the admittance value on the system stability. At the same time, the introduction of residual connections can effectively solve problems such as performance degradation and gradient disappearance that may be caused by the increase in network depth, and improve the stability of fault detection. Set batch_size=64, input_size=13, and the network structure of this module is shown in the following table:
[0067] The network structure of the residual block is shown in the following table:
[0068] Convolutional layers 1 and 2 are used to extract features; the batch normalization layer accelerates the training process and improves the stability of the model; the Relu activation function improves the nonlinear expression ability of the model; and the 1x1 convolutional layer is used to adjust the number of input and output channels to be consistent during the residual connection. Finally, the module generates a feature map containing local correlations between features.
[0069] Sub-step C2: Global feature extraction module based on dynamic Transformer encoder. In the dynamic Transformer encoder, we introduce a dynamic attention bias term B, so that the attention calculation formula is modified to:
[0070] The bias term B is dynamically generated by a lightweight perceptron consisting of two fully connected layers, namely:
[0071] In the power system, changes in certain physical quantities can often reflect potential fault information better than other physical quantities. For example, in the smart grid stability data set used in the present invention, the active power of node 1 and the active power of node 2 may have a greater impact on the stability of the smart grid. However, the traditional attention mechanism does not tend to assign a higher attention weight to the active power of node 1, but treats all features equally when allocating attention. Since the bias term B is dynamically generated by the input data, the correlation between fault information and each feature can be additionally introduced to guide the model to focus on more important individual features. This enables the attention mechanism to flexibly adjust the allocation of attention weights, allocate larger attention weights to key features in a targeted manner, and compensate for the defects of the traditional attention mechanism in improperly allocating attention to key features, thereby improving the model's ability to analyze global features. Finally, the module generates a feature map containing the global features of the input signal.
[0072] Sub-step C3: Adaptive feature weighted fusion module. Sub-step C1 and sub-step C2 work in parallel. By setting parameters appropriately, the feature graphs obtained by the two have the same dimension. Global features capture the overall behavior of the power grid, such as the frequency stability and power flow of the system as a whole; local features focus on the detailed parameters of the power grid, such as current and voltage fluctuations between nodes, dynamic changes of neighboring nodes, etc. The function of this module is to weight the local features of the input signal. and global features , the steps are as follows: First, and The concatenated feature map undergoes a linear mapping and then normalization to obtain a two-dimensional weight vector :
[0073] in and are learnable model parameters, The vector contains the weights and And meet The final fused feature map is expressed as:
[0074] and Controlled by learnable parameters, enabling adaptive adjustment and The weight of the fusion It takes into account the dual advantages of both the global and partial features of the input signal.
[0075] Sub-step C4: Classification output layer. The above steps together complete feature extraction and fusion. According to the number of fault types, the fused feature vector is transformed and mapped to the corresponding dimension through the fully connected layer, and then The predicted probability of each fault category is obtained through layer processing, and the system is judged to have the fault with the largest predicted probability value.
[0076] Step 4: Model training and evaluation; The step 4 comprises the following sub-steps: Sub-step D1: Model training. In each training round, a batch of data is taken out each time and input into the model to obtain the predicted probability of each category, the cross entropy loss is calculated, and then the model parameters are updated using the Adam algorithm. After each round of training, the accuracy of fault detection is calculated using the validation set. To prevent overfitting, the training is stopped in advance when the fault detection accuracy on the validation set has not been improved for 10 consecutive rounds, otherwise the training is stopped when the maximum number of training rounds is reached. The smart grid stability data set used in the present invention is a binary classification problem, and the calculation formula for the cross entropy loss is as follows:
[0077] Where N is the number of samples, is the label of sample i (positive class is 1, negative class is 0, and faulty class is defined as positive class), is the probability that sample i is a positive class.
[0078] Sub-step D2: Use the ZOA optimization algorithm to optimize the model hyperparameters, including the number of heads of the multi-head attention mechanism and the learning rate of the Adam optimizer. ZOA initially randomly generates 5 candidate solutions to form a population , candidate solution Represents two hyperparameters to be optimized. The optimization steps are as follows: 1) For each candidate solution, create a corresponding model and train it to calculate its performance in the objective function Fitness , the objective function is the fault detection accuracy of the model on the validation set.
[0079] 2) Find the solution with the best fitness in the current population, recorded as .
[0080]
[0081] 3) Calculate the parameters a, A and C in the update formula:
[0082] Where t is the current iteration number and T is the maximum iteration number. Randomly generate two vectors and , calculate the update factor:
[0083]
[0084] 4) Each solution is based on the optimal solution Update location:
[0085]
[0086] in is the distance vector from the current solution to the optimal solution.
[0087] 5) To ensure that the updated solution is within the given domain, perform boundary processing
[0088] in and are the lower and upper bounds of the variable.
[0089] 6) Repeat the above steps until the maximum number of iterations is reached or the fitness no longer improves significantly.
[0090] Sub-step D3: Evaluation of model performance. After completing hyperparameter tuning, recreate the model and train it using the same method as sub-step D1. The model with the highest fault detection accuracy on the validation set is selected as the optimal model. Calculate the fault detection accuracy, precision, recall, and F1 score of the test set on the optimal model to evaluate model performance:
[0091]
[0092]
[0093]
[0094] Among them, TP, TN, FP, and FN are true positive examples, true negative examples, false positive examples, and false negative examples, respectively.
[0095] The present application discloses a fault detection system for operation and inspection equipment based on an improved deep learning model, comprising: A characteristic signal processing unit is used to obtain the original data, decompose the original data using EEMD to enhance the characteristics, obtain the decomposed signal, and perform noise reduction on the decomposed signal to obtain the characteristic signal after noise reduction; A model building unit is used to build a deep learning model based on Resnet and dynamic Transformer encoder according to the denoised feature signal, and output the predicted probability of each fault category; The model optimization unit is used to optimize the deep learning model hyperparameters using the ZOA optimization algorithm to obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
[0096] The present application discloses an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the method for fault detection of operation and inspection equipment based on an improved deep learning model as described above are implemented.
[0097] The present application discloses a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the steps of the above-mentioned method for fault detection of operation and inspection equipment based on an improved deep learning model are implemented.
[0098] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0099] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0100] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0101] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0102] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.
Claims
1. A method for fault detection of operation and inspection equipment based on an improved deep learning model, characterized in that: include: Obtain the original data, use EEMD to decompose the original data for feature enhancement, obtain a decomposed signal, perform noise reduction on the decomposed signal, and obtain a noise-reduced feature signal; According to the denoised feature signal, a deep learning model is built based on Resnet and dynamic Transformer encoder to output the predicted probability of each fault category; Use the ZOA optimization algorithm to optimize the deep learning model hyperparameters, obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
2. The method for detecting faults of an operation and inspection equipment based on an improved deep learning model according to claim 1, characterized in that: The obtaining of original data comprises: Obtain smart grid stability datasets; The smart grid stability dataset is normalized to obtain a preprocessed dataset, which is then divided into a training set, a validation set, and a test set in a ratio of 7:2:
1.
3. The method for detecting faults of an operation and inspection equipment based on an improved deep learning model according to claim 1, characterized in that: The method of using EEMD to decompose the original data to enhance the features, obtain the decomposed signal, and perform noise reduction on the decomposed signal to obtain the noise-reduced feature signal specifically includes: Perform EEMD decomposition on the original data to obtain multiple intrinsic mode functions; The modal function of the evidence is screened based on the adaptive noise reduction method to obtain the selected modal function of the evidence; The selected intrinsic modal functions are superimposed to obtain the denoised characteristic signal.
4. The method for detecting faults of an operation and inspection equipment based on an improved deep learning model according to claim 1, characterized in that: According to the de-noised feature signal, a deep learning model is constructed based on Resnet and dynamic Transformer encoder to output the predicted probability of each fault category, specifically including: S201: extract local features using Resnet for the denoised feature signal; The denoised feature signal is used as the input signal and mapped to a high-dimensional space through a fully connected layer. Two residual blocks are used to deeply mine the local features of the data and capture the nonlinear relationship between the local features. A feature map containing the local correlation between the input signal features is generated based on the local features and the nonlinear relationship. S202: Use the dynamic Transformer encoder to extract global features; In the dynamic Transformer encoder, a dynamic attention bias term is introduced to generate a feature map containing the global features of the input signal; S203: performing weighted summation of local features and global features to obtain fusion features; The feature map containing the local correlation between the input signal features and the feature map containing the global features of the input signal are concatenated to obtain the feature map, the feature map is linearly mapped and normalized to obtain a two-dimensional weight vector, and the weights of the local features and the global features are adaptively adjusted based on the two-dimensional weight vector to obtain a fusion feature; S204: classification output layer; According to the number of fault types, the feature vector of the fusion feature is mapped to the corresponding dimension through the fully connected layer transformation, and then The predicted probability of each fault category is obtained through layer processing.
5. The method for detecting faults of operation and inspection equipment based on an improved deep learning model according to claim 2, characterized in that: Use the ZOA optimization algorithm to optimize the deep learning model hyperparameters, obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category, including: S301: Use the training set to input the deep learning model for model training, introduce an early stopping mechanism based on the fault detection accuracy on the validation set to prevent overfitting, and obtain a preliminary model; S302: Optimize the hyperparameters of the preliminary model using the ZOA optimization algorithm to obtain an optimized model; S303: The validation set is input into the optimization model, the model with the highest fault detection accuracy is the optimal model, and the predicted probability of each fault category of the model is output.
6. The method for detecting faults of operation and inspection equipment based on an improved deep learning model according to claim 5, characterized in that: The ZOA optimization algorithm is used to optimize the hyperparameters of the preliminary model. ZOA initially randomly generates 5 candidate solutions to form a population , candidate solution Represents two hyperparameters to be optimized, including: S3021: Create and train a model corresponding to the candidate solution, and calculate the candidate solution in the objective function Fitness , the objective function is the fault detection accuracy of the model on the validation set; S3022: Find the solution with the best fitness in the current population, recorded as ; S3023: Calculate the parameters a, A and C in the update formula: Where t is the current iteration number and T is the maximum iteration number; two vectors are randomly generated and , calculate the update factor: S3024: Each solution is based on the optimal solution Update location: in is the distance vector from the current solution to the optimal solution; S3025: Boundary Processing: in and are the upper and lower bounds of the variable; S3026: Repeat the above steps until the maximum number of iterations is reached or the fitness is no longer significantly improved.
7. The method for detecting faults of operation and inspection equipment based on an improved deep learning model according to claim 5, characterized in that: The evaluation optimizes the model performance by calculating the fault detection accuracy, precision, recall and F1 score of the test set on the optimal model: Among them, TP, TN, FP, and FN are true positive examples, true negative examples, false positive examples, and false negative examples, respectively.
8. A fault detection system for operation and inspection equipment based on an improved deep learning model, characterized in that: include: A characteristic signal processing unit is used to obtain the original data, decompose the original data using EEMD to enhance the characteristics, obtain the decomposed signal, and perform noise reduction on the decomposed signal to obtain the characteristic signal after noise reduction; A model building unit is used to build a deep learning model based on Resnet and dynamic Transformer encoder according to the denoised feature signal, and output the predicted probability of each fault category; The model optimization unit is used to optimize the deep learning model hyperparameters using the ZOA optimization algorithm to obtain the optimized model, evaluate the performance of the optimized model, obtain the optimal model, and output the predicted probability of each fault category.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method for fault detection of operation and inspection equipment based on an improved deep learning model as described in any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the steps of the method for fault detection of operation and inspection equipment based on an improved deep learning model as described in any one of claims 1 to 7.
Citation Information
Cited By
Industrial equipment fault prediction method and system based on deep learning
CN120430460A
A deep learning-based industrial equipment fault prediction method and system
CN120430460B
Fault monitoring method and system for stacker-reclaimer
CN120774216A
Water chiller fault data generation method, device, equipment, medium and product
CN121935615A