Electricity automatic calibration method based on smart meter
By constructing a time window feature matrix and a multiple linear regression equation, the problem of nonlinear superposition line loss interference from multiple households consuming electricity simultaneously in existing technologies is solved, thus achieving accurate decoupling and stable calibration of metering errors.
Patent Information
- Application Number
- CN202611674005.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-28
- Publication Date
- 2026-11-27
AI Technical Summary
Existing software-based automatic calibration methods cannot accurately isolate the nonlinear superposition line loss interference caused by multiple households using electricity simultaneously, resulting in serious distortion of meter measurement errors and the inability to achieve stable closed-loop calibration, especially in the absence of underlying wiring diagrams.
By acquiring the frozen electricity and average current of the transformer's main meter and sub-meters within a time window, a time window feature matrix is constructed. Feature decomposition and sub-meter clustering are then performed to establish a multiple linear regression equation. The metering error coefficient is then solved and converted into a multiplicative correction coefficient, which is sent to the management software for numerical rounding of the underlying raw electricity.
In the absence of underlying wiring diagrams, the incremental local nonlinear line loss caused by the superposition of multiple households' simultaneous electricity consumption was accurately quantified, achieving complete decoupling and extraction of metering errors and enabling accurate and stable remote closed-loop calibration.
Smart Images

Figure CN123176647A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electricity meter calibration technology, and more specifically to an automatic electrical calibration method based on smart meters. Background Technology
[0002] In the daily operation and settlement of low-voltage power distribution networks, smart meters, as core terminals, experience physical aging and performance degradation of their internal analog-to-digital conversion and metering components as their service life increases, resulting in imperceptible one-way drift errors in the meter readings.
[0003] Existing software-based automatic calibration methods are typically based on the principle of energy conservation in distribution areas. This involves subtracting the total electricity consumption of individual meters from the total electricity consumption, then further subtracting a fixed percentage for line losses, and considering the remaining difference as meter error. However, in practical engineering applications, the line losses in distribution networks exhibit non-linear variations with load fluctuations. Without access to the underlying wiring diagrams, conventional estimation algorithms cannot accurately isolate the non-linear superimposed line loss interference caused by simultaneous electricity consumption by multiple households, leading to severely distorted error extraction and ultimately preventing stable closed-loop calibration. Summary of the Invention
[0004] To address the issue that in practical engineering applications, the line losses in power distribution networks exhibit nonlinear variations with load fluctuations. Furthermore, in the absence of underlying wiring diagrams, conventional estimation algorithms cannot accurately isolate the nonlinear superimposed line loss interference caused by simultaneous power consumption by multiple households, leading to severely distorted error extraction and ultimately hindering stable closed-loop calibration. This invention aims to provide an automatic electrical calibration method based on smart meters, with the specific technical solution as follows: Obtain the frozen power of the transformer's total meter and each sub-meter within each preset time window, as well as the average current of each sub-meter within the time window. Within each preset time window, the line loss characteristic variable of a single meter is calculated based on the numerical characteristics of the average current of the sub-meters within the time window; the difference characteristics of the frozen electricity between the transformer main meter and each sub-meter are analyzed to obtain the difference in electricity between the main meter and the sub-meters, and a time window characteristic matrix is formed by combining the line loss characteristic variable of a single meter, the frozen electricity, and the average current of the time window under all preset time windows. Based on the correlation between the average current of each sub-table in the time window feature matrix, feature decomposition and sub-table clustering are performed to obtain a sub-table set; after the cumulative number of time window rows in the time window feature matrix meets the full rank condition determined by the number of sub-table sets, the numerical characteristics of the average current of the time window in the same sub-table set in the time window feature matrix are analyzed under each preset time window to obtain the trunk line superimposed line loss characteristic variable for each preset time window. Based on the difference in electricity consumption between the main meter and sub-meters, the line loss characteristic variables of individual meters, the superimposed line loss characteristic variables of each trunk line, and the frozen electricity consumption of each sub-meter, a multiple linear regression equation is established for the line loss fitting coefficient and the meter measurement error coefficient. The meter measurement error coefficient of each sub-meter is obtained by solving the multiple linear regression equation. The meter measurement error coefficient is converted into a multiplication correction coefficient and sent to the management software of the corresponding sub-meter for numerical rounding of the underlying original electricity consumption.
[0005] Furthermore, the method for obtaining the single-meter line loss characteristic variables includes: Under each preset time window, the average current of all sub-meters under each time window is independently squared and then summed to obtain the single-meter line loss characteristic variable under each preset time window.
[0006] Furthermore, the method for obtaining the difference in power consumption between the main meter and the sub-meter includes: Within each preset time window, the sum of the frozen electricity of all sub-meters is taken as the cumulative electricity sum, and the difference between the frozen electricity of the transformer main meter and the cumulative electricity sum is taken as the total sub-meter electricity difference under each preset time window.
[0007] Furthermore, the method for obtaining the time window feature matrix includes: The total power difference between the sub-meters, the line loss characteristic variables of a single meter, the frozen power of all sub-meters, and the average current of each sub-meter within each preset time window are packaged and assembled into tuple data of a single row dimension. According to the time sequence of the preset time windows, the tuple data corresponding to each preset time window are sequentially appended and pushed into the storage space, and the time window feature matrix is constructed by accumulating row by row.
[0008] Furthermore, the method for obtaining the set of partitioned tables includes: Extract the current time series data composed of the average current of each sub-table under all preset time windows in the time window feature matrix; Calculate the Pearson correlation coefficient of current time series data between any two sub-tables to construct an adjacency matrix. Based on the adjacency matrix, obtain the corresponding standardized Laplace matrix. Perform eigenvalue decomposition on the standardized Laplace matrix to obtain all eigenvalues and their corresponding eigenvectors. After removing the feature values with a value of 0, the remaining feature values are arranged into an increasing sequence. The first-order difference sequence of the feature values in the increasing sequence is calculated. In the first-order difference sequence, the position index corresponding to the maximum difference is obtained, and the position index value is determined as the optimal K value. Extract the K feature vectors corresponding to the first K feature values in the increasing sequence, combine them column by column to form a K-column feature space matrix, and use the K-means clustering algorithm to perform cluster analysis on all row vectors of the feature space matrix to obtain all the sub-table sets. Each row vector of the feature space matrix corresponds to a sub-table, and the distance metric is the Euclidean distance between the row vectors.
[0009] Furthermore, the method for obtaining the trunk line superimposed line loss characteristic variables includes: For each sub-table set, extract the average current of all sub-tables belonging to that sub-table set in the time window feature matrix under each preset time window; Under each preset time window, the average current of all sub-meters in the same sub-meter set is accumulated to obtain the total overlapping current of each sub-meter set under each preset time window; The total overlapping current is squared to obtain the trunk line superimposed line loss characteristic variable of each sub-table set under each preset time window.
[0010] Furthermore, the method for obtaining the multiple linear regression equation includes: The total meter-to-meter power difference, single meter line loss characteristic variable, superimposed line loss characteristic variable of each trunk line, and frozen power of each sub-meter in the time window feature matrix are standardized respectively. The standardized total meter-to-meter power difference is used as the prediction target variable, and the standardized single meter line loss characteristic variable, superimposed line loss characteristic variable of each trunk line, and frozen power of each sub-meter are used as independent variables. A linear equation containing the sum of the following parts is constructed as a multiple linear regression equation: Under each preset time window, the standardized single-meter line loss characteristic variable is multiplied by the single-meter line loss fitting coefficient to be solved to obtain the first product factor; the standardized trunk line superimposed line loss characteristic variable is multiplied by the trunk line loss fitting coefficient to be solved to obtain the second product factor; the standardized sub-meter frozen electricity is multiplied by the standardized meter measurement error coefficient to be solved to obtain the third product factor. A linear equation is constructed in which the sum of the first product factor, the second product factor of all sub-meter sets, and the third product factor of all sub-meters equals the predicted target variable, which serves as the multiple linear regression equation.
[0011] Furthermore, the method for obtaining the metering error coefficient includes: The target loss function is set as the mean square error between the predicted electricity difference obtained from the established multiple linear regression equation and the predicted target variable. In the loss function, only the L1 norm absolute value penalty term is applied to the standardized meter measurement error coefficient to be solved. Initiate the regression algorithm to iteratively solve for the global minimum of the target loss function, so that the standardized metering error coefficients corresponding to some sub-meters converge to 0, and solve for the standardized metering error coefficients of each sub-meter. The standardized meter measurement error coefficient is calculated by multiplying the standard deviation of the total electricity consumption difference between the sub-meters under all preset time windows, and the result is used as the numerator. The sum of the standard deviation of the frozen electricity consumption of the corresponding sub-meters under all preset time windows and the preset parameters is used as the denominator to obtain the meter measurement error coefficient of each sub-meter.
[0012] Furthermore, the step of converting the metering error coefficient into a multiplication correction coefficient and sending it to the management software of the corresponding sub-meter for rounding off the underlying original electricity value includes: Using constant 1 as the numerator and the sum of constant 1 and the metering error coefficient of each sub-meter as the denominator, the resulting ratio is used as the error equivalent offset ratio for each sub-meter. Obtain the historical absolute correction ratio for each sub-table, multiply the historical absolute correction ratio by the error equivalent offset ratio to obtain the latest absolute correction ratio, and determine whether the absolute value of the difference between the latest absolute correction ratio and the benchmark value exceeds the preset compensation limit threshold, where the benchmark value is a constant 1. If the value is not exceeded, the latest absolute correction ratio is subtracted from the benchmark value to obtain the multiplication correction coefficient, and the multiplication correction coefficient is packaged and sent to the management software of the corresponding sub-table. If the value is exceeded, the sending action to the corresponding sub-table is truncated, and a table replacement maintenance work order is generated.
[0013] Furthermore, the methods for setting the full-rank condition include: The number of sub-table sets inferred from clustering is taken as the total number of trunk lines; The sum of the total number of sub-tables, the total number of trunk lines, and the constant 1 is used as the judgment threshold. When the cumulative number of time window rows in the time window feature matrix is greater than the judgment threshold, it is determined that the full rank condition is met.
[0014] The present invention has the following beneficial effects: First, within each preset time window, the frozen electricity and average current of the transformer's main meter and each sub-meter are obtained. Because line loss is not fixed but changes non-linearly with the current, the average current characteristics of the sub-meters within the time window are extracted to generate single-meter line loss characteristic variables, establishing a feature mapping strongly correlated with the actual loss situation. Simultaneously, since meter errors cannot be directly measured and need to be calculated through residual derivation, and the electricity flowing out of the main meter is not equal to the sum of the electricity used by all sub-meters (the difference being line loss and error), the difference characteristics of the frozen electricity between the main meter and sub-meters are analyzed to obtain the total and sub-meter electricity difference, thereby constructing a time window feature matrix. This provides a high-level data foundation with dimension alignment for error stripping in subsequent complex scenarios. Furthermore, by performing feature decomposition and sub-meter clustering based on the correlation of average current within a time window, sub-meter sets are obtained. After satisfying the full-rank condition determined by the number of sub-meter sets, the characteristic variables of trunk line superposition line loss are calculated. This allows for the automatic deduction of the shared trunk line topology for users even without physical wiring diagrams of the transformer substations. This enables precise quantification of the local nonlinear line loss increment caused by the superposition of multiple households' simultaneous electricity consumption, overcoming the calculation interference caused by using a fixed proportion of line loss deduction. Next, a multiple linear regression equation is established by integrating various line loss characteristic variables and electricity data to solve for the meter measurement error coefficient. This coefficient is then converted into a multiplicative correction coefficient and sent to the management software of the corresponding sub-meter for numerical rounding of the underlying original electricity consumption. This allows for the complete decoupling and extraction of line loss fluctuation interference and actual meter error, ultimately achieving accurate, stable, and fully automatic remote closed-loop calibration. Attached Figure Description
[0015] Figure 1 This is a flowchart illustrating an automatic electrical calibration method based on a smart meter, as provided in one embodiment of the present invention. Detailed Implementation
[0016] The following description, in conjunction with the accompanying drawings, details a specific scheme for an automatic electrical calibration method based on a smart meter provided by the present invention.
[0017] Please see Figure 1 The diagram illustrates a flowchart of an automatic electrical calibration method based on a smart meter according to an embodiment of the present invention. The method includes the following steps: Step S1: Obtain the frozen power of the transformer's total meter and each sub-meter within each preset time window, as well as the average current of each sub-meter within the time window.
[0018] First, based on a unified clock reference, consecutive preset time windows are divided according to a fixed time step (e.g., set to 1 hour). At the end of each preset time window (i.e., at the hour), the electricity information collection master station or the smart edge gateway deployed on the transformer substation side sends a frozen data recall command to the transformer substation equipment through a low-voltage power line carrier (HPLC) communication network or a low-power wireless communication network. This command is used to read the periodic frozen electricity of the transformer's low-voltage side main meter at that moment. At the same time, according to the transformer substation file, the periodic frozen electricity of the smart meters (i.e., each sub-meter) of all terminal users under that substation is read concurrently. Thus, the frozen electricity of the transformer main meter and each sub-meter within each preset time window is obtained.
[0019] Since current is a transient value that fluctuates in real time with the load, in order to accurately characterize the electricity consumption and heating level within the entire preset time window, high-frequency polling sampling needs to be performed on each sub-meter. Within the same preset time window, the electricity information acquisition master station sends dense sampling instructions to each smart meter. As a specific sampling frequency setting, the instantaneous effective current value of each sub-meter can be captured in real time at a cycle of once every 5 minutes (for example, within a 1-hour time window, a total of 12 effective current readings are captured for each sub-meter). Subsequently, all high-frequency effective current readings collected by each sub-meter within the current time window are summed and divided by the total number of samplings to calculate the time window average current of each sub-meter within the preset time window.
[0020] Step S2: Within each preset time window, calculate the single-meter line loss characteristic variable based on the numerical characteristics of the average current of the sub-meters within the time window; analyze the difference characteristics of the frozen electricity between the transformer main meter and each sub-meter to obtain the total sub-meter electricity difference, and combine the single-meter line loss characteristic variable, frozen electricity and average current of the time window under all preset time windows to form a time window characteristic matrix.
[0021] Since it is impossible to obtain the physical resistance parameters of the conductors of each end user, it is not possible to directly calculate the Joule loss power using physical formulas. Therefore, by using the numerical characteristics of the average current of each sub-meter within its time window, the nonlinear power consumption trend of the line can be equivalently replaced to obtain the single-meter line loss characteristic variable, which can be used to fit the line loss power that absorbs fluctuations in the subsequent process.
[0022] Preferably, in one embodiment of the present invention, the method for obtaining the characteristic variables of single-meter line loss includes: Based on Joule's law, it is known that power loss is proportional to the square of the current. Therefore, under each preset time window, the average current of all sub-meters in each time window is independently squared and then summed to obtain the single-meter line loss characteristic variable under each preset time window. The single-meter line loss characteristic variable integrates discrete user losses into a global feature. The larger the value, the higher the cumulative line loss trend benchmark on all independent conductors at the end of the transformer area that do not have current crossover within the preset time window.
[0023] The amount of electricity flowing out of the main transformer meter in the distribution area is not equal to the sum of the electricity consumption of each sub-meter. The difference in electricity is the line loss and meter error. Therefore, within each preset time window, the difference between the frozen electricity of the main transformer meter and the frozen electricity of the sub-meters is analyzed to obtain the total electricity difference between the main and sub-meters, which can represent the total amount of electricity lost.
[0024] Preferably, in one embodiment of the present invention, the method for obtaining the difference in power consumption between the main meter and the branch meter includes: Within each preset time window, the sum of the frozen electricity consumption of all sub-meters is used as the cumulative electricity consumption sum. This sum is used to summarize the total meter readings of all end users in the transformer area within each preset time window. The larger the cumulative electricity consumption sum, the more cumulative electricity consumption of all end users in the transformer area is officially recorded by the equipment. Then, the difference between the frozen electricity consumption of the transformer's main meter and the cumulative electricity consumption sum is calculated as the total electricity consumption difference between the main and sub-meters under each preset time window. The larger the total electricity consumption difference between the main and sub-meters, the more total mixed error electricity consumption is caused by line physical losses and missed recordings due to meter aging within the corresponding preset time window.
[0025] Since the data from a single time window is only a snapshot, and the aging error of the meter is a long-term systematic deviation, multiple unknown variables can only be calculated through data accumulation. Therefore, the discrete total and sub-meter power difference, single meter line loss characteristic variables, frozen power of each sub-meter, and average current of the time window are spliced and combined to form a dimension-aligned time window feature matrix, which provides a full-rank data foundation for the fitting and solution of the subsequent multiple linear regression equation.
[0026] Preferably, in one embodiment of the present invention, the method for obtaining the time window feature matrix includes: Because the heterogeneous data sources generated by the transformer substations are scattered, encapsulating related variables such as the difference in total and sub-meter power consumption and individual meter line loss characteristics within the same time slice can eliminate time-series misalignments when formulating subsequent equations. Therefore, the total and sub-meter power consumption difference, individual meter line loss characteristics, frozen power consumption of all sub-meters, and average current of each sub-meter within each preset time window are packaged and assembled into single-row tuple data. This ensures strict temporal alignment and structured binding of various data within the same preset time window, and the dimensional span of the tuple data at this point represents the scale of the monitored objects in the transformer substation.
[0027] Then, according to the time sequence of the preset time windows, the tuple data corresponding to each preset time window are sequentially appended and pushed into the storage space, and the time window feature matrix is constructed by accumulating rows. At this time, the rows of the time window feature matrix represent the time series, that is, each row represents an independent preset time window, and the columns of the time window feature matrix represent the feature dimensions of the data. For example, the first column is the difference between the total and sub-meter power consumption, the second column is the single meter line loss feature variable, the third to N+2 columns are the frozen power consumption of all N sub-meters, and the N+3 to 2N+2 columns are the average current of all N sub-meters within the time window.
[0028] Step S3: Based on the correlation between the average current of each sub-table in the time window feature matrix, perform feature decomposition and sub-table clustering to obtain the sub-table set; after the cumulative number of time window rows in the time window feature matrix meets the full rank condition determined by the number of sub-table sets, analyze the numerical characteristics of the average current of the sub-table in the same sub-table set in the time window feature matrix under each preset time window to obtain the trunk line superimposed line loss characteristic variable for each preset time window.
[0029] Since the actual line losses in a distribution network are not linearly cumulative, when multiple users belonging to the same trunk line consume electricity simultaneously during peak hours, the resulting overlapping current can cause a nonlinear surge in local line losses. If these user combinations connected in parallel on the same trunk line cannot be identified, this surge in additional line losses cannot be isolated, and it will be incorrectly attributed to meter errors. Therefore, in this embodiment of the invention, by analyzing the correlation of current waveforms based on the average current of each sub-meter in the time window feature matrix and performing clustering, sub-meters with highly synchronized electricity consumption fluctuations can be automatically grouped into a single sub-meter set, thereby providing the necessary topological reference for eliminating interference from local trunk lines.
[0030] Preferably, in one embodiment of the present invention, the method for obtaining the set of partitioned tables includes: First, extract the current time series data composed of the average current of each sub-table under all preset time windows in the time window feature matrix.
[0031] Then, the Pearson correlation coefficient of the current time series data between any two sub-meters is calculated to construct the adjacency matrix. When calculating the Pearson correlation coefficient, a preset minimum positive number (such as 0.001) is added to the denominator to prevent the variance from becoming zero due to long-term power outages by users, which could cause the program to crash due to division by zero. The magnitude of the Pearson correlation coefficient represents the degree of synchronization of the power consumption fluctuations of the two sub-meters. The closer the value is to 1, the more synchronized the current fluctuations of the two meters are, and the greater the probability that they share the same trunk line physically. The adjacency matrix constructed in this way is a panoramic probability map of the electrical coupling strength of the transformer substation area.
[0032] Since the adjacency matrix obtained from the aforementioned steps is large in dimension and contains a lot of noise, a corresponding normalized Laplace matrix is obtained based on the adjacency matrix. Then, eigenvalue decomposition is performed on the normalized Laplace matrix to obtain all eigenvalues and their corresponding eigenvectors. The eigenvalues characterize the difficulty of separation or structural independence between different electrical trunks in the physical topology of the transformer area. In the graph theory decomposition of the Laplace matrix, the smaller the eigenvalue, the easier it is for the corresponding physical trunk network to be isolated from the complex relationship of the entire transformer area. The eigenvectors characterize the trunk identity coordinates of each sub-table after removing transient random power consumption noise.
[0033] After removing eigenvalues with a value of 0, the remaining eigenvalues are arranged into an increasing sequence. The points where a large drop (maximum first-order difference) occurs in this increasing sequence physically represent the complete decomposition and exhaustion of all truly independent trunk line combinations within the transformer substation. Therefore, the location of this jump point directly reveals the actual number of existing trunk lines in the substation. Thus, the first-order difference sequence of the eigenvalues in the increasing sequence is calculated. Within this sequence, the location index corresponding to the maximum difference is obtained, and this location index is determined as the optimal K value. At this point, the first K eigenvectors correspond to the K most prevalent local power supply modes within the transformer substation. The specific values contained within each eigenvector represent the participation or response weight of each sub-meter to this specific power supply mode.
[0034] When multiple table partitions have highly similar coordinate values in the extracted feature vector space, it means they are highly bound in terms of macroscopic electrical and physical characteristics, and therefore should be connected to the same physical cable in terms of physical topology. Therefore, we extract the K eigenvectors corresponding to the first K eigenvalues in the increasing sequence, combine them column-wise into a K-column feature space matrix, and use the K-means clustering algorithm to perform cluster analysis on all row vectors of the feature space matrix to obtain all table partition sets. Each row vector of the feature space matrix corresponds to one table partition, and the distance metric is the Euclidean distance between the row vectors.
[0035] It should be noted that the K-means clustering algorithm is a well-known technique, and the specific process will not be described in detail here.
[0036] Because the regression algorithm used in subsequent steps needs to accurately extract the error coefficients and line loss fitting coefficients of multiple sub-tables, which is a solution of a system of multiple linear equations, the cumulative number of historical time windows (i.e., the number of equations / the number of matrix rows) must be greater than the total number of unknowns (determined by the total number of sub-tables and the number of sub-table trunk sets just calculated). Therefore, it is necessary to determine whether the number of time window rows accumulated by the time window feature matrix satisfies the full rank condition determined by the number of sub-table sets.
[0037] Preferably, in one embodiment of the present invention, the method for setting the full-rank condition includes: The number of sub-table sets inferred from clustering is taken as the total number of trunk lines. The larger the value, the more branches the power grid has in the region, and the larger the dimension of the parameters that need to be solved.
[0038] In linear algebra theory, to accurately solve for each unknown (including N sub-meter errors, K trunk line losses, and 1 substation single-meter bus loss), the number of equations (i.e., the number of rows M of the historical time window matrix) must be strictly greater than the total number of all unknowns (N+K+1). Therefore, the sum of the total number of sub-meters, the total number of trunk lines, and the constant 1 is used as the judgment threshold. Only when the cumulative number of time window rows in the time window feature matrix is strictly greater than the judgment threshold is the full rank condition determined to be satisfied.
[0039] After satisfying the full rank condition, in order to isolate and quantify the large amount of nonlinear losses caused by concentrated power consumption in the transformer area, the numerical characteristics of the average current of the time window in the same sub-meter set can be analyzed under each preset time window to obtain the characteristic variables of the main line superimposed line loss of each preset time window.
[0040] It should be noted that if the full rank condition is not met, the calculation of the trunk line superimposed line loss characteristic variables and the subsequent solution steps of the multiple linear regression equation within the current preset time window will be skipped, and the data will continue to accumulate in the next preset time window.
[0041] Preferably, in one embodiment of the present invention, the method for obtaining the characteristic variables of trunk line superimposed line loss includes: After determining the sub-meter set, since the sub-meters in each sub-meter set can be regarded as belonging to the same trunk line, the user currents on this trunk line will overlap and physically interfere with each other. Therefore, for each sub-meter set, the average current of all sub-meters belonging to the sub-meter set in the time window feature matrix under each preset time window is extracted.
[0042] Then, because the branch currents of each household at the end of the physical trunk line converge on the main line, algebraic summation must be performed first to objectively simulate the electrical load state of this main power supply conductor under pressure within this time window. Therefore, under each preset time window, the average current of all sub-meters in the same sub-meter set is accumulated to obtain the overlapping total current of each sub-meter set under each preset time window. The magnitude of the overlapping total current represents the total load demand intensity gathered on this main line within the corresponding preset time window. The larger the value, the more congested the current peak electricity consumption period.
[0043] Finally, based on Joule's law for physical circuits, the total overlapping current is squared to obtain the trunk line superimposed line loss characteristic variable for each sub-meter set under each preset time window. The magnitude of the trunk line superimposed line loss characteristic variable represents the baseline destructive force contributed by the local traffic congestion-type heat caused by these users sharing the same cable to the total power loss. The larger the value, the more serious the superimposed heat of the trunk line, and the stronger the interference on the error assessment of the entire station area.
[0044] Step S4: Based on the difference in electricity consumption between the main meter and sub-meters, the line loss characteristic variables of individual meters, the superimposed line loss characteristic variables of each trunk line, and the frozen electricity consumption of each sub-meter, establish a multiple linear regression equation for the line loss fitting coefficient and the meter measurement error coefficient; solve the multiple linear regression equation to obtain the meter measurement error coefficient of each sub-meter; convert the meter measurement error coefficient into a multiplication correction coefficient and send it to the management software of the corresponding sub-meter for rounding the underlying original electricity value.
[0045] The difference between the total and sub-meter power consumption represents the total power loss in the distribution area. This difference includes heat generated by individual households using electricity independently, as well as the surge in heat generated by multiple households sharing the same line. It also includes the miscalculation of the proportion of faulty meters. If all the decisive factors are not placed under the same equation framework for a comprehensive comparison and fitting, it is impossible to determine which part of the electricity is lost due to line burnout and which part is lost due to meter leakage. Therefore, in this embodiment of the invention, a multivariate equation containing all line loss characteristics and power consumption data is established. This provides a data foundation for subsequent use of regression algorithms to forcibly remove physical interference from the chaotic fluctuations in the difference and to identify hidden meter faults.
[0046] Preferably, in one embodiment of the present invention, the method for constructing a multiple linear regression equation includes: Because the line loss characteristic variable includes the square of the current (which may be extremely large), while the value of the frozen electricity of individual meters is usually relatively small, the total electricity difference between individual meters, the line loss characteristic variable of a single meter, the line loss characteristic variable of each trunk line, and the frozen electricity of each individual meter in the time window characteristic matrix are first standardized. The standardized total electricity difference between individual meters is used as the target variable for prediction, and the standardized line loss characteristic variable of a single meter, the line loss characteristic variable of each trunk line, and the frozen electricity of each individual meter are used as independent variables. A linear equation containing the sum of the following parts is constructed as the multiple linear regression equation: Within each preset time window, the standardized single-meter line loss characteristic variable is multiplied by the single-meter line loss fitting coefficient to be solved, yielding the first product factor. The magnitude of the single-meter line loss fitting coefficient to be solved characterizes the overall comprehensive line diameter impedance level of the independent inlet conductor at the end of the transformer area. The larger the value, the more prevalent the overall heating and aging of the inlet conductor in that transformer area, and the greater the actual power loss per unit current characteristic. The standardized trunk line superimposed line loss characteristic variable is multiplied by the trunk line line loss fitting coefficient to be solved, yielding the second product factor. The trunk line line loss fitting coefficient to be solved... The magnitude of the line loss fitting coefficient characterizes the severe congestion and heating properties or the degree of physical material attenuation of a specific physical trunk line. The larger the value, the more electrical energy is wasted when the specific trunk cable bears the same superimposed load. Multiplying the standardized sub-meter frozen electricity by the standardized metering error coefficient to be solved yields the third product factor. The magnitude of the standardized metering error coefficient to be solved characterizes the severity of unidirectional drift and attenuation of the metering components inside a specific sub-meter. The larger the value, the more severely the meter's measurement accuracy has been distorted.
[0047] The total differential electricity loss in the distribution area (the target variable for prediction) can only be determined by the strict addition of three parts in the objective physical world: independent line losses of individual users, line losses due to main line congestion, and errors caused by faulty meters. Therefore, a linear equation is constructed where the sum of the first product factor, the second product factor of all sub-meter sets, and the third product factor of all sub-meters equals the target variable for prediction. This equation serves as the multiple linear regression equation. By constructing this equality relationship in the multiple linear regression equation, the solution algorithm can continuously test and err on the basis of historical data, ultimately decoupling and separating the mixed physical heat generation and metering errors.
[0048] After constructing the multiple linear regression equation, the equation can be solved to obtain the metering error coefficient for each sub-meter.
[0049] Preferably, in one embodiment of the present invention, the method for obtaining the metering error coefficient includes: For the established multiple linear regression equation, the target loss function is set as the mean square error between the predicted electricity difference (the estimated value calculated on the right side of the multiple linear regression equation) and the predicted target variable. In the loss function, only the L1 norm absolute value penalty term is applied to the standardized meter measurement error coefficients to be solved. The magnitude of the L1 norm absolute value penalty term (hyperparameter) represents the zero tolerance for normal meter fluctuations. The larger the value, the more ruthlessly the system squeezes the error coefficients, and the more meters will be forcibly identified as zero without any error, thus only revealing those aging meters whose miscalculations are too serious to be concealed.
[0050] Then, the regression algorithm is started to iteratively solve for the global minimum of the target loss function, so that the standardized metering error coefficients corresponding to some sub-meters converge to 0, and the standardized metering error coefficients of each sub-meter are solved.
[0051] Finally, because standardization was performed in the early stage to prevent algorithm failure, it needs to be reversed after the iteration. Therefore, the standardized meter measurement error coefficient is multiplied by the standard deviation of the total sub-meter electricity difference under all preset time windows and used as the numerator. The sum of the standard deviation of the frozen electricity of the corresponding sub-meter under all preset time windows and the preset parameter (which is used to prevent the denominator from being 0, and can be set to 0.001) is used as the denominator to obtain the meter measurement error coefficient of each sub-meter. At this time, the size of the meter measurement error coefficient obtained by reverse restoration directly represents the actual miscalculation percentage of the underlying hardware device of the corresponding sub-meter.
[0052] It should be noted that the specific value of the L1 norm absolute value penalty term in this embodiment of the invention can be dynamically determined using the K-fold cross-validation method. For example, the historical time window data accumulated in the time window feature matrix is divided into 5 time window data subsets, and 5-fold cross-validation is performed; the preset candidate hyperparameter value range (e.g., a discrete value distribution range including 0.001, 0.01, 0.1, and 1) is traversed, and 4 of the time window data subsets are used in turn for equation fitting each time, and the prediction residual is calculated on the remaining 1 time window data subset; the average mean square error of each candidate value in the cross-validation is calculated, and the candidate value that produces the smallest average mean square error is determined as the final specific value of the L1 norm absolute value penalty term.
[0053] While the aforementioned steps can obtain the error of each sub-meter, directly sending instructions to tamper with the original electricity stored in the underlying metering chip of the meter may cause significant engineering compliance risks. Therefore, by converting the error into an offset rounding ratio in reciprocal form and sending it to an independent management software layer, the management software can perform multiplication and rounding to offset the error after reading the original electricity data. This allows for a closed-loop calibration of the electricity output from the software side without physical isolation or modification of the underlying hardware data.
[0054] Preferably, in one embodiment of the present invention, the metering error coefficient is converted into a multiplication correction coefficient and sent to the management software of the corresponding sub-meter for rounding off the underlying original electricity value, including: Using constant 1 as the numerator and the sum of constant 1 and the metering error coefficient of each sub-meter as the denominator, the resulting ratio is used as the error equivalent offset ratio for each sub-meter. The magnitude of the error equivalent offset ratio indicates the direction and intensity of the calculated correction requirement. For example, an error equivalent offset ratio of 0.95 indicates that the meter reading in the current period is too fast and needs to be compressed downward by multiplying by this coefficient; if the calculated ratio is 1.03, it indicates that the meter reading is too slow and has been missed, and needs to be increased.
[0055] Then, the historical absolute correction ratio for each sub-table is obtained (the backend creates an independent absolute correction ratio field for each sub-table within the region, with an initial default value of a constant 1. Each time a new correction ratio is calculated and successfully issued, this field is automatically updated and persisted. When a new round of error assessment and coefficient conversion is needed in the next cycle, the system directly reads the latest field value saved in the previous cycle from the database and uses it as the historical absolute correction ratio required for this calculation). The historical absolute correction ratio is multiplied by the error equivalent offset ratio to obtain the latest absolute correction ratio. The magnitude of this value represents the total deviation of the sub-meter from its original true value and the total depth of the system's cumulative compensation. The greater the deviation of this value from the benchmark value, the more thorough the actual aging and degradation of the meter's underlying structure, and the closer it is to the set scrapping threshold. Therefore, it is determined whether the absolute value of the difference between the latest absolute correction ratio and the benchmark value exceeds the preset compensation limit threshold, where the benchmark value is a constant of 1. If it does not exceed the limit, the latest absolute correction ratio is subtracted from the benchmark value to obtain the multiplication correction coefficient, which is then packaged and sent to the management software of the corresponding sub-meter. If it exceeds the limit, the sending action to the corresponding sub-meter is truncated, and a meter replacement maintenance work order is directly generated.
[0056] In summary, the frozen electricity and average current of the transformer's main meter and individual sub-meters are first obtained within each preset time window. Since line loss is not fixed but varies non-linearly with current, the average current characteristics of the sub-meters within the time window are extracted to generate single-meter line loss characteristic variables, establishing a feature mapping strongly correlated with actual losses. Simultaneously, because meter errors cannot be directly measured and must be calculated through residual derivation, and the electricity flowing from the main meter is not equal to the sum of electricity used by all sub-meters (the difference being line loss and error), the differences in frozen electricity between the main meter and sub-meters are analyzed to obtain the difference in electricity consumption between the main and sub-meters. This constructs a time window feature matrix, providing a high-level data foundation with dimension alignment for error stripping in subsequent complex scenarios. Furthermore, by performing feature decomposition and sub-meter clustering based on the correlation of average current within a time window, sub-meter sets are obtained. After satisfying the full-rank condition determined by the number of sub-meter sets, the characteristic variables of trunk line superposition line loss are calculated. This allows for the automatic deduction of the shared trunk line topology for users even without physical wiring diagrams of the transformer substations. This enables precise quantification of the local nonlinear line loss increment caused by the superposition of multiple households' simultaneous electricity consumption, overcoming the calculation interference caused by using a fixed proportion of line loss deduction. Next, a multiple linear regression equation is established by integrating various line loss characteristic variables and electricity data to solve for the meter measurement error coefficient. This coefficient is then converted into a multiplicative correction coefficient and sent to the management software of the corresponding sub-meter for numerical rounding of the underlying original electricity consumption. This allows for the complete decoupling and extraction of line loss fluctuation interference and actual meter error, ultimately achieving accurate, stable, and fully automatic remote closed-loop calibration.
[0057] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the principles of the present invention should be included within the protection scope of the present invention.
Claims
1. An automatic electrical calibration method based on a smart meter, characterized in that, The method includes: Obtain the frozen power of the transformer's total meter and each sub-meter within each preset time window, as well as the average current of each sub-meter within the time window. Within each preset time window, the line loss characteristic variable of a single meter is calculated based on the numerical characteristics of the average current of the sub-meters within the time window; the difference characteristics of the frozen electricity between the transformer main meter and each sub-meter are analyzed to obtain the difference in electricity between the main meter and the sub-meters, and a time window characteristic matrix is formed by combining the line loss characteristic variable of a single meter, the frozen electricity, and the average current of the time window under all preset time windows. Based on the correlation between the average current of each sub-table in the time window feature matrix, feature decomposition and sub-table clustering are performed to obtain a sub-table set; after the cumulative number of time window rows in the time window feature matrix meets the full rank condition determined by the number of sub-table sets, the numerical characteristics of the average current of the time window in the same sub-table set in the time window feature matrix are analyzed under each preset time window to obtain the trunk line superimposed line loss characteristic variable for each preset time window. Based on the difference in electricity consumption between the main meter and sub-meters, the line loss characteristic variables of individual meters, the superimposed line loss characteristic variables of each trunk line, and the frozen electricity consumption of each sub-meter, a multiple linear regression equation is established for the line loss fitting coefficient and the meter measurement error coefficient. The meter measurement error coefficient of each sub-meter is obtained by solving the multiple linear regression equation. The meter measurement error coefficient is converted into a multiplication correction coefficient and sent to the management software of the corresponding sub-meter for numerical rounding of the underlying original electricity consumption.
2. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The method for obtaining the single-table line loss characteristic variables includes: Under each preset time window, the average current of all sub-meters under each time window is independently squared and then summed to obtain the single-meter line loss characteristic variable under each preset time window.
3. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The method for obtaining the difference in battery power between the main and sub-meters includes: Within each preset time window, the sum of the frozen electricity of all sub-meters is taken as the cumulative electricity sum, and the difference between the frozen electricity of the transformer main meter and the cumulative electricity sum is taken as the total sub-meter electricity difference under each preset time window.
4. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The method for obtaining the time window feature matrix includes: The total power difference between the sub-meters, the line loss characteristic variables of a single meter, the frozen power of all sub-meters, and the average current of each sub-meter within each preset time window are packaged and assembled into tuple data of a single row dimension. According to the time sequence of the preset time windows, the tuple data corresponding to each preset time window are sequentially appended and pushed into the storage space, and the time window feature matrix is constructed by accumulating row by row.
5. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The methods for obtaining the set of partitioned tables include: Extract the current time series data composed of the average current of each sub-table under all preset time windows in the time window feature matrix; Calculate the Pearson correlation coefficient of current time series data between any two sub-tables to construct an adjacency matrix. Based on the adjacency matrix, obtain the corresponding standardized Laplace matrix. Perform eigenvalue decomposition on the standardized Laplace matrix to obtain all eigenvalues and their corresponding eigenvectors. After removing the feature values with a value of 0, the remaining feature values are arranged into an increasing sequence. The first-order difference sequence of the feature values in the increasing sequence is calculated. In the first-order difference sequence, the position index corresponding to the maximum difference is obtained, and the position index value is determined as the optimal K value. Extract the K feature vectors corresponding to the first K feature values in the increasing sequence, combine them column by column to form a K-column feature space matrix, and use the K-means clustering algorithm to perform cluster analysis on all row vectors of the feature space matrix to obtain all the sub-table sets. Each row vector of the feature space matrix corresponds to a sub-table, and the distance metric is the Euclidean distance between the row vectors.
6. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The method for obtaining the trunk line superimposed line loss characteristic variables includes: For each sub-table set, extract the average current of all sub-tables belonging to that sub-table set in the time window feature matrix under each preset time window; Under each preset time window, the average current of all sub-meters in the same sub-meter set is accumulated to obtain the total overlapping current of each sub-meter set under each preset time window; The total overlapping current is squared to obtain the trunk line superimposed line loss characteristic variable of each sub-table set under each preset time window.
7. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The method for obtaining the multiple linear regression equation includes: The total meter-to-meter power difference, single meter line loss characteristic variable, superimposed line loss characteristic variable of each trunk line, and frozen power of each sub-meter in the time window feature matrix are standardized respectively. The standardized total meter-to-meter power difference is used as the prediction target variable, and the standardized single meter line loss characteristic variable, superimposed line loss characteristic variable of each trunk line, and frozen power of each sub-meter are used as independent variables. A linear equation containing the sum of the following parts is constructed as a multiple linear regression equation: Under each preset time window, the standardized single-meter line loss characteristic variable is multiplied by the single-meter line loss fitting coefficient to be solved to obtain the first product factor; the standardized trunk line superimposed line loss characteristic variable is multiplied by the trunk line loss fitting coefficient to be solved to obtain the second product factor; the standardized sub-meter frozen electricity is multiplied by the standardized meter measurement error coefficient to be solved to obtain the third product factor. A linear equation is constructed in which the sum of the first product factor, the second product factor of all sub-meter sets, and the third product factor of all sub-meters equals the predicted target variable, which serves as the multiple linear regression equation.
8. The automatic electrical calibration method based on a smart meter according to claim 7, characterized in that, The method for obtaining the metering error coefficient includes: The target loss function is set as the mean square error between the predicted electricity difference obtained from the established multiple linear regression equation and the predicted target variable. In the loss function, only the L1 norm absolute value penalty term is applied to the standardized meter measurement error coefficient to be solved. Initiate the regression algorithm to iteratively solve for the global minimum of the target loss function, so that the standardized metering error coefficients corresponding to some sub-meters converge to 0, and solve for the standardized metering error coefficients of each sub-meter. The standardized meter measurement error coefficient is calculated by multiplying the standard deviation of the total electricity consumption difference between the sub-meters under all preset time windows, and the result is used as the numerator. The sum of the standard deviation of the frozen electricity consumption of the corresponding sub-meters under all preset time windows and the preset parameters is used as the denominator to obtain the meter measurement error coefficient of each sub-meter.
9. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The step of converting the meter's measurement error coefficient into a multiplication correction coefficient and sending it to the corresponding sub-meter's management software for rounding off the underlying raw electricity value includes: Using constant 1 as the numerator and the sum of constant 1 and the metering error coefficient of each sub-meter as the denominator, the resulting ratio is used as the error equivalent offset ratio for each sub-meter. Obtain the historical absolute correction ratio for each sub-table, multiply the historical absolute correction ratio by the error equivalent offset ratio to obtain the latest absolute correction ratio, and determine whether the absolute value of the difference between the latest absolute correction ratio and the benchmark value exceeds the preset compensation limit threshold, where the benchmark value is a constant 1. If the value is not exceeded, the latest absolute correction ratio is subtracted from the benchmark value to obtain the multiplication correction coefficient, and the multiplication correction coefficient is packaged and sent to the management software of the corresponding sub-table. If the value is exceeded, the sending action to the corresponding sub-table is truncated, and a table replacement maintenance work order is generated.
10. The automatic electrical calibration method based on a smart meter according to claim 1, characterized in that, The methods for setting the full rank condition include: The number of sub-table sets inferred from clustering is taken as the total number of trunk lines; The sum of the total number of sub-tables, the total number of trunk lines, and the constant 1 is used as the judgment threshold. When the cumulative number of time window rows in the time window feature matrix is greater than the judgment threshold, it is determined that the full rank condition is met.
