Electric energy meter state evaluation method based on space-time attention mechanism
Through the power meter state evaluation method based on the spatiotemporal attention mechanism, the problem of insufficient accuracy in the prior art when dealing with different types of power meter and composite abnormalities is solved, and high accuracy evaluation and abnormal diagnosis of power meter status are achieved.
Patent Information
- Application Number
- CN202510518562.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-24
- Publication Date
- 2025-05-23
- Estimated Expiration
- 2045-04-24
AI Technical Summary
The existing power meter state evaluation technology is insufficient in dealing with different load characteristics and composite abnormalities of different types of power meters, especially in areas with high spatial sparsity, which is difficult to achieve global accurate evaluation.
The state evaluation method of the power meter based on the spatiotemporal attention mechanism is adopted, through the adaptive decomposition of multi-scale time domain features and the construction of spatial correlation maps, the spatiotemporal attention weights perceived by load characteristics are calculated, and the spatiotemporal attention matrix is dynamically modulated to realize the adaptive evaluation and abnormal diagnosis of the state of the power meter.
It significantly improves the accuracy and reliability of the state evaluation of electricity meter and enhances the ability to identify composite anomalies, especially in scenarios with load mutations and large spatial sparseness, reducing the false alarm rate and false classification rate.
Smart Images

Figure CN120030395A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a data processing method, in particular to an electric energy meter state evaluation method based on a spatiotemporal attention mechanism. Background Art
[0002] As a key measuring device in the power system, the status of the energy meter directly affects the accuracy of energy measurement, the safety of power grid operation and the reliability of power supply services. With the in-depth advancement of smart grid construction, the number of energy meters has increased dramatically, and the equipment operating environment has become increasingly complex and changeable. Improving the accuracy and real-time performance of energy meter status assessment has become a key link in smart grid management. Efficient and reliable energy meter status assessment technology can not only detect potential faults in a timely manner and reduce power loss, but also provide an important basis for power grid operation decision-making and asset management, with significant economic benefits and social value.
[0003] At present, a variety of technical routes have been developed in the field of electricity meter status assessment. Traditional methods mainly rely on rule matching and threshold monitoring to detect abnormal conditions by setting the normal range of electrical parameters. In recent years, with the development of machine learning technology, state assessment methods based on algorithms such as support vector machines, random forests, and gradient boosting trees have emerged. These methods can automatically learn the normal operating mode of electricity meters and improve the flexibility of anomaly detection. The introduction of deep learning technology has further promoted the development of this field. Long short-term memory networks (LSTM), convolutional neural networks (CNN), and basic attention mechanisms have been applied to electricity meter status sequence modeling, achieving good results. In terms of data preprocessing, time-frequency analysis methods such as wavelet transform and empirical mode decomposition are also widely used in multi-scale feature extraction of electricity meter data.
[0004] Although the existing technology has made some progress, it still faces the following technical challenges in practical applications: First, the load characteristics of different types of electric energy meters vary greatly, and the existing fixed-architecture attention mechanism cannot dynamically adjust the focus according to the load type, resulting in a significant decrease in accuracy when dealing with load mutations (such as industrial users starting and stopping large equipment). Secondly, the state characteristics of electric energy meters vary at different time scales (second-level fluctuations, daily load curves, seasonal changes, etc.). The existing feature fusion method mainly relies on manually predefined time windows, which makes it difficult to automatically identify and extract key features at different time scales, resulting in poor recognition of complex anomalies (such as sudden failures under seasonal backgrounds). In addition, in areas where electric meters are unevenly distributed (such as rural or remote areas), the effect of the spatial attention mechanism is significantly reduced. The existing methods are difficult to handle this spatial sparsity problem, affecting the global accuracy of state assessment. The existence of these technical problems seriously restricts the application effect of electric energy meter state assessment technology in practical scenarios. Summary of the invention
[0005] The purpose of the invention is to provide an electric energy meter state assessment method based on the spatiotemporal attention mechanism, in order to solve at least one technical problem existing in the prior art.
[0006] Technical solution, a method for evaluating the state of an electric energy meter based on a spatiotemporal attention mechanism, comprising the following steps: Obtaining the original data of the electric energy meter, preprocessing it, obtaining a standard electric energy meter data set, and performing multi-scale time domain feature adaptive decomposition on it to obtain a multi-scale time domain feature set; Based on the grid topology data and the location information of the electric energy meter, the spatial topological relationship of the grid is constructed to obtain a spatial correlation map; Combining the multi-scale time domain feature set and the spatial correlation map, the load characteristic-aware spatiotemporal attention weights are calculated to obtain a dynamically modulated spatiotemporal attention matrix. Based on the dynamically modulated spatiotemporal attention matrix, the multi-scale time domain feature sets are adaptively fused to construct the state representation vector of the electricity meter. State assessment and abnormality diagnosis are then performed to obtain the state assessment result of the electricity meter.
[0007] Preferably, the multi-scale time domain feature adaptive decomposition is performed on the standard electric energy meter data set, including: Calculate the signal complexity index of the standard electric energy meter data set, determine the optimal number of decomposition modes based on it, and generate the decomposition parameter configuration; According to the decomposition parameter configuration, the standard electric energy meter data set is processed using the self-optimizing variational mode decomposition algorithm to obtain the intrinsic mode function set; Feature extraction is performed on the intrinsic modal function set, and the time domain statistical features, frequency domain features and nonlinear features are calculated. Each modal function is mapped to a specific time scale to generate a multi-scale time domain feature set and a time scale attribution map.
[0008] By adaptively decomposing the multi-scale time domain features of the standard electric energy meter data set, the automatic stratification and feature decoupling of the electric energy meter data are realized. The introduction of the signal complexity index to adaptively determine the optimal number of decomposition modes avoids the overfitting or underfitting problems caused by the fixed number of modes in the traditional method, enabling the system to dynamically adjust the decomposition strategy according to the complexity of different electric energy meter data. The self-optimizing variational mode decomposition algorithm extracts the intrinsic mode function and realizes the accurate separation of features at different time scales, especially for the common multi-time scale superposition faults in the electric energy meters of industrial users. The separation effect is improved by about 42%, which significantly enhances the accuracy and reliability of subsequent state assessment, while reducing the error classification rate.
[0009] Preferably, the steps of processing using a self-optimizing variational mode decomposition algorithm include: Determine the initial mode number and center frequency according to the decomposition parameter configuration and generate an initial decomposition parameter set; The variational modal decomposition algorithm is performed on the standard electric energy meter data set using the initial decomposition parameter set to obtain the coarse-grained modal function set and modal quality assessment index; Based on the modal quality assessment index, low-quality modes in the coarse-grained modal function set are identified, and variational decomposition is recursively performed on each low-quality mode. Sparse optimization constraints are applied to obtain the optimized modal function set. The decomposition quality of the optimized modal function set is verified, the reconstruction error and orthogonality index are calculated, the decomposition parameters are confirmed or adjusted according to the verification results, and the intrinsic modal function set is output.
[0010] The self-optimizing variational modal decomposition algorithm is used to solve the difficulties in parameter preset and modal aliasing in the traditional variational modal decomposition algorithm. The variational modal decomposition is performed on the standard electric energy meter data set using the initial decomposition parameter set, and then recursively optimized based on the modal quality evaluation index. The progressive decomposition strategy from coarse to fine significantly improves the decomposition quality. Especially for electric energy meter data containing impact interference, traditional VMD is prone to boundary effects and energy leakage. This method reduces mutual interference between modes and improves the recognition rate of transient anomalies by introducing a dual verification mechanism of reconstruction error and orthogonality index. At the same time, it reduces the computational complexity and improves the processing speed.
[0011] Preferably, the steps of identifying low-quality modes based on the modal quality assessment index and recursively performing variational decomposition include: Calculate the energy retention rate and inter-modal correlation matrix of each mode in the coarse-grained modal function set; and identify the modes whose energy retention rate is lower than the preset threshold or the inter-modal correlation is higher than the preset threshold based on this, to form a low-quality modal set; Perform variational modal decomposition on each modal signal in the low-quality modal set as a new input signal, set the initial number of modes to 2, and generate the corresponding sub-modal set; The sub-modes are combined with the stored original high-quality mode set, and the objective function is applied to minimize the inter-modal aliasing, outputting the optimized modal function set.
[0012] By identifying low-quality modes through modal quality evaluation indicators and recursively performing variational decomposition, the problem of feature loss caused by fixed decomposition levels in traditional variational modal decomposition algorithms is successfully overcome. The introduction of energy retention rate and inter-modal correlation matrix as evaluation indicators can accurately identify low-quality modes that need to be further decomposed, thereby deeply mining potential abnormal signals. The number of initial modes is set to 2 during the recursive decomposition process, which not only maintains the stability of the algorithm but also realizes fine-grained feature extraction. The application of sparse optimization constraints to minimize inter-modal aliasing provides a more robust feature basis for the status assessment of electric energy meters in complex power grid environments, significantly improves the detection sensitivity of small signal faults, and reduces the minimum detectable deviation of 5.8% of traditional methods to 1.2%, realizing early warning of small drifts of electric energy meter parameters.
[0013] Preferably, the step of calculating the load characteristic-aware spatiotemporal attention weights comprises: Extract load features based on multi-scale time domain feature sets and build a load feature dictionary; The current load is represented as a linear combination of feature dictionaries to obtain the load type identifier and load sparse representation coefficient, based on which a hierarchical self-adjusting attention calculation skeleton and resource allocation strategy are constructed; Combining the spatial correlation graph, load sparse representation coefficients and attention calculation skeleton, dynamic attention modulation enhanced by pattern transfer is realized to obtain a dynamically modulated spatiotemporal attention matrix.
[0014] By calculating the spatiotemporal attention weights of load characteristic perception, the problem of the lack of load adaptability of the traditional attention mechanism is solved. The introduction of load feature dictionary and load sparse representation technology can accurately distinguish the load characteristics of industrial, commercial and residential users, and realize the dynamic adjustment of the attention mechanism. The hierarchical self-adjusting attention calculation skeleton automatically configures computing resources according to the load type, avoiding the problem of uneven accuracy caused by using the same attention configuration for all electricity meters in the traditional method. The pattern migration enhancement mechanism designed in combination with the spatial topology information of the power grid realizes the knowledge migration from data-sufficient areas to data-sparse areas, significantly improving the accuracy of electricity meter status assessment in rural and remote areas, reducing the overall false alarm rate of the system, and laying the foundation for consistency assessment across the entire network.
[0015] Preferably, the step of constructing a load feature dictionary and expressing the current load as a linear combination of the feature dictionary comprises: Extract typical load characteristics from multi-scale time domain feature sets, including daily load curve shape, peak-to-valley ratio and volatility characteristics; Construct a load feature dictionary based on typical load features, including the feature representation of industrial, commercial and residential loads; Represent the current load as a linear combination of basis vectors in the load feature dictionary to obtain sparse coefficients; The load is classified based on the sparse coefficient, the load type identifier is determined, and the sparse coefficient is output as a load sparse representation coefficient.
[0016] By constructing a load feature dictionary and representing the current load as a linear combination of the feature dictionary, accurate identification and classification of different types of loads are achieved. Typical load features such as daily load curve shape, peak-to-valley ratio and volatility are extracted from the multi-scale time domain feature set, and a feature dictionary containing various types of industrial, commercial and residential loads is specifically constructed, so that the system can "understand" the operating rules of different loads. The innovative method of representing loads based on sparse coefficients can not only determine the dominant type of load, but also quantify the composition ratio of mixed loads, providing an accurate basis for subsequent attention modulation. This refined load identification significantly improves the contextual adaptability of the status assessment of the electricity meter, improves the accuracy of anomaly detection in load mutation scenarios, and reduces the false alarm rate caused by normal load changes, reaching the industry-leading level.
[0017] Preferably, the steps of implementing dynamic attention modulation with enhanced mode transfer include: Based on the spatial correlation graph, an associated network of electric energy meters with similar load characteristics is established to obtain the load similarity and network topology relationship and calculate the comprehensive similarity between electric energy meters accordingly; An attention model is built for electricity meters with sufficient data. For electricity meters with insufficient data, similar electricity meters are selected from the electricity meter association network according to the comprehensive similarity, and a progressive migration weight function based on data sufficiency is constructed. Fast Fourier transform is applied to the load sparse representation coefficients to construct a frequency domain attention modulation function that dynamically adjusts the frequency response gain for different load types; The attention model calculation formula is modified according to the transfer weight function and the frequency domain attention modulation function to obtain a dynamically modulated spatiotemporal attention matrix.
[0018] By implementing dynamic attention modulation enhanced by pattern migration, the problem of inconsistent evaluation accuracy caused by uneven spatial distribution of power grids is solved. This method establishes an associated network of electric energy meters with similar load characteristics based on the topological relationship of the power grid, innovatively designs a comprehensive similarity calculation method, organically combines electrical distance and load similarity, and accurately identifies "electrically similar" groups of electric energy meters. For electric energy meters with insufficient data, the knowledge transfer of the attention model is realized through a progressive migration weight function. As the data accumulates, the migration weight is automatically adjusted to ensure that the model smoothly transitions to the autonomous learning stage. The frequency domain attention modulation mechanism dynamically adjusts the frequency response gain according to different load types, so that industrial loads pay attention to high-frequency changes and commercial loads pay attention to daily cycle fluctuations, which significantly improves the pertinence of anomaly detection and increases the F1 score of state evaluation under different load types from an average of 0.76 to 0.91.
[0019] Preferably, constructing a progressive migration weight function includes: Based on the energy meter association network and node similarity matrix, the energy meters are grouped according to similarity, and a representative energy meter is calculated for each group; Build an attention model for representative energy meters with sufficient data, identify the groups to which energy meters with insufficient data belong and the corresponding representative energy meters, and design a transfer weight function TW i (t)=exp(-γ·D i (t)), where D i (t) is the data adequacy of electric energy meter i, and γ is the attenuation coefficient; Building a hybrid attention model AM i =TW i (t)·AM r +(1-TW i (t))·AM i local , where AM r 、AM i local Attention model and local attention model for a representative energy meter.
[0020] By constructing a progressive migration weight function, the "cold start" problem of newly installed electricity meters or data-sparse areas was successfully solved. This method is based on intelligent grouping of electricity meter association networks and node similarity matrices, and innovatively calculates representative electricity meters for each group to ensure the high quality and reliability of the knowledge migration source. The designed migration weight function achieves a smooth transition. The hybrid attention model combines representative electricity meters with local models, which improves the accuracy of the system in the first month of status assessment of newly installed electricity meters by 72%, shortens the model convergence time from 4-6 months in traditional methods to 2-3 weeks, and significantly improves the management efficiency in the scenario of power grid expansion.
[0021] Preferably, the step of adaptively fusing the multi-scale time domain feature set includes: Based on the multi-scale time domain feature set and time scale attribution mapping, a hierarchical time domain feature map is constructed to represent the structural relationship between features at different time scales. The importance of multi-scale temporal feature sets is ranked according to the dynamically modulated spatiotemporal attention matrix, and the most discriminative feature subset is selected; By utilizing the hierarchical time-domain feature graph and the dynamically modulated spatiotemporal attention matrix, graph-guided adaptive feature fusion is performed to construct an electric energy meter state representation vector containing multi-scale time-domain information and spatial correlation information.
[0022] Through the adaptive fusion of multi-scale time-domain feature sets, a comprehensive characterization and accurate assessment of the energy meter status are achieved. By introducing a hierarchical time-domain feature map, the features at different time scales are organized into a structured relationship network, breaking through the limitation of simply superimposing the features at each time scale in traditional methods. Based on the spatio-temporal attention matrix with dynamic modulation, the feature importance is ranked to ensure that the most discriminative feature subset is retained during the dimensionality reduction process, improving the accuracy of the system while reducing complexity. The map-guided adaptive feature fusion mechanism takes into account the structured relationship between features, enabling the system to capture the abnormal propagation paths across time scales, significantly improving the recognition rate of complex faults. In particular, the early detection ability for sudden faults and slowly evolving faults under seasonal backgrounds is tripled, and the detection lead time is extended from an average of 4.2 days to 12.6 days.
[0023] Preferably, the steps of constructing the hierarchical time-domain feature map include: Define the time scale hierarchy from the second level to the monthly level, and map the features in the multi-scale time-domain feature set to the corresponding time scales according to the time scale attribution mapping. Calculate the information entropy of each time scale level as an important indicator of the information content contained in that time scale. Use Granger causality test to identify the causal relationships between features at different time scales, and construct a cross-scale causal relationship matrix and a causal delay parameter table. Based on the time scale hierarchy and the cross-scale causal relationship matrix, construct a hierarchical directed graph, where the nodes in the graph represent the features at different time scales, and the edges represent the cross-scale causal relationships.
[0024] By constructing the hierarchical time-domain feature map, the multi-scale organization and causal correlation analysis of the energy meter status features are realized. This method defines a complete time scale hierarchy from the second level to the monthly level, uses information entropy to quantify the importance of each time scale, and can adaptively focus on the time scales containing rich information. The introduction of Granger causality test technology enables the system to identify the causal relationships between features at different time scales, and the constructed cross-scale causal relationship matrix and causal delay parameter table accurately describe the abnormal propagation mechanism in the time dimension. The hierarchical directed graph constructed based on this visually shows the structured relationship between features, and the direction and weight of the edges represent the causal direction and intensity respectively, significantly improving the interpretability of the status assessment results, enabling maintenance personnel to clearly locate the fault source and predict the development trend, improving the accuracy of fault root cause analysis, and greatly reducing the operation and maintenance costs and power outage losses.
[0025] Beneficial effects: Through the incremental decomposition strategy, the power grid topology correlation network, and the frequency-domain attention modulation, an accurate assessment of the energy meter status of different load types is achieved, significantly improving the abnormal detection accuracy, and is particularly suitable for the early identification of complex faults. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 It is the overall flow chart of the present invention.
[0027] Figure 2 It is a flow chart of the data acquisition and preprocessing of the electric energy meter of the present invention.
[0028] Figure 3 It is a flow chart of the adaptive decomposition of multi-scale time domain features of the present invention.
[0029] Figure 4 It is a flow chart of constructing the spatial topological relationship of the power grid of the present invention.
[0030] Figure 5 It is a flow chart of the load characteristic aware spatiotemporal attention calculation of the present invention.
[0031] Figure 6 It is a flow chart of multi-scale spatiotemporal feature fusion and state representation of the present invention.
[0032] Figure 7 It is a flow chart of the electric energy meter status evaluation and abnormality diagnosis of the present invention. DETAILED DESCRIPTION
[0033] like Figure 1 As shown, a method for evaluating the state of an electric energy meter based on a spatiotemporal attention mechanism specifically includes the following steps: S1. Electricity meter data acquisition and preprocessing S11, multi-source heterogeneous data acquisition: read the original electric energy meter data, including the time series of electrical parameters such as voltage, current, power factor, active power, reactive power, etc., and simultaneously obtain the grid topology data and electric energy meter location information, and output the original multi-source data set; S12, Data quality assessment and anomaly marking: Input the original multi-source data set, calculate the data integrity, consistency and validity scores, detect and mark outliers and missing segments, and output the quality assessment report and anomaly marking data set; S13, data cleaning and standardization: input the abnormal labeled data set, correct the outliers (use median filtering for sudden outliers and forward filling for missing data), perform time alignment and standardization, and output the standardized electricity meter data set.
[0034] S2, multi-scale time domain feature adaptive decomposition S21, signal complexity adaptive evaluation: input standardized electric energy meter data set, calculate the approximate entropy and sample entropy of the signal, construct the signal complexity index CI, adaptively determine the optimal number of decomposition modes K according to the complexity index, and output the decomposition parameter configuration; S22, self-optimizing variational modal decomposition: input the standardized electric energy meter data set and decomposition parameter configuration, and perform the following processing: initialize the number of modes K and the center frequency; apply the variational modal decomposition algorithm for preliminary decomposition; optimize by minimizing the following improved objective function: J(uk)=α‖∑uk-f‖ 2 2 +β‖dt[∑(uk 2 )]‖ 1 +∑‖dω[(F(uk)(ω-ωk)]‖ 2 2 , where α is the data fidelity weight and β is the sparsity constraint weight; implement an incremental decomposition strategy to optimize the mode from coarse-grained to fine-grained; verify the decomposition quality through Hilbert-Huang transform and adjust the parameters if necessary; output K intrinsic mode functions (IMFs); S23. Multi-scale feature extraction and time domain attribution identification: Input intrinsic mode functions IMFs and perform feature extraction on each IMF, including: calculating time domain statistical features (mean, variance, kurtosis, skewness, etc.); extracting frequency domain features (power spectral density, main frequency components, etc.); calculating nonlinear features (sample entropy, Lyapunov exponent, etc.); applying an adaptive time scale attribution algorithm to map each IMF to a specific time scale (seconds, minutes, hours, days, weeks, etc.); outputting a multi-scale time domain feature set MTFS and a time scale attribution map TSM.
[0035] S3. Construction of spatial topological relationship of power grid S31, power grid topology data analysis and node mapping: input power grid topology data and electric energy meter location information, establish a mapping relationship between electric energy meter and power grid node, and output an electric energy meter-node mapping table; S32, spatial correlation strength quantification: input the meter-node mapping table, calculate the electrical distance between nodes based on power flow analysis, and build a multidimensional spatial correlation strength matrix based on geographical distance, and output the spatial correlation strength matrix SCRM; S33. Dynamic adaptive update of power grid topology: Input the spatial correlation intensity matrix SCRM and the standardized electricity meter data set, monitor the changes in power grid topology (such as switch state changes, line switching, etc.), update the spatial correlation intensity matrix in real time, and output the dynamically updated spatial correlation map DSRG.
[0036] S4. Load-feature-aware spatiotemporal attention computation S41, load characteristics identification and classification: input multi-scale time domain feature set MTFS and standardized electric energy meter data set, perform the following processing: extract typical load characteristics (daily load curve shape, peak-to-valley ratio, volatility, etc.); construct load feature dictionary LFD, which contains typical patterns of different load types; apply sparse coding algorithm to represent the current load as a linear combination of feature dictionary: L=∑ci·Fi+ε, where ci is the sparse coefficient and Fi is the basis vector in the feature dictionary; classify the load (industrial, commercial, residential, etc.) based on the sparse coding coefficient ci; output load type identification LTI and load sparse representation coefficient LSC; S42, hierarchical self-adjusting attention skeleton construction: input the load type identifier LTI and the load sparse representation coefficient LSC, and build the basic attention calculation framework, including: selecting the corresponding attention initial configuration template according to the load type; designing a lightweight attention skeleton (edge end) and a full-feature attention model (cloud end); establishing a dynamic allocation strategy for attention resources to control the calculation complexity according to the importance of data; outputting the attention calculation skeleton ACS and the resource allocation strategy RAS; S43. Dynamic attention modulation enhanced by pattern transfer: Input the attention calculation skeleton ACS, the dynamically updated spatial association map DSRG and the load sparse representation coefficient LSC, and perform the following processing: Based on the spatial association map of the power grid, establish an association network of electricity meters with similar load characteristics; For electricity meters with insufficient data, select the most similar electricity meter from the association network to learn from its attention configuration; Design a progressive knowledge transfer mechanism to gradually reduce the weight of migrated knowledge as data accumulates; Apply the frequency domain attention modulation function to adjust the attention weights of different frequency components according to the load characteristics: D(C) = diag(σ(Wf·FFT(C) + bf)), where C is the load sparse representation coefficient; Dynamically update the attention calculation formula: Attention(Q,K,V,C) = softmax(QK^T·D(C) / √d)V; Output the dynamically modulated spatiotemporal attention matrix DTSAM.
[0037] S5. Multi-scale spatiotemporal feature fusion and state representation S51. Construction of hierarchical time domain feature graph: Input the multi-scale time domain feature set MTFS and the time scale attribution map TSM, and perform the following processing: construct a hierarchical graph structure G=(V,E), where the node V represents the features of different time scales; establish the edge E between nodes through the Granger causality test to represent the causal relationship between cross-scale features; design a graph node weight update mechanism to reflect the importance of features of different time scales; capture the state evolution trajectory of the electric energy meter by comparing the graph changes in different time periods; output the hierarchical time domain feature graph HTFG; S52, attention-guided spatiotemporal feature selection: input the dynamically modulated spatiotemporal attention matrix DTSAM and the multi-scale temporal feature set MTFS, sort the feature importance according to the attention weight, select the most discriminative feature subset, and output the preferred feature subset SFS; S53, Adaptive feature fusion and state representation: Input the preferred feature subset SFS, the hierarchical time domain feature map HTFG and the dynamically modulated spatiotemporal attention matrix DTSAM, and perform the following processing: design a map-guided feature fusion strategy, adjust the fusion weight according to the relationship between nodes; introduce a second-order interaction term to capture the nonlinear relationship between features: F = ∑(w i ·F i )+∑(w ij ·F i ·F j ), where w ij is the feature interaction weight; constructs a state representation vector, which includes multi-scale time domain information and spatial correlation information; and outputs the electric energy meter state representation vector MSRV.
[0038] S6. Electricity meter status assessment and abnormality diagnosis S61, state deviation quantification and scoring: input the electric energy meter state representation vector MSRV, calculate the state deviation score by comparing it with the historical normal state mode, and output the state evaluation score SES; S62, abnormal pattern recognition and fault classification: input the state evaluation score SES and the electric energy meter state representation vector MSRV, match them with the abnormal pattern library, identify potential fault types, and output the fault type diagnosis result FDR; S63. Explainability analysis of evaluation results: Input the fault type diagnosis result FDR, the hierarchical time domain feature map HTFG and the dynamically modulated spatiotemporal attention matrix DTSAM, locate the specific time scale and spatial area where the anomaly occurs, generate a visual explanation, and output an explainable evaluation report XER.
[0039] According to a further improvement of the present invention, step S22 of self-optimizing variational mode decomposition specifically includes: S221, initial modal decomposition parameter configuration: input the standardized electric energy meter data set and decomposition parameter configuration, and determine the initial modal number K according to the signal complexity index CI i nit, set the initial center frequency {ω 1 , ω 2 , ..., ω k}, configure the basic parameters of the VMD algorithm (bandwidth constraint α, data fidelity weight τ), and output the initial decomposition parameter set IDP; S222, Coarse-grained variational modal basic decomposition: Input the standardized electricity meter data set and the initial decomposition parameter set IDP, and execute the basic VMD algorithm, including: converting the original signal f(t) to the analytical signal space through Hilbert transform; adding quadratic penalty terms and Lagrangian multipliers to each mode uk, and constructing the augmented Lagrangian function: L({uk},{ωk},λ)=α∑‖dt[(δ(t)+j / πt)⊛uk(t)]e -jωkt ‖ 2 2 +‖f(t)-∑uk(t)‖ 2 2 +〈λ(t),f(t)-∑uk(t)〉; The alternating direction multiplier method (ADMM) is used to solve the optimization problem and iteratively update uk, ωk and λ; The iteration termination condition is set to a relative error less than ε=10 -6 Or reach the maximum number of iterations N=500; output the coarse-grained modal function set CMF and modal quality evaluation index MQI; S223, incremental decomposition strategy execution: input the coarse-grained modal function set and modal quality evaluation index, and perform incremental decomposition optimization, including: calculating the energy retention rate EPR of each mode i =Energy(u i ) / Energy(sum(u i )); Calculate the correlation matrix CorrM between modes, where CorrM ij =Correlation(u i , u j ); identify low-quality modes (modes with low energy retention or high correlation); for each low-quality mode u i , perform the following incremental optimization: a) treat the modal signal as a new input f i (t); b) Re-execute the VMD algorithm and change K i Set to 2; c) Generate two sub-modes u i1 and u i2 ; d) Evaluate the quality of the sub-modal. If the threshold requirement is not met, continue the recursive decomposition; apply the sparse optimization constraint to minimize the objective function: J(uk)=α‖∑uk - f‖ 2 2 +β‖dt[∑(uk 2 )]‖ 1 +∑‖dω[(F(uk)(ω-ωk)]‖ 2 2 ; Output the optimized modal function set (OMF), which contains all valid modes after incremental decomposition; d is the symbol of partial derivative.
[0040] S224, Decomposition quality verification and parameter fine-tuning: Input the optimized modal function set OMF and perform decomposition quality verification, including: Calculate the reconstruction error RE = ‖f - ∑uk‖ 2 / ‖f‖ 2 ; Analyze the instantaneous frequency stability of each mode through Hilbert-Huang transform; Check the orthogonality between modes and calculate the orthogonality index OI=∑|〈u i , u j 〉| / (‖u i ‖·‖u j ‖), i≠j; if RE>threshold T_RE or OI>threshold T_OI, adjust parameters α, β and return to S222 to re-execute; otherwise, confirm that the decomposition result is valid; output the final inherent modal function set FIMFs and modal characteristic description table MCT, where MCT contains information such as the center frequency, bandwidth and energy distribution of each mode.
[0041] According to a further improvement of the present invention, the dynamic attention modulation enhanced by mode migration in step S43 specifically includes: S431, power grid topology association network construction: input the dynamically updated spatial association graph DSRG and the meter-node mapping table to construct the energy meter association network, including: extracting the key connection relationship in the power grid topology structure to form an adjacency matrix A, where A ij Represents the connection relationship between electric energy meters i and j; calculates the electrical distance matrix ED, and determines the electrical influence between any two nodes based on power flow analysis; combines the geographical distance GD to construct a comprehensive distance matrix: CD ij =w 1 ·ED ij +w 2 ·GD ij , where w 1 and w 2 is the weight coefficient; apply the Gaussian kernel function to convert the distance into similarity: S ij =exp(-CD ij 2 / σ 2 ), where σ is the kernel parameter; set the similarity threshold λ, retain S ij >λ to form a sparse association graph; output the electric energy meter association network MARN and the node similarity matrix NSM; S432, similar load electric energy meter identification and grouping: input the electric energy meter association network MARN, load type identifier LTI and load sparse representation coefficient LSC, perform similar load electric energy meter identification, including: for each load sparse representation coefficient LSC i Calculate load similarity: LS ij =cosine_similarity(LSC i, LSC j ) ; Combine topology similarity and load similarity to calculate comprehensive similarity: CS ij =α·S ij +(1-α)·LS ij , where α is a balance parameter; construct a K nearest neighbor graph based on comprehensive similarity, and determine the K most similar electric energy meters for each electric energy meter i; apply a community detection algorithm (such as the Louvain method) to group the association network; calculate representative electric energy meters for each group, and select the node with the highest connectivity within the group; output similar electric energy meter groups SMG and electric energy meter representativeness scores MRS; S433, attention knowledge transfer mechanism design: input similar electricity meter group SMG, electricity meter representative score MRS and load sparse representation coefficient LSC to realize attention knowledge transfer, including: for each representative electricity meter with sufficient data, build an attention model AM r ; For the electric energy meter i with insufficient data, identify its group g and the corresponding representative electric energy meter r; design the migration weight function: TW i (t)=exp(-γ·D i (t)), where D i (t) is the data sufficiency of the energy meter i, γ is the attenuation coefficient; construct a hybrid attention model: AM i =TW i (t)·AM_r+ (1-TW i (t))·AM i local ; As local data accumulates, the migration weight TW is dynamically adjusted i (t); Output transfer enhanced attention model (TEAM) and transfer weight function TWF; S434. Construction of frequency domain attention modulation function: Input the load sparse representation coefficient LSC and the transfer enhanced attention model TEAM, design the frequency domain attention modulation function, including: apply fast Fourier transform to the load sparse representation coefficient LSC to obtain the frequency domain representation: F_LSC=FFT(LSC); extract the amplitude and phase information of the frequency domain features; design the frequency response function H(f), adjust the gain according to the frequency domain characteristics of different load types: for industrial loads, enhance the high-frequency component response; for commercial loads, enhance the daily cycle frequency response; for residential loads, balance and enhance the daily cycle and weekly cycle responses; construct the frequency domain modulation matrix: D(C)=diag(σ(W f ·H(f)·|F_LSC|+b f )), where σ is the activation function, W f and b f are learnable parameters; output frequency domain attention modulation function FAMF and frequency response characteristic table FRT.
[0042] According to a further improvement of the present invention, step S51 of constructing a hierarchical time domain feature map specifically includes: S511, time scale hierarchy definition and feature mapping: input multi-scale time domain feature set MTFS and time scale attribution mapping TSM, define the time scale hierarchy structure, including: establish a time scale hierarchy system L={L 1 , L 2 , ..., L n}, where: L 1 Indicates the second scale (1-60 seconds), L 2 Indicates minute scale (1-60 minutes), L 3 Indicates hourly scale (1-24 hours), L 4 Indicates the day scale (1-7 days), L 5 Indicates the weekly scale (1-4 weeks), L 6 Represents the monthly scale (January to December); According to the time scale attribution mapping (TSM), each IMF and its characteristics are mapped to the corresponding time scale; Calculate the feature importance index of each scale layer: II i =Entropy(L i ) / ∑Entropy(L j ), measure the amount of information contained in the time scale; output the time scale hierarchy structure TSH and the hierarchical feature map LFM; S512, cross-scale causal relationship identification: input the time scale hierarchy structure TSH and the multi-scale time domain feature set MTFS, identify cross-scale causal relationships, including: for each pair of time scale levels (L i , L j ), extract the corresponding feature sequence F i and F j ; Apply the bivariate Granger causality test to construct the causal relationship matrix CRM: CRM ij = GrangerCausality(F i →F j ), indicating F i F j The causal influence strength; set the statistical significance threshold p_threshold to screen the significant causal relationship; for the significant causal relationship, calculate the delay parameter τ ij , represents the time required for the causal effect to propagate from scale i to scale j; verifies the stability of the causal relationship and ensures the consistency of the causal relationship through sub-sample testing; outputs the cross-scale causal relationship matrix CCRM and the causal delay parameter table CDP; S513, graph structure construction and attribute definition: Input the time scale hierarchy structure TSH, the hierarchical feature map LFM and the cross-scale causal relationship matrix CCRM, and construct the graph structure, including: Create a hierarchical directed graph G = (V, E): Node set V = {v 1 , v 2 , ..., v n}, where v i Indicates the time scale L i The feature representation of edge set E={e ij}, based on the cross-scale causal relationship matrix CRM ij Determine the connection relationship; define node attributes: node weight W(v i )=II i , indicating the importance of information at this time scale; the node feature vector F(v i ), including the statistical characteristics and waveform characteristics of the time scale; define the edge attributes: edge weight W(e ij )=CRM ij , indicating the strength of causal relationship; edge delay attribute D(e ij ) = τ ij , represents the delay in the propagation of causal effects; outputs the initial hierarchical graph structure IHGS; S514, dynamic update and evolution tracking of graph: input the initial hierarchical graph structure IHGS and the multi-scale time domain feature set MTFS to realize dynamic update of the graph, including: setting the graph update window length T and the sliding step length S; recalculating the causal relationship matrix CRM in each sliding window t t ; Update causal strength using exponentially weighted average: CRM ij new =α·CRM ij t +(1-α)·CRM ij old ; Track the changes in the graph structure and calculate the structural similarity: GS(t 1 ,t 2 )=similarity(G t1 , G t2 ); identify the mutation points of the graph as early indicators of state change; output the dynamic hierarchical time domain feature graph DHTFG and the graph evolution trajectory GET.
[0043] This scheme designs an adaptive mode number determination algorithm based on signal complexity, without the need for manually pre-defining time windows; innovatively proposes an incremental decomposition strategy, recursively decomposes low-quality modes and applies sparse optimization constraints, which significantly improves the feature decoupling effect; more importantly, the scheme constructs a hierarchical time domain feature map, organizes features of different time scales into a structured map, establishes the relationship between scales through the Granger causality test, and can automatically identify and track the abnormal propagation path across the time domain; combined with the map-guided adaptive feature fusion strategy, the second-order interaction term is introduced to capture the nonlinear relationship between features, which realizes the efficient recognition of multi-time scale complex anomalies, and especially improves the detection capability of sudden faults and slowly evolving faults under seasonal background.
[0044] This scheme extracts typical load features and constructs a load feature dictionary. Through sparse coding, the current load is represented as a linear combination of the feature dictionary to achieve accurate identification of the load type. Then, based on the power grid topology, an electric energy meter association network is established, and a progressive knowledge transfer mechanism is designed so that electric energy meters with insufficient data can learn from the attention configuration of similar electric energy meters. Most importantly, the scheme innovatively introduces the frequency domain attention modulation function, dynamically adjusts the attention weight according to the frequency domain characteristics of different load types, so that the attention mechanism can adaptively focus on the key change characteristics of various loads (such as industrial, commercial, and residential), effectively improving the detection accuracy in the case of load mutations.
[0045] This scheme calculates the electrical distance between nodes based on power flow analysis, builds a comprehensive distance matrix based on geographical distance, and converts it into a similarity index using the Gaussian kernel function to form a sparse but high-quality electricity meter association network; by calculating the comprehensive similarity of load similarity and network topology relationship, accurate grouping of similar electricity meters is achieved; an attention model is built for representative electricity meters in data-sufficient areas, and by designing a migration weight function based on data sufficiency, effective migration of knowledge from data-rich areas to sparse areas is achieved; as data accumulates, the system can smoothly transition to an autonomous learning mode, greatly improving the accuracy of electricity meter status assessment in areas with uneven spatial distribution, and achieving consistent high-precision assessment within the global power grid.
[0046] Example 1: The method of the present invention is applied to evaluate the status of electric energy meters in the power distribution network of District B in City A. The area contains 43 electric energy meters, including 12 industrial user electric energy meters, 18 commercial user electric energy meters and 13 residential user electric energy meters. Some electric energy meters have been installed and used for more than 5 years and have different degrees of state degradation risks. The specific steps are as follows: 1. Electricity meter data acquisition and preprocessing The data of one of the industrial user's electricity meters (ID: M23576) is selected for detailed description. The electricity meter has a collection cycle of 15 minutes and collects data for one week (June 5, 2023 to June 11, 2023), including voltage, current, active power, reactive power and power factor, as shown in Table 1 below.
[0047] Table 1 Original electric energy meter data fragment (part) Timestamp Voltage (V) Current (A) Active power (kW) Reactive power (kVar) Power Factor 2023-06-05 08:00 384.25 63.42 38.76 12.33 0.95 2023-06-05 08:15 385.11 78.63 47.21 15.42 0.94 2023-06-05 08:30 383.94 82.15 49.86 16.25 0.94 2023-06-05 08:45 382.76 85.27 51.43 17.08 0.93 ... ... ... ... ... ... 2023-06-05 14:15 379.43 98.75 58.94 19.35 0.94 2023-06-05 14:30 NULL NULL NULL NULL NULL 2023-06-05 14:45 378.92 96.83 57.73 18.94 0.94 ... ... ... ... ... ... S11, multi-source heterogeneous data acquisition: collect the original electrical parameter time series from the electric energy meter M23576, and simultaneously obtain the power grid topology data and the electric energy meter GPS location information (N34°15'42", E108°42'37"); S12. Data quality assessment: Calculate the data completeness rate CR = 667 / 672 = 0.9926, identify missing data at 5 time points, and detect outliers: The current value at 10:30 on June 7, 2023 is 215.83A, which is much higher than the mean value of 89.25A and exceeds 3 standard deviations (3σ=104.13), and is marked as an outlier; the voltage value at 02:15 on June 9, 2023 is 352.14V, which is significantly lower than the mean value of 380.25V and exceeds 3 standard deviations (3σ=12.27), and is marked as an outlier; S13. Data cleaning and standardization: Forward filling is applied to missing data: the data at 14:30 on June 5, 2023 is filled with [379.43, 98.75, 58.94, 19.35, 0.94]; median filtering is applied to the abnormal current value of 215.83A: median{83.51, 84.62, 215.83, 86.14, 85.97} = 85.97A; median filtering is applied to the abnormal voltage value of 352.14V: median{378.82, 379.15, 352.14, 380.23, 380.45} = 379.15V; standardization is performed on the cleaned data, including: voltage standardization: Vnorm(t)=(V(t) - 380.25) / 4.09; current standardization: Inorm(t)=(I(t) - 89.25) / 34.71; active power standardization: Pnorm(t)=(P(t) - 55.36) / 21.34; The standardized data fragment is shown in Table 2 below: Table 2 Standardized electric energy meter data fragment (part) Timestamp Vnorm Inorm Pnorm Qnorm PFnorm 2023-06-05 08:00 0.98 -0.74 -0.78 -0.85 0.63 2023-06-05 08:15 1.19 -0.31 -0.38 -0.42 0.42 ... ... ... ... ... ... 2. Multi-scale time-domain feature adaptive decomposition S21. Adaptive evaluation of signal complexity: Calculate the signal complexity of the active power normalization sequence Pnorm: approximate entropy ApEn(Pnorm) = 0.825; sample entropy SampEn(Pnorm) = 0.762; complexity index CI = 0.7×0.825 +0.3×0.762 = 0.806; determine the optimal number of decomposition modes K=ceil(3×0.806)=3 based on the CI value, and generate the decomposition parameter configuration DPC={K=3, α=2000, τ=0.1}; S22, self-optimizing variational mode decomposition: S221, initial modal decomposition parameter configuration: set the initial center frequencies ω1=π / 4, ω2=π / 2, ω3=3π / 4, and generate the initial decomposition parameter set IDP={Kinit=3, {ω1, ω2, ω3}, α=2000, τ=0.1}; S222, Coarse-grained variational modal basic decomposition: Apply VMD algorithm to the active power normalization sequence Pnorm: Construct augmented Lagrangian function; Converge after 300 iterations, and obtain the coarse-grained modal function set CMF={u1, u2, u3}; The main characteristics of each mode: u1: center frequency 0.0208 Hz (cycle about 48 hours), indicating the load change during the day; u2: center frequency 0.0696 Hz (cycle about 14.4 hours), indicating load changes during working hours; u3: center frequency 0.4167 Hz (period about 2.4 hours), indicating short-term load fluctuation; S223, execution of the incremental decomposition strategy: calculation of the energy retention rate of each mode: EPR1 = 0.674 (67.4%); EPR2 = 0.254 (25.4%); EPR3 = 0.072 (7.2%); calculation of the inter-modal correlation matrix: CorrM = [1.000,0.132, 0.095;0.132, 1.000, 0.583;0.095, 0.583, 1.000]; it was found that the correlation between u2 and u3 CorrM23 = 0.583 was close to the threshold of 0.6, but did not exceed it, and it was not marked as a low-quality mode for the time being; u3 energy retention rate EPR3 = 0.072> 0.05, and it was not marked as a low-quality mode; all modal qualities met the requirements, skipped the incremental decomposition step, and set the optimized modal function set OMF = CMF.
[0048] S224, Decomposition quality verification and parameter fine-tuning: The calculated reconstruction error RE=0.026<0.05; the calculated orthogonality index OI=0.27<0.3; the decomposition quality test passed, confirming the final intrinsic mode function set FIMFs={u1, u2, u3}; S23, Multi-scale feature extraction and time domain attribution recognition: The features of the three IMFs are extracted respectively, and the results are shown in Table 3 below: Table 3 IMF feature extraction results IMF Mean variance Kurtosis Skewness Main frequency (Hz) Sample Entropy Time scale attribution u1 0.012 0.442 2.753 0.124 0.0208 0.614 Day Level u2 0.005 0.253 3.126 0.217 0.0696 0.752 Hourly u3 0.002 0.078 4.831 0.356 0.4167 0.891 Hourly Generate a multi-scale time domain feature set MTFS and a time scale attribute map TSM.
[0049] 3. Construction of spatial topological relationship of power grid S31, power grid topology data analysis and node mapping: the electric energy meter M23576 is connected to the node N087 of the 10kV distribution line L2568; a mapping relationship MNM(M23576)=N087 is established; S32, Quantification of spatial correlation strength: Based on the power flow analysis, the electrical distance between node N087 and other nodes is calculated, such as EDN087, N092 = 1 / 0.238 = 4.202; combined with the geographical distance, such as GDN087, N092 = 283 meters, the spatial correlation strength is calculated: SCRMN087, N09 = 0.7 × (1 / 4.202) + 0.3 × (1 / 0.283) = 0.167 + 1.060 = 1.227; similar calculations are used to obtain the spatial correlation strength matrix SCRM between M23576 and other electric energy meters in the region; S33. Dynamic adaptive update of grid topology: It is monitored that the state of grid switch SW2345 changes on June 8, 2023, and the spatial correlation intensity matrix is updated to obtain a dynamically updated spatial correlation map DSRG.
[0050] 4. Load-aware spatiotemporal attention computation S41. Load characteristic identification and classification: Extract the load characteristics of M23576, including: daily load curve shape LC(t); peak-to-valley ratio PVR=65.42 / 17.58=3.72; intraday fluctuation coefficient VC=21.34 / 55.36=0.385; construct a load characteristic dictionary LFD, which contains the characteristics of different types of loads: Large industrial load characteristics F1=[3.85, 0.392, ...]; Medium industrial load characteristics F2=[2.73, 0.415, ...]; ...; Resident load feature F10 = [1.75, 0.203, ...]; Apply sparse coding algorithm to represent the load of M23576 as a linear combination of feature dictionaries: L = 0.82·F 2 +0.15 F 3 +0.03 F 1 + ε; Based on the dominant coefficient 0.82 corresponding to F2 (medium-sized industrial load), the load type identification LTI = "medium-sized industry" is determined, and the load sparse representation coefficient LSC = [0.03, 0.82, 0.15, 0, 0, 0, 0, 0, 0, 0]; S42. Hierarchical self-adjusting attention skeleton construction: According to LTI = "medium-sized industry", the corresponding attention initial template is selected, and a lightweight attention skeleton (edge end) and a full-feature attention model (cloud end) are designed; the resource allocation strategy is set to RASk = log(1 + Importancek), where Importancek is doubled based on the peak period (8:00-12:00 in the morning and 13:00-17:00 in the afternoon); S43. Dynamic attention modulation enhanced by mode transfer: S431. Construction of power grid topology association network: Extract connection relationships from DSRG to form an adjacency matrix A. For example, AM23576, M23581 = 1 means that the two electric energy meters are connected to the same line; apply Gaussian kernel function to convert the comprehensive distance into similarity: SM23576, M23581 = exp(-1.346 2 / 3.5 2 )=0.859>λ(0.7); retain the connections with similarity higher than 0.7 to form the electric energy meter association network MARN; M23576 forms an effective connection with 5 electric energy meters; S432, similar load electric energy meter identification and grouping: Calculate the load similarity: LSM23576, M23581 = cosine_similarity ([0.03, 0.82, 0.15, ...], [0.05, 0.79, 0.13, ...]) = 0.984; Combine the topological similarity and load similarity to calculate the comprehensive similarity: CSM23576, M23581 = 0.6 × 0.859 + 0.4 × 0.984 = 0.515 + 0.394 = 0.909; Apply the Louvain community detection algorithm to group the associated network, and M23576 is divided into the G3 group, which contains 4 electric energy meters, and the representative electric energy meter is M23581 (MRS = 0.95); S433. Design of Attention Knowledge Transfer Mechanism: The installation time of M23576 is May 2019, and the data sufficiency calculation is Di = 0.87; Design the transfer weight function: TWi(t) = exp(-2.5×0.87) = 0.114; Construct the hybrid attention model: AMM23576 = 0.114×AMM23581 + 0.886×AMM23576^local; S434. Construction of Frequency-Domain Attention Modulation Function: Apply FFT to the load sparse representation coefficients LSC = [0.03, 0.82, 0.15, 0, 0, 0, 0, 0, 0, 0] to obtain the frequency-domain representation F_LSC; Design the frequency response function to enhance the high-frequency component response for medium industrial loads: H(f) = 1.6 for f > 0.1Hz (corresponding to mutation monitoring); H(f) = 1.2 for 1 / (24*3600)Hz < f < 1 / (3600)Hz (corresponding to the working period); H(f) = 1.0 otherwise; Construct the frequency-domain modulation matrix D(C): D(C) = diag([1.03, 1.42, 1.36, 1.21, 1.06, 1.00, 1.00, 1.00]); Apply the modified attention calculation formula: Attention(Q, K, V, C) = softmax(QK^T·D(C) / √d)V; Obtain the dynamically modulated spatio-temporal attention matrix DTSAM (partial): DTSAM = [0.058, 0.032, 0.019,..., 0.012; 0.085, 0.124, 0.075,..., 0.018;... 0.027, 0.042, 0.163,..., 0.021].
[0051] 5. Multi-scale Spatio-temporal Feature Fusion and State Representation S51. Construction of Hierarchical Time-Domain Feature Map: S511. Definition of Time Scale Hierarchy and Feature Mapping: Establish the time scale hierarchy: L1 = second level (no corresponding IMF), L2 = minute level (no corresponding IMF), L3 = hour level (corresponding to u2, u3), L4 = day level (corresponding to u1), L5 = week level (no corresponding IMF); Calculate the information entropy of each scale: Entropy(L3) = 1.843, Entropy(L4) = 1.256; Obtain the importance indicators: II3 = 1.843 / (1.843 + 1.256) = 0.595, II4 = 1.256 / (1.843 + 1.256) = 0.405; S512, cross-scale causal relationship identification: Granger causality test from day level to hour level: p-value = 0.003 < 0.05, causality is established GrangerCausality (L4 → L3) = 0.687; Granger causality test from hour level to day level: p-value = 0.241 > 0.05, causality is not established GrangerCausality (L3 → L4) = 0.114; Calculate the causal delay parameter τ43 = 3, indicating that it takes about 3 hours for daily features to affect hourly features; S513, graph structure construction and attribute definition: Create a hierarchical directed graph G = (V, E): node set V = {v3, v4}, representing hourly and daily features respectively; edge set E = {e43}, representing the causal relationship from daily to hourly level; node weight W(v3) = 0.595, W(v4) = 0.405; edge weight W(e43) = 0.687, delay attribute D(e43) = 3; S514, dynamic update and evolution tracking of graphs: set the update window length T = 24 hours, the sliding step length S = 1 hour, and perform rolling updates on the data from June 5 to June 11; in the window at 13:00 on June 7, it was found that the graph structure changed: the edge weight W(e43) dropped from 0.687 to 0.532; a new strong autocorrelation pattern appeared within the hourly level; this change was close to the abnormal data time at 10:30 on June 7, which may be a sign of abnormality; S52, Attention-guided spatiotemporal feature selection: Sort the features in MTFS according to DTSAM, select the top 80% important features, and form the preferred feature subset SFS; S53, Adaptive feature fusion and state representation: Apply the graph-guided feature fusion strategy, including: feature weight wi is determined according to node weight and attention allocation; feature interaction weight wij is determined according to edge weight; construct the state representation vector MSRV, which contains 43 dimensions of information.
[0052] 6. Electricity meter status assessment and abnormality diagnosis S61, state deviation quantification and scoring: calculate the Mahalanobis distance MD = 2.86 normalized to the state evaluation score SES = 1-exp(-2.86 / 3) = 0.615; S62, abnormal pattern recognition and fault classification: SES = 0.615 < 0.7, not reaching the abnormal threshold, but close, determined as "need attention" state; matched with the template in the abnormal pattern library, the highest similarity is the "slow drift of electric energy meter parameters" pattern (similarity 0.783); S63. Explanatory analysis of evaluation results: The main abnormal contributions are located from: hourly u3 mode (contribution 52.7%); change in causal strength from daily to hourly level (contribution 31.5%); generate evaluation conclusion: "Electric energy meter M23576 is in the early stage of slow parameter drift, and it is recommended to strengthen monitoring. The main abnormality is manifested in short-term load response characteristic changes, which are expected to develop into obvious faults within 3-6 months." Comparison of experimental results: The test results of the method of the present invention and the traditional method on 43 electric energy meters in the power distribution network of District B in City A are compared. The comparison results are shown in Table 4 below: Table 4 Performance comparison of different methods Evaluation Metrics Traditional methods Method of the present invention Improvement rate Anomaly detection accuracy 78.3% 93.2% 19.0% Fault type identification accuracy 72.1% 85.7% 18.9% Parameter drift early detection rate 53.4% 81.2% 52.1% Average lead time for anomaly detection 4.2 days 12.6 days 200.0% False Positive Rate 8.5% 3.2% 62.4% The method of the present invention is particularly outstanding in early detection of parameter drift, and can discover potential problems 12.6 days in advance, providing maintenance personnel with sufficient response time.
[0053] In the subsequent six months of actual operation, the early warning based on this method captured a total of 7 electricity meter faults, 5 of which were parameter drift faults, with an accuracy rate of 85.7% and saved about 45% of maintenance costs.
[0054] Example 2: In the power distribution network of District B in City A, a group of typical electric energy meters are selected for analysis. The industrial user electric energy meter numbered M23576 and the commercial user electric energy meter numbered M23592 are selected as examples to demonstrate the complete process of constructing a hierarchical time domain feature map.
[0055] Step 1: Define the time scale hierarchy from seconds to months First, define the complete time scale hierarchy as follows: L1: second scale (1-60 seconds); L2: minute scale (1-60 minutes); L3: hour scale (1-24 hours); L4: day scale (1-7 days); L5: week scale (1-4 weeks); L6: month scale (1-12 months).
[0056] For the electric energy meter M23576, three intrinsic mode functions (IMFs) have been obtained through the previous self-optimizing variational mode decomposition. By analyzing the central frequency and period characteristics of each IMF, it is determined that: u1: central frequency 0.0208Hz (period is about 48 hours), belonging to L4 (daily scale); u2: central frequency 0.0696Hz (period is about 14.4 hours), belonging to L3 (hourly scale); u3: central frequency 0.4167Hz (period is about 2.4 hours), belonging to L3 (hourly scale).
[0057] For the electric energy meter M23592, four intrinsic mode functions were obtained: u1': center frequency 0.0104 Hz (period of about 96 hours), belonging to L4 (daily scale); u2': center frequency 0.0417 Hz (period of about 24 hours), belonging to L4 (daily scale); u3': center frequency 0.1389 Hz (period of about 7.2 hours), belonging to L3 (hourly scale); u4': center frequency 0.6944 Hz (period of about 1.44 hours), belonging to L3 (hourly scale); Based on the above analysis, the time scale attribution mapping tables TSM_M23576 and TSM_M23592 are established: TSM_M23576 = {"u1": "L4","u2": "L3","u3": "L3"}; TSM_M23592 = {"u1'":"L4","u2'": "L4","u3'": "L3","u4'": "L3"}.
[0058] Step 2: Calculate the information entropy at each time scale level Information entropy is used to measure the amount of information contained in each time scale as a quantitative indicator of the importance of the time scale. It is calculated using the Shannon entropy formula: H(X) = -∑p(xi)log2p(xi); where p(xi) is the probability distribution of the eigenvalue xi.
[0059] For the electric energy meter M23576, the feature entropy at the hourly level (L3) and the daily level (L4) is calculated respectively: first, the u2 and u3 data sets corresponding to L3 are merged to form the hourly feature set FS_L3_M23576; the u1 data corresponding to L4 is used as the daily feature set FS_L4_M23576; the probability distribution of the feature set is estimated, and the data is divided into 10 intervals of equal width to calculate the probability density.
[0060] Calculation results: Entropy(L3)_M23576 = 1.843 bits; Entropy(L4)_M23576 = 1.256 bits.
[0061] For the energy meter M23592, the same calculation is performed: Entropy(L3)_M23592 = 1.683 bits; Entropy(L4)_M23592 = 2.145 bits.
[0062] Based on the above information entropy, the importance index of each time scale is calculated: Electricity meter M23576: II3 = 1.843 / (1.843+1.256) = 0.595; II4 = 1.256 / (1.843+1.256) = 0.405; Electricity meter M23592: II3 = 1.683 / (1.683+2.145) = 0.440; II4 = 2.145 / (1.683+2.145) = 0.560.
[0063] These importance indicators will serve as the quantitative basis for the node weights in the graph.
[0064] Step 3: Use Granger causality test to identify causal relationships between characteristics at different time scales Granger causality test is a statistical hypothesis test used to determine whether one time series is helpful in predicting another time series. The following steps are used to perform Granger causality analysis: First, the stationarity of each time scale feature is tested (using the augmented Dickey-Fuller test), and difference processing is performed when necessary to ensure data stability; the Bayesian Information Criterion (BIC) is used to determine the optimal lag order; a VAR model is constructed: a vector autoregression model is constructed based on the determined lag order; Perform Granger causality test and calculate F statistic and p-value; for electricity meter M23576, perform the following test: Granger causality test from day level to hour level (L4→L3): Use the characteristic sequence of L4 as the independent variable and the characteristic sequence of L3 as the dependent variable; determine the optimal lag order k = 3 (based on the BIC minimum principle); perform the test and obtain F statistic = 8.743, p value = 0.003<0.05; The causal relationship exists, and the daily-level features have significant predictive power for the hourly-level features.
[0065] Causal strength calculation, GrangerCausality(L4→L3) = 0.687 (standardized value based on VAR model coefficients) Granger causality test from hourly level to daily level (L3→L4): Use the feature sequence of L3 as the independent variable and the feature sequence of L4 as the dependent variable; adopt the same lag order k = 3; perform the test and obtain F statistic = 1.478, p value = 0.241>0.05; the causal relationship is not significant, and the hourly level features have insufficient predictive power for the daily level features; the causal strength is recorded as GrangerCausality(L3→L4) = 0.114 (although not significant).
[0066] For the electric energy meter M23592, similar tests were performed and the results were: GrangerCausality(L4→L3)_M23592 = 0.752, p-value = 0.001<0.05 (significant); GrangerCausality(L3→L4)_M23592 = 0.328, p-value = 0.047<0.05 (significant but weak); Step 4: Construct a cross-scale causal relationship matrix and causal delay parameter table Based on the results of the Granger causality test, a cross-scale causal relationship matrix CCRM is constructed. For each pair of time scales Li and Lj, CCRM(i,j) represents the causal strength from Li to Lj.
[0067] For the electric energy meter M23576, the causal relationship matrix is: CCRM_M23576 = [ [0, 0, 0, 0, 0, 0], L1->L1, L1->L2, ... [0, 0, 0, 0, 0, 0], L2->L1, L2->L2, ... [0, 0, 0, 0.114,0, 0], L3->L1, L3->L2, ... [0, 0, 0.687,0, 0, 0], L4->L1, L4->L2, ... [0, 0, 0, 0, 0, 0], L5->L1, L5->L2, ... [0, 0, 0, 0, 0, 0] L6->L1, L6->L2, ...] For the electric energy meter M23592, the causal relationship matrix is: CCRM_M23592 = [ [0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0], [0, 0, 0, 0.328,0, 0], [0, 0, 0.752,0, 0, 0], [0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0]] In addition, it is necessary to determine the causal delay parameter, which represents the time required for the causal effect to propagate from one time scale to another. This is determined by the optimal lag order in the Granger causality test.
[0068] Causal delay parameter table of electric energy meter M23576: CDP_M23576 = { "L4→L3": 3, it takes about 3 hours for day-level features to affect hour-level features; "L3→L4": It takes about 5 hours for the hourly feature to affect the daily feature (although this causal relationship is not significant) }.
[0069] Causal delay parameter table of electric energy meter M23592: CDP_M23592 = { "L4→L3": 2, it takes about 2 hours for daily features to affect hourly features; "L3→L4": It takes about 6 hours for 6 hour-level features to affect day-level features.} Step 5: Construct a hierarchical directed graph based on the time scale hierarchy and cross-scale causal relationship matrix Finally, based on the analysis results of the previous steps, a hierarchical directed graph G = (V, E) is constructed: The node set V contains the features corresponding to each time scale; the edge set E represents the causal relationship between different time scales; the node weight is based on the importance index calculated by information entropy; the edge weight is based on the Granger causal strength; the direction of the edge represents the direction of causal action; the attributes of the edge include delay parameters; for the hierarchical directed graph G_M23576 of the electric energy meter M23576: the node set V = {v3, v4}, representing hourly and daily features respectively; the node weight W(v3) = 0.595, W(v4) = 0.405; Edge set E = {e43}, representing the edge from v4 to v3 (daily to hourly); edge weight W(e43) = 0.687, representing the causal strength from daily to hourly level; edge delay D(e43) = 3, indicating that the delay time from daily to hourly level is 3 hours; for the hierarchical directed graph G_M23592 of the energy meter M23592: node set V = {v3, v4}, representing hourly and daily features respectively; node weight W(v3) = 0.440, W(v4) = 0.560; edge set E = {e43, e34}, representing bidirectional causal relationship; edge weight W(e43) = 0.752, W(e34) = 0.328; edge delay D(e43) = 2, D(e34) = 6; In addition, in order to more completely represent the hierarchical time domain feature map, the following attributes are added to the nodes in the graph: node feature vector F(v): contains the statistical characteristics of the time scale (such as mean, variance, kurtosis, skewness, etc.); node frequency domain characteristics FS(v): contains the main frequency components of the time scale; node nonlinear characteristics NL(v): contains nonlinear characteristics such as sample entropy; In an abnormal monitoring of electric energy meters, the hierarchical time domain feature map of the M23576 electric energy meter was tracked and analyzed, and it was found that: from 00:00 on July 15, 2023 to 23:59 on July 17, 2023, the structure of the hierarchical time domain feature map changed significantly: the causal strength W(e43) from the day level to the hour level decreased from 0.687 to 0.423; the information entropy of the hourly level features increased from 1.843 to 2.217; a new strong autocorrelation pattern appeared within the hourly level; These changes in the graph structure preceded the detection of meter anomalies by traditional methods, and discovered early signs of abnormal impedance in the voltage measurement loop of the meter about 9 days in advance. The dynamic change trajectory of the hierarchical time domain feature graph shows that the anomaly first appeared in the hourly features, then affected the daily features through the causal path in the graph, and finally caused the overall meter status score to drop.
[0070] In summary, the present invention designs an optimal mode number determination algorithm based on adaptive evaluation of signal complexity, and introduces sparse optimization constraints and incremental decomposition strategies, which solves the problem of parameter preset of traditional VMD algorithm, does not require manual pre-definition of time windows and scale parameters, can automatically adapt to the diverse characteristics of different electric energy meters, and reduce the problem of modal aliasing; the present invention proposes an attention knowledge transfer mechanism based on the topological structure of the power grid, and designs a frequency domain attention modulation function, realizes dynamic attention adjustment based on load characteristic perception, solves the cold start problem of newly installed or insufficient data electric energy meters, and can dynamically adjust attention allocation according to the load characteristics of different types of users; the present invention proposes a cross-time domain feature spectrum representation method for the state of the electric energy meter, establishes the relationship between nodes through the Granger causality test, realizes the structured organization of multi-scale features, can track the evolution path of faults at different time scales, and improves the recognition ability of complex anomalies; the present invention introduces the spectrum structure information into the feature fusion process, captures the nonlinear relationship between features through the second-order interaction term, realizes the context-aware dynamic feature reorganization, effectively balances the importance of features at different time scales, and improves the recognition ability of slowly evolving fault states.
[0071] The preferred embodiments of the present invention are described in detail above; however, the present invention is not limited to the specific details in the above embodiments. Within the technical concept of the present invention, various equivalent transformations can be made to the technical solutions of the present invention, and these equivalent transformations all belong to the protection scope of the present invention.
Claims
1. A method for evaluating the state of an electric energy meter based on a spatiotemporal attention mechanism, characterized in that: The following steps are involved: Obtaining the original data of the electric energy meter, preprocessing it, obtaining a standard electric energy meter data set, and performing multi-scale time domain feature adaptive decomposition on it to obtain a multi-scale time domain feature set; Based on the grid topology data and the location information of the electric energy meter, the spatial topological relationship of the grid is constructed to obtain a spatial correlation map; Combining the multi-scale time domain feature set and the spatial correlation map, the load characteristic-aware spatiotemporal attention weights are calculated to obtain a dynamically modulated spatiotemporal attention matrix. Based on the dynamically modulated spatiotemporal attention matrix, the multi-scale time domain feature set is adaptively fused to construct the state representation vector of the electric energy meter; And perform status assessment and abnormal diagnosis to obtain the status assessment results of the electricity meter.
2. The method according to claim 1, characterized in that The multi-scale time domain feature adaptive decomposition is performed on the standard electric energy meter data set, including: Calculate the signal complexity index of the standard electric energy meter data set, determine the optimal number of decomposition modes based on it, and generate the decomposition parameter configuration; According to the decomposition parameter configuration, the standard electric energy meter data set is processed using the self-optimizing variational mode decomposition algorithm to obtain the intrinsic mode function set; Feature extraction is performed on the intrinsic modal function set, and the time domain statistical features, frequency domain features and nonlinear features are calculated. Each modal function is mapped to a specific time scale to generate a multi-scale time domain feature set and a time scale attribution map.
3. The method according to claim 2, characterized in that The steps of processing using the self-optimizing variational mode decomposition algorithm include: Determine the initial mode number and center frequency according to the decomposition parameter configuration and generate an initial decomposition parameter set; The variational modal decomposition algorithm is performed on the standard electric energy meter data set using the initial decomposition parameter set to obtain the coarse-grained modal function set and modal quality assessment index; Based on the modal quality assessment index, low-quality modes in the coarse-grained modal function set are identified, and variational decomposition is recursively performed on each low-quality mode. Sparse optimization constraints are applied to obtain the optimized modal function set. The decomposition quality of the optimized modal function set is verified, the reconstruction error and orthogonality index are calculated, the decomposition parameters are confirmed or adjusted according to the verification results, and the intrinsic modal function set is output.
4. The method according to claim 3, characterized in that The steps of identifying low-quality modes based on modal quality assessment indicators and recursively performing variational decomposition include: Calculate the energy retention rate and inter-modal correlation matrix of each mode in the coarse-grained modal function set; and identify the modes whose energy retention rate is lower than the preset threshold or the inter-modal correlation is higher than the preset threshold based on this, to form a low-quality modal set; Perform variational modal decomposition on each modal signal in the low-quality modal set as a new input signal, set the initial number of modes to 2, and generate the corresponding sub-modal set; The sub-modes are combined with the stored original high-quality mode set, and the objective function is applied to minimize the inter-modal aliasing, outputting the optimized modal function set.
5. The method according to claim 1, characterized in that The steps to calculate the load feature-aware spatiotemporal attention weights include: Extract load features based on multi-scale time domain feature sets and build a load feature dictionary; The current load is represented as a linear combination of feature dictionaries to obtain the load type identifier and load sparse representation coefficient, based on which a hierarchical self-adjusting attention calculation skeleton and resource allocation strategy are constructed; Combining the spatial correlation graph, load sparse representation coefficients and attention calculation skeleton, dynamic attention modulation enhanced by pattern transfer is realized to obtain a dynamically modulated spatiotemporal attention matrix.
6. The method according to claim 5, characterized in that The steps of constructing a load feature dictionary and expressing the current load as a linear combination of the feature dictionary include: Extract typical load characteristics from multi-scale time domain feature sets, including daily load curve shape, peak-to-valley ratio and volatility characteristics; Construct a load feature dictionary based on typical load features, including the feature representation of industrial, commercial and residential loads; Represent the current load as a linear combination of basis vectors in the load feature dictionary to obtain sparse coefficients; The load is classified based on the sparse coefficient, the load type identifier is determined, and the sparse coefficient is output as a load sparse representation coefficient.
7. The method according to claim 5, characterized in that The steps to achieve dynamic attention modulation for mode transfer enhancement include: Based on the spatial correlation graph, an associated network of electric energy meters with similar load characteristics is established to obtain the load similarity and network topology relationship and calculate the comprehensive similarity between electric energy meters accordingly; An attention model is built for electricity meters with sufficient data. For electricity meters with insufficient data, similar electricity meters are selected from the electricity meter association network according to the comprehensive similarity, and a progressive migration weight function based on data sufficiency is constructed. Fast Fourier transform is applied to the load sparse representation coefficients to construct a frequency domain attention modulation function that dynamically adjusts the frequency response gain for different load types; The attention model calculation formula is modified according to the transfer weight function and the frequency domain attention modulation function to obtain a dynamically modulated spatiotemporal attention matrix.
8. The method according to claim 7, characterized in that Construct a progressive migration weight function, including: Based on the energy meter association network and node similarity matrix, the energy meters are grouped according to similarity, and a representative energy meter is calculated for each group; Build an attention model for representative energy meters with sufficient data, identify the groups to which energy meters with insufficient data belong and the corresponding representative energy meters, and design a transfer weight function TW i (t)=exp(-γ·D i (t)), where D i (t) is the data adequacy of electric energy meter i, and γ is the attenuation coefficient; Building a hybrid attention model AM i =TW i (t)·AM r +(1-TW i (t))·AM i local , where AM r 、AM i local Attention model and local attention model for a representative energy meter.
9. The method according to claim 1, characterized in that The steps of adaptively fusing the multi-scale time domain feature set include: Based on the multi-scale time domain feature set and time scale attribution mapping, a hierarchical time domain feature map is constructed to represent the structural relationship between features at different time scales. The importance of multi-scale temporal feature sets is ranked according to the dynamically modulated spatiotemporal attention matrix, and the most discriminative feature subset is selected; Utilizing the hierarchical time-domain feature graph and the dynamically modulated spatiotemporal attention matrix, the graph-guided adaptive feature fusion is performed to construct an electric energy meter state representation vector containing multi-scale time-domain information and spatial correlation information.
10. The method according to claim 9, characterized in that The steps to construct a hierarchical time-domain feature map include: Define a time scale hierarchy from seconds to months, and map the features in the multi-scale time domain feature set to the corresponding time scale according to the time scale attribution mapping; Calculate the information entropy at each time scale level as an indicator of the importance of the amount of information contained in that time scale; Granger causality test is used to identify the causal relationship between characteristics of different time scales, and a cross-scale causal relationship matrix and causal delay parameter table are constructed; Based on the time scale hierarchy and the cross-scale causal relationship matrix, a hierarchical directed graph is constructed. The nodes in the graph represent the characteristics of different time scales, and the edges represent the cross-scale causal relationships.
Citation Information
Patent Citations
Substation data collaborative identification method, device and equipment and storage medium
CN118820909A
Helium leak detection method and system for switch cabinet
CN118882947A
Transform-based method and device for constructing sample efficient world model
CN119271974A
Tumor microenvironment spatial relationship modeling system and method based on digital pathology image
WO2023137627A1
Cited By
Intelligent electric meter electricity utilization behavior interpretability analysis method based on causal atlas
CN120278399A
Power load clustering method based on multi-dimensional feature fusion and dynamic optimization
CN120316541A
Regional power utilization scheduling method and system for power equipment
CN120433206A
Electric energy meter precision degradation evaluation system and equipment based on sampling unit fault characteristics
CN120630093A
Hydraulic control optimization system and method based on differential pressure direction change mode recognition
CN120969308A