Electronic voltage transformer error prediction method and system

By introducing time series convolutional neural network (TCN) and linear attention mechanism into the electronic voltage transformer error prediction model, the problem that traditional models cannot capture dynamic changes in real time is solved, and higher error prediction accuracy and stability are achieved.

CN119862791AInactive Publication Date: 2025-04-22国网福建省电力有限公司营销服务中心 +1

Patent Information

Application Number
CN202510343582.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-21
Publication Date
2025-04-22
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The error prediction model of traditional electronic voltage transformer cannot capture the impact of dynamic changes on errors in real time, resulting in low prediction accuracy.

Method used

Time series convolutional neural network (TCN) is used to construct an error prediction model in combination with linear attention mechanism, and dynamically update model parameters to adapt to changes in data distribution through a combination of offline learning and online learning.

Benefits of technology

It improves the accuracy and stability of error prediction, can capture changes in data distribution in a timely manner, and ensures efficient prediction in a dynamic environment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119862791A_ABST
    Figure CN119862791A_ABST
Patent Text Reader

Abstract

The invention relates to an error prediction method and system for an electronic voltage transformer, and belongs to the technical field of electric appliance measurement, and the method comprises the following steps: collecting historical operation data of the electronic voltage transformer, including temperature, humidity, load voltage, secondary voltage and a historical ratio error value; a time sequence convolutional neural network TCN is selected as a basis, an error prediction model is constructed in combination with a linear attention mechanism, and offline learning is performed by using historical data. Operating data is collected in real time, the relative entropy of the operating data and historical data is calculated, and a distribution threshold value is set; and when the relative entropy exceeds a threshold value, updating model parameters online by using real-time data. According to the method, the data distribution change is detected through the relative entropy, and the prediction precision of the model in a dynamic environment is ensured. The relative entropy serves as an index for measuring probability distribution differences, data distribution mutation can be effectively recognized, online learning can be triggered, the model can be dynamically adjusted, and errors of the electronic voltage transformer can be predicted more accurately.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to an electronic voltage transformer error prediction method and system, belonging to the technical field of electrical appliance measurement. Background Art

[0002] Electronic Voltage Transformer (EVT) is an important measuring device in modern power systems and is widely used in voltage measurement, electric energy metering, relay protection and other fields. Traditional voltage transformers are mainly based on the principle of electromagnetic induction, while electronic voltage transformers use electronic technology and sensor technology to collect and convert voltage signals. It has the advantages of small size, light weight, strong anti-interference ability, high measurement accuracy, and wide dynamic range, and can better adapt to the development needs of modern smart grids. With the continuous development of power systems, higher requirements are placed on the measurement accuracy and reliability of electronic voltage transformers. Error prediction is a key link to ensure the performance of electronic voltage transformers. Through error prediction, potential measurement deviations can be discovered in advance, and calibration and adjustment can be carried out in time, thereby improving the operational safety and economy of the power system.

[0003] Traditional error prediction models are mostly trained based on static data and lack the ability to adapt to dynamically changing data. In actual operation, the error of electronic voltage transformers is affected by many factors, such as ambient temperature, humidity, load changes, etc. Changes in these factors will lead to dynamic changes in errors. Traditional models cannot capture these dynamic changes in real time, thus affecting the prediction accuracy.

[0004] The patent document with the patent number "CN114692505A" has developed a method and device for predicting errors in capacitive voltage transformers. The model structure of this method is relatively simple, but it needs to rely on complex optimization algorithms to improve performance, which not only increases the computational cost, but may also fall into local optimality during the optimization process, resulting in the model performance not being able to reach the optimal level. Although this method can improve the model's ability to identify fault samples, this method is mainly aimed at static processing of historical data and lacks a detection mechanism for dynamic changes in real-time data. Summary of the invention

[0005] In order to solve the above problems existing in the prior art, the present invention proposes an electronic voltage transformer error prediction method and system.

[0006] The technical solution of the present invention is as follows: In one aspect, the present invention provides an electronic voltage transformer error prediction method, comprising the following steps: Collecting historical operating data of the electronic voltage transformer, the operating data including temperature, humidity, load voltage, secondary voltage and historical ratio error value; Select the time series convolutional neural network TCN as the base and combine it with linear attention to build an error prediction model; Using the historical operating data to perform offline learning on the error prediction model; Collecting real-time operating data of the electronic voltage transformer, calculating the relative entropy of the historical operating data and the real-time operating data and setting a distribution threshold, if the relative entropy is greater than the distribution threshold, performing online learning on the error prediction model through the real-time operating data to update the parameters of the error prediction model; The error prediction model is used to predict the error of the electronic voltage transformer.

[0007] As a preferred implementation, the error prediction model adds a linear attention mechanism to the convolution calculation of each layer, which is specifically expressed as follows: ; ; in, Represents the input value of the tth node in the input layer and the input value of the t-1th node in the input layer The calculation results of the dilated causal convolution are: , represents the weight matrix, represents the bias term, represents the output value of the tth node in the hidden layer 1, represents the learnable parameter matrix, represents the hyperbolic tangent activation function.

[0008] As a preferred implementation, the relative entropy is calculated as follows: Let the historical sample data set composed of the historical operation data of the electronic voltage transformer be S, and the length of the historical sample data set be N; Let the target sample data set composed of the real-time operation data of the electronic voltage transformer be T, and the length of the target sample data set be M; Divide the historical sample data set S into Several historical subsample sets of length M ; Calculate the i-th historical subsample set Relative entropy with the target sample data set T : ; in, Represents the data sample probability distribution of the target sample data set T, Indicates Historical subsamples The probability distribution of the data sample is Indicates the preset maximum number, Indicates The data sample is in Historical subsamples The probability of occurrence in Indicates The probability that a data sample appears in the target sample data set T.

[0009] As a preferred implementation, the steps of offline learning include: S1, randomly initialize the weights of the error prediction model; S2, input the historical operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; S3, using the loss function to calculate the loss value between the predicted result and the preset true label; S4. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; S5. Execute step S2 until the loss value is less than or equal to the preset loss threshold to complete offline learning.

[0010] As a preferred implementation, the steps of online learning include: D1. Load the error prediction model learned offline; D2, preset configuration, including learning algorithm and learning rate; D3, input the real-time operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; D4. Use the loss function to calculate the loss value of the predicted result and the preset true label; D5. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; D6. Execute step D3 until the loss value is less than or equal to the preset loss threshold to complete the online learning.

[0011] In another aspect, the present invention further provides an electronic voltage transformer error prediction system, comprising: Data acquisition module: collects historical operation data of the electronic voltage transformer, the operation data including temperature, humidity, load voltage, secondary voltage and historical ratio error value; Model building module: Select the time series convolutional neural network TCN as the base and combine it with linear attention to build an error prediction model; Offline learning module: using the historical operation data to perform offline learning on the error prediction model; Data comparison module: collects real-time operation data of the electronic voltage transformer, calculates the relative entropy of the historical operation data and the real-time operation data and sets the distribution threshold. If the relative entropy is greater than the distribution threshold, the error prediction model is online learned through the real-time operation data to update the parameters of the error prediction model; Error prediction module: uses the error prediction model to predict the error of the electronic voltage transformer.

[0012] The present invention has the following beneficial effects: The TCN of the present invention is a deep learning model specially designed for time series data, which can effectively capture long-term dependencies in time series. It can expand the receptive field without increasing the computational complexity through causal convolution and dilated convolution, so as to better capture the long-term dependencies in time series. The introduction of the linear attention mechanism further enhances the model's ability to focus on key features. It can dynamically adjust the model's attention to different input features, thereby improving the model's prediction accuracy. At the same time, the computational complexity of the linear attention mechanism is relatively low, and it will not significantly increase the burden of the model. The change in data distribution is judged by calculating the relative entropy of historical data and real-time data. Relative entropy is an indicator that measures the difference between two probability distributions and can effectively detect mutations in data distribution. When the relative entropy exceeds the threshold, online learning is triggered and the model parameters are dynamically updated. This mechanism enables the model to capture changes in data distribution in a timely manner and ensure the prediction accuracy of the model in a dynamic environment. TCN combined with the linear attention mechanism can better capture long-term dependencies and key features in time series data, thereby improving the accuracy of error prediction. The introduction of the linear attention mechanism enables the model to focus on key features more effectively, further improving the accuracy and stability of prediction. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] Figure 1 The present invention is a flowchart for implementing the method.

[0014] Figure 2 It is a structural diagram of the error prediction model of the present invention. DETAILED DESCRIPTION

[0015] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0016] It should be understood that the step numbers used in this document are only for convenience of description and are not intended to limit the order in which the steps are executed.

[0017] It should be understood that the terms used in the present specification are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the present specification and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.

[0018] The terms “include” and “comprising” indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.

[0019] The term "and / or" means and includes any and all possible combinations of one or more of the associated listed items.

[0020] Embodiment 1: See also Figure 1 The present invention provides an electronic voltage transformer error prediction method, comprising the following steps: Collect historical operation data of the electronic voltage transformer, the operation data including temperature, humidity, load voltage, secondary voltage and historical ratio error value (the historical ratio error value is obtained by offline detection during the historical operation of the transformer and stored in the database, and can be directly obtained); Select the time series convolutional neural network TCN as the base and combine it with linear attention to build an error prediction model; Using the historical operating data to perform offline learning on the error prediction model; Collecting real-time operating data of the electronic voltage transformer, calculating the relative entropy of the historical operating data and the real-time operating data and setting a distribution threshold, if the relative entropy is greater than the distribution threshold, performing online learning on the error prediction model through the real-time operating data to update the parameters of the error prediction model; The error prediction model is used to predict the error of the electronic voltage transformer.

[0021] The error prediction model proposed in the present invention is consistent with the TCN model in terms of overall structure. Its innovation lies in the calculation process of nodes in the network layer. The TCN model only relies on dilated causal convolution for layer-by-layer calculation, while the error prediction model provided by the present invention adds a linear attention mechanism to the convolution calculation of each layer. Take the calculation process of the last node of hidden layer 1 as an example. At this time, if the last two nodes of the input layer are and , then the last node of hidden layer 1 The calculation process is: through the last two nodes of the input layer and Perform convolution calculations and then add the convolution calculation results to the penultimate node of hidden layer 1 Perform linear attention calculation, the result of which is the last node of hidden layer 1 .

[0022] See also Figure 2 As a preferred implementation, the error prediction model adds a linear attention mechanism to the convolution calculation of each layer; Specifically expressed as: ; ; in, Represents the input value of the tth node in the input layer and the input value of the t-1th node in the input layer The calculation result of the dilated causal convolution (in this embodiment, the t-th node is the last node, and the t-1-th node is the second to last node), , represents the weight matrix (obtained by random initialization), represents the bias term, represents the output value of the tth node in the hidden layer 1, represents the learnable parameter matrix, represents the hyperbolic tangent activation function, Indicates that and the output value of the t-1th node in hidden layer 1 Perform vector stitching.

[0023] The above calculation process describes the calculation process of the output value of a node in the network layer of the improved TCN. The calculation of the entire network is to perform the above node calculations one by one from the input layer through the hidden layer to the output layer.

[0024] like Figure 2 The figure shows the structure diagram of the error prediction model provided by the present invention. The TCN network has limited use of past time series information and cannot rely well on the effective information in the historical data when updating information. The present invention improves its internal calculation structure through linear attention, so that the error prediction model can adaptively weigh the weights assigned to new data features when the model is updated through online learning. For inputs at time points corresponding to weak correlation with historical time data, the model will rely more on the most recent input information, while for some time points with strong correlation, it can make more use of past input information.

[0025] As a preferred implementation, the relative entropy is calculated as follows: Let the historical sample data set composed of the historical operation data of the electronic voltage transformer be S, and the length of the historical sample data set be N; Let the target sample data set composed of the real-time operation data of the electronic voltage transformer be T, and the length of the target sample data set be M; Divide the historical sample data set S into Several historical subsample sets of length M ; Calculate the i-th historical subsample set Relative entropy with the target sample data set T : ; in, Represents the data sample probability distribution of the target sample data set T, Indicates Historical subsamples The probability distribution of the data sample is Indicates the preset maximum number, Indicates The data sample is in Historical subsamples The probability of occurrence in Indicates The probability that a data sample appears in the target sample data set T.

[0026] As a preferred implementation, the steps of offline learning include: S1, randomly initialize the weights of the error prediction model; S2, input the historical operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; S3, using the loss function to calculate the loss value between the predicted result and the preset true label; S4. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; S5. Execute step S2 until the loss value is less than or equal to the preset loss threshold to complete offline learning.

[0027] As a preferred implementation, the steps of online learning include: D1. Load the error prediction model learned offline; D2, preset configuration, including learning algorithm and learning rate; D3, input the real-time operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; D4. Use the loss function to calculate the loss value of the predicted result and the preset true label; D5. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; D6. Execute step D3 until the loss value is less than or equal to the preset loss threshold to complete the online learning.

[0028] In this embodiment, online learning and offline learning are both common model training methods in deep learning and are not limited here.

[0029] Embodiment 2: The present invention also provides an electronic voltage transformer error prediction system, comprising: Data acquisition module: collects historical operation data of the electronic voltage transformer, the operation data including temperature, humidity, load voltage, secondary voltage and historical ratio error value; Model building module: Select the time series convolutional neural network TCN as the base and combine it with linear attention to build an error prediction model; Offline learning module: using the historical operation data to perform offline learning on the error prediction model; Data comparison module: collects real-time operation data of the electronic voltage transformer, calculates the relative entropy of the historical operation data and the real-time operation data and sets the distribution threshold. If the relative entropy is greater than the distribution threshold, the error prediction model is online learned through the real-time operation data to update the parameters of the error prediction model; Error prediction module: uses the error prediction model to predict the error of the electronic voltage transformer.

[0030] The system is used to implement the method in Example 1, which will not be described in detail here.

[0031] In the embodiments of the present application, "at least one" refers to one or more, and "more than one" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent the existence of A alone, the existence of A and B at the same time, and the existence of B alone. Among them, A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following" and similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b and c can be represented by: a, b, c, a and b, a and c, b and c, or a and b and c, where a, b, c can be single or multiple.

[0032] Those of ordinary skill in the art will appreciate that the various units and algorithm steps described in the embodiments disclosed herein can be implemented in a combination of electronic hardware, computer software, and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0033] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0034] In several embodiments provided in the present application, if any function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, 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, which is stored in a storage medium and includes 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 application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory; hereinafter referred to as: ROM), random access memory (Random Access Memory; hereinafter referred to as: RAM), disk or optical disk, and other media that can store program codes.

[0035] The above descriptions are merely embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A method for predicting an error of an electronic voltage transformer, characterized in that: The following steps are involved: The method comprises the following steps: collecting historical operation data of an electronic voltage transformer, wherein the operation data includes temperature, humidity, load voltage, secondary voltage and historical ratio error value; selecting a time series convolutional neural network TCN as a base and combining it with linear attention to construct an error prediction model; using the historical operation data to perform offline learning on the error prediction model; collecting real-time operation data of the electronic voltage transformer, calculating the relative entropy of the historical operation data and the real-time operation data and setting a distribution threshold, and if the relative entropy is greater than the distribution threshold, performing online learning on the error prediction model through the real-time operation data to update the parameters of the error prediction model; and using the error prediction model to predict the error of the electronic voltage transformer.

2. The electronic voltage transformer error prediction method according to claim 1, characterized in that: The error prediction model adds a linear attention mechanism to the convolution calculation of each layer, which is specifically expressed as follows: ; ; in, Represents the input value of the tth node in the input layer and the input value of the t-1th node in the input layer The calculation results of the dilated causal convolution are: , represents the weight matrix, represents the bias term, represents the output value of the tth node in the hidden layer 1, represents the learnable parameter matrix, represents the hyperbolic tangent activation function.

3. The electronic voltage transformer error prediction method according to claim 1, characterized in that: The relative entropy is calculated as follows: Let the historical sample data set composed of the historical operation data of the electronic voltage transformer be S, and the length of the historical sample data set be N; Let the target sample data set composed of the real-time operation data of the electronic voltage transformer be T, and the length of the target sample data set be M; Divide the historical sample data set S into Several historical subsample sets of length M ; Calculate the i-th historical subsample set Relative entropy with the target sample data set T : ; in, Represents the data sample probability distribution of the target sample data set T, Indicates Historical subsamples The probability distribution of the data sample is Indicates the preset maximum number, Indicates The data sample is in Historical subsamples The probability of occurrence in Indicates The probability that a data sample appears in the target sample data set T.

4. The electronic voltage transformer error prediction method according to claim 1, characterized in that ,The steps of offline learning include: S1, randomly initialize the weights of the error prediction model; S2, input the historical operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; S3, using the loss function to calculate the loss value between the predicted result and the preset true label; S4. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; S5. Execute step S2 until the loss value is less than or equal to the preset loss threshold to complete offline learning.

5. The electronic voltage transformer error prediction method according to claim 1, characterized in that ,The steps of online learning include: D1. Load the error prediction model learned offline; D2, preset configuration, including learning algorithm and learning rate; D3, input the real-time operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; D4. Use the loss function to calculate the loss value of the predicted result and the preset true label; D5. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; D6. Execute step D3 until the loss value is less than or equal to the preset loss threshold to complete the online learning.

6. An electronic voltage transformer error prediction system, characterized in that: include: Data acquisition module: collects historical operation data of the electronic voltage transformer, the operation data including temperature, humidity, load voltage, secondary voltage and historical ratio error value; Model building module: Select the time series convolutional neural network TCN as the base and combine it with linear attention to build an error prediction model; Offline learning module: using the historical operation data to perform offline learning on the error prediction model; Data comparison module: collects real-time operation data of the electronic voltage transformer, calculates the relative entropy of the historical operation data and the real-time operation data and sets the distribution threshold. If the relative entropy is greater than the distribution threshold, the error prediction model is online learned through the real-time operation data to update the parameters of the error prediction model; Error prediction module: uses the error prediction model to predict the error of the electronic voltage transformer.

7. The electronic voltage transformer error prediction system according to claim 6, characterized in that: The error prediction model adds a linear attention mechanism to the convolution calculation of each layer, which is specifically expressed as follows: ; ; in, Represents the input value of the tth node in the input layer and the input value of the t-1th node in the input layer The calculation results of the dilated causal convolution are: , represents the weight matrix, represents the bias term, represents the output value of the tth node in the hidden layer 1, represents the learnable parameter matrix, represents the hyperbolic tangent activation function.

8. The electronic voltage transformer error prediction system according to claim 6, characterized in that: The relative entropy is calculated as follows: Let the historical sample data set composed of the historical operation data of the electronic voltage transformer be S, and the length of the historical sample data set be N; Let the target sample data set composed of the real-time operation data of the electronic voltage transformer be T, and the length of the target sample data set be M; Divide the historical sample data set S into Several historical subsample sets of length M ; Calculate the i-th historical subsample set Relative entropy with the target sample data set T : ; in, Represents the data sample probability distribution of the target sample data set T, Indicates Historical subsamples The probability distribution of the data sample is Indicates the preset maximum number, Indicates The data sample is in Historical subsamples The probability of occurrence in Indicates The probability that a data sample appears in the target sample data set T.

9. The electronic voltage transformer error prediction system according to claim 6, characterized in that ,The steps of offline learning include: S1, randomly initialize the weights of the error prediction model; S2, input the historical operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; S3, using the loss function to calculate the loss value between the predicted result and the preset true label; S4. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; S5. Execute step S2 until the loss value is less than or equal to the preset loss threshold to complete offline learning.

10. The electronic voltage transformer error prediction system according to claim 6, characterized in that ,The steps of online learning include: D1. Load the error prediction model learned offline; D2, preset configuration, including learning algorithm and learning rate; D3, input the real-time operation data into the error prediction model, and perform forward calculation through the convolution layer, residual layer, and output layer to obtain the prediction result; D4. Use the loss function to calculate the loss value of the predicted result and the preset true label; D5. Calculate the gradient using the chain rule based on the loss value and update the model parameters based on the gradient; D6. Execute step D3 until the loss value is less than or equal to the preset loss threshold to complete the online learning.

Citation Information

Patent Citations

  • Capacitive voltage transformer error prediction method and device

    CN114692505A

  • CVT error state prediction method and device based on incremental ensemble learning model

    CN115169704A

  • Electronic voltage transformer error prediction method based on Prophet, self-attention mechanism and time sequence convolutional network

    CN115438576A

  • Updating prediction model

    US20150302318A1

Cited By

  • Adaptive control system based on optical measurement 10KV outdoor mutual inductor

    CN120222635A

  • Electric energy meter error prediction method and system based on Internet of Things

    CN120742221A

  • Error state prediction method and system for direct-current voltage transformer

    CN121365216A

  • Electronic voltage transformer error prediction method and system

    CN121995294A

  • An electronic voltage transformer error prediction method and system

    CN121995294B