Current transformer error prediction method and system
By collecting and preprocessing the current transformer signal data, combining machine learning algorithms to select and predict features, and building a multi-domain feature prediction model, it solves the problem of online monitoring of current transformer errors in the existing technology, and realizes accurate prediction and online monitoring of current transformer errors, improving the stability and efficiency of power grid operation.
Patent Information
- Application Number
- CN202411607851.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-12
- Publication Date
- 2025-02-28
AI Technical Summary
When monitoring the errors of current transformers online, it is difficult to achieve continuous monitoring and accurate error evaluation, and traditional offline power outage inspections have problems such as affecting the normal operation of the power grid and equipment deactivation.
By collecting signal data from the device, preprocessing and feature extraction, combining machine learning algorithms for feature selection and prediction, a multi-domain feature prediction model is built to achieve accurate prediction and online monitoring of current transformer errors.
It realizes continuous monitoring and accurate error evaluation of current transformers without affecting the normal operation of the power grid, improves the accurate identification of the operating conditions of the current transformer, and reduces computing costs and memory consumption.
Smart Images

Figure CN119537894A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of state evaluation and online monitoring of power transmission and distribution equipment, and in particular to a current transformer error prediction method and system. Background Art
[0002] The metering current transformer is a key component of the electric energy metering system, and the accuracy of its measurement results is directly related to the fairness and accuracy of electric energy metering. However, as the use time increases, the metering current transformer may be affected by various factors, resulting in the gradual accumulation of measurement errors. Through online monitoring and error evaluation, these transformers with abnormal errors can be discovered in time and alarms can be issued to avoid their impact on the electric energy metering results. Therefore, the online monitoring technology of current transformer errors has become a hot spot and difficulty in the development of intelligent operation and maintenance technology for electric energy metering devices.
[0003] In the past, the offline power outage inspection method was mainly used to determine the error state of the operating current transformer in the current transformer operation management process. However, this method has the following disadvantages: First, the transformer and peripheral equipment under inspection must be powered off during the inspection, which takes a long time and has a great impact on the normal operation of the power grid; second, the high-precision standard required for the inspection is bulky and not easy to carry; third, there is a certain difference between the working conditions during the offline power outage inspection and the working conditions during the actual operation, which cannot fully reflect the dynamic changes of the operation error. Compared with the traditional offline power outage inspection, online monitoring realizes the error evaluation of the current transformer under the condition of non-power outage, can timely detect the transformer with abnormal error and give an alarm, and avoid the economic losses caused by the comprehensive power outage inspection. Therefore, the online monitoring method has broad application prospects for the error evaluation of current transformers. Summary of the invention
[0004] In view of the above-mentioned problems, the present invention is proposed.
[0005] Therefore, the technical problem solved by the present invention is: how to achieve continuous monitoring and accurate error evaluation of the current transformer without affecting the normal operation of the power grid.
[0006] In order to solve the above technical problems, the present invention provides the following technical solutions: a current transformer error prediction method, which comprises the following steps:
[0007] As a preferred solution of a current transformer error prediction method described in the present invention, wherein:
[0008] Collect signal data from the device and perform preprocessing;
[0009] Use method 1 and method 2 to extract features from the preprocessed data and perform dimensionality reduction;
[0010] The feature data after dimensionality reduction is transferred to the machine learning algorithm for feature selection and prediction, and the results are output.
[0011] As a preferred solution of the current transformer error prediction method described in the present invention, wherein: the collecting signal data from the device includes collecting current data of the current transformer in normal operating state and performing data preprocessing.
[0012] As a preferred solution of the current transformer error prediction method described in the present invention, the dimensionality reduction processing includes using method one to decompose the current data of the current transformer to obtain the inherent mode, and using method two to discretize the current data of the current transformer.
[0013] As a preferred solution of the current transformer error prediction method described in the present invention, wherein: the transmitting of the dimension-reduced feature data to the machine learning algorithm for feature selection includes:
[0014] By calculating the time-frequency domain characteristics of the inherent modal components obtained by calculation method one and the average energy of the results of calculation method two, the characteristic vector is output and the reduced-dimensional single-phase current characteristic matrix is constructed.
[0015] As a preferred solution of the current transformer error prediction method described in the present invention, wherein: the transmitting of the dimension-reduced feature data to the machine learning algorithm for feature selection also includes:
[0016] The constructed single-phase current feature matrix is input into the first machine learning algorithm for training to obtain feature importance.
[0017] As a preferred solution of the current transformer error prediction method described in the present invention, wherein: the transmitting of the dimension-reduced feature data to the machine learning algorithm for feature selection also includes:
[0018] Based on the feature importance obtained by the first machine learning algorithm, the optimal feature group is selected and input into the second machine learning algorithm for training.
[0019] As a preferred solution of the current transformer error prediction method described in the present invention, the output result includes:
[0020] The prediction result outputted by the second machine learning algorithm training is compared with the error threshold and the result is outputted.
[0021] Another object of the present invention is to provide a current transformer error prediction system, which can predict the performance changes and errors of the current transformer through real-time data analysis and machine learning technology. This system can effectively solve the problem of power grid operation interruption caused by comprehensive power outage inspection in the prior art, while improving the pertinence of power outage inspection and the timeliness of problem handling.
[0022] In order to solve the above technical problems, the present invention provides the following technical solutions: a current transformer error prediction system, comprising: a data acquisition and preprocessing module, a feature extraction, dimension reduction and selection module, and a machine learning training and prediction module;
[0023] The data acquisition and preprocessing module collects raw signal data from the current transformer and performs data preprocessing;
[0024] The feature extraction, dimensionality reduction and selection module simplifies data by feature extraction and dimensionality reduction;
[0025] The machine learning training and prediction module uses the selected features to train the first machine learning model after feature selection, screens the features that have the greatest impact on the prediction, uses the selected features to train the second machine learning model, performs the final error prediction, and outputs the results.
[0026] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the current transformer error prediction method as described above when executing the computer program.
[0027] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of a current transformer error prediction method as described above.
[0028] Beneficial effects of the present invention: The present invention combines the time domain, frequency domain and wavelet domain features of the current transformer monitoring signal to construct a multi-domain feature prediction model, thereby improving the ability to accurately identify the operating status of the current transformer. The present invention uses the CatBoost algorithm to evaluate the importance of features, improves the feature interpretability of the model, and ensures the effectiveness of model training and the accuracy of prediction.
[0029] The present invention uses HistGB as a regression model, which not only greatly improves the training speed, but also significantly reduces the computing cost and memory consumption when processing large amounts of data. The present invention effectively solves the problems of traditional offline power outage inspection being not targeted and abnormal identification being poorly timely. Through online monitoring of high-voltage current transformers, the quantitative analysis of operating current transformer errors and timely prediction of error states are achieved, thereby providing technical support for current transformer operation management. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for describing the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work. Among them:
[0031] Figure 1 An overall flow chart of a current transformer error prediction method provided by the first embodiment of the present invention;
[0032] Figure 2 A data signal collected in a current transformer error prediction method provided by a second embodiment of the present invention;
[0033] Figure 3 A VMD decomposition diagram of a current transformer error prediction method provided by a second embodiment of the present invention;
[0034] Figure 4 A convergence curve diagram of a fitness function of a sparrow search algorithm in a current transformer error prediction method provided by a second embodiment of the present invention;
[0035] Figure 5 A wavelet packet decomposition tree with three layers and frequency distribution in a current transformer error prediction method provided by a second embodiment of the present invention;
[0036] Figure 6 A ranking diagram of the importance of multi-domain features under different numbers of tasks for a current transformer error prediction method provided in the second embodiment of the present invention. DETAILED DESCRIPTION
[0037] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the drawings of the specification. Obviously, the described embodiments are part of the embodiments of the present invention, but not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary persons in the art without creative work should fall within the scope of protection of the present invention.
[0038] Embodiment 1 is an embodiment of the present invention, which provides a current transformer error prediction method, including:
[0039] The existing transformer evaluation models usually only have single-domain inputs in the model's input features, and rarely have inputs that combine multi-domain features. At the same time, even if these types of features exist, convolutional neural network models are often used to extract them, which loses the interpretability of the model for the features.
[0040] Existing transformer machine learning models such as XGBoost (eXtreme Gradient Boosting) and LightGBM (Light Gradient Boosting Machine) usually require additional encoding processing of category features when processing category features, which increases the computational cost and memory consumption; the input features selected by existing transformer evaluation models are usually information in the time domain or frequency domain, ignoring the importance of the wavelet domain in analyzing and processing signals; most of the deep learning models selected in existing transformer evaluation models have problems such as slow training speed and high computing resource requirements.
[0041] The present invention discloses a current transformer error prediction method based on multi-domain features and HistGB (Hist Gradient Boosting), and solves the following technical problems:
[0042] When extracting characteristic information of current transformer monitoring data, the present invention combines the characteristic information in the time domain, frequency domain and wavelet domain of the current transformer monitoring signal to construct multi-domain features. The time domain feature captures the law of signal change over time, the frequency domain feature reveals the frequency component and energy distribution of the signal, and the wavelet domain feature provides localized information of the signal at different scales and positions. By combining these multi-domain features, a richer and more comprehensive feature description is constructed, thereby improving the ability to accurately characterize the current transformer condition and avoiding problems such as model overfitting that may be caused by selecting only a single domain feature.
[0043] Collect signal data from the device and perform preprocessing.
[0044] Collect the current signal amplitude data of the secondary side of the single-phase current transformer every 15 minutes under normal operation, and collect 900 data points for each signal. Remove abnormal values that are out of range according to the maximum and minimum values of historical normal signal changes. Eliminate non-numeric values, continuous repeated values, and abnormal normal operation values in the matrix. Perform standardized data processing and normalization on the single-phase current amplitude data matrix.
[0045] The preprocessed data features are subjected to dimensionality reduction processing.
[0046] The current data of the current transformer is decomposed to obtain the inherent mode using the first method, and the current data of the current transformer is discretized using the second method.
[0047] It should be noted that method one may include multiple optimization schemes, and the design scheme may be a variational mode decomposition method or a Hilbert-Huang transform method.
[0048] It should also be noted that the preprocessed current signal data is efficiently decomposed using variational mode decomposition (VMD) to obtain a set of physically meaningful intrinsic mode functions (IMFs). The advantage of the VMD method is that it can adaptively determine the number and frequency of modes, thereby avoiding modal aliasing and endpoint effects, and improving the accuracy and reliability of signal decomposition.
[0049] The IMF components obtained by VMD decomposition further extract key features such as the center frequency, bandwidth and energy of each component. These feature vectors can comprehensively and accurately describe the operating status of the current transformer and provide rich feature information for fault diagnosis and prediction. The principal component analysis (PCA) is used to reduce the dimension of the feature vector, which effectively reduces the redundancy of the data while retaining the information that can best characterize the operating status of the current transformer. The machine learning algorithm is used to evaluate the importance of the features after dimensionality reduction and train the prediction model based on this. The model can accurately predict the potential errors of the current transformer and provide timely decision support for the stable operation of the power system.
[0050] It should also be noted that the Hilbert-Huang transform method uses empirical mode decomposition (EMD) to decompose the preprocessed current signal data to obtain a series of IMF components. The current signal data is effectively decomposed into a series of IMF components. This step greatly enhances the ability to analyze the time-frequency characteristics of the signal, making the analysis of complex signals more intuitive and clear. Hilbert transform is performed on each IMF component to obtain the time-frequency characteristics of the signal. Each IMF component is processed by Hilbert transform. The obtained time-frequency characteristics further reveal the essential characteristics of the signal, and key information such as the distribution of frequency centers and energy distribution are extracted from the time-frequency characteristics to construct feature vectors. The key information extracted from the time-frequency characteristics, such as the distribution of frequency centers and energy distribution, constructs highly representative feature vectors, which can accurately reflect the operating status of the current transformer and provide strong data support for fault diagnosis and prediction.
[0051] It should be noted that method 2 can be multiple optimization schemes, and the design scheme can be db4 wavelet transform or synchronous compression transform method.
[0052] It should also be noted that the synchronous compression transform method is based on the principle of empirical mode decomposition (EMD) or wavelet transform, which improves the resolution of time-frequency features by redistributing the energy in the time-frequency spectrum. The current signal on the secondary side of the current transformer is denoised and filtered to ensure signal quality. The synchronous compression transform is applied to the pre-processed signal. The frequency components in the time-frequency spectrum are compressed by the synchronous squeezing transform (SST), so that the originally scattered energy is more concentrated, thereby improving the frequency resolution and making the estimation of the instantaneous frequency more accurate. Key features such as instantaneous frequency, amplitude modulation, energy distribution, etc. are extracted from the time-frequency representation obtained by SST. These features can reflect the working status and potential errors of the current transformer. Feature vectors are constructed, which will contain the most representative features extracted from the SST time-frequency spectrum.
[0053] It should also be noted that the db4 wavelet transform is a method of more effectively separating low-frequency contour information and high-frequency details, noise and other information through wavelet decomposition. However, as the number of wavelet decomposition layers increases, the resolution of different frequency components will gradually increase. And too many increase in the number of wavelet decomposition layers will lead to partial loss of useful signals, so it is extremely important to determine the optimal number of wavelet decomposition layers. The present invention combines the characteristics of permutation entropy to calculate the permutation entropy values of components with different numbers of layers, and then calculates the average value thereof, and finally determines the optimal number of layers.
[0054] Permutation entropy is an average entropy parameter used to measure the randomness of time series. It has the characteristics of strong noise resistance, high sensitivity and simple calculation, and can monitor the error of current transformer more accurately. The more regular the time series, the smaller the corresponding permutation entropy; the more complex the time series, the larger the corresponding permutation entropy.
[0055] The feature data after dimensionality reduction is subjected to feature selection and prediction. The time-frequency domain characteristics of the inherent modal components obtained by calculation method one and the average energy of the results of calculation method two are used to output the feature vector and construct the reduced-dimensional single-phase current feature matrix.
[0056] The constructed single-phase current feature matrix is input into the first machine learning algorithm for training to obtain feature importance.
[0057] It should be noted that the first machine learning algorithm can be multiple optimization schemes, and the design scheme can be a CatBoost algorithm or an XGBoost algorithm.
[0058] It should also be noted that the CatBoost algorithm is based on the time-frequency domain characteristics of the inherent modal components of calculation method one and the average energy of the results of calculation method two, and outputs a multi-dimensional feature vector, which further constitutes a single current feature matrix after dimensionality reduction. The obtained matrix is transmitted to the CatBoost algorithm for training to obtain several feature vectors, from which the best feature vector is selected for storage and output to the HistGB learning algorithm for prediction.
[0059] It should also be noted that the XGBoost algorithm constructs a multidimensional feature vector based on the time-frequency domain features obtained by calculation method one and the average energy obtained by calculation method two, and forms a single-phase current feature matrix; then, we preprocess the feature matrix, including data cleaning and standardization, to ensure data quality; then, the preprocessed data is input into the XGBoost model for training, and the model parameters are optimized and overfitting is prevented through cross-validation and early stopping strategies, and the key feature vectors are selected using feature importance evaluation; finally, the model performance is evaluated through the validation set and necessary optimization is performed, and the final model is used to predict new data.
[0060] Based on the feature importance obtained by the first machine learning algorithm, the optimal feature group is selected and input into the second machine learning algorithm for training.
[0061] It should be noted that the second machine learning algorithm can be multiple optimization schemes, and the design scheme can be an extreme learning machine, random forest, XGBoost, CatBoost or HistGB algorithm.
[0062] It should also be noted that the extreme learning machine is a single hidden layer feedforward neural network learning algorithm. Unlike traditional neural network training methods, ELM can randomly initialize the connection weights between the input layer and the hidden layer and the bias of the hidden layer neurons during the training process, and then determine the connection weights between the hidden layer and the output layer by solving a linear system.
[0063] Random forest is a machine learning algorithm based on ensemble learning. It constructs multiple decision trees and combines the prediction results of these decision trees to obtain more accurate predictions. This ensemble learning method can effectively reduce the overfitting risk of a single decision tree and improve the generalization ability of the model.
[0064] XGBoost is an algorithm based on gradient boosting trees. It improves the model by continuously adding new decision trees. Each new tree is built to make up for the shortcomings of the existing trees, thereby gradually improving the performance of the model.
[0065] CatBoost is a machine learning algorithm based on gradient boosting decision trees.
[0066] HistGB is a histogram-based gradient boosting machine learning algorithm.
[0067] Example 2, reference Figure 1 to Figure 6 , as an embodiment of the present invention, provides a current transformer error prediction method comprising:
[0068] ① Collect the current signal amplitude data of the secondary side of the single-phase current transformer every 15 minutes under normal operating conditions, and collect 900 data points for each signal.
[0069] ② Remove abnormal values that exceed the range according to the maximum and minimum values of historical normal signal changes. Remove non-numeric values, continuous repeated values, and abnormal operating values in the matrix.
[0070] ③Perform standardized data processing and normalization on the single-phase current amplitude data matrix.
[0071] ④Use variational mode decomposition (VMD) to decompose the current transformer monitoring data and obtain two inherent modes. And use db4 wavelet to perform three-layer decomposition of one-dimensional discrete wavelet packet on the current transformer monitoring data.
[0072] It is further explained that:
[0073] The first method described above is that the present invention uses the VMD method to decompose two intrinsic modal components, so that the signal decomposition effect is optimized.
[0074] VMD can effectively distinguish and extract multiple modal components in complex signals, and the accuracy of its signal decomposition depends largely on the selection of its parameters, among which the decomposition mode number K and the penalty factor α are key parameters, which influence and restrict each other. The present invention introduces the sparrow search algorithm to optimize the parameters of VMD to obtain the best decomposition effect. The core idea of the algorithm is to divide the search process into three roles: discoverer, follower and alerter, and use the synergy between these roles to optimize the solution to the problem. The discoverer looks for a better solution in the entire population, the follower uses the discoverer to find the solution by following it, and the alerter is responsible for discovering potential dangers and guiding the entire population to a safe area. Through this division of labor and cooperation, the sparrow search algorithm can effectively explore the problem space and find the optimal solution.
[0075] The experimental data of the present invention comes from the secondary side current data of the current transformer sampled by an offline platform. The data is sampled once per second, and a total of 900 current amplitude data are collected within half an hour. Figure 2 As shown in the figure, the original signal is decomposed into Figure 3 The two sub-signals are shown.
[0076] like Figure 4 As shown in the figure, as the number of optimization iterations increases, the convergence curve of the fitness function shows a gentle trend after several iterations, and the algorithm gradually approaches the optimal solution. Finally, the optimal decomposition mode number K is determined to be 2 and the penalty factor α is 9854.
[0077] The modal components after VMD decomposition are as follows Figure 3 VMD decomposes the original current sequence into IMF1 and res terms. Among them, IMF1 with a smaller overall amplitude represents the local high-frequency component of the sequence, and res with a low frequency and a larger amplitude represents the overall change trend of the original sequence.
[0078] It is further explained that:
[0079] The second method described above is the db4 method used in the present invention.
[0080] Wavelet decomposition can more effectively separate low-frequency contour information and high-frequency details, noise and other information. However, as the number of wavelet decomposition layers increases, the resolution of different frequency components will gradually increase. And too many wavelet decomposition layers will lead to partial loss of useful signals. Therefore, it is extremely important to determine the optimal number of wavelet decomposition layers. The present invention combines the characteristics of permutation entropy to calculate the permutation entropy values of components with different numbers of layers, and then calculates the average value, and finally determines the optimal number of layers.
[0081] Permutation entropy is an average entropy parameter used to measure the randomness of time series. It has the characteristics of strong noise resistance, high sensitivity and simple calculation, and can monitor the error of current transformer more accurately. The more regular the time series, the smaller the corresponding permutation entropy; the more complex the time series, the larger the corresponding permutation entropy.
[0082] Table 1 Average permutation entropy values at different levels
[0083]
[0084] It can be seen from the table that the average permutation entropy value is the smallest when the three-layer decomposition is performed, that is, it contains more available information and the noise is smaller, so the three-layer wavelet decomposition is selected.
[0085] ⑤ Calculate the time-frequency domain characteristics of each inherent modal component and the average energy of each sub-waveform in the wavelet domain to obtain a 76-dimensional feature vector, which constitutes a reduced-dimensional single-phase current feature matrix.
[0086] It should be further explained that in order to fully describe the condition of the current transformer, this paper abandons the traditional method of extracting only single-domain features when extracting the characteristic information of the current transformer monitoring data, but combines the characteristic information in the time domain, frequency domain and wavelet domain of the current transformer monitoring signal to construct multi-domain features. The relevant features of multi-domain feature extraction are shown in Table 2, with a total of 76 dimensional features. After the variational mode decomposition model is constructed, the single-phase current transformer input signal will generate 2 modes each, which have different frequency and amplitude characteristics, reflecting the different vibration components in the signal. In order to better understand the structure and characteristics of the signal, it is necessary to extract time and frequency domain features of these modes so as to extract representative information from the signal to support subsequent analysis and application.
[0087] Table 2 Parameter information of multi-domain feature extraction
[0088]
[0089]
[0090] In terms of wavelet domain features, the present invention uses wavelet packet decomposition to perform wavelet domain analysis on the three-phase current transformer monitoring data. Wavelet packet decomposition is a classic extension of discrete wavelet transform. It divides the frequency band into several layers, can decompose high-frequency band and low-frequency band signals, and can realize feature extraction of current transformer monitoring signals in different frequency bands.
[0091] Given the orthogonal scaling function Φ(t) and the wavelet function Ψ(t), the two-scale equation of wavelet packet decomposition can be expressed as:
[0092]
[0093] Among them, h 0k 、h 1k is the filter coefficient in multiresolution analysis; Z is an integer set; k refers to the element in the integer set Z, and t refers to time.
[0094] To further generalize the two-scale equation, the following recursive relationship is defined:
[0095]
[0096] When n=0, w1=Ψ(t), w1=Ψ(t); {w n (t)} is the basis function w n =Φ(t) determines the wavelet packet, n represents the nth wavelet packet.
[0097] Wavelet packet decomposition can be regarded as a filtering process. Assuming the filter length is 2n, the low-pass and high-pass filters are g(s) and h(s) respectively (s is the position index, s = 1, 2, ..., 2n), then the W-th layer wavelet packet coefficient can be expressed as:
[0098]
[0099] Where: S W,L (n) and S W,H (n) are the n-th values of the low-frequency coefficient and high-frequency coefficient of the W-th layer decomposition node respectively.
[0100] Finally, after K layers of decomposition, the original signal S can be decomposed into 2 K nodes.
[0101] Due to the completeness of wavelet packet decomposition, the signal can be decomposed into different sub-bands without redundancy during the decomposition process. The total energy can be expressed as follows:
[0102]
[0103] Where: E is energy.
[0104] Using formula (0-3) to decompose the original signal to the third layer, the energy of the original signal is decomposed into 8 sub-bands. The calculation formula for the average energy of each band signal is as follows:
[0105]
[0106] Where: E j,i is the average signal energy of the i-th frequency band in the j-th layer; S j,i is the wavelet packet decomposition coefficient of the i-th frequency band of the j-th layer; x j,i (n) represents S with length N j,i The discrete waveform signal corresponding to the reconstruction of wavelet coefficients.
[0107] It should be further explained that the db4 wavelet is used to perform a three-layer decomposition of the one-dimensional discrete wavelet packet on the current transformer monitoring data. The wavelet packet decomposition tree (3 layers) and the frequency distribution diagram are shown in the figure. Figure 5 As shown. S represents the original signal before decomposition; A represents the low-frequency signal after decomposition; D represents the high-frequency signal after decomposition. The numbers at the end of A and D represent the number of decomposition layers (starting from 1 by default). The wavelet energy domain is decomposed by three layers of wavelet packets and the average energy value E of each sub-waveform is calculated. 3,i , and obtain 8 energy characteristic parameters. Figure 5 shown.
[0108] The present invention describes the operating status of the three-phase current transformer as comprehensively as possible by extracting 76 features in the time domain, frequency domain and wavelet domain.
[0109] ⑥ Send the data matrix of the extracted multi-domain features into CatBoost for training to obtain the feature importance.
[0110] It is further explained that:
[0111] The first machine learning algorithm described above is the CatBoost algorithm in the present invention.
[0112] CatBoost inputs the 76-dimensional multi-domain features extracted from the current transformer data into the model to calculate the feature importance. The main idea of this method is to determine the importance of the feature by measuring the impact of the change in the feature on the predicted value. Specifically, it perturbs each feature, such as randomly shuffling the value of the feature or deleting the feature, and then observes the change in the model's predicted value. If the perturbation of a feature causes a large change in the predicted value, it means that the feature has an important impact on the model's prediction results, so it can be considered that the feature has a high importance. The calculation formulas for feature importance feature_importanceF and weighted average avr are shown below.
[0113]
[0114] Where c1 and c2 represent the total weights in the left and right leaves, respectively. If no weight is specified for the dataset, this weight is equal to the number of objects in each leaf. v1 and v2 represent the predicted values in the left and right leaves, respectively. trees represents the number of trees, and leaves F Refers to the number of leaf nodes.
[0115] The calculation results of 76 feature importance are as follows Figure 6 Therefore, the present invention selects the top 10 important features for prediction according to the feature importance.
[0116] ⑦ Select the top 10 important features and send them into HistGB for training and prediction results.
[0117] It should be further explained that the first 10 important feature variables after CatBoost selection are used as training data sets, of which 80% are used as training sets and the remaining 20% are used as test sets. The labels of the input samples are the real ratio difference and angle difference, and are sent to the HistGB regression model for training. The input feature variable data set is input into the trained model to obtain the ratio difference and angle difference predicted by the mutual inductor, which are compared with the real ratio difference and angle difference. The better the model, the smaller the error; the worse the model, the larger the error. The present invention uses two evaluation indicators, mean absolute error (MAE) and mean square error (MSE), as the basis for judging the model prediction effect. The calculation method is as follows:
[0118]
[0119] Where n is the number of samples, Y i is the true value, Y i ' is the predicted value.
[0120] The following table compares the results of the HistGB algorithm with other algorithms. The MSE of the HistGB prediction ratio difference is 0.0073, and the MAE is 0.0551; the MSE of the HistGB prediction angle difference is 21.5642, and the MAE is 2.7953.
[0121] It is further explained that:
[0122] The second machine learning algorithm described above is the HistGB method.
[0123] The performance evaluation indicators of five different computational learning algorithms are compared under the same circumstances, see Table 3.
[0124] Table 3 Comparison of algorithm performance evaluation indicators
[0125]
[0126] Through comparative analysis of the two indicators of MSE and MAE, it is found that the histogram-based gradient boosting algorithm (HistGB) is the best, so the present invention substitutes the calculated data into the HistGB algorithm for effective prediction.
[0127] It should be further explained that when extracting characteristic information of monitoring data, the present invention is no longer limited to the feature extraction of a single field in the traditional method, but comprehensively utilizes the characteristic information in the time domain, frequency domain and wavelet domain. The current transformer monitoring data is decomposed by variational mode decomposition (VMD) to obtain two inherent modes, and 34 features are extracted from them respectively, resulting in a total of 68 features. The db4 wavelet is used to perform a three-layer decomposition of the one-dimensional discrete wavelet packet on the current transformer monitoring data to obtain 8 energy features. The time domain features capture the law of signal change over time, the frequency domain features reveal the frequency components and energy distribution of the signal, and the wavelet domain features provide localized information of the signal at different scales and positions. By combining these multi-domain features, a richer and more comprehensive feature description is constructed, thereby improving the ability to accurately characterize the current transformer condition.
[0128] The present invention proposes to use the CatBoost algorithm to analyze the feature importance of the extracted multi-domain features and select important features to train the model. While ensuring the accuracy of the model, the data input of the model is greatly reduced, the original 76-dimensional data is reduced to 10 dimensions, and the redundant information of the data and the calculation time and cost of the model are reduced.
[0129] ⑧ Compare the ratio difference and angle difference results predicted by the model with the error threshold. If the predicted ratio difference and angle difference are less than the threshold, it indicates that the current transformer is in normal operation; if they are greater than the threshold, it indicates that the current transformer is likely to be in abnormal operation.
[0130] The present invention uses HistGB as a regression model to predict the ratio error and angle error of the current transformer. The data distribution of the current transformer is approximated by the HistGB algorithm, and the input samples are divided into integer value boxes (usually 256 boxes), which greatly reduces the number of split points that need to be considered, greatly reduces the complexity of data processing, reduces the storage and calculation of data, and improves the training speed of the model.
[0131] The present invention proposes a transformer error assessment method based on multi-domain features. When extracting characteristic information of monitoring data, it is no longer limited to the feature extraction of a single field in the traditional method, but comprehensively utilizes the characteristic information in the time domain, frequency domain and wavelet domain. The time domain features capture the law of signal change over time, the frequency domain features reveal the frequency components and energy distribution of the signal, and the wavelet domain features provide localized information of the signal at different scales and positions. By combining these multi-domain features, a richer and more comprehensive feature description is constructed, thereby improving the ability to accurately characterize the condition of the current transformer.
[0132] The present invention selects CatBoost to calculate the feature importance of the processed multi-domain features, selects the top 10 important features to train the model, and realizes the effective dimensionality reduction of the current transformer monitoring data while ensuring the accuracy of the model, speeds up the training of the model, reduces the calculation cost of the model, and improves the feature interpretability of the model.
[0133] The present invention selects HistGB as the transformer error prediction model based on single-phase current data. The HistGB model is trained based on a histogram estimator. When the sample data volume is large, HistGB is several orders of magnitude faster than the gradient boosting tree model. Compared with the traditional gradient boosting machine algorithm, HistGB has a significant improvement in computational efficiency, memory usage, and accuracy, greatly improving the monitoring efficiency of current transformers.
[0134] Embodiment 3 is an embodiment of the present invention, which provides a system for a current transformer error prediction method, including: a data acquisition and preprocessing module, a feature extraction, dimension reduction and selection module, and a machine learning training and prediction module.
[0135] The data acquisition and preprocessing module collects raw signal data from the current transformer and performs data preprocessing.
[0136] The feature extraction, dimensionality reduction and selection module simplifies data through feature extraction and dimensionality reduction.
[0137] The machine learning training and prediction module uses the selected features to train the first machine learning model after feature selection, screens the features that have the greatest impact on the prediction, and uses the selected features to train the second machine learning model to make the final error prediction, transmitting the results to the relevant staff for operation and maintenance.
[0138] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc., which can store program code.
[0139] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in conjunction with such instruction execution systems, devices or apparatuses. For the purposes of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in conjunction with such instruction execution systems, devices or apparatuses.
[0140] More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection with one or more wires (electronic device), a portable computer disk case (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be a paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, deciphering or, if necessary, processing in another suitable manner, and then stored in a computer memory.
[0141] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0142] 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 preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention, which should all be included in the scope of the claims of the present invention.
Claims
1. A current transformer error prediction method, characterized in that: include: Collect signal data from the device and perform preprocessing; Use method 1 and method 2 to extract features from the preprocessed data and perform dimensionality reduction; The feature data after dimensionality reduction is transferred to the machine learning algorithm for feature selection and prediction, and the results are output.
2. A current transformer error prediction method as claimed in claim 1, characterized in that: The collecting of signal data from the device includes collecting current data of the current transformer in a normal operating state and performing data preprocessing.
3. A current transformer error prediction method as claimed in claim 2, characterized in that: The dimension reduction processing includes using method one to decompose the current data of the current transformer to obtain the inherent mode, and using method two to discretize the current data of the current transformer.
4. A current transformer error prediction method as claimed in claim 3, characterized in that: The transferring of the dimension-reduced feature data to the machine learning algorithm for feature selection includes: By calculating the time-frequency domain characteristics of the inherent modal components obtained by calculation method one and the average energy of the results of calculation method two, the characteristic vector is output and the reduced-dimensional single-phase current characteristic matrix is constructed.
5. A current transformer error prediction method as claimed in claim 4, characterized in that: The transferring of the dimension-reduced feature data to the machine learning algorithm for feature selection also includes: The constructed single-phase current feature matrix is input into the first machine learning algorithm for training to obtain feature importance.
6. A current transformer error prediction method as claimed in claim 5, characterized in that: The transferring of the dimension-reduced feature data to the machine learning algorithm for feature selection also includes: Based on the feature importance obtained by the first machine learning algorithm, the optimal feature group is selected and input into the second machine learning algorithm for training.
7. A current transformer error prediction method as claimed in claim 6, characterized in that: The output results include: The prediction result outputted by the second machine learning algorithm training is compared with the error threshold and the result is outputted.
8. A system using a current transformer error prediction method as claimed in any one of claims 1 to 7, characterized in that: It includes data collection and preprocessing module, feature extraction, dimension reduction and selection module, and machine learning training and prediction module; The data acquisition and preprocessing module collects raw signal data from the current transformer and performs data preprocessing; The feature extraction, dimensionality reduction and selection module simplifies data by feature extraction and dimensionality reduction; The machine learning training and prediction module uses the selected features to train the first machine learning model after feature selection, screens the features that have the greatest impact on the prediction, uses the selected features to train the second machine learning model, performs the final error prediction, and outputs the results.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of a current transformer error prediction method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of a current transformer error prediction method as described in any one of claims 1 to 7 are implemented.
Citation Information
Cited By
Multi-branch current transformer metering error overrun identification method and device
CN120610222A