A neural network-based static var generator fault diagnosis method and system
By using a neural network-based fault diagnosis method, LSTM and BP neural network models are employed to diagnose and handle SVG faults. This solves the problem that existing technologies cannot comprehensively, accurately, and in real-time diagnose SVG faults, and achieves efficient and reliable fault identification and handling.
Patent Information
- Application Number
- CN202411727871.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-28
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2044-11-28
AI Technical Summary
Existing SVG fault diagnosis methods cannot comprehensively, accurately, and in real time diagnose various faults, especially IGBT open-circuit faults, which lead to unstable SVG operation and affect power grid safety.
A neural network-based fault diagnosis method is adopted. By collecting SVG operating parameters and fault data, data preprocessing, feature extraction and encoding are performed to construct LSTM and BP neural network models. Combined with an improved genetic algorithm for optimization, multi-class fault diagnosis and latent fault identification are achieved.
It improves the efficiency and accuracy of SVG fault diagnosis, and can automatically provide fault handling strategies to ensure the reliability of SVG operation and the stability of the power grid.
Smart Images

Figure CN119644009B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of power electronics, in particular to a static var generator fault diagnosis method and system based on neural networks. BACKGROUND
[0002] As an important reactive power compensation device in modern power systems, static var generator (SVG) can quickly and accurately regulate reactive power, which plays a crucial role in maintaining grid voltage stability and improving power quality. However, in actual operation, SVG may encounter various faults, such as power electronic device damage, control circuit failure, connection reactor or transformer failure, etc. If these faults cannot be detected and diagnosed in time, not only will it affect the normal operation of SVG itself, leading to the failure of reactive power compensation function, but also may pose a serious threat to the safe and stable operation of the entire power system.
[0003] Currently, the existing SVG fault diagnosis methods have certain limitations. For example, some methods can only diagnose single type of fault and cannot cover all possible fault conditions of SVG; some methods have low diagnosis accuracy and are prone to misdiagnosis or missed diagnosis. Secondly, some diagnosis methods have poor real-time performance and cannot accurately detect faults and issue alarms at the first time of fault occurrence. Thirdly, static var generators generally need to work in high-voltage and high-power environment for a long time, and power switch tubes work under high temperature and high frequency conditions for a long time, which increases the probability of failure. When IGBT open circuit fault occurs, SVG can still run with fault for a period of time, and the fault may not be detected for a long time. However, "running with disease" cannot effectively provide reactive current to the power grid, and causes DC bus capacitor voltage fluctuation, affecting the performance of compensation and causing more serious losses, so it is of great significance to study SVG fault diagnosis.
[0004] Therefore, it is necessary to develop a method that can comprehensively, accurately and timely diagnose SVG faults. SUMMARY
[0005] The technical problem to be solved by the present application is to provide a static var generator fault diagnosis method and system based on neural networks to solve the deficiencies of the prior art described in the background.
[0006] To solve the above technical problems, the embodiments of the present application provide the following technical solutions: a static var generator fault diagnosis method based on neural networks, comprising the following steps:
[0007] Collect running parameter data of the static var generator (SVG) in a fault state and a normal state during operation, record corresponding processing process data and fault result data in the fault state, collect compensation current data of the SVG in a normal operation condition, and establish a fault diagnosis database;
[0008] The data in the fault diagnosis database is preprocessed, including:
[0009] The running parameter data is processed through data cleaning, data normalization, data standardization and feature engineering. The running parameter data after preprocessing is processed through feature extraction, and key features reflecting the running state of the SVG are extracted through the establishment of a feature extraction model;
[0010] The keywords of the processing process data and the fault result data are extracted, the extracted keywords are encoded, and the encoded processing process data and the fault result data are mapped to establish a fault disposal database;
[0011] The compensation current data of the SVG in a normal operation condition is processed through Fourier transform to extract the amplitude and phase of the compensation current fundamental wave and each harmonic when the SVG has a single tube open circuit fault, and to identify the implicit fault characteristics;
[0012] An LSTM model data set is constructed based on the preprocessed running parameter data and running result data in the fault diagnosis database, including a training set, a validation set and a test set, which are divided in the ratio of 70:15:15. Then, an LSTM neural network fault prediction model is constructed, which is optimized based on an improved genetic algorithm, and the training set data is input into the LSTM model for model training. At the same time, based on the implicit fault characteristics identified by the SVG in a normal operation condition, the implicit fault characteristics are valued and encoded, and the implicit fault characteristic values are normalized. A BP neural network model is established, and the implicit fault characteristic normalized values and fault codes are used for BP neural network model training;
[0013] The running parameter data in the test set is input into the trained LSTM model, a Softmax classifier is used to identify whether a fault occurs and to perform multi-classification division of the fault category, and a confidence vector data of fault diagnosis is obtained, wherein the category corresponding to the highest confidence in the vector data is the diagnosis result. The diagnosis result is input into the fault disposal database, and a fault disposal strategy is obtained through data mapping matching;
[0014] The implicit fault characteristics of the SVG in a normal operation condition in the test set are valued and input into the trained BP neural network model, the fault code value is calculated, the fault code value is decoded to obtain the implicit fault of the SVG in a normal operation condition, and the corresponding processing is performed based on the implicit fault.
[0015] Further, the data cleaning, data normalization, data standardization and feature engineering of the operating parameter data are specifically as follows:
[0016] Data cleaning, including missing value processing, repeated value processing, abnormal value processing and error value processing;
[0017] Data normalization, the formula is:
[0018]
[0019] Wherein, x is the original sample data, x min is the minimum value in the sample data, x max is the maximum value in the sample data, and y is the normalized data;
[0020] Data standardization, including time series data standardization and data format standardization;
[0021] Feature engineering, including feature selection and feature combination construction.
[0022] Further, the feature extraction of the preprocessed operating parameter data is specifically as follows:
[0023] Time domain feature extraction, including average value calculation, effective value calculation, value and peak-peak value determination, variance and standard deviation calculation;
[0024] Frequency domain feature extraction, including frequency spectrum analysis, power spectrum density calculation and harmonic analysis;
[0025] Time-frequency domain feature extraction, specifically using wavelet transform analysis;
[0026] Event-based feature extraction, including fault event features and operation event features;
[0027] Correlation feature extraction, including device correlation features and time correlation features.
[0028] Further, the keyword extraction of the process data is specifically as follows:
[0029] Data cleaning is performed on the text content of the process data to remove redundant spaces, punctuation and abnormal characters in the text;
[0030] Syntax analysis is performed on the text content after data cleaning, including classifying Chinese nouns and technical English nouns;
[0031] Part-of-speech tagging is performed on the text, and the tagged words are matched with a pre-established vocabulary to obtain initial keywords;
[0032] The initial keywords are removed of stop words, merged with synonyms and the weights of the keywords are adjusted, wherein the weight order is maintenance object noun > maintenance action word > parameter quantity word.
[0033] Further, the extracted processing process data keywords and fault result data are subjected to keyword extraction, the extracted keywords are encoded, and the encoded processing process data and fault result data are mapped, specifically:
[0034] The Unicode encoding corresponding to each Chinese character is queried for the processing process data keywords, and the Unicode encoding is converted into binary;
[0035] The Unicode encoding is converted into binary using dictionary encoding technology for data compression;
[0036] The encoded processing process data keywords and fault result data are mapped as an array.
[0037] Further, the fault prediction model of the LSTM neural network is constructed, and the improved genetic algorithm is used for optimization, and the training set data is input into the LSTM model for model training, specifically:
[0038] The constructed LSTM model includes an input layer, a hidden layer and an output layer, wherein the input layer is provided with at least 10 neurons, the hidden layer is three layers, the output layer is provided with at least 5 neurons, and Softmax is used as the activation function; a full connection layer is added, and a Dropout layer is added before the full connection layer to prevent overfitting;
[0039] An evaluation function of the improved genetic algorithm is constructed, a population is initialized using binary encoding, and various parameters are set; a fitness function is set, the fitness values of individuals are calculated, and the individual with the maximum fitness is retained; it is judged whether the algorithm ending condition is met, if the convergence condition is met, the result is output, otherwise, the crossover operation, mutation operation and selection operation are performed; it is judged whether the result of the selection operation meets the algorithm ending condition, and if the result meets the algorithm ending condition, the algorithm is ended;
[0040] The constructed LSTM neural network model is used as the main architecture of the fault prediction model, the number of input layers is set to 3, and the output layer outputs a state matrix; RMSE is determined as the error evaluation standard, and RMSE is also used as the evaluation function of the improved genetic algorithm;
[0041] The improved genetic algorithm is used to dynamically calculate the fitness value of the step length of each LSTM training, and the step length with the optimal fitness value is determined as the LSTM neural network training step length;
[0042] The running parameter data in the training set is taken as input, the fault result data corresponding to the running parameter data in the training set is taken as output, cross entropy is taken as a loss function of the model, and the loss function and the improved genetic algorithm are used for training, the weights between the neurons are continuously adjusted according to the value of the loss function, so that the value of the loss function gradually decreases.
[0043] After each complete training data set traversal, the loss function value of the verification set is recorded, the loss function value is checked, when the loss function value meets the set threshold, the training is ended, and the trained LSTM neural network model is obtained.
[0044] Further, the cross entropy loss function is specifically:
[0045]
[0046] Y is the true label of the jth sample, j Y is the true label of the jth sample, Y is the predicted probability of the jth sample, Y is the calculation result of the cross entropy loss function, used for quantifying the overall error between the model prediction result and the sample true label, and N is the total number of samples participating in the loss calculation.
[0047] Further, the fault handling strategy is obtained through data mapping matching, and the mapping matching based on a dictionary or a lookup table is adopted to obtain the fault handling strategy.
[0048] Further, the running parameter data includes, and the fault result data includes but is not limited to overcurrent, overvoltage, overtemperature, IGBT module damage, communication failure, control failure, and the running parameter data includes but is not limited to SVG output voltage value, SVG output current value, SVG reactive power output, SVG power factor, SVG operating temperature, and SVG operating environment parameter.
[0049] The application further provides a diagnosis system for realizing the above-mentioned neural network-based static var generator fault diagnosis method, and the diagnosis system comprises:
[0050] A data acquisition unit is configured to acquire running parameter data of a static var generator (SVG) in a fault state and a normal state during SVG operation, record corresponding processing process data and fault result data in the fault state, acquire compensation current data of the SVG in a normal operation condition, and establish a fault diagnosis database.
[0051] A data preprocessing unit is configured to preprocess data in the fault diagnosis database, and the preprocessing includes:
[0052] The operation parameter data is subjected to data cleaning, data normalization, data standardization and feature engineering processing; the preprocessed operation parameter data is subjected to feature extraction, and a feature extraction model is established to extract key features reflecting the running state of the SVG;
[0053] The process data and the fault result data are subjected to keyword extraction, the extracted keywords are coded, and the coded process data and the fault result data are mapped to establish a fault handling database;
[0054] The compensation current data of the SVG under normal running conditions is subjected to amplitude and phase feature extraction of the fundamental wave and each harmonic of the compensation current when the SVG has a single tube open circuit fault through Fourier transform, and hidden fault feature recognition is performed;
[0055] The prediction model construction unit is used to construct an LSTM model data set based on the preprocessed operation parameter data and the operation result data in the fault diagnosis database, including a training set, a validation set and a test set, which are divided in a ratio of 70:15:15, then a fault prediction model of an LSTM neural network is constructed, and the training set data is input into the LSTM model for model training; at the same time, based on the hidden fault features recognized by the SVG under normal running conditions, the hidden fault features are valued and coded, and the hidden fault feature values are normalized, a BP neural network model is established, and the hidden fault feature normalized values and the fault codes are used for BP neural network model training;
[0056] The explicit fault diagnosis unit inputs the operation parameter data in the test set into the trained LSTM model, uses a Softmax classifier to recognize whether a fault occurs and performs multi-classification division of the fault category, respectively obtains a confidence vector data of fault diagnosis, wherein the category corresponding to the highest confidence in the vector data is the diagnosis result, the diagnosis result is input into the fault handling database, and a fault handling strategy is obtained through data mapping matching;
[0057] The hidden fault diagnosis unit inputs the hidden fault features of the SVG under normal running conditions in the test set after being valued into the trained BP neural network model, calculates the fault code value, decodes the fault code value to obtain the hidden fault of the SVG under normal running conditions, and performs corresponding processing based on the hidden fault.
[0058] The beneficial effects of the above technical solutions of the present application are as follows:
[0059] 1. The application is based on the operating parameter data of SVG in fault state and normal state, and the corresponding processing process data and fault result data in fault state, to build a diagnosis database. The pre-processed operating parameter data and operating result data in the fault diagnosis database construct the LSTM model data set, then the LSTM model is constructed and the training set data is input into the LSTM model for model training, then the operating parameter data in the test set is input into the trained LSTM model, the Softmax classifier is used to identify whether a fault occurs and to perform fault category multi-classification division, and the confidence vector data of fault diagnosis is obtained respectively, wherein the class corresponding to the highest confidence in the vector data is the diagnosis result, and finally the diagnosis result is input into the fault disposal database to obtain the fault disposal strategy through data mapping matching. The neural network model is constructed and trained, the SVG operating parameter data is diagnosed, the efficiency of SVG fault diagnosis is improved, the fault disposal strategy can be automatically given, which is helpful for assisting to quickly eliminate faults.
[0060] 2. The application performs different preprocessing measures on the SVG operating parameter data and the corresponding processing process data and fault result data in fault state before the neural network model is constructed and trained; wherein the operating parameter data is processed by data cleaning, data normalization, data standardization and feature engineering; the pre-processed operating parameter data is feature extracted, the key features reflecting the SVG operating state are extracted by establishing a feature extraction model; finally, the key words of the processing process data and the fault result data are extracted, the extracted key words are encoded, and the encoded processing process data and fault result data are mapped to construct a fault disposal database. Through these pre-processing, the accuracy of neural network model construction and training and the data processing efficiency are improved.
[0061] 3. In addition to predicting the obvious faults of SVG, the application is also based on the compensation current data of SVG in normal operation, and the amplitude and phase of the compensation current fundamental wave and each harmonic when a single tube open circuit fault occurs in SVG are extracted by Fourier transform for implicit fault feature recognition. And based on the implicit fault feature data, a BP neural network model is constructed and trained to predict implicit faults, providing technical support for implicit fault prediction of SVG in normal operation, making the SVG operation more reliable.
[0062] 4. When the LSTM model is constructed and trained, the improved genetic algorithm is introduced to dynamically adjust the training step length of the neural network, giving different training step lengths to the neural network at different times, thereby reducing the training error and improving the prediction accuracy. BRIEF DESCRIPTION OF DRAWINGS
[0063] Figure 1Flow chart of the neural network-based static var generator fault diagnosis method of the present application;
[0064] Figure 2 Principle block diagram of the neural network-based static var generator fault diagnosis system of the present application;
[0065] Figure 3 Circuit principle diagram of the prior art three-level SVG reactive power compensation system;
[0066] Figure 4 Specific circuit diagram of the three-level converter of the present application. Figure 3 Specific circuit diagram of the three-level converter of the present application. DETAILED DESCRIPTION
[0067] In order to make the technical problems, technical solutions and advantages of the present application clearer, the following will be described in detail with reference to the accompanying drawings and specific embodiments.
[0068] As shown in Figure 1 , the present application proposes a neural network-based static var generator fault diagnosis method, comprising the following steps:
[0069] S1, collecting the operating parameter data of the static var generator (SVG) in the fault state and the normal state during operation, recording the corresponding processing process data and fault result data in the fault state, collecting the compensation current data of the SVG in the normal operation condition, and establishing a fault diagnosis database;
[0070] S2, pre-processing the data in the fault diagnosis database, comprising:
[0071] processing the operating parameter data through data cleaning, data normalization, data standardization and feature engineering; extracting the features of the pre-processed operating parameter data, and extracting the key features reflecting the operating state of the SVG through the establishment of a feature extraction model;
[0072] extracting the keywords of the processing process data and the fault result data, encoding the extracted keywords, establishing a mapping between the encoded processing process data and the fault result data, and constructing a fault disposal database;
[0073] extracting the amplitude and phase features of the compensation current fundamental wave and each harmonic of the SVG when a single tube open circuit fault occurs through Fourier transform on the compensation current data of the SVG in the normal operation condition, and identifying the hidden fault features;
[0074] S3, based on the pre-processed operating parameter data and operating result data in the fault diagnosis database, an LSTM model data set is constructed, including a training set, a validation set and a test set, which are divided according to the proportion of 70%:15%:15%, then a fault prediction model of the LSTM neural network is constructed, and the training set data is input into the LSTM model for model training; at the same time, based on the hidden fault features identified by the SVG under normal operation, the hidden fault features are valued, coded, and the hidden fault feature values are normalized, a BP neural network model is established, and the hidden fault feature normalized values and fault codes are used for BP neural network model training;
[0075] S4, input the operating parameter data in the test set into the trained LSTM model, use the Softmax classifier to identify whether a fault occurs and perform fault category multi-classification division, and obtain a confidence vector data of fault diagnosis, wherein the class corresponding to the highest confidence in the vector data is the diagnosis result, the diagnosis result is input into the fault disposal database, and a fault disposal strategy is obtained through data mapping matching;
[0076] S5, input the hidden fault features of the SVG under normal operation after being valued in the test set into the trained BP neural network model, calculate the fault code value, perform fault code value decoding to obtain the hidden fault of the SVG under normal operation, and perform corresponding processing based on the hidden fault.
[0077] The specific implementation process of the above steps is described in detail as follows:
[0078] The SVG operating parameter data in step S1 includes, and the fault result data includes but is not limited to overcurrent, overvoltage, overtemperature, IGBT module damage, communication failure, control failure, operating parameter data includes but is not limited to SVG output voltage value, SVG output current value, SVG reactive power output, SVG power factor, SVG operating temperature, SVG operating environment parameter.
[0079] The processing process data is the disposal method used when the above SVG fault occurs. Before establishing the database, the fault disposal process is input, such as "in the case that the IGBT module is not damaged, disconnect the external connection of the IGBT module, use the diode file and resistance file of the multimeter to measure the G-E and C-E terminals of the IGBT module, and generally the fault IGBT can be found by comparison", "check whether the collector plug-in terminal on the unit drive board side and the IGBT side is loose"
[0080] Fault result data, including the definition of fault type after fault disposal, such as XX overcurrent, XX overvoltage, XX overtemperature, IGBT module damage, XX communication fault, XX control fault, wherein "XX" represents the name of the object.
[0081] Step S2 performs data cleaning, data normalization, data standardization, and feature engineering processing on the operation parameter data, specifically:
[0082] (I) Data cleaning, including missing value processing, duplicate value processing, outlier value processing, and error value processing, which is the process of reviewing and verifying the collected data, aiming to identify and correct errors, missing values, duplicate data, outliers, and other problems in the data to improve data quality, wherein:
[0083] (1) Missing value processing includes:
[0084] Identify missing values: Determine which data is missing by checking if there are null values (such as empty cells in a table) or specific placeholders (such as "NA", "NULL", etc.) in the data set.
[0085] Fill in missing values: including mean, median or mode filling, for numerical data, the mean, median of the column data can be used to fill in missing values; for categorical data, the mode (the value with the most occurrences) can be used to fill in.
[0086] (2) Processing duplicate data
[0087] Identify duplicate data: Find records that are identical (all column values are the same) or have the same values in key columns by comparing each record in the data set.
[0088] Delete duplicate data: Generally, one record is retained and the remaining duplicate records are deleted to reduce data redundancy and avoid bias affecting the results in subsequent analysis.
[0089] (3) Processing error data
[0090] Format error: For example, the date format should be "YYYY-MM-DD", but some data records have other incorrect formats such as "DD-MM-YYYY", which need to be converted to the correct format. For example, a column should be numerical data, but some text data is mixed in, which needs to be converted to numerical data (if possible) or processed accordingly (such as deleting error data records).
[0091] (4) Processing outliers
[0092] If the abnormal value is caused by data entry errors or other reasons, and has a greater impact on the analysis results, it can be considered for deletion. If it can be determined that the abnormal value is due to special circumstances but not error (such as a power outage caused by an external sudden unexpected cause), it can be tried to be corrected by reasonable methods, such as taking the average of the normal data near the abnormal value to replace the abnormal value.
[0093] Through effective data cleaning, the data can be more accurate, complete and standardized, thereby providing a reliable basis for subsequent deeper data analysis, data mining and data-based decision-making.
[0094] (II) Data normalization, the formula is:
[0095]
[0096] Where x is the original sample data, x min is the minimum value in the sample data, x max is the maximum value in the sample data, and y is the normalized data. Through linear transformation of the original data, the value range of the data can meet the specific requirements, such as unifying the original data characteristics of different orders of magnitude and different value ranges to a new value range that is standard and convenient for comparison and subsequent processing. For example, after normalizing the voltage amplitude related to SVG fault diagnosis, the neural network can consistently process these data, avoiding the excessive influence of features with large values on the training results.
[0097] (III) Data standardization, including time series data standardization and data format standardization.
[0098] Time series data standardization. For time series data in power systems (such as power load changes over time, voltage fluctuation sequences, etc.), moving average, difference, and other methods can be used for standardization. Moving average can smooth short-term fluctuations in data, and difference can remove the trend of data. For example, for power load time series, 3-hour moving average can be used to obtain a smoother load curve, and then difference processing (current load minus previous load) can be performed to convert non-stationary time series into stationary sequences, facilitating neural network learning of their dynamic change rules.
[0099] Data format standardization ensures that the formats of different sources of power data are consistent. For example, the format of the timestamp should be unified, and some data timestamps are in the format of "year-month-day-hour: minute: second", while others are in the form of numerical representation of the timestamp, which needs to be unified. At the same time, the units of the data should also be standardized, such as power units unified to kilowatts (kW) or megawatts (MW), voltage units unified to kilovolts (kV), etc. This can avoid neural network training errors caused by data format confusion.
[0100] (iv) Feature engineering, including feature selection and feature combination construction, in which:
[0101] Feature selection, selecting the most valuable features for neural network training from numerous power data features. In SVG fault prediction, in addition to power parameter data, external environmental data (temperature, humidity, dust, etc.) may have important influence on the effect of failure. Features with high correlation with target variables (such as failure probability) can be selected through correlation analysis (such as calculating Pearson correlation coefficient). For features with low correlation, they can be discarded to reduce data dimension and improve the training efficiency of neural network.
[0102] Feature combination construction, combining or constructing new features from original power data features. For example, when analyzing the power system stability of SVG performing power compensation, the voltage amplitude and phase angle are combined into a complex voltage vector as a new feature. Or according to the operating principle of power equipment, new features are constructed, such as for transformers, the product of load rate (actual load power to rated power) and oil temperature change rate is constructed as a new feature to reflect the comprehensive operating state of the transformer.
[0103] Step S2 extracts features from the preprocessed operating parameter data, specifically including:
[0104] Time domain feature extraction, including mean value calculation, effective value calculation, value and peak-to-peak value determination, variance and standard deviation calculation, the specific content is not described;
[0105] Frequency domain feature extraction, including spectrum analysis, power spectral density calculation, harmonic analysis, the specific content is not described;
[0106] Time-frequency domain feature extraction, specifically using wavelet transform analysis; wavelet transform has the characteristics of multi-resolution analysis, which can analyze the time-frequency characteristics of the signal at different scales (corresponding to different scaling factors), which can capture high-frequency detail information of the signal and analyze low-frequency trend information of the signal.
[0107] Event-based feature extraction, including fault event features and operation event features, such as external grid failure and non-standard operation factors, which all affect the normal work of SVG;
[0108] Correlation feature extraction, including device correlation features and time correlation features, such as device state information related to SVG power compensation and device operating period features, which all indirectly affect the working performance of SVG.
[0109] In step S2, keyword extraction is performed on the process data, specifically:
[0110] Data cleaning is performed on the text content of the process data to remove redundant spaces, punctuation marks and abnormal characters in the text. For example, multiple spaces in the text are replaced by a single space, and some meaningless special characters (such as tab, line feed, etc.) are deleted unless they have specific meanings in the text.
[0111] Syntax analysis is performed on the text content after data cleaning, including classification of Chinese nouns and technical English nouns. Through syntax analysis, professional and technical nouns existing in the process data are mainly distinguished to avoid interference of these nouns on subsequent data training.
[0112] Word part-of-speech tagging is performed on the text to match the tagged words with a pre-established vocabulary table to obtain initial keywords. Word part-of-speech tagging is performed on the text to determine the part-of-speech of each word (such as noun, verb, adjective, etc.), and then the keywords are determined according to specific rules.
[0113] The initial keywords are removed from the stop words, merged with the synonyms, and the keyword weights are adjusted, in which the weight order is maintenance object noun > maintenance action word > parameter quantity word. By adjusting the keyword weight, the steps that play a key role in daily fault handling can be quickly located, which is conducive to improving the accuracy of model training. The most critical thing in the maintenance process is to first locate the object, and then how to maintain the work, and the parameter quantity can be obtained by on-site debugging or testing.
[0114] In step S2, the extracted process data keywords and fault result data are extracted, the extracted keywords are encoded, and the encoded process data and fault result data are mapped, specifically as follows:
[0115] The Unicode encoding corresponding to each Chinese character is queried for the process data keywords, and the Unicode encoding is converted into binary. Unicode (Unified Code, Universal Code, Single Code) is an industry standard in the field of computer science, which organizes and encodes most of the world's writing systems, so that computers can process and display characters in multiple languages.
[0116] The Unicode encoding is converted into binary using dictionary encoding technology for data compression. Because the binary data after conversion of the text keywords is relatively large, data compression can effectively store and transmit data, thereby reducing the computing load and improving the efficiency of the algorithm.
[0117] The coded processing process data keywords and fault result data are mapped to an array, which provides support for finding the corresponding solution strategy through the fault result after diagnosing the fault result through the neural network. In a specific real-time, an array containing the SVG fault handling process is defined, and each SVG fault handling process after processing has different keyword attributes (such as recovery, replacement, welding, overcurrent, and overvoltage). Through array mapping, a function is defined, which is associated with the fault result. According to the new fault handling requirements, the attributes of each SVG fault handling process are recombined or adjusted, thereby converting it into a mapping array of another situation, such as replacing the keyword attribute "replacement" with "welding" to meet the requirements of this situation.
[0118] In step S3, a fault prediction model of an LSTM neural network is constructed, and is optimized based on an improved genetic algorithm. The training set data is input into the LSTM model for model training. Specifically:
[0119] The constructed LSTM model includes an input layer, a hidden layer, and an output layer. The input layer is provided with at least 10 neurons, the hidden layer is three layers, and the output layer is provided with at least 5 neurons. Softmax is used as the activation function. A fully connected layer is added, and a Dropout layer is added before the fully connected layer to prevent overfitting.
[0120] An evaluation function of the improved genetic algorithm is constructed. The population is initialized by binary coding, and each parameter is set. The fitness function is set, the fitness value of each individual is calculated, and the individual with the maximum fitness is retained. It is judged whether the algorithm ending condition is met. If the convergence condition is met, the result is output. Otherwise, the crossover operation, mutation operation, and selection operation are performed. It is judged whether the result of the selection operation meets the algorithm ending condition. If the result is met, the algorithm is ended.
[0121] The constructed LSTM neural network model is used as the main architecture of the fault prediction model. The number of input layers is set to 3, and the output layer outputs a state matrix. RMSE is determined as the error evaluation standard, and RMSE is also used as the evaluation function of the improved genetic algorithm.
[0122] The improved genetic algorithm is used to dynamically calculate the fitness value of the step length of each LSTM training. The step length with the optimal fitness value is determined as the LSTM neural network training step length.
[0123] The running parameter data in the training set is used as the input, and the fault result data corresponding to the running parameter data in the training set is used as the output. Cross-entropy is used as the loss function of the model. The model is trained according to the loss function and the improved genetic algorithm. The weights between the neurons are constantly adjusted according to the value of the loss function, so that the value of the loss function gradually decreases.
[0124] After each complete training data set traversal, record the loss function value of the validation set, check the loss function value, when the loss function value meets the set threshold, the training is completed, and the trained LSTM neural network model is obtained.
[0125] The cross-entropy loss function is specifically:
[0126]
[0127] Y j is the true label of the jth sample, is the predicted probability of the jth sample, is the calculation result of the cross-entropy loss function, used to quantify the overall error between the model prediction result and the sample true label, and N is the total number of samples participating in loss calculation.
[0128] From the perspective of information theory, cross-entropy can be understood as a measure of the "distance" between two probability distributions. In a classification task, the probability distribution of the true label is determined (one-hot encoding has only one class probability of 1, and the rest is 0), and the model predicts an estimated probability distribution. The cross-entropy loss function is to make the model's predicted probability distribution as close as possible to the true probability distribution. When the model's predicted probability distribution is exactly the same as the true probability distribution, the cross-entropy loss value is 0. And the greater the difference between the two, the greater the cross-entropy loss value, which prompts the model to continuously adjust the parameters to reduce the loss value, thereby improving the prediction accuracy.
[0129] Step S3 values and encodes the latent fault features identified by the SVG under normal operating conditions, normalizes the latent fault feature values, establishes a BP neural network model, and trains the BP neural network model based on the normalized latent fault feature values and fault codes, specifically:
[0130] When an IGBT open circuit fault occurs, the SVG can still operate with the fault for a period of time, and the fault may not be detected for a long time. However, "running with disease" cannot effectively provide reactive current to the power grid, and at the same time causes DC bus capacitor voltage fluctuation, affecting the performance of compensation, so the present application defines the diagnosis of SVG latent fault.
[0131] The IGBT fault type is generally divided into open circuit fault and short circuit fault, wherein the causes of the IGBT open circuit fault are mainly divided into overcurrent burnout and drive circuit breaking. In the power electronic circuit, one fuse is connected in series with each IGBT, when the IGBT has a short circuit fault, the current of the faulty IGBT branch is too large, and the fuse connected in series will be burned out in a very short time, so the short circuit fault of the IGBT finally appears as an open circuit fault. Therefore, the IGBT faults considered by the present application are all open circuit faults.
[0132] When the IGBT has an open circuit fault, the AC voltage waveform output by the diode clamped three-level topology will be obviously distorted, and when different power tubes have faults, the voltage waveform distortion shapes have their own characteristics, therefore, the output voltage of the three-level inverter can reflect the running state of the system. Since the SVG outputs a multi-level voltage when working, which is converted into an output compensation current, therefore, the running state of the IGBT can also be reflected by detecting the compensation current. Similarly, the compensation current output by the three-level topology changes the phase and harmonics of the grid current, so when the SVG has an IGBT open circuit fault, the grid current will also be distorted. Since three current sensors are needed when the SVG system current is tracked, and if the voltage signal is selected as the fault sampling point, the system needs to additionally add a voltage Hall to sample the phase voltage or line voltage, this method not only increases the cost, but also occupies hardware space, therefore, the present application selects the three-phase compensation current as the fault sampling point of the three-level SVG. As shown in the figure, Figure 3 it is a three-level SVG reactive power compensation system circuit principle diagram of the prior art, Figure 4 it is Figure 3 a specific circuit diagram of the three-level converter, and the three-level converter is the core executive device of the SVG for reactive power compensation, wherein S1a, S2a, S3a, S4a and S1b, S2b, S3b, S4b as well as S1c, S2c, S3c, S4 are IGBT devices.
[0133] According to the test, when the A-phase has a single tube open circuit fault, not only the waveform of the faulty phase is distorted, but also the current of the non-faulty phase is affected. When S1a is faulty, the negative half cycle current waveform is basically unchanged, and the positive half cycle only works normally for half the time; when S2a is faulty, the positive half cycle has almost no waveform output, and the negative half cycle waveform is basically unchanged; when S3a is faulty, the negative half cycle has almost no current waveform, and the positive half cycle is basically unchanged; when S4a is faulty, the positive half cycle current amplitude is basically unchanged, and the negative half cycle only works normally for half the time. According to the analysis, the waveforms of each fault condition have their own characteristics, the SVG compensation current can be used as the fault sampling point, and then the FFT analysis of the fault condition is carried out for the extraction of the fault parameters.
[0134] Therefore, the application firstly extracts the amplitude and phase characteristics of the fundamental wave and each harmonic of the compensation current of the SVG when a single tube open-circuit fault occurs through Fourier transform FFT on the compensation current data of the SVG under normal operation, and performs implicit fault feature recognition. At the same time, based on the implicit fault feature recognized by the SVG under normal operation, the implicit fault feature is valued, coded, and the implicit fault feature value is normalized, a BP neural network model is established, and the BP neural network model is trained based on the normalized value of the implicit fault feature and the fault code.
[0135] Under general conditions, after FFT analysis to obtain the amplitude and phase angle, the amplitude and phase of the first two harmonics (including the DC component) can be used to identify the fault characteristics. In order to further improve the accuracy of diagnosis, the application selects the A, B and C three-phase compensation currents as the fault characteristic sampling points, and extracts the DC component D, the fundamental wave amplitude Al, the fundamental wave phase angle Bl and the second harmonic phase angle B2 of each phase current as the fault characteristic signals. For the convenience of analysis, according to the fault tube number, 12 kinds of fault states can be divided, and the SVG system without fault under normal operation is regarded as a special fault state, so there are 13 kinds of fault states in total. Each fault state is composed of 12 characteristic values, and before the neural network training of the fault waveform characteristic values, the fault coding of each fault condition is required, and then the 12 characteristic values of each fault state are normalized, and then the BP neural network model is established with the corresponding fault code.
[0136] Step S4 inputs the operating parameter data in the test set into the trained LSTM model, uses a Softmax classifier to identify whether a fault occurs and perform multi-classification division of the fault category, and obtains a confidence vector data of the fault diagnosis, wherein the category corresponding to the highest confidence in the vector data is the diagnosis result.
[0137] In a multi-class classification problem, our goal is to divide the input data into multiple different categories. For example, in an image classification task, the input image is to be judged as a cat, a dog, a rabbit, etc. different animal categories; in the text classification task of the application, the input text is to be divided into different categories such as voltage fault, current fault, temperature fault, communication fault, etc.
[0138] The Softmax classifier makes classification decisions based on probability distribution, which converts the output values of the last layer (output layer) of the neural network into probability values corresponding to each class, and then determines the class to which the input data belongs according to these probability values. First, the input data is processed by the previous layers (such as the input layer, the hidden layer, etc.) of the neural network to extract features and perform nonlinear transformations, etc. This part of the calculation is similar to the general neural network calculation process, which gradually converts the original input data into a feature representation more suitable for classification decisions through weighted summation between neurons in each layer and the action of the activation function. After processing by the previous layers, the data reaches the output layer. Assuming that the output layer has N neurons, corresponding to N possible classes. For each input data, the output value of each neuron in the output layer after processing by the neural network is denoted as z j (j = 1, 2, …, N). Next, the output values z j of the output layer are converted into probability values corresponding to each class by applying the Softmax function. The calculation formula of the Softmax function is as follows:
[0139]
[0140] where p j is the probability that the input data is judged to be class j, and e is the base of the natural logarithm (approximately equal to 2.71828). That is, by the Softmax function, the original output values z j of the output layer are normalized, so that the probability values p j corresponding to all classes sum to 1, and a probability distribution about the possibility of each class is obtained.
[0141] According to the obtained probability values p j corresponding to each class, a classification decision is made. The present application adopts the maximum probability decision: the class with the maximum probability value is selected as the class to which the input data belongs. That is, if for a certain input data, the probability value obtained after processing by the Softmax function is p k is the maximum (where k is the index of a certain class), then it is determined that the input data belongs to class k.
[0142] Finally, the diagnostic result is input into a fault handling database, and a fault handling strategy is obtained through data mapping matching, and the mapping matching is based on a dictionary or a lookup table. The dictionary contains a series of keys and corresponding values. In the dictionary-based mapping matching, according to a known key-value pair relationship, the input data element is compared with the keys in the dictionary, and after the matching key is found, the corresponding value is obtained, so as to realize data mapping and matching. The lookup table (LUT) is essentially a pre-defined data structure, which is used to store the corresponding relationship between specific data elements, so as to quickly perform mapping matching operation in the subsequent processing process, and find the output result corresponding to the input data.
[0143] Step S5 inputs the implicit fault characteristics of the SVG in the normal operation condition in the test set into the trained BP neural network model, calculates the fault code value, decodes the fault code value to obtain the implicit fault of the SVG in the normal operation condition, and processes based on the implicit fault. This is the implicit fault diagnosis step of the SVG, based on the trained BP neural network model in step S3, by inputting the implicit fault characteristic assignment data of the SVG in the normal operation condition in the test set, the fault prediction can be realized. Since the fault handling type is less, the application does not independently establish a corresponding handling strategy database.
[0144] As shown in Figure 2 The application further provides a diagnosis system for realizing the above-mentioned SVG fault diagnosis method based on a neural network, which comprises:
[0145] The data acquisition unit 101 is used for acquiring the operation parameter data of the SVG in the fault state and the normal state during operation, recording the corresponding processing process data and fault result data in the fault state, acquiring the compensation current data of the SVG in the normal operation condition, and establishing a fault diagnosis database;
[0146] The data preprocessing unit 102 is used for preprocessing the data in the fault diagnosis database, including:
[0147] The operation parameter data is subjected to data cleaning, data normalization, data standardization and feature engineering processing; the preprocessed operation parameter data is subjected to feature extraction, and a feature extraction model is established to extract key features reflecting the SVG operation state;
[0148] The key words of the processing process data and the fault result data are extracted, the extracted key words are coded, the coded processing process data and the fault result data are mapped, and a fault handling database is constructed;
[0149] The compensation current data of the SVG in the normal operation condition is subjected to Fourier transform to extract the amplitude and phase of the fundamental wave and each harmonic of the compensation current of the SVG when a single tube open circuit fault occurs, and hidden fault feature recognition is performed.
[0150] The prediction model construction unit 103 is configured to construct an LSTM model data set including a training set, a validation set and a test set based on the preprocessed operation parameter data and operation result data in the fault diagnosis database, divide the sets according to a ratio of 70%:15%:15%, then construct a fault prediction model of an LSTM neural network, optimize the model based on an improved genetic algorithm, and input the training set data into the LSTM model for model training; at the same time, based on the hidden fault features identified by the SVG in the normal operation condition, the hidden fault features are assigned and coded, and the hidden fault feature values are normalized, a BP neural network model is established, and the model is trained based on the normalized hidden fault feature values and the fault codes;
[0151] The explicit fault diagnosis unit 104 inputs the operation parameter data in the test set into the trained LSTM model, uses a Softmax classifier to identify whether a fault occurs and perform multi-classification division of the fault category, and respectively obtains a confidence vector data of the fault diagnosis, wherein the category corresponding to the highest confidence in the vector data is the diagnosis result, the diagnosis result is input into the fault disposal database, and a fault disposal strategy is obtained through data mapping matching;
[0152] The hidden fault diagnosis unit 105 inputs the hidden fault features of the SVG in the normal operation condition after being assigned in the test set into the trained BP neural network model, calculates the fault code value, decodes the fault code value to obtain the hidden fault of the SVG in the normal operation condition, and performs corresponding processing based on the hidden fault.
[0153] The above modules are based on the content of the neural network-based static reactive power generator fault diagnosis method in specific operation, which is not described here.
[0154] The above is the preferred embodiment of the present application. It should be noted that for those skilled in the art, without departing from the principles of the present application, several improvements and refinements can be made, which should also be considered within the scope of protection of the present application.
Claims
1. A neural network-based static var generator fault diagnosis method, characterized by, The method comprises the following steps: Collecting running parameter data of a static var generator (SVG) in a fault state and a normal state during operation, recording corresponding processing process data and fault result data in the fault state, collecting compensation current data of the SVG in a normal operation condition, and establishing a fault diagnosis database; Pretreating data in the fault diagnosis database, including: Performing data cleaning, data normalization, data standardization, and feature engineering processing on the running parameter data; performing feature extraction on the pretreated running parameter data; and extracting key features reflecting the running state of the SVG by establishing a feature extraction model; Extracting keywords from the processing process data and the fault result data, encoding the extracted keywords, establishing a mapping relationship between the encoded processing process data and the fault result data, and constructing a fault disposal database; Performing feature extraction on amplitudes and phases of a compensation current fundamental wave and each harmonic of the SVG when a single-tube open-circuit fault occurs to the SVG by Fourier transform, and performing implicit fault feature recognition; Constructing an LSTM model data set based on the pretreated running parameter data and the running result data in the fault diagnosis database, including a training set, a verification set, and a test set, and dividing the sets according to a 70:15:15 ratio, then constructing an LSTM neural network fault prediction model, optimizing the model based on an improved genetic algorithm, and inputting the training set data into the LSTM model for model training; at the same time, based on the implicit fault feature recognized by the SVG in the normal operation condition, assigning values to the implicit fault feature, encoding the implicit fault feature, normalizing the implicit fault feature values, establishing a BP neural network model, and training the BP neural network model based on the implicit fault feature normalized values and the fault codes; Inputting the running parameter data in the test set into the trained LSTM model, using a Softmax classifier to identify whether a fault occurs and to perform multi-classification division of fault categories, and obtaining a confidence vector data of fault diagnosis, wherein a category corresponding to the highest confidence in the vector data is the diagnosis result; inputting the diagnosis result into the fault disposal database, and obtaining a fault disposal strategy through data mapping matching; Inputting the implicit fault feature of the SVG in the normal operation condition in the test set into the trained BP neural network model after assigning values to the implicit fault feature, calculating fault code values, decoding the fault code values to obtain an implicit fault of the SVG in the normal operation condition, and performing corresponding processing based on the implicit fault. 2.The neural network-based static var generator fault diagnosis method according to claim 1, characterized in that, The data cleaning, data normalization, data standardization, and feature engineering processing on the running parameter data are specifically: Data cleaning, including missing value processing, repeated value processing, abnormal value processing, and error value processing; Data normalization, the formula being: Wherein, x is the original data of the sample, x min is the minimum value in the sample data, x max is the maximum value in the sample data, and y is the normalized data; Data standardization, including time series data standardization and data format standardization; Feature engineering, including feature selection and feature combination construction. 3.The neural network-based static var generator fault diagnosis method according to claim 1, characterized in that, The feature extraction on the pretreated running parameter data specifically includes: Time domain feature extraction, including average value calculation, effective value calculation, value and peak-to-peak value determination, variance and standard deviation calculation; Frequency domain feature extraction, including spectral analysis, power spectral density calculation, harmonic analysis; Time-frequency domain feature extraction, specifically using wavelet transform analysis; Event-based feature extraction, including fault event features and operation event features; Correlation feature extraction, including device correlation features and time correlation features. 4.The neural network-based static var generator fault diagnosis method according to claim 1, characterized in that, The keyword extraction of the processing process data specifically includes: Data cleaning of the text content of the processing process data to remove redundant spaces, punctuation, and abnormal characters in the text; Syntax analysis of the data cleaned text content, including classification of Chinese nouns and technical English nouns; Part-of-speech tagging of the text, matching the tagged words with a pre-established vocabulary to obtain initial keywords; Removing stop words, merging synonyms, and adjusting keyword weights from the initial keywords, with the weight order being maintenance object nouns > maintenance action words > parameter quantity words. 5.The neural network based static var generator fault diagnostic method of claim 1, wherein, The keyword extraction of the extracted processing process data keywords and fault result data, encoding of the extracted keywords, and mapping of the encoded processing process data and fault result data specifically includes: Querying the Unicode encoding corresponding to each Chinese character for the processing process data keywords, and converting the Unicode encoding to binary; Using dictionary encoding technology for data compression when converting Unicode encoding to binary; Mapping the encoded processing process data keywords and fault result data as arrays. 6.The neural network based static var generator fault diagnostic method of claim 1, wherein, The construction of the LSTM neural network fault prediction model, the optimization based on the improved genetic algorithm, and the input of the training set data into the LSTM model for model training specifically include: The constructed LSTM model includes an input layer, a hidden layer, and an output layer, with at least 10 neurons in the input layer, three layers in the hidden layer, and at least 5 neurons in the output layer, using Softmax as the activation function; and adding a fully connected layer, adding a Dropout layer before the fully connected layer to prevent overfitting; The evaluation function of the improved genetic algorithm is constructed, the population is initialized using binary encoding, and the parameters are set; the fitness function is set, the fitness values of each individual are calculated, and the individual with the maximum fitness is retained; the algorithm termination condition is judged, if the convergence condition is met, the result is output, otherwise the crossover operation, mutation operation, and selection operation are performed; the result of the selection operation is judged to determine whether the algorithm termination condition is met, if the result is met, the algorithm is terminated; The constructed LSTM neural network model is used as the main architecture of the fault prediction model, the number of input layers is set to 3, and the output state matrix is output by the output layer; RMSE is determined as the error evaluation standard, and RMSE is also used as the evaluation function of the improved genetic algorithm; The improved genetic algorithm is used to dynamically calculate the fitness value of the step length of each LSTM training, and the step length with the optimal fitness value is determined as the LSTM neural network training step length; The running parameter data in the training set is taken as input, the fault result data corresponding to the running parameter data in the training set is taken as output, cross entropy is taken as a loss function of the model, and the loss function and the improved genetic algorithm are used for training, so that the weights between neurons are continuously adjusted according to the value of the loss function, and the value of the loss function is gradually reduced. After each complete training data set traversal, the loss function value of the verification set is recorded, the loss function value is checked, when the loss function value meets the set threshold, the training is ended, and the trained LSTM neural network model is obtained.
7. The neural network-based static var generator fault diagnostic method according to claim 6, characterized by, The cross entropy loss function is specifically: where Y j is the true label of the jth sample, is the predicted probability of the jth sample, is the calculation result of the cross-entropy loss function, which is used to quantify the overall error between the model prediction result and the true label of the sample, and N is the total number of samples participating in the loss calculation. 8.The neural network based static var generator fault diagnostic method of claim 1, wherein, The fault handling strategy is obtained through data mapping matching, and the fault handling strategy is obtained through mapping matching based on a dictionary or a lookup table. 9.The neural network based static var generator fault diagnostic method of claim 1, wherein, The running parameter data includes, but is not limited to, overcurrent, overvoltage, overtemperature, IGBT module damage, communication failure, control failure, and the running parameter data includes, but is not limited to, SVG output voltage value, SVG output current value, SVG reactive power output, SVG power factor, SVG operating temperature, and SVG operating environment parameter.
10. A diagnosis system for implementing the neural network-based static var generator fault diagnosis method according to any one of claims 1 to 9, characterized in that, It comprises: A data acquisition unit is configured to acquire running parameter data of a static var generator (SVG) in a fault state and a normal state during operation of the SVG, record corresponding processing process data and fault result data in the fault state, acquire compensation current data of the SVG in a normal operation condition, and establish a fault diagnosis database; A data preprocessing unit is configured to preprocess data in the fault diagnosis database, including: The running parameter data is subjected to data cleaning, data normalization, data standardization and feature engineering processing; the preprocessed running parameter data is subjected to feature extraction, and key features reflecting the operating state of the SVG are extracted through establishment of a feature extraction model; Key words of the processing process data and the fault result data are extracted, the extracted key words are coded, the coded processing process data and the fault result data are mapped, and a fault handling database is constructed; The compensation current data of the SVG in the normal operation condition is subjected to feature extraction of amplitudes and phases of a compensation current fundamental wave and each harmonic wave of the SVG when a single-tube open-circuit fault occurs, and implicit fault feature recognition is performed; A prediction model construction unit is configured to construct an LSTM model data set based on the preprocessed running parameter data and the operating result data in the fault diagnosis database, including a training set, a verification set and a test set, the training set, the verification set and the test set are divided according to a ratio of 70:15:15, then a fault prediction model of an LSTM neural network is constructed, the training set data is input into the LSTM model for model training, and the implicit fault features are valued, coded and normalized based on the implicit fault features recognized by the SVG in the normal operation condition, a BP neural network model is established, and the BP neural network model is trained based on the implicit fault feature normalized value and the fault code; The explicit fault diagnosis unit inputs the parameter data in the test set into the trained LSTM model, uses a Softmax classifier to identify whether a fault has occurred and perform multi-classification division of the fault category, respectively obtains a confidence vector data of fault diagnosis, wherein the category corresponding to the highest confidence in the vector data is the diagnosis result, inputs the diagnosis result into the fault handling database, and obtains a fault handling strategy through data mapping matching; The implicit fault diagnosis unit inputs the implicit fault features of the SVG under normal operation into the trained BP neural network model after assigning values, calculates a fault code value, performs decoding of the fault code value to obtain the implicit fault of the SVG under normal operation, and handles the implicit fault based on the implicit fault.
Citation Information
Patent Citations
SVG fault analysis system
CN113765111A
SVG parameter optimization identification method based on convolutional neural network
CN114740730A