An abnormal power consumption identification method and system of an electric energy meter
Patent Information
- Application Number
- CN202611347084.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-02
- Publication Date
- 2026-11-03
- Estimated Expiration
- 2046-09-02
AI Technical Summary
Existing methods for identifying abnormal electricity consumption in electricity meters have low sensitivity to sophisticated tampering techniques such as high-frequency phase fine-tuning and zero-sequence component spoofing, and are easily affected by harmonic interference introduced by nonlinear loads, resulting in high rates of missed and false alarms.
High-frequency noise signals are injected into the power grid lines, harmonic response features are extracted through a time-series convolutional network, and electricity theft behavior is determined by combining waveform symmetry and zero-sequence component change rate. Dynamic threshold verification and multi-layer dilated convolutional networks are used to capture time-series deviations in electricity consumption behavior.
It significantly improves the detection rate of sophisticated tampering-type electricity theft, reduces the false alarm rate caused by nonlinear loads, and enhances anti-interference capabilities.
Smart Images

Figure CN122859860B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of abnormal electricity consumption identification technology, and specifically to a method and system for identifying abnormal electricity consumption in an electricity meter. Background Technology
[0002] The identification of abnormal electricity consumption by existing electricity meters mainly relies on traditional methods such as year-on-year and month-on-month comparison of electricity consumption, detection of sudden changes in load curves, or analysis of abnormal power factors. These methods have a certain ability to detect large-scale electricity theft behaviors such as "bypassing the electricity meter" and "short-circuiting the current loop", but have low sensitivity to sophisticated tampering-type electricity theft such as high-frequency phase fine-tuning and zero-sequence component spoofing.
[0003] Meanwhile, traditional methods mostly rely on static thresholds for single frames, without considering the temporal evolution characteristics of electricity consumption behavior itself. They are easily affected by harmonic interference introduced by nonlinear loads (such as frequency converters and charging piles), resulting in false alarms. Furthermore, the thresholds are mostly set in a fixed manner, making it difficult to adapt to seasonal load fluctuations and changes in transformer topology, leading to both high false alarm and missed alarm rates during long-term operation. Summary of the Invention
[0004] To address the aforementioned technical shortcomings, the purpose of this invention is to provide a method and system for identifying abnormal electricity consumption in electricity meters, thereby solving the problems of low detection rate and insufficient anti-interference capability of existing abnormal electricity consumption identification methods for phase tampering-related electricity theft.
[0005] To solve the above-mentioned technical problems, the present invention adopts the following technical solution: In a first aspect, the present invention provides a method for identifying abnormal electricity consumption in an electricity meter, comprising: Step S1: Inject a high-frequency noise signal of a preset frequency into the power grid line where the electricity meter is located, and simultaneously collect the harmonic response sequence and instantaneous waveform data of the three-phase voltage and current in the line. Step S2: Simultaneously demodulate the harmonic response sequence, extract the amplitude and phase characteristics of the fundamental component and each harmonic, and form a multidimensional feature vector; Step S3: Input the multidimensional feature vector into the pre-trained temporal convolutional network. The temporal convolutional network captures the distortion pattern of the harmonic response on the time axis through multi-layer dilated convolution and outputs an abnormal index that reflects the deviation of electricity consumption behavior from the normal baseline. Step S4: Based on the comparison results of the anomaly index and the dynamic threshold, and combined with the waveform symmetry and zero-sequence component change rate calculated from the three-phase voltage and current waveform data, determine whether there is any electricity theft.
[0006] Preferably, in one possible implementation of the first aspect, step S1 specifically includes: A high-frequency noise signal of a preset frequency is injected into the power grid line where the electricity meter is located. The high-frequency noise is superimposed onto the low-voltage power supply line of the distribution area by the coupling circuit. The injection time is aligned with the zero-crossing time of the grid voltage. The carrier frequency of the high-frequency noise avoids the power frequency and its harmonic frequencies. When synchronously acquiring the harmonic response sequence in the line, an independent sampling clock asynchronous with the power frequency is used to sample the line signal at the coupling point, and the sampling rate satisfies the Nyquist condition for the high-frequency noise bandwidth. When synchronously acquiring instantaneous waveform data of three-phase voltage and current, a sampling clock of the same origin as the harmonic response sequence is used to latch the secondary output of each phase voltage and current transformer. The latching trigger is driven by the zero-crossing alignment signal. The three-phase instantaneous waveform and the harmonic response sequence share the same time base stamp.
[0007] Preferably, in one possible implementation of the first aspect, the synchronous demodulation process in step S2 includes: When synchronously demodulating the harmonic response sequence, a phase-locked loop is used to track the fundamental phase of the power grid and output the quadrature local oscillator signal. The harmonic response sequence is multiplied by the in-phase local oscillator and the quadrature local oscillator respectively to obtain two mixing outputs. The two mixing outputs are separated into the in-phase and quadrature components of the fundamental wave and the in-phase and quadrature components of each harmonic after being low-pass filtered. The in-phase and quadrature components are paired one by one according to the harmonic order. The amplitudes of the fundamental component and each harmonic component are calculated using the following formula: ,in For the first In-phase components of subharmonics For the first Orthogonal components of subharmonics Indicates the fundamental frequency. Indicates each harmonic; The phase is calculated by the following formula: ,in For the first The phase of the subharmonics; the amplitude and phase of the fundamental wave and each subharmonic are arranged in ascending order of harmonic order to form an intermediate characteristic sequence.
[0008] Preferably, in one possible implementation of the first aspect, the process of forming the multidimensional feature vector includes: The multidimensional feature vector is constructed by concatenating the intermediate feature sequence with the quantized values derived from each phase. The intermediate feature sequence includes the fundamental amplitude. Fundamental phase The amplitude of each harmonic from the 2nd to the Nth harmonic to With phase to N is the pre-set harmonic interception order; The derived quantitative quantities for each phase include the ratio sequence of each harmonic amplitude of phase A voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase B voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase C voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase A current relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase B current relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase C current relative to the fundamental amplitude, as well as the three-phase voltage imbalance and the three-phase current imbalance. All components are assembled into a fixed-length vector in a fixed order to form a multidimensional feature vector.
[0009] Preferably, in one possible implementation of the first aspect, the structure of the temporal convolutional network in step S3 includes an input mapping layer, multi-level residual blocks, and an output mapping layer: The input mapping layer maps multidimensional feature vectors from the input dimension to the network's hidden dimension; Each residual block contains, in sequence, a first weight normalization layer, a first ReLU activation layer, a first causal dilated convolutional layer, a second weight normalization layer, a second ReLU activation layer, a random deactivation layer, and a second causal dilated convolutional layer. A shortcut connection is set between the input of the residual block and the output of the second causal dilated convolutional layer to achieve element-wise addition. The expansion coefficients of residual blocks at each level increase exponentially, the kernel size remains consistent across all layers, and the network as a whole satisfies causal constraints. The output of the last-stage residual block is mapped by the output mapping layer and then enters the anomaly index output branch.
[0010] Preferably, in one possible implementation of the first aspect, an attention unit is configured after the shortcut connection output of each residual block, the attention unit being composed of a channel attention submodule and a time attention submodule cascaded together; The channel attention submodule performs global average pooling on the residual block output along the feature channel dimension, and then generates channel weights through a fully connected transformation; The temporal attention submodule performs global average pooling and global max pooling on the residual block output along the channel axis along the time dimension. The two are concatenated and then transformed by convolution to generate temporal weights. Except for the final residual block, all other residual blocks at each level have side output branches. Each side output branch is first weighted by the attention unit of the corresponding level, and then the weighted result is concatenated according to the channel dimension. After concatenation, it is sent to the input mapping front end of the next level residual block. The output of the final residual block is sent directly to the output mapping layer without passing through the side output branch.
[0011] Preferably, in one possible implementation of the first aspect, the output process of the anomaly index includes: The output of the final residual block of the temporal convolutional network is first compressed into a fixed-length one-dimensional representation along the time dimension by global pooling. The global pooling is processed by two paths, max pooling and average pooling, and then concatenated. The spliced one-dimensional representation is fed into a fully connected layer and mapped to a scalar value, which is the anomaly index. The magnitude of the anomaly index is determined by the training phase of the temporal convolutional network, which uses the harmonic response distortion mode under normal power consumption scenarios as the baseline and the harmonic response distortion mode under known electricity theft scenarios as the deviation target. Through backpropagation, the anomaly index corresponding to the normal baseline is in the first value range, and the anomaly index corresponding to the deviation from electricity theft is in the second value range. The anomaly index during the inference phase is directly calculated and output from the forward calculation.
[0012] Preferably, in one possible implementation of the first aspect, the phase tampering determination process in step S4 includes: The dynamic threshold is obtained by extracting the distribution of the abnormal index within the sliding history window according to a preset quantile, and the sliding history window is updated continuously as the calculation is performed. When the cumulative number of frames in which the current abnormal index continuously exceeds the dynamic threshold reaches a preset number of frames, a joint verification of waveform symmetry and zero-sequence component change rate is triggered. Waveform symmetry is calculated by the following formula: ,in The integral of the absolute values of the sampling points during the positive half-cycle of the instantaneous waveform of phase A voltage within the current power frequency cycle. The integral of the absolute value of the sampling points in the negative half-cycle within the same period; The rate of change of the zero-sequence component is calculated by the following formula: ,in For the first The average value of the zero-sequence current within each sliding window. It is the average of the zero-sequence currents in the next adjacent sliding window; When the waveform symmetry D exceeds the symmetry threshold and the zero-sequence component change rate R exceeds the change rate threshold, it is determined that there is phase tampering caused by electricity theft. If no condition is exceeded, the system returns to monitoring mode, and the dynamic threshold continues to update as the history window slides.
[0013] In a second aspect, the present invention provides an abnormal electricity consumption identification system for an electricity meter, the system being used to implement an abnormal electricity consumption identification method for an electricity meter as described in the first aspect, comprising: The high-frequency injection acquisition module injects a high-frequency noise signal of a preset frequency into the power grid line where the energy meter is located, and simultaneously acquires the harmonic response sequence and instantaneous waveform data of the three-phase voltage and current in the line. The harmonic demodulation feature module synchronously demodulates the harmonic response sequence, extracts the amplitude and phase features of the fundamental component and each harmonic, and forms a multi-dimensional feature vector. The temporal convolution detection module inputs multi-dimensional feature vectors into a pre-trained temporal convolutional network. The temporal convolutional network captures the distortion patterns of harmonic responses on the time axis through multi-layer dilated convolutions and outputs an abnormal index that reflects the deviation of electricity consumption behavior from the normal baseline. The phase tampering identification module determines whether electricity theft exists based on the comparison results of the anomaly index and the dynamic threshold, combined with the waveform symmetry and zero-sequence component change rate calculated from the three-phase voltage and current waveform data.
[0014] The beneficial effects of this invention are as follows: By injecting high-frequency noise signals that avoid the power frequency and its harmonic frequencies into the power grid lines, and synchronously acquiring the harmonic response sequence and the instantaneous waveforms of the three-phase voltage and current with an independent sampling clock asynchronous with the power frequency, the invention can separate the subtle distortion features introduced by electricity theft from the source, and significantly enhance the anti-interference capability.
[0015] The harmonic response sequence is synchronously demodulated by a phase-locked loop to extract the fundamental wave and the amplitude and phase of each harmonic to form a multi-dimensional feature vector. This vector is then input into a multi-layer dilated convolutional network to capture the time axis distortion pattern and output an anomaly index. Compared with static thresholds, this index can better characterize the temporal deviation of electricity consumption behavior.
[0016] The judgment stage introduces a 95th percentile dynamic threshold of the sliding historical window, and combines waveform symmetry and zero-sequence component change rate for joint verification. Only when the abnormal index continuously exceeds the threshold and both physical criteria are met simultaneously is it judged as phase tampering electricity theft. This reduces false alarms caused by nonlinear loads and improves the detection rate of refined tampering-type electricity theft. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 This application provides a flowchart of a method for identifying abnormal electricity consumption by an electricity meter. Detailed Implementation
[0019] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0020] Example 1: As Figure 1 As shown, the present invention provides a method for identifying abnormal electricity consumption in an electricity meter, comprising: Step S1: Inject a high-frequency noise signal of a preset frequency into the power grid line where the electricity meter is located, and simultaneously collect the harmonic response sequence and instantaneous waveform data of the three-phase voltage and current in the line.
[0021] In this embodiment, a high-frequency noise signal of a preset frequency is injected into the power grid line where the electricity meter is located. The carrier frequency of this high-frequency noise signal is set to... Avoid power frequency and its 2nd to 39th harmonic frequencies ( to ), and is not Integer multiples of frequencies are used to avoid overlap with inherent harmonic components of the power grid. The modulation bandwidth of the high-frequency noise signal is... Therefore, the highest effective frequency is The injection operation is achieved through a coupling circuit, which consists of a DC blocking capacitor connected in series with an impedance matching transformer. The capacitance of the DC blocking capacitor is [value missing]. The withstand voltage rating is not lower than that of AC. The impedance matching transformer turns ratio is Working bandwidth coverage to This superimposes high-frequency noise signals onto the low-voltage power supply lines in the distribution area. Phase. The injection time is aligned with the zero-crossing time of the grid voltage, specifically achieved through the following circuit: the grid voltage is reduced to [a value] by a voltage transformer. After measuring the range, the data is sent to a high-speed comparator. The negative terminal of the comparator is connected The reference potential is connected to the positive terminal of the mains voltage sampling signal. The comparator has an external hysteresis resistor network, and the hysteresis threshold is set to... Peak value to prevent false triggering caused by noise near zero crossing; comparator output A square wave, which is passed through a monostable multivibrator. After shaping, 10 are generated that are aligned with each zero crossing point. The narrow pulse, which serves as a zero-crossing alignment signal, directly triggers the start port of the high-frequency noise signal generator, thereby ensuring that each injection action is performed at the instant the grid voltage crosses zero.
[0022] The harmonic response sequence in the synchronous acquisition line is used. The acquisition of the harmonic response sequence employs an independent sampling clock asynchronous with the power frequency. This independent sampling clock consists of a single chip. The active crystal oscillator is frequency-divided by a frequency divider chain, with a division ratio of 1000, and the output is... Sampling pulse. The sampling pulse is sent to the high-speed analog-to-digital converter. of The pin samples the line signal at the coupling point at a sampling rate of 40kHz. Since the highest effective frequency is... , The sampling rate satisfies the Nyquist condition, that is, the sampling rate is greater than twice the highest effective frequency. Furthermore, there is ample margin. This independent sampling clock is not synchronized with the power grid frequency to avoid uneven sampling intervals caused by power frequency fluctuations, thus ensuring the equal-interval characteristics of the harmonic response sequence on the time axis.
[0023] The instantaneous waveform data of three-phase voltage and current are acquired synchronously. The acquisition of the instantaneous waveform data of three-phase voltage and current uses a sampling clock of the same origin as the harmonic response sequence, i.e., the same chip. Active crystal oscillators are generated via the same frequency divider chain. The sampling pulse simultaneously supplies a six-channel analog-to-digital converter with the secondary outputs of three voltage transformers and three current transformers. of The pins ensure that all sampling channels are physically identical at the start-up time of the conversion. The transformation ratio of each phase voltage transformer is... The current transformer ratio for each phase is The secondary output passes through an anti-aliasing filter (a second-order Butterworth low-pass filter with a cutoff frequency of...). ) then sent in Input terminal. Latch triggering is driven by a zero-crossing alignment signal: each zero-crossing alignment pulse triggers a latch enable signal, which sets the latch for the current sampling clock cycle. The conversion result is latched into a register, and the time base stamp of that frame is also latched. The three-phase instantaneous waveform data and the harmonic response sequence share the same time base stamp. The time base stamp generation mechanism is as follows: The system is configured with a 32-bit incrementing counter, with a counting clock of... The original clock of an active crystal oscillator without frequency division ( When each zero-crossing alignment pulse arrives, the current value of the counter is latched as the time base origin of that zero-crossing window. ; thereafter, after each 40kHz sampling pulse (i.e., every 25... The counter value increases by 40MHz / 40kHz = 1000, therefore the first... Time base stamp of each sampling point ,in For the first time after zero Each sampling point number; harmonic response With three-phase voltage and current After each sampling is completed, by The controller will combine its respective conversion results with the current... The values are written together to the memory buffer, thus aligning the two sets of data on the timeline. All All use 16-bit resolution, with a full-scale input range of [missing information]. The sampling holding time is The conversion time is 4 ,satisfy Time constraints on sampling rate.
[0024] Step S2: Simultaneously demodulate the harmonic response sequence, extract the amplitude and phase characteristics of the fundamental component and each harmonic, and form a multidimensional feature vector.
[0025] In this embodiment, when synchronously demodulating the harmonic response sequence, a second-order software phase-locked loop implemented in the digital domain is used to track the fundamental phase of the power grid, outputting two orthogonal local oscillator sequences. The phase-locked loop uses... Sampling The phase voltage fundamental segment is used as input, and the loop filter bandwidth is set to... After locking, the numerically controlled oscillator outputs an in-phase local oscillator sequence and a quadrature local oscillator sequence. The frequency of the in-phase local oscillator sequence is... Initial phase and power grid The phase voltage fundamental zero-crossing points are aligned, and the frequency of the quadrature local oscillator sequence is... The phase lags behind the in-phase local oscillator sequence. The harmonic response sequence is The sampled digital sequence is multiplied point-by-point in the digital domain by both the in-phase local oscillator sequence and the quadrature local oscillator sequence to obtain two mixing output sequences. The two mixing output sequences are then passed through a fourth-order Butterworth low-pass filter. The filter is set to a cutoff frequency of [value missing]. The stopband attenuation slope is Every ten octaves, after low-pass filtering, the in-phase and quadrature components of the fundamental frequency and the in-phase and quadrature components of each harmonic are separated. The in-phase and quadrature components are paired one by one according to the harmonic order. The amplitudes of the fundamental frequency component and each harmonic component are calculated by the following formula:
[0026] in For the first In-phase components of subharmonics For the first Orthogonal components of subharmonics Indicates the fundamental frequency. Represents each harmonic; the phase is calculated by the following formula:
[0027] in For the first The phase of each harmonic. The amplitude and phase of the fundamental wave and each harmonic are arranged in ascending order of harmonic order to form an intermediate characteristic sequence, which includes the fundamental wave amplitude. Fundamental phase , the second to the third The amplitude of each harmonic in the subharmonic to With phase to , In this embodiment, the harmonic cutoff order is predetermined. Taking 20 means capturing the 2nd to 20th harmonics.
[0028] The multidimensional feature vector is constructed by concatenating the intermediate feature sequence with the phase-derived quantization quantities. Each phase-derived quantization quantity includes... The sequence of ratios of phase voltage harmonic amplitudes to fundamental amplitude. The sequence of ratios of phase voltage harmonic amplitudes to fundamental amplitude. The sequence of ratios of phase voltage harmonic amplitudes to fundamental amplitude. The sequence of ratios of the amplitudes of each harmonic of the phase current to the amplitude of the fundamental current. The sequence of ratios of the amplitudes of each harmonic of the phase current to the amplitude of the fundamental current. The sequence of ratios of the amplitudes of each harmonic of the phase current to the amplitude of the fundamental wave, as well as the three-phase voltage imbalance and the three-phase current imbalance.
[0029] The sequence of ratios of the amplitudes of each harmonic of the phase voltage to the amplitude of the fundamental voltage, from the 2nd to the 20th harmonic. Phase voltage harmonic amplitude divided by The phase voltage fundamental amplitude value was obtained, with a total of 19 ratios; The sequence of ratios of the amplitudes of each harmonic of the phase voltage to the amplitude of the fundamental voltage, from the 2nd to the 20th harmonic. Phase voltage harmonic amplitude divided by The phase voltage fundamental amplitude value was obtained, with a total of 19 ratios; The sequence of ratios of the amplitudes of each harmonic of the phase voltage to the amplitude of the fundamental voltage, from the 2nd to the 20th harmonic. Phase voltage harmonic amplitude divided by The phase voltage fundamental amplitude value was obtained, with a total of 19 ratios; The sequence of ratios of the amplitudes of each harmonic of the phase current relative to the amplitude of the fundamental wave, from the 2nd to the 20th harmonic. Phase current harmonic amplitude divided by The phase current fundamental amplitude value was obtained, with a total of 19 ratios; The sequence of ratios of the amplitudes of each harmonic of the phase current relative to the amplitude of the fundamental wave, from the 2nd to the 20th harmonic. Phase current harmonic amplitude divided by The phase current fundamental amplitude value was obtained, with a total of 19 ratios; The sequence of ratios of the amplitudes of each harmonic of the phase current relative to the amplitude of the fundamental wave, from the 2nd to the 20th harmonic. Phase current harmonic amplitude divided by The phase current fundamental amplitude values were obtained, with a total of 19 ratios.
[0030] Three-phase voltage imbalance according to The prescribed method for calculating negative sequence voltage unbalance involves the following steps: performing a Fourier transform on the instantaneous waveform data of the three-phase voltages. Mutually, Mutually, Phase fundamental complex phasor , , The amplitudes of the fundamental positive-sequence component and the fundamental negative-sequence component are calculated using symmetric component transformation. The formula for symmetric component transformation is:
[0031] in , For the fundamental positive-sequence complex phasor, For fundamental negative-sequence complex phasors, This is a zero-sequence complex phasor. The amplitude of the fundamental positive-sequence component is... The amplitude of the fundamental negative sequence component is The three-phase voltage imbalance is calculated by the following formula: Three-phase voltage imbalance
[0032] The three-phase current imbalance is calculated using the same method, that is, by performing a Fourier transform on the instantaneous waveform data of the three-phase current to obtain the fundamental complex phasors of phases A, B, and C. , , The fundamental positive-sequence complex phasor is obtained through the same symmetric component transformation. With fundamental negative sequence complex phasor The three-phase current imbalance is calculated by the following formula: Three-phase current imbalance
[0033] All components are concatenated into a fixed-length vector in a fixed order to form a multidimensional feature vector. The fixed order is as follows: first, the intermediate feature sequence is placed, and then the intermediate feature sequence is arranged according to the fundamental amplitude value. Fundamental phase 2nd harmonic amplitude Second harmonic phase 3rd harmonic amplitude 3rd harmonic phase Up to the 20th harmonic amplitude 20th harmonic phase Arrange them in order; then place them. The sequence of ratios of the phase voltage harmonic amplitudes relative to the fundamental amplitude is arranged internally in the order of the ratios of the 2nd to the 20th harmonics; then place... The sequence of ratios of the phase voltage harmonic amplitudes relative to the fundamental amplitude is arranged internally in the order of the ratios of the 2nd to the 20th harmonics; then place... The sequence of ratios of the phase voltage harmonic amplitudes relative to the fundamental amplitude is arranged internally in the order of the ratios of the 2nd to the 20th harmonics; then place... The sequence of ratios of the phase current harmonic amplitudes relative to the fundamental current amplitude is arranged internally in the order of the ratios from the 2nd to the 20th harmonic; then place... The sequence of ratios of the phase current harmonic amplitudes relative to the fundamental current amplitude is arranged internally in the order of the ratios from the 2nd to the 20th harmonic; then place... The sequence of ratios of the amplitudes of each harmonic of the phase current relative to the amplitude of the fundamental wave is arranged internally in the order of the ratios of the 2nd to the 20th harmonics; finally, the three-phase voltage imbalance and the three-phase current imbalance are placed.
[0034] The entire multidimensional feature vector contains a total of 194 components, including 2 fundamental components, 38 harmonic amplitude components, 38 harmonic phase components, 114 voltage and current harmonic amplitude ratio components, and 2 unbalance components, forming a 194-dimensional fixed-length vector.
[0035] Step S3: Input the multidimensional feature vector into the pre-trained temporal convolutional network. The temporal convolutional network captures the distortion pattern of the harmonic response on the time axis through multi-layer dilated convolution and outputs an abnormal index that reflects the deviation of electricity consumption behavior from the normal baseline.
[0036] In this embodiment, the temporal convolutional network structure includes an input mapping layer, an eight-level residual block, and an output mapping layer. The input mapping layer is a fully connected layer with 128 neurons and an activation function of [function name missing]. The function maps a 194-dimensional multidimensional feature vector from the input dimension of 194 to the network's hidden dimension of 128. Within each residual block, a first weight normalization layer, a first... Activation layer, first causal dilated convolutional layer, second weight normalization layer, second The system consists of an activation layer, a random deactivation layer, and a second causal dilated convolutional layer. Both the first and second weight normalization layers employ... Norm normalization, normalization parameters .First Activation layer and second The negative slopes of the activation layers are all 0. The kernel size of both the first and second causal dilated convolutional layers is 3×1, with causal padding, meaning that the kernel size minus one zero is padded to the left of the time dimension, ensuring that the output at the current time step depends only on the inputs at the current time step and previous time steps, satisfying the causal constraint. The dilation coefficient of each residual block increases exponentially: the dilation coefficient of the first-level residual block is... The expansion coefficient of the second-level residual block is The expansion coefficient of the third-order residual block is The expansion coefficient of the fourth-order residual block is The expansion coefficient of the fifth-order residual block is The expansion coefficient of the sixth-level residual block is The expansion coefficient of the seventh-order residual block is The expansion coefficient of the eighth-level residual block is The deactivation probability of the random deactivation layer is set to 0.2. A shortcut connection is set between the input of the residual block and the output of the second causal dilated convolutional layer to achieve element-wise addition.
[0037] Each level of residual block is followed by an attention unit after its shortcut connection output. This attention unit is composed of a cascaded channel attention submodule and a temporal attention submodule. The channel attention submodule performs global average pooling on the residual block output along the feature channel dimension. The output dimension of the global average pooling is... The first fully connected layer compresses the number of channels to one-sixteenth of the original number, i.e., 8. The second fully connected layer restores the original number of channels to 128. A third fully connected layer is inserted between the two fully connected layers. Activation layer, finally through The function generates channel weights, which are then multiplied channel by channel by the residual block output to obtain the channel-weighted feature tensor. The temporal attention submodule performs global average pooling and global max pooling along the channel axis on the channel-weighted feature tensor along the time dimension. The output dimension of the global average pooling is... The output dimension of global max pooling is ,in The time step length is used to concatenate the two pooling results along the channel axis. A tensor, which is processed by a convolution kernel of size . The convolutional layer is transformed into The time weights, the activation function of the convolutional layer are The function, which multiplies the time weights and channel-weighted feature tensors step-by-step, yields the final output of the attention unit.
[0038] Except for the final residual block of level 8, all residual blocks from levels 1 to 7 have side output branches at the output of their corresponding attention units. Each side output branch is the weighted result of the attention unit at that level. The weighted results of each side output branch are then concatenated along the channel dimension and fed into the input mapping front of the next level residual block. The output of the final residual block of level 8 is fed directly into the output mapping layer without passing through the side output branches. The output mapping layer first performs global pooling on the output of the final residual block, compressing it into a fixed-length one-dimensional representation along the time dimension. Global pooling uses two paths, max pooling and average pooling, to process the data separately and then concatenate them. Max pooling takes the maximum value of each channel along the time dimension to obtain a 128-dimensional vector, and average pooling takes the average value of each channel along the time dimension to obtain a 128-dimensional vector. After concatenation, a 256-dimensional one-dimensional representation is obtained. This one-dimensional representation is fed into a fully connected layer and mapped to a scalar value, which is the anomaly index. The fully connected layer has 1 neuron and no activation function.
[0039] The magnitude of the anomaly index is determined through backpropagation during the training phase of the temporal convolutional network, using the harmonic response distortion pattern under normal electricity consumption scenarios as the baseline and the harmonic response distortion pattern under known electricity theft-marked scenarios as the deviation target. Training ensures that the anomaly index corresponding to the normal baseline is within a certain range. The first numerical range, the deviation of electricity theft from the corresponding abnormal index is in The second numerical range. During training, the loss function uses mean squared error loss, and the optimizer uses... The optimizer has an initial learning rate of 0.001, a batch size of 64, and 200 training epochs. An early stopping strategy is applied to the validation set: training stops when the validation loss does not decrease for 10 consecutive epochs to prevent overfitting. The anomaly index during the inference phase is directly calculated and output from the forward pass.
[0040] Step S4: Based on the comparison results of the anomaly index and the dynamic threshold, and combined with the waveform symmetry and zero-sequence component change rate calculated from the three-phase voltage and current waveform data, determine whether there is any electricity theft.
[0041] In this embodiment, the dynamic threshold is obtained by extracting the distribution of the abnormal index within the sliding history window according to a preset quantile. The length of the sliding history window is set to 120 time frames, with each time frame corresponding to one power frequency cycle. The total length of the window is The window stores a sequence of anomaly index values from the most recent 120 frames. After each new anomaly index calculation, the window slides forward one frame, removing the oldest frame and adding the latest, thus achieving a rolling update. The specific calculation process for the dynamic threshold is as follows: The 120 anomaly index values in the window are sorted in ascending order to obtain an ordered sequence. The preset quantile value is 0.95, meaning the 114th value in the sorted sequence (120 multiplied by 0.95 equals 114) is used as the dynamic threshold. If the 114th value is equal to the 115th value, that value is directly used; otherwise, linear interpolation is used to calculate the precise quantile value. The interpolation formula is: Dynamic Threshold ,in Since the decimal part of 0.95 multiplied by 120 is 0.0, the dynamic threshold is directly taken as... .
[0042] When the cumulative number of frames in which the current anomaly index continuously exceeds the dynamic threshold reaches a preset number of frames, a joint verification of waveform symmetry and zero-sequence component change rate is triggered. The preset number of frames is set to 5 frames, meaning that the joint verification process is initiated when the anomaly index is greater than the dynamic threshold for 5 consecutive frames. If the consecutive frame exceedance does not reach 5 frames, the verification is not triggered, the dynamic threshold continues to update with the sliding window, and the system remains in monitoring mode.
[0043] The calculation of waveform symmetry is based on Instantaneous waveform data of phase voltage. Within each power frequency cycle, starting from the voltage zero-crossing point, the sampling points within a complete power frequency cycle are divided into positive and negative half-cycles. The positive half-cycle is defined as the half-cycle interval where the instantaneous voltage value is greater than or equal to zero, that is, the first half of the period from the zero-crossing point to the next zero-crossing point, with a duration of... The negative half-cycle is defined as the latter half of the period when the instantaneous voltage value is less than zero, and its duration is... .exist At the given sampling rate, each half-cycle contains 400 sampling points. The integral of the absolute value of the sampling points in the positive half-cycle is... The calculation method is as follows: sum the absolute values of the voltages at all sampling points during the positive half-cycle, i.e. ,in For the positive half-cycle The instantaneous voltage value at each sampling point. The absolute value integral at each sampling point during the negative half-cycle. The calculation method is as follows: sum the absolute values of the voltages at all sampling points during the negative half-cycle, i.e. ,in For the negative half-week The instantaneous voltage value at each sampling point. The waveform symmetry D is calculated by the following formula: Logarithmic operations use the natural logarithm base e. The symmetry threshold is set to 0.15. When D is greater than 0.15, it indicates that the asymmetry of the positive and negative half-cycle waveforms exceeds the allowable range, and there may be waveform distortion caused by phase tampering.
[0044] The rate of change of the zero-sequence component is calculated based on the instantaneous waveform data of the three-phase current. The zero-sequence current is obtained by summing the instantaneous values of the three-phase current and dividing by 3, i.e. ,in , , The currents of phases A, B, and C at time [times] are respectively The instantaneous sampled values. The sliding window length for the zero-sequence current is set to 10 power frequency cycles, or 200ms, with each sliding window containing 4000 sampling points (at a 40kHz sampling rate). The mean of zero-sequence current within each sliding window It is calculated from the arithmetic mean of all zero-sequence current sampling points within the window: The adjacent sliding window (the first one) The mean of (a sliding window) This is also calculated from 4000 sampling points within the window. There is no overlap between the two sliding windows, i.e., the first... Each sliding window covers a time interval , No. A sliding window coverage Rate of change of zero-sequence component Calculated by the following formula: To prevent the denominator from being zero, when When the absolute value is less than 0.001 amperes, The value is forcibly assigned to 0.001 amperes. The rate of change threshold is set to 0.3, or 30%. When A value greater than 0.3 indicates that the zero-sequence current has changed significantly between two adjacent sliding windows, which may be caused by phase tampering due to electricity theft.
[0045] When the joint verification is triggered, the waveform symmetry The rate of change of the zero-sequence component is taken from the latest calculation results of the current power frequency cycle. The value is taken from the most recent sliding window calculation. The logic of the joint verification is: when the waveform symmetry... Exceeding the symmetry threshold of 0.15 and the rate of change of the zero-sequence component When the rate of change exceeds the threshold of 0.3, phase tampering caused by electricity theft is determined, the system issues an electricity theft alarm signal, and marks the current time frame as an electricity theft event frame. If either of the two conditions is not exceeded, i.e. or If the threshold is not exceeded, it is not considered electricity theft, and the system returns to monitoring mode. The dynamic threshold continues to update as the history window scrolls, waiting for the next five consecutive frames exceeding the threshold before triggering a joint verification. The entire judgment process runs in real time, performing a threshold comparison and cumulative frame count judgment after each frame's anomaly index calculation, ensuring a rapid response to electricity theft.
[0046] Example 2: This invention provides an abnormal electricity consumption identification system for electricity meters, comprising: The high-frequency injection acquisition module injects a high-frequency noise signal of a preset frequency into the power grid line where the energy meter is located, and simultaneously acquires the harmonic response sequence and instantaneous waveform data of the three-phase voltage and current in the line. The harmonic demodulation feature module synchronously demodulates the harmonic response sequence, extracts the amplitude and phase features of the fundamental component and each harmonic, and forms a multi-dimensional feature vector. The temporal convolution detection module inputs multidimensional feature vectors into a pre-trained temporal convolutional network. The temporal convolutional network captures the distortion patterns of harmonic responses on the time axis through multi-layer dilated convolutions and outputs an abnormal index that reflects the deviation of electricity consumption behavior from the normal baseline. The phase tampering identification module determines whether electricity theft exists based on the comparison results of the anomaly index and the dynamic threshold, combined with the waveform symmetry and zero-sequence component change rate calculated from the three-phase voltage and current waveform data.
[0047] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.
Claims
1. A method for identifying abnormal electricity consumption in an electricity meter, characterized in that, include: Step S1: Inject a high-frequency noise signal of a preset frequency into the power grid line where the electricity meter is located, and simultaneously collect the harmonic response sequence and instantaneous waveform data of the three-phase voltage and current in the line. Step S2: Simultaneously demodulate the harmonic response sequence, extract the amplitude and phase characteristics of the fundamental component and each harmonic, and form a multidimensional feature vector; The formation process of the multidimensional feature vector includes: The multidimensional feature vector is constructed by concatenating the intermediate feature sequence with the quantized values derived from each phase. The intermediate feature sequence includes the fundamental amplitude. Fundamental phase The amplitude of each harmonic from the 2nd to the Nth harmonic to With phase to N is the pre-set harmonic interception order; The derived quantitative quantities for each phase include the ratio sequence of each harmonic amplitude of phase A voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase B voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase C voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase A current relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase B current relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase C current relative to the fundamental amplitude, as well as the three-phase voltage imbalance and the three-phase current imbalance. All components are concatenated in a fixed order to form a fixed-length vector as a multidimensional feature vector; Step S3: Input the multidimensional feature vector into the pre-trained temporal convolutional network. The temporal convolutional network captures the distortion pattern of the harmonic response on the time axis through multi-layer dilated convolution and outputs an abnormal index that reflects the deviation of electricity consumption behavior from the normal baseline. Step S4: Based on the comparison results of the anomaly index and the dynamic threshold, and combined with the waveform symmetry and zero-sequence component change rate calculated from the three-phase voltage and current waveform data, determine whether there is any electricity theft.
2. The method for identifying abnormal electricity consumption in an electricity meter as described in claim 1, characterized in that, Step S1 specifically includes: A high-frequency noise signal of a preset frequency is injected into the power grid line where the electricity meter is located. The high-frequency noise is superimposed onto the low-voltage power supply line of the distribution area by the coupling circuit. The injection time is aligned with the zero-crossing time of the grid voltage. The carrier frequency of the high-frequency noise avoids the power frequency and its harmonic frequencies. When synchronously acquiring the harmonic response sequence in the line, an independent sampling clock asynchronous with the power frequency is used to sample the line signal at the coupling point, and the sampling rate satisfies the Nyquist condition for the high-frequency noise bandwidth. When synchronously acquiring instantaneous waveform data of three-phase voltage and current, a sampling clock of the same origin as the harmonic response sequence is used to latch the secondary output of each phase voltage and current transformer. The latching trigger is driven by the zero-crossing alignment signal. The three-phase instantaneous waveform and the harmonic response sequence share the same time base stamp.
3. The method for identifying abnormal electricity consumption in an electricity meter as described in claim 1, characterized in that, The synchronous demodulation process in step S2 includes: When synchronously demodulating the harmonic response sequence, a phase-locked loop is used to track the fundamental phase of the power grid and output the quadrature local oscillator signal. The harmonic response sequence is multiplied by the in-phase local oscillator and the quadrature local oscillator respectively to obtain two mixing outputs. The two mixing outputs are separated into the in-phase and quadrature components of the fundamental wave and the in-phase and quadrature components of each harmonic after being low-pass filtered. The in-phase and quadrature components are paired one by one according to the harmonic order. The amplitudes of the fundamental component and each harmonic component are calculated using the following formula: ,in For the first In-phase components of subharmonics For the first Orthogonal components of subharmonics Indicates the fundamental frequency. Indicates each harmonic; The phase is calculated by the following formula: ,in For the first The phase of the subharmonics; the amplitude and phase of the fundamental wave and each subharmonic are arranged in ascending order of harmonic order to form an intermediate characteristic sequence.
4. The method for identifying abnormal electricity consumption in an electricity meter as described in claim 1, characterized in that, The structure of the temporal convolutional network in step S3 includes an input mapping layer, multi-level residual blocks, and an output mapping layer. The input mapping layer maps multidimensional feature vectors from the input dimension to the network's hidden dimension; Each residual block contains, in sequence, a first weight normalization layer, a first ReLU activation layer, a first causal dilated convolutional layer, a second weight normalization layer, a second ReLU activation layer, a random deactivation layer, and a second causal dilated convolutional layer. A shortcut connection is set between the input of the residual block and the output of the second causal dilated convolutional layer to achieve element-wise addition. The expansion coefficients of residual blocks at each level increase exponentially, the kernel size remains consistent across all layers, and the network as a whole satisfies causal constraints. The output of the last-stage residual block is mapped by the output mapping layer and then enters the anomaly index output branch.
5. The method for identifying abnormal electricity consumption in an electricity meter as described in claim 4, characterized in that, Each level of residual block is configured with an attention unit after the shortcut connection output. This attention unit is composed of a channel attention submodule and a time attention submodule cascaded together. The channel attention submodule performs global average pooling on the residual block output along the feature channel dimension, and then generates channel weights through a fully connected transformation; The temporal attention submodule performs global average pooling and global max pooling on the residual block output along the channel axis along the time dimension. The two are concatenated and then transformed by convolution to generate temporal weights. Except for the final residual block, all other residual blocks at each level have side output branches. Each side output branch is first weighted by the attention unit of the corresponding level, and then the weighted result is concatenated according to the channel dimension. After concatenation, it is sent to the input mapping front end of the next level residual block. The output of the final residual block is sent directly to the output mapping layer without passing through the side output branch.
6. The method for identifying abnormal electricity consumption in an electricity meter as described in claim 5, characterized in that, The process of outputting the anomaly index includes: The output of the final residual block of the temporal convolutional network is first compressed into a fixed-length one-dimensional representation along the time dimension by global pooling. The global pooling is processed by two paths, max pooling and average pooling, and then concatenated. The spliced one-dimensional representation is fed into a fully connected layer and mapped to a scalar value, which is the anomaly index. The magnitude of the anomaly index is determined by the training phase of the temporal convolutional network, which uses the harmonic response distortion mode under normal power consumption scenarios as the baseline and the harmonic response distortion mode under known electricity theft scenarios as the deviation target. Through backpropagation, the anomaly index corresponding to the normal baseline is in the first value range, and the anomaly index corresponding to the deviation from electricity theft is in the second value range. The anomaly index during the inference phase is directly calculated and output from the forward calculation.
7. The method for identifying abnormal electricity consumption in an electricity meter as described in claim 1, characterized in that, The process for determining electricity theft in step S4 includes: The dynamic threshold is obtained by extracting the distribution of the abnormal index within the sliding history window according to a preset quantile, and the sliding history window is updated continuously as the calculation is performed. When the cumulative number of frames in which the current abnormal index continuously exceeds the dynamic threshold reaches a preset number of frames, a joint verification of waveform symmetry and zero-sequence component change rate is triggered. Waveform symmetry is calculated by the following formula: ,in The integral of the absolute values of the sampling points during the positive half-cycle of the instantaneous waveform of phase A voltage within the current power frequency cycle. The integral of the absolute value of the sampling points in the negative half-cycle within the same period; The rate of change of the zero-sequence component is calculated by the following formula: ,in For the first The average value of the zero-sequence current within each sliding window. It is the average of the zero-sequence currents in the next adjacent sliding window; When the waveform symmetry D exceeds the symmetry threshold and the zero-sequence component change rate R exceeds the change rate threshold, it is determined that there is phase tampering caused by electricity theft. If no condition is exceeded, the system returns to monitoring mode, and the dynamic threshold continues to update as the history window slides.
8. An abnormal electricity consumption identification system for an electricity meter, characterized in that, The system is used to implement a method for identifying abnormal electricity consumption in an electricity meter as described in any one of claims 1 to 7, comprising: The high-frequency injection acquisition module injects a high-frequency noise signal of a preset frequency into the power grid line where the energy meter is located, and simultaneously acquires the harmonic response sequence and instantaneous waveform data of the three-phase voltage and current in the line. The harmonic demodulation feature module synchronously demodulates the harmonic response sequence, extracts the amplitude and phase features of the fundamental component and each harmonic, and forms a multi-dimensional feature vector. The formation process of the multidimensional feature vector includes: The multidimensional feature vector is constructed by concatenating the intermediate feature sequence with the quantized values derived from each phase. The intermediate feature sequence includes the fundamental amplitude. Fundamental phase The amplitude of each harmonic from the 2nd to the Nth harmonic to With phase to N is the pre-set harmonic interception order; The derived quantitative quantities for each phase include the ratio sequence of each harmonic amplitude of phase A voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase B voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase C voltage relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase A current relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase B current relative to the fundamental amplitude, the ratio sequence of each harmonic amplitude of phase C current relative to the fundamental amplitude, as well as the three-phase voltage imbalance and the three-phase current imbalance. All components are concatenated in a fixed order to form a fixed-length vector as a multidimensional feature vector; The temporal convolution detection module inputs multidimensional feature vectors into a pre-trained temporal convolutional network. The temporal convolutional network captures the distortion patterns of harmonic responses on the time axis through multi-layer dilated convolutions and outputs an abnormal index that reflects the deviation of electricity consumption behavior from the normal baseline. The phase tampering identification module determines whether electricity theft exists based on the comparison results of the anomaly index and the dynamic threshold, combined with the waveform symmetry and zero-sequence component change rate calculated from the three-phase voltage and current waveform data.
Citation Information
Patent Citations
Safety tamper-proof control method for electric energy meter
CN121324732A
Electric energy meter anomaly detection method and system
CN121831666A
