Energy consumption anomaly real-time detection method and system for smart energy
By constructing gradient vector fields and energy transfer networks in time and space dimensions, and combining them with gradient mutation detection, the problem of identifying energy consumption anomalies under the dynamic interaction of multiple subsystems in smart energy systems is solved. This achieves efficient and accurate detection of energy consumption anomalies, improving system operating efficiency and security.
Patent Information
- Application Number
- CN202510711586.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-29
- Publication Date
- 2025-11-11
- Estimated Expiration
- 2045-05-29
AI Technical Summary
Existing technologies struggle to effectively identify energy consumption anomalies caused by dynamic interactions between multiple subsystems in smart energy systems, resulting in low accuracy in anomaly identification and a high false alarm rate. Furthermore, traditional methods neglect the dynamic process of energy transfer, making it difficult to detect potential energy consumption anomalies in a timely manner.
By constructing gradient vector fields in time and space dimensions, combined with energy balance analysis of communication nodes, key features are extracted and the energy transfer process between subsystems is tracked. An energy transfer network is constructed using graph convolution algorithm to generate a spatial interaction feature matrix. Combined with gradient mutation detection and energy path tracing algorithms, abnormal flow points are identified.
It enables comprehensive monitoring of smart energy systems, timely detection of abnormal flow, improved system operating efficiency and security, and enhanced accuracy of anomaly detection and system stability.
Smart Images

Figure CN120470409B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a method and system for real-time detection of energy consumption anomalies in smart energy systems. Background Technology
[0002] Energy is the material basis of human activities and the most fundamental driving force for global development and economic growth. There are many types of energy, but in process industries, they can generally be divided into five categories: water, air, gas, electricity, and steam. It is under the drive of these five energy sources that a factory can transform its input raw materials and human resources into corresponding products. As an important part of production costs, enterprises have increasingly higher requirements for energy management. In order to gain a foothold and stand out in the fierce market competition, in addition to increasing revenue, it is also necessary to reduce costs. Therefore, the requirements for energy management are crucial from the perspectives of human resource protection, enterprise cost management, and improving business efficiency.
[0003] However, current energy anomaly detection methods face significant limitations in complex systems. Traditional solutions often rely on single-dimensional statistical analysis or rule-based thresholds, making them ill-suited for complex scenarios involving dynamic interactions between multiple subsystems. In particular, they are insufficient in capturing energy flow characteristics across time and space, resulting in low accuracy and high false alarm rates in anomaly identification. These methods often overlook the dynamic processes of energy transfer, making it difficult to detect potential energy consumption anomalies in a timely manner. Summary of the Invention
[0004] Based on the above-mentioned technical problems, this application provides a method and system for real-time detection of abnormal energy consumption in smart energy, so as to improve the accuracy of detecting abnormal energy consumption nodes.
[0005] Firstly, this application provides a method for real-time detection of energy consumption anomalies in smart energy systems. The smart energy system includes multiple energy-consuming nodes. The method includes: acquiring energy consumption data and energy flow data of each energy-consuming node in the smart energy system; extracting a spatial interaction feature matrix based on the energy consumption data and energy flow data; the spatial interaction feature matrix reflects the connectivity and intensity of energy flow between energy-consuming nodes; determining candidate nodes for anomalies in the smart energy system based on the spatial interaction feature matrix, obtaining a set of candidate nodes for anomalies; the connectivity of energy flow of the candidate nodes for anomalies is less than a first preset threshold, and the intensity of energy flow is less than a second preset threshold; extracting energy anomaly propagation feature vectors corresponding to the set of candidate nodes for anomalies; the energy anomaly propagation feature vectors reflect the intensity of energy flow and the uniformity of energy gradient distribution of each candidate node for anomalies; and using a pattern matching algorithm, comparing the similarity between the energy anomaly propagation feature vectors and the corresponding normal energy propagation feature vectors in a pre-established normal energy consumption pattern library. If the similarity is less than a third preset threshold, the candidate nodes for anomalies are determined to be real anomalies, and a final anomaly detection result is generated.
[0006] In one possible implementation, a spatial interaction feature matrix is extracted based on energy consumption data and energy flow data. This includes: constructing an energy transfer network between energy-consuming nodes using a graph convolution algorithm based on the trend slope and abrupt change time points of the energy consumption data, as well as the flow direction intensity and flow direction angle in the energy flow data; generating a weighted adjacency matrix describing the flow direction connectivity and flow direction intensity between nodes; and obtaining the spatial interaction feature matrix.
[0007] In one possible implementation, based on a spatial interaction feature matrix, abnormal candidate nodes in the smart energy system are determined, including: obtaining the flow direction intensity and energy inflow / outflow deviation of each node from the spatial interaction feature matrix; calculating the deviation vector using a vector decomposition method; if the magnitude of the deviation vector is greater than a fourth preset threshold, it is marked as a node to be optimized, thus obtaining a set of nodes to be optimized; for the set of nodes to be optimized, calculating the gradient magnitude and flow direction angle of each node using a gradient calculation method; obtaining a set of node feature vectors by vector synthesis, which includes the gradient magnitude and flow direction angle; calculating the uniformity of gradient distribution and flow direction connectivity between nodes using a graph analysis method based on the set of node feature vectors, generating an energy balance vector containing the uniformity of distribution and connectivity features, thus obtaining a set of energy balance vectors; if the connectivity feature of a vector in the energy balance vector set is less than a fifth preset threshold, then an abnormal candidate node is screened using an anomaly detection algorithm, thus obtaining a set of abnormal candidate nodes.
[0008] In one possible implementation, the energy anomaly propagation feature vector corresponding to the set of anomaly candidate nodes is extracted, including: for the set of anomaly candidate nodes, a gradient field modeling method is used, combining the volatility amplitude and periodic amplitude of energy consumption data, and the gradient amplitude and flow direction angle of energy flow data, to calculate the local extreme values of the gradient and the flow direction bifurcation points of each node in the time and space dimensions, generating a gradient vector field; a gradient mutation detection algorithm is used to detect whether there are gradient mutation points in the gradient vector field, and if the gradient amplitude change rate of any region in the gradient vector field is greater than a sixth preset threshold, it is marked as an abnormal flow direction point, obtaining a set of anomaly point locations; based on the gradient mutation points in the set of anomaly point locations, combined with an energy path tracing algorithm, the flow direction bifurcation points and flow direction intensity between the anomaly point and adjacent nodes are analyzed, the propagation direction and gradient distribution uniformity of the abnormal flow direction are calculated, and the energy anomaly propagation feature vector is obtained.
[0009] The technical solution provided in this application brings at least the following beneficial effects:
[0010] (1) This application discloses a real-time detection method for energy consumption anomalies in smart energy systems. It combines energy consumption data in the time dimension with energy flow data in the spatial dimension to extract a spatial interaction feature matrix reflecting the connectivity and intensity of energy flow between energy-consuming nodes. By constructing gradient vector fields in the time and spatial dimensions, combined with energy balance analysis of AC nodes, key features are extracted and the energy transfer process between subsystems is tracked to accurately identify gradient abrupt changes or abnormal flow points, thereby finding abnormal energy-consuming nodes. Compared to traditional solutions that rely heavily on single-dimensional statistical analysis or rule thresholds, which are difficult to adapt to complex scenarios of dynamic interaction between multiple subsystems, this application provides comprehensive monitoring of smart energy systems in both the time and spatial dimensions, enabling timely detection of abnormal flow directions and improving system operating efficiency and security.
[0011] (2) Based on the trend slope and abrupt change time points of energy consumption data, and the flow direction intensity and angle in energy flow data, this application uses a graph convolution algorithm to construct an energy transfer network between energy-consuming nodes, generating a weighted adjacency matrix describing the flow direction connectivity and flow direction intensity between nodes, thus obtaining a spatial interaction feature matrix. The spatial interaction feature matrix is a mathematical tool used to describe the interaction relationships between different regions or entities in geographic space. Its core lies in quantifying the interaction between spatial units, thus revealing the inherent laws and dynamic characteristics of spatial structure.
[0012] (3) With the development of digital twin and urban computing technologies, spatial interaction feature matrices will evolve towards high resolution, multimodality and real-time. Based on the spatial interaction feature matrix, this application identifies abnormal candidate nodes in the smart energy system, providing more accurate decision support for the screening of abnormal candidate nodes.
[0013] (4) This application combines a node balancing algorithm to determine candidate abnormal nodes and uses a gradient field modeling method to generate a dynamic energy flow map. Abnormal flow points are marked using a gradient mutation detection algorithm, and abnormal propagation characteristics are analyzed using an energy path tracing algorithm. Finally, a pattern matching algorithm is used to compare the similarity between abnormal propagation characteristics and normal patterns, confirming the true anomaly and generating the final detection result. This application achieves comprehensive monitoring of the smart energy system, enabling timely detection of abnormal flow directions and improving system operating efficiency and security.
[0014] Secondly, this application provides a real-time energy consumption anomaly detection system for smart energy. The system includes an energy consumption anomaly detection device, which comprises a processing unit and a determination unit. The processing unit acquires energy consumption data and energy flow data of each energy-consuming node in the smart energy system, and extracts a spatial interaction feature matrix based on the energy consumption data and energy flow data. The spatial interaction feature matrix reflects the energy flow connectivity and energy flow intensity between each energy-consuming node. The determination unit determines anomaly candidate nodes in the smart energy system based on the spatial interaction feature matrix, obtaining an anomaly candidate node set. The energy flow connectivity of the anomaly candidate nodes is less than a first preset threshold, and the energy flow intensity is less than a second preset threshold. The processing unit further extracts energy anomaly propagation feature vectors corresponding to the anomaly candidate node set. The energy anomaly propagation feature vectors reflect the energy flow intensity and energy gradient distribution uniformity of each anomaly candidate node. The determination unit further employs a pattern matching algorithm to compare the similarity between the energy anomaly propagation feature vectors and the corresponding normal energy consumption pattern feature vectors in a pre-established normal energy consumption pattern library. If the similarity is lower than a third preset threshold, the anomaly candidate node is determined to be a real anomaly, and a final anomaly detection result is generated.
[0015] In one possible implementation, the processing unit is specifically used to: construct an energy transfer network between energy-consuming nodes using a graph convolution algorithm based on the trend slope and abrupt change time points of energy consumption data, as well as the flow direction intensity and flow direction angle in energy flow data, generate a weighted adjacency matrix describing the flow direction connectivity and flow direction intensity between nodes, and obtain a spatial interaction feature matrix.
[0016] In one possible implementation, the unit is specifically used for: obtaining the flow direction intensity and energy inflow / outflow deviation of each node from the spatial interaction feature matrix; calculating the deviation vector using a vector decomposition method; if the magnitude of the deviation vector is greater than a fourth preset threshold, it is marked as a node to be optimized, thus obtaining a set of nodes to be optimized; for the set of nodes to be optimized, calculating the gradient magnitude and flow direction angle of each node using a gradient calculation method; obtaining a set of node feature vectors by vector synthesis containing the gradient magnitude and flow direction angle; calculating the uniformity of gradient distribution and flow direction connectivity between nodes using a graph analysis method based on the set of node feature vectors; generating an energy balance vector containing the uniformity of distribution and connectivity features, thus obtaining a set of energy balance vectors; if the connectivity feature of a vector in the energy balance vector set is less than a fifth preset threshold, filtering abnormal candidate nodes using an anomaly detection algorithm, thus obtaining a set of abnormal candidate nodes.
[0017] In one possible implementation, the processing unit is specifically used for: for the set of abnormal candidate nodes, using a gradient field modeling method, combining the volatility amplitude and periodic amplitude of energy consumption data, and the gradient amplitude and flow direction angle of energy flow data, to calculate the local extreme values of the gradient and the flow direction bifurcation points of each node in the time and space dimensions, generating a gradient vector field; using a gradient mutation detection algorithm to detect whether there are gradient mutation points in the gradient vector field, if the rate of change of gradient amplitude in any region of the gradient vector field is greater than a sixth preset threshold, it is marked as an abnormal flow direction point, obtaining a set of abnormal point locations; based on the gradient mutation points in the set of abnormal point locations, combined with an energy path tracing algorithm, analyzing the flow direction bifurcation points and flow direction intensity between the abnormal points and adjacent nodes, calculating the propagation direction and gradient distribution uniformity of the abnormal flow direction, and obtaining an energy anomaly propagation feature vector.
[0018] Thirdly, this application provides an electronic device, including: a processor and a memory; the memory stores processor-executable instructions; when the processor is configured to execute the instructions, the electronic device implements the method described in the first aspect above.
[0019] Fourthly, this application provides a computer program product that, when run in an electronic device, causes the electronic device to execute the methods related to the first aspect described above, thereby implementing the methods of the first aspect.
[0020] Fifthly, this application provides a computer-readable storage medium comprising: software instructions; which, when executed in an electronic device, cause the electronic device to implement the method described in the first aspect.
[0021] The beneficial effects of the second to fifth aspects mentioned above can be referred to the first aspect, and will not be repeated here. Attached Figure Description
[0022] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1 This is a schematic diagram of the structure of a smart energy system provided in an embodiment of this application;
[0024] Figure 2 A schematic diagram illustrating the composition of the electronic device provided in the embodiments of this application;
[0025] Figure 3 A flowchart illustrating the real-time detection method for energy consumption anomalies in smart energy provided in this application embodiment;
[0026] Figure 4 This is a schematic diagram of the composition of the energy consumption anomaly detection device provided in the embodiments of this application. Detailed Implementation
[0027] To enable those skilled in the art to better understand the technical solutions of this application, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings.
[0028] It should be noted that the terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0029] Furthermore, in the description of the embodiments of this application, unless otherwise stated, " / " means "or". For example, A / B can mean A or B. The term "and / or" in this document is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, in the description of the embodiments of this application, "multiple" refers to two or more.
[0030] Before providing a detailed explanation of the embodiments of this application, some related terms and technologies involved in the embodiments of this application will be introduced first.
[0031] Energy management is a crucial pillar of sustainable industrial and urban development, directly impacting resource utilization efficiency and environmental protection. Smart energy systems provide key support for achieving a low-carbon economy by monitoring and optimizing energy consumption in real time.
[0032] However, current energy anomaly detection methods face significant limitations in complex systems. Traditional solutions often rely on single-dimensional statistical analysis or rule-based thresholds, making them ill-suited for complex scenarios involving dynamic interactions between multiple subsystems. In particular, they are insufficient in capturing energy flow characteristics across time and space, resulting in low accuracy and high false alarm rates in anomaly identification. These methods often overlook the dynamic processes of energy transfer, making it difficult to detect potential energy consumption anomalies in a timely manner. The core challenge lies in effectively characterizing the dynamic changes in energy consumption across time and space, and in extracting key features from complex energy transfer networks to identify anomalies.
[0033] In the time dimension, fluctuations in energy consumption may vary due to load changes or equipment failures. In the spatial dimension, energy flow between subsystems is nonlinear and heterogeneous, making it difficult for traditional methods to construct a unified characteristic description model.
[0034] Furthermore, energy balance analysis at AC nodes involves multivariate coupling, and existing technologies lack robustness in handling abrupt gradient changes or abnormal flow directions, making it difficult to accurately locate anomalies. These unresolved technical factors directly constrain the anomaly detection capabilities of smart energy systems in highly dynamic environments, thus raising the unique challenge of achieving efficient and accurate anomaly detection in complex systems.
[0035] In view of the above problems, this application provides a method for real-time detection of energy consumption anomalies in smart energy. By constructing a gradient vector field in time and space dimensions, combined with energy balance analysis of AC nodes, key features are extracted and the energy transfer process between subsystems is tracked to accurately identify gradient abrupt changes or abnormal flow points, thereby discovering abnormal energy consumption nodes.
[0036] The method for real-time detection of energy consumption anomalies for smart energy provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings.
[0037] The real-time energy consumption anomaly detection method for smart energy provided in this application embodiment can be applied to smart energy systems. Figure 1 A schematic diagram of the structure of this smart energy system is shown. Figure 1As shown, the smart energy system 10 includes an energy consumption anomaly detection device 11 and multiple energy consumption nodes 12. The energy consumption nodes 12 are connected to each other via wired or wireless means. The energy consumption anomaly detection device 11 is also connected to the multiple energy consumption nodes 12 via wired or wireless means. Specifically, the energy consumption anomaly detection device 11 can be connected to multiple energy consumption nodes individually or to a single overall energy consumption node; this embodiment does not limit the connection in this application.
[0038] The power consumption anomaly detection device 11 can be any electronic device with data processing capabilities. For example, the power consumption anomaly detection device 11 can be a server, a computer, or a server cluster consisting of multiple servers. In some embodiments, the server cluster can also be a distributed cluster. Optionally, the server can be a central server, and the server can also be implemented on a cloud platform. For example, the cloud platform can include private cloud, public cloud, hybrid cloud, community cloud, distributed cloud, inter-cloud, and multi-cloud, or any combination thereof. This application embodiment does not limit this.
[0039] The execution entity of the real-time energy consumption anomaly detection method for smart energy provided in this application embodiment can be the aforementioned energy consumption anomaly detection device 11. As mentioned above, the energy consumption anomaly detection device 11 can be an electronic device with data processing capabilities, such as a computer or server. Optionally, the energy consumption anomaly detection device 11 can also be a processor (e.g., a central processing unit, CPU) in the aforementioned electronic device; or, the energy consumption anomaly detection device 11 can also be an application (APP) with model training capabilities installed in the aforementioned electronic device; or, the energy consumption anomaly detection device 11 can also be a functional module with model training capabilities in the aforementioned electronic device, etc. This application embodiment does not impose any limitations on this.
[0040] For simplicity, the following description will use the power consumption anomaly detection device 11 as an electronic device as an example.
[0041] Figure 2 This is a schematic diagram illustrating the composition of an electronic device provided in an embodiment of this application. For example... Figure 2 As shown, the electronic device may include: a processor 20, a memory 21, a communication line 22, a communication interface 23, and an input / output interface 24.
[0042] The processor 20, memory 21, communication interface 23 and input / output interface 24 can be connected via communication line 22.
[0043] Processor 20 is used to execute instructions stored in memory 21 to implement the fault analysis method provided in the following embodiments of this application. Processor 20 may be a CPU, a network processor (NP), a digital signal processor (DSP), a microprocessor, a microcontroller (MCU), a programmable logic device (PLD), or any combination thereof. Processor 20 may also be any other device with processing capabilities, such as a circuit, device, or software module; this application embodiment does not limit this. In one example, processor 20 may include one or more CPUs, for example... Figure 2 CPU0 and CPU1 in the example. As an optional implementation, the electronic device may include multiple processors; for example, in addition to processor 20, it may also include processor 25. Figure 2 (The example shown is a dashed line).
[0044] The memory 21 is used to store instructions. For example, the instructions may be computer programs. Optionally, the memory 21 may be a read-only memory (ROM) or other types of static storage devices that can store static information and / or instructions; it may also be a random access memory (RAM) or other types of dynamic storage devices that can store information and / or instructions; it may also be an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), magnetic disk storage media, or other magnetic storage devices, etc. The embodiments of this application do not limit this.
[0045] It should be noted that the memory 21 can exist independently of the processor 20, or it can be integrated with the processor 20. The memory 21 can be located inside or outside the electronic device, and this embodiment does not impose any restrictions on this.
[0046] Communication line 22 is used to transmit information between the components included in the electronic device.
[0047] Communication interface 23 is used for communication with other devices or other communication networks. These other communication networks can be Ethernet, radio access network (RAN), wireless local area networks (WLAN), etc. Communication interface 23 can be a module, circuit, transceiver, or any device capable of enabling communication.
[0048] Input / output interface 24 is used to enable human-computer interaction between the user and the electronic device. For example, it enables action interaction or information exchange between the user and the electronic device.
[0049] For example, the input / output interface 24 can be a mouse, keyboard, display screen, or touch screen. Action interaction or information exchange between the user and the electronic device can be achieved through a mouse, keyboard, display screen, or touch screen.
[0050] It should be noted that, Figure 2 The structures shown do not constitute a limitation on electronic devices, except... Figure 2 In addition to the components shown, electronic devices may include more or fewer components than illustrated, or combinations of certain components, or different component arrangements.
[0051] The following describes the real-time energy consumption anomaly detection method for smart energy provided in the embodiments of this application.
[0052] Figure 3 This is a flowchart illustrating a real-time energy consumption anomaly detection method for smart energy provided in an embodiment of this application. Optionally, this method can be implemented by a person having the above-described... Figure 2 The electronic device with the hardware structure shown performs, such as Figure 3 As shown, the method includes S301 to S304.
[0053] S301. Obtain energy consumption data and energy flow data of each energy-consuming node in the smart energy system, and extract the spatial interaction feature matrix based on the energy consumption data and energy flow data.
[0054] Among them, the spatial interaction feature matrix is used to reflect the connectivity and intensity of energy flow between energy-consuming nodes.
[0055] As one possible implementation, electronic devices can acquire real-time energy consumption data (also known as energy consumption data) and energy flow data from each energy-consuming node in a smart energy system through sensor networks.
[0056] Specifically, in smart energy systems, real-time energy consumption and energy flow data are acquired through sensor networks, and the real-time nature and accuracy of data acquisition must be ensured.
[0057] For example, sensors deployed at substations and user terminals in smart grids monitor parameters such as voltage and current in real time, collecting data once per second to generate datasets containing timestamps and consumption data. Time-series databases such as InfluxDB can efficiently store this type of high-frequency data.
[0058] Preferably, time indexing optimizes query efficiency to ensure low latency in subsequent analysis. When processing energy flow data, spatial vector analysis tools can vectorize the energy flow of each node in the power grid into vector form.
[0059] For example, flow direction intensity represents the power transmitted per unit time, and flow direction angle reflects the geometric distribution of energy flow direction, generating a second dataset containing these features. For the initial time-series dataset, Fourier transform is used to analyze the periodic fluctuations in energy consumption.
[0060] Specifically, the daily electricity consumption data of an industrial park, after being Fourier transformed, reveals a 24-hour periodic fluctuation with an amplitude of 200kW. If the amplitude exceeds a preset threshold of 150kW, a peak electricity consumption algorithm is used to identify the daily peak electricity consumption, such as the peak time point at 2 pm, forming a time series feature set containing fluctuation amplitude, periodic frequency, and peak time.
[0061] Understandably, this feature set can be used to predict peak electricity demand, optimize energy dispatch, and reduce peak load pressure. In processing spatially distributed datasets, vector decomposition algorithms decompose flow direction intensity and angle into orthogonal components.
[0062] For example, if the energy flow intensity at a node is 500kW and the angle is 45 degrees, the energy distribution in the north-south and east-west directions can be clearly represented after decomposition. If the intensity is below the threshold of 100kW, then the missing data is estimated based on the intensity values of neighboring nodes using an interpolation algorithm, such as Kriging interpolation, to generate a complete spatial distribution feature set.
[0063] It should be noted that this method can improve data integrity and ensure the reliability of subsequent analysis. The matrix generation algorithm performs dimensional alignment between the time series feature set and the spatial distribution feature set.
[0064] Preferably, dimensionality reduction is achieved through principal component analysis, retaining the main feature dimensions.
[0065] For example, the fluctuation amplitude and periodic frequency of time series data can be aligned with the flow direction intensity and angle of spatial distribution to generate a unified dimension matrix. Data fusion algorithms, such as weighted average fusion, can integrate all features to generate an initial energy state matrix.
[0066] In one embodiment, the matrix can reflect the overall operating status of a regional power grid at a specific time, such as the energy flow being concentrated in the industrial area during peak periods, with an intensity of 800kW and a fluctuation range of 250kW.
[0067] For example, this matrix can be used to monitor the power grid status in real time, predict potential faults, and improve energy efficiency.
[0068] In one possible implementation, the integrated application of the above-mentioned technical solutions can significantly improve the operating efficiency of smart energy systems.
[0069] For example, peak loads can be predicted using time series feature sets, allowing for advance adjustments to power generation plans; energy allocation can be optimized using spatial distribution feature sets, reducing transmission losses.
[0070] Understandably, these methods collectively support efficient management of the energy system, reduce operating costs, and improve system stability.
[0071] Specifically, in smart energy systems, extracting time-series data from the initial energy state matrix and performing feature analysis is a crucial step in optimizing energy management.
[0072] For example, the initial energy state matrix contains voltage, current, and power data of a power grid in an industrial park, with a time resolution of once per minute. The principle of wavelet transform algorithm for decomposing time series data is to decompose the signal into components of different frequencies, preserving low-frequency trends and high-frequency fluctuations.
[0073] Specifically, the low-frequency trend component reflects the overall trend of daily electricity consumption, such as a gradual increase in electricity consumption on weekdays; the high-frequency fluctuation component captures instantaneous changes, such as power spikes caused by equipment startup.
[0074] In one embodiment, the power data of a substation is processed by wavelet transform to extract the low-frequency component of the daily average power variation, showing that the power is stable at around 500kW from 8:00 AM to 5:00 PM, while the high-frequency component reveals an hourly power fluctuation of approximately 50kW, forming a first feature set. For this first feature set, an autoregressive moving average algorithm is used to evaluate the stationarity of the time window.
[0075] It should be noted that the stationarity index measures whether the data has a stable mean and variance. If the index is below the threshold of 0.8, the data may be missing or abnormal.
[0076] For example, a node experiences a power data loss for a certain period due to a sensor malfunction, causing the stability index to drop to 0.6.
[0077] Preferably, a Lagrange interpolation algorithm is used to estimate the missing data based on the power values at previous and subsequent time points. For example, the missing power values at 10 points are interpolated to 480kW to generate an optimized second feature set. Based on the second feature set, a Fast Fourier Transform is used to analyze the periodic frequency and amplitude.
[0078] Understandably, the algorithm converts time-series data into the frequency domain to identify the main periodic patterns.
[0079] In one possible implementation, electricity consumption data from a user terminal, after being processed by a Fast Fourier Transform, shows a 24-hour periodic amplitude of 150kW and a 12-hour periodic amplitude of 80kW. If the amplitude exceeds a threshold of 100kW, a peak detection algorithm identifies peak times, such as a power peak of 650kW at 3 PM daily, generating a third feature set containing periodic frequency, amplitude, and peak time. A matrix generation algorithm then aligns the dimensions of this third feature set, integrating volatility amplitude, periodic frequency, and peak time.
[0080] For example, aligning the 24-hour periodic amplitude of 150kW, frequency of 1 / 24 hours, peak time of 15:00 with other features generates a time-dimensional feature vector.
[0081] Specifically, this vector can be used to describe the operating characteristics of the power grid during a specific time window, such as the high load condition on a weekday afternoon.
[0082] It should be noted that dimension alignment ensures a consistent feature vector format, which facilitates subsequent analysis.
[0083] In one embodiment, the above method generates high-precision feature vectors by decomposing and optimizing time-series data, which helps to accurately identify electricity consumption patterns.
[0084] For example, eigenvectors can be used to predict peak loads, adjust energy allocation in advance, and reduce grid stress.
[0085] Understandably, these methods collectively improve the reliability of data analysis and provide technical support for the efficient operation of smart energy systems.
[0086] As one possible implementation, electronic devices can construct an energy transfer network between energy-consuming nodes using graph convolution algorithms based on the trend slope and abrupt change time points of energy consumption data, as well as the flow intensity and angle in energy flow data. This generates a weighted adjacency matrix describing the flow connectivity and flow intensity between nodes, thus obtaining a spatial interaction feature matrix.
[0087] Specifically, in smart energy systems, extracting the time trend slope and abrupt change time points from the time dimension feature vector is key to analyzing dynamic changes in energy.
[0088] For example, the time trend slope reflects the rate of change of the power grid in an industrial park over a period of time, such as an increase of 10kW per hour. The time series segmentation method divides the data into windows by hour or day and calculates the slope of each window.
[0089] Preferably, if the slope exceeds a preset threshold of 15kW / hour, the starting point of the window is marked as a sudden change time point, such as a sudden increase in power caused by concentrated equipment startup at 9 am.
[0090] It should be noted that abrupt change times are usually related to production scheduling or failures. These time points, once marked, form a time-dimensional feature set containing slope and abrupt change time information, facilitating subsequent analysis. Based on this time-dimensional feature set, flow intensity and angle are extracted from the spatial data to capture the energy transfer characteristics between subsystems.
[0091] In one possible implementation, the flow direction intensity represents the amount of power transferred from a substation to a load node, such as 100kW; the flow direction angle reflects the direction of transmission, such as a current phase angle of 30 degrees. The vector decomposition method breaks down the flow direction vector into intensity and angle components and analyzes their dynamic changes.
[0092] For example, if the flow intensity at a node increases to 150kW during peak hours and the angle shifts to 45 degrees, a spatial flow direction feature matrix is generated to record the flow direction characteristics of each node. A graph convolution algorithm is then used to construct an energy transfer network between subsystems, combining the spatial flow direction feature matrix and node connectivity.
[0093] Specifically, graph convolution calculates the impact of energy transfer by using the connection weights between nodes.
[0094] For example, a substation has strong connectivity with multiple load nodes, and its graph convolution weights are high, generating a weighted adjacency matrix that reflects the intensity of energy interaction between nodes.
[0095] In one embodiment, a weight value of 0.8 indicates that a node has a significant impact on the power of its neighboring nodes, and the matrix clearly displays the network topology. A spatial interaction feature matrix is generated by combining the weighted adjacency matrix with node energy distribution and subsystem interaction data.
[0096] Understandably, node energy distribution describes the power allocation of each node, such as a node accounting for 20% of the total power; subsystem interaction data records the frequency of energy exchange between nodes.
[0097] For example, if the energy transfer efficiency between nodes is higher than 80%, the interaction is considered stable, and the final spatial interaction characteristic matrix is determined. This matrix integrates flow direction, weights, and interaction information, and fully describes the spatial dynamic characteristics of the power grid.
[0098] For example, during peak weekday hours, an industrial park identified a sudden change in load at 10:00 AM using the aforementioned method, where the flow intensity increased to 200kW. Graph convolution weights showed that the core substation had a significant impact on the load, and the spatial interaction feature matrix further revealed an efficient energy distribution pattern. These features provide data support for optimized scheduling.
[0099] S302. Based on the spatial interaction feature matrix, determine the abnormal candidate nodes in the smart energy system and obtain the abnormal candidate node set.
[0100] Among them, the energy flow connectivity of the abnormal candidate node is less than the first preset threshold, and the energy flow intensity is less than the second preset threshold.
[0101] As one possible implementation, the electronic device can obtain the flow direction intensity and energy inflow / outflow deviation of each node from the spatial interaction feature matrix, calculate the deviation vector using vector decomposition, and mark the node as a node to be optimized if the magnitude of the deviation vector is greater than a fourth preset threshold, thus obtaining a set of nodes to be optimized. Further, for the set of nodes to be optimized, the gradient magnitude and flow direction angle of each node are calculated using gradient calculation methods, and node feature vectors containing gradient magnitude and flow direction angle are obtained through vector synthesis, resulting in a set of node feature vectors. Based on the set of node feature vectors, the electronic device can use graph analysis methods to calculate the uniformity of gradient distribution and flow direction connectivity between nodes, generating an energy balance vector containing distribution uniformity and connectivity features, thus obtaining a set of energy balance vectors. If the connectivity feature of a vector in the energy balance vector set is less than a fifth preset threshold, an anomaly detection algorithm is used to filter out abnormal candidate nodes, resulting in a set of abnormal candidate nodes.
[0102] Specifically, in smart energy systems, extracting the flow intensity and energy inflow / outflow deviation of nodes from the spatial interaction feature matrix is crucial for analyzing the dynamic balance of the power grid. The spatial interaction feature matrix records the energy transfer characteristics between nodes. For example, if the flow intensity of a node is 150kW, the energy inflow / outflow deviation reflects the difference between the energy received and output by that node.
[0103] For example, if a substation receives 200kW of energy and receives 180kW of energy, the deviation is 20kW. The vector decomposition method decomposes the deviation into magnitude and direction, where the magnitude represents the magnitude of the deviation and the direction reflects the energy flow trend.
[0104] Specifically, nodes whose modulus exceeds a preset threshold, such as 30kW, are marked as nodes to be optimized, and a set of nodes to be optimized is generated.
[0105] For example, in the power grid of an industrial park, the core substation, due to load fluctuations during peak hours, has a deviation magnitude of 40kW and is marked as a node to be optimized. This method helps identify nodes with uneven energy distribution. For the set of nodes to be optimized, a gradient calculation method is used to calculate the gradient magnitude and flow direction angle of each node. The gradient magnitude reflects the drasticness of energy changes at the node, and the flow direction angle indicates the direction of energy transfer.
[0106] In one possible implementation, a node has a gradient magnitude of 25 kW / h and a flow direction angle of 60 degrees. A node feature vector is generated through vector synthesis, which contains magnitude and angle information, forming a set of node feature vectors.
[0107] Understandably, the set of node feature vectors provides a structured data foundation for subsequent analysis.
[0108] For example, a sudden increase in gradient magnitude at a load node due to equipment startup indicates a significant impact on grid stability. Based on the node feature vector set, graph analysis methods are used to calculate the uniformity of gradient distribution and flow connectivity among nodes. Gradient distribution uniformity measures the balance of energy changes among nodes, while flow connectivity reflects the tightness of energy transfer between nodes.
[0109] Preferably, if the gradient distribution in a certain region is relatively uniform, it indicates that the energy distribution is stable.
[0110] In one embodiment, the flow connectivity between the core substation and surrounding load nodes reaches 0.9, indicating efficient energy transfer. This generates an energy balance vector, incorporating both uniform distribution and connectivity characteristics, forming an energy balance vector set. These vectors provide a basis for assessing the overall stability of the power grid. If the connectivity characteristic of a vector in the energy balance vector set is lower than a preset threshold, such as 0.7, an anomaly detection algorithm is used to screen for candidate nodes with abnormal connectivity. The anomaly detection algorithm, based on statistical analysis or machine learning, identifies nodes with abnormal connectivity.
[0111] It should be noted that low connectivity may be caused by equipment failure or aging lines.
[0112] For example, a remote load node with a connectivity of only 0.5 due to aging lines is marked as an abnormal candidate node, generating an abnormal candidate node set.
[0113] Specifically, the set of abnormal candidate nodes provides a precise target for subsequent maintenance.
[0114] For example, after detecting an anomaly at a node, the condition of its connecting lines can be checked first. This method improves the efficiency of power grid anomaly troubleshooting.
[0115] In one embodiment, during peak weekday hours, an industrial park identifies substations with excessive deviation magnitudes. After calculating their gradient magnitude and flow direction angle, it is found that their connectivity is below a threshold. Anomaly detection further confirms the node as a candidate for anomaly, prompting maintenance personnel to inspect the equipment. These steps form a closed-loop analysis, ensuring the dynamic balance and operational efficiency of the power grid.
[0116] S303. Extract the energy anomaly propagation feature vector corresponding to the abnormal candidate node set.
[0117] Among them, the energy anomaly propagation feature vector is used to reflect the energy flow intensity and energy gradient distribution uniformity of each anomaly candidate node.
[0118] As one possible implementation, for the set of anomalous candidate nodes, the electronic device can employ a gradient field modeling method. This method combines the volatility amplitude and periodic amplitude of energy consumption data with the gradient amplitude and flow direction angle of energy flow data to calculate the local extrema and flow direction bifurcation points of each node in the temporal and spatial dimensions, generating a gradient vector field. Furthermore, the electronic device can employ a gradient mutation detection algorithm to detect the existence of gradient mutation points in the gradient vector field. If the rate of change of gradient amplitude in any region of the gradient vector field exceeds a sixth preset threshold, it is marked as an anomalous flow direction point, resulting in a set of anomalous point locations. Based on the gradient mutation points in the set of anomalous point locations, and combined with an energy path tracing algorithm, the electronic device analyzes the flow direction bifurcation points and flow direction intensity between the anomalous points and adjacent nodes, calculates the propagation direction and gradient distribution uniformity of the anomalous flow direction, and obtains an energy anomaly propagation feature vector.
[0119] Specifically, in smart energy systems, the analysis of time-dimensional eigenvectors is an important means of studying the dynamic characteristics of the power grid. Time fluctuations reflect the changing trend of node energy over time.
[0120] For example, power data from a substation is collected, such as recording the power value every minute, to form a time series. Fourier transform is then used to decompose this time series into periodic components of different frequencies, resulting in a periodic amplitude sequence.
[0121] For example, the periodic amplitude sequence of a substation shows that the amplitude of the 24-hour period is 50kW, indicating that the daily load fluctuates significantly. If the amplitude exceeds a preset threshold, such as 30kW, local extreme points in the time series are extracted to generate a set of local extreme points.
[0122] It should be noted that these extreme points may correspond to peak or trough periods, such as the power surge in an industrial park when equipment is started up on a weekday morning. Based on the set of local extreme points and the spatial interaction feature matrix, the gradient operator performs a convolution operation on the matrix to generate a gradient magnitude distribution. The spatial interaction feature matrix records the energy transfer relationships between nodes, such as the power difference between a node and its neighbors. The gradient magnitude distribution reflects the spatial characteristics of energy changes.
[0123] In one possible implementation, the gradient amplitude of a core substation is 20 kW / h, indicating that its energy changes drastically. If the amplitude exceeds a threshold such as 15 kW / h, it is marked as a candidate bifurcation point.
[0124] Specifically, bifurcation points may be caused by sudden load changes or line switching, such as an abnormal energy flow at a node due to equipment startup. By using candidate bifurcation points and flow angles, a vector field interpolation method is used to calculate the change in flow angle and construct a vector field structure. The flow angle represents the direction of energy transfer; for example, if the flow angle at a node suddenly changes from 45 degrees to 90 degrees, the rate of change is 50%. If the rate of change exceeds a threshold such as 30%, the bifurcation point location is confirmed.
[0125] Preferably, the location of the bifurcation point can indicate a potential discontinuity in the energy flow of the power grid.
[0126] For example, a substation's flow direction angle changes rapidly due to load fluctuations, which is identified as a bifurcation point, providing a basis for subsequent optimization. Flow direction characteristics are extracted from the vector field structure, and a streamline tracing algorithm plots the streamline distribution, forming a dynamic graph. Flow direction characteristics describe the energy transfer path between nodes.
[0127] In one embodiment, flowline tracing shows dense flowlines in a core substation of an industrial park, indicating concentrated energy output. The dynamic graph visually presents the energy flow path, such as flowlines diverging from the substation to load nodes.
[0128] Understandably, dynamic graphs provide a visual tool for analyzing the power grid's operating status and help identify bottleneck nodes.
[0129] For example, areas with sparse flow lines may experience low transmission efficiency, prompting maintenance personnel to optimize line layout. Through the above methods, features from both temporal and spatial dimensions are combined to comprehensively characterize the dynamic properties of the power grid, providing data support for operational optimization.
[0130] Specifically, in smart energy systems, gradient vector field analysis of dynamic energy flow maps is an important method for studying the dynamic characteristics of power grids. The amplitude distribution of the gradient vector field reflects the intensity of energy changes at nodes.
[0131] For example, power data from a substation is collected and recorded every 5 minutes to form a time series, and the gradient magnitude of each node is calculated. The rate of change of the magnitude is calculated using a differential operator, which works by dividing the power difference between adjacent time points by the time interval to obtain the rate of change.
[0132] In one possible implementation, the amplitude change rate of a certain substation is 25 kW / min, the preset threshold is 15 kW / min, and anything exceeding the threshold is marked as a candidate mutation point.
[0133] It should be noted that candidate abrupt change points may correspond to moments of sudden load changes or equipment switching in the power grid, such as the rapid power surge caused by the startup of large equipment in an industrial park. For the set of candidate abrupt change points, a vector field interpolation method is used to calculate the rate of change of the flow direction angle. The flow direction angle represents the direction of energy transfer, and the interpolation method estimates the angle change using vector field data from neighboring nodes.
[0134] Specifically, if the flow angle of a candidate mutation point changes from 30 degrees to 80 degrees, the rate of change is 55%, and the preset threshold is 30%, then it is confirmed as a mutation point if it exceeds the threshold.
[0135] In one embodiment, abrupt changes may be caused by line switching or faults, such as a short circuit at a node leading to abnormal energy flow. The set of abrupt changes provides key location information for subsequent analysis. The gradient vector field is meshed using a region partitioning algorithm, dividing the vector field into regular grids, with each grid assigned a unique identifier.
[0136] Preferably, a mutation point is located in the region with grid ID G-23, and a region label set is generated.
[0137] Understandably, gridding helps locate the spatial distribution of anomalous points, such as identifying high-load areas within an industrial park. The region label set provides the foundation for subsequent clustering. Coordinate information of anomalous points is extracted from the region label set, and the K-means clustering algorithm is used to cluster the anomalous points, generating a set of outlier locations.
[0138] For example, clustering results show that three mutation points in an industrial park are concentrated in the same area, with coordinates (100,200), (110,210) and (105,205).
[0139] In one embodiment, these anomalies may be located in areas of concentrated high-voltage line loads near power plants. Cluster analysis helps identify anomalous clusters of energy flow in the power grid, providing a basis for optimized scheduling.
[0140] Understandably, the set of anomaly locations directly reflects potential operational risks in the power grid, such as areas prone to line overload or equipment failure, providing data support for operation and maintenance decisions.
[0141] Specifically, in smart energy systems, processing the set of anomaly locations is a crucial step in optimizing power grid operation.
[0142] For example, coordinate information is extracted from the set of anomaly locations. Suppose anomalies are detected near a substation with coordinates (150, 300) and (160, 310). A grid partitioning algorithm is used to divide the gradient vector field into regular grids, each 50×50 meters in size, generating a grid set. Each grid is assigned a unique identifier, such as G-45 or G-46. The anomaly (150, 300) is mapped to grid G-45, generating a mapping set between anomalies and area identifiers.
[0143] Understandably, this mapping facilitates subsequent analysis of the spatial distribution of outliers.
[0144] Specifically, based on the mapping set, the energy path tracing algorithm is used to calculate the energy flow trajectory of the subsystem where the anomaly point is located. Assuming that the anomaly point (150, 300) is located in a subsystem of an industrial park, the tracing algorithm analyzes the power data and draws the energy flow trajectory starting from this point. It finds that the trajectory extends to the boundary of the adjacent subsystem, forming a flow bifurcation point, such as coordinates (180, 320).
[0145] It should be noted that the bifurcation point reflects the redistribution of energy flow and may be caused by load changes.
[0146] Preferably, if the flow intensity at the bifurcation point is 30kW, exceeding the preset threshold of 20kW, it is identified as a critical bifurcation point.
[0147] In one embodiment, a vector field interpolation method is used to calculate the propagation direction and gradient magnitude distribution for key bifurcation points. Assuming the flow angle at the bifurcation point (180, 320) changes from 45 degrees to 60 degrees, the interpolation method estimates the propagation direction using neighboring node data, generating a set of propagation directions. Simultaneously, the gradient magnitude distribution shows that the magnitude at this point increases from 20 kW / m to 35 kW / m, forming a set of magnitude distributions.
[0148] Understandably, this reflects a localized concentration of energy flow, which may indicate abnormal equipment operation.
[0149] For example, the K-means clustering algorithm can be used to extract features from the propagation direction and amplitude distribution sets, generating a set of anomalous propagation feature vectors. Suppose that cluster analysis reveals that the propagation directions at multiple bifurcation points in a subsystem are concentrated between 60 and 70 degrees, and the gradient amplitude uniformity is high, indicating that the energy flow anomalies are consistent.
[0150] Preferably, this set of feature vectors can be used to identify potential high-risk areas in the power grid, providing a basis for operation and maintenance decisions.
[0151] In one possible implementation, the above method forms a complete analysis chain from anomaly localization to feature extraction through multi-dimensional analysis.
[0152] It should be noted that the analysis of bifurcation points and propagation characteristics helps to detect potential problems in power grid operation in advance, such as line overload or equipment failure, thereby improving system stability.
[0153] S304. Using a pattern matching algorithm, the similarity between the energy anomaly propagation feature vector and the corresponding energy normal propagation feature vector in the normal energy consumption pattern library is compared with that in the pre-established normal energy consumption pattern library. If the similarity is lower than the third preset threshold, the abnormal candidate node is determined to be a real anomaly, and the final anomaly detection result is generated.
[0154] Specifically, in smart energy systems, extracting flow intensity values and gradient distribution data from the set of anomaly propagation feature vectors is the core step in analyzing the propagation patterns of anomalies in the power grid.
[0155] For example, the flow direction intensity value reflects the power of the energy flow at the anomaly point, while the gradient distribution data describes the rate of change of the energy flow in space. Suppose a substation detects an anomaly point with a flow direction intensity value of 25 kW, and the gradient distribution in the adjacent area shows an amplitude gradually changing from 15 kW / m to 30 kW / m. A vector decomposition algorithm is used to process the eigenvectors, aiming to break down the complex eigenvectors into independent components for easier subsequent analysis.
[0156] Specifically, the vector decomposition algorithm separates the flow direction intensity and gradient distribution, generating a set of flow direction intensities such as {20kW, 25kW, 30kW} and a set of gradient distributions such as {15kW / m, 22kW / m, 30kW / m}. This decomposition method is helpful in capturing the local characteristics of anomaly propagation.
[0157] Preferably, based on the above set, the Fast Fourier Transform (FFT) algorithm is used to analyze the periodic frequency of anomaly propagation. The FFT identifies periodic patterns of energy flow changes by converting the time-domain signal into the frequency domain.
[0158] For example, after analyzing the set of flow intensity, it was found that there is a power fluctuation every 10 seconds near the anomaly point, with a corresponding periodic frequency of 0.1Hz, generating a set of periodic frequencies {0.1Hz, 0.15Hz}.
[0159] It should be noted that if the similarity between this frequency set and typical frequencies in the normal pattern library, such as {0.2Hz, 0.25Hz}, is less than the preset threshold of 0.8, it indicates that the abnormal propagation has atypical periodicity and may be caused by equipment failure or sudden load changes.
[0160] In one embodiment, if the periodic frequency is abnormal, the feature vector is further processed using a linear regression algorithm to calculate the set of trend slopes for anomaly propagation. The linear regression algorithm estimates the long-term trend of anomaly propagation by fitting the time-series data of the feature vectors.
[0161] For example, analyzing the change in flow intensity over time reveals that the intensity value increases from 20kW to 30kW in 1 hour, with a slope of approximately 0.028kW / min, generating a trend slope set {0.028kW / min, 0.032kW / min}.
[0162] Understandably, this trend analysis helps determine whether the anomaly continues to worsen.
[0163] For example, a pattern matching algorithm compares a set of trend slopes with slope data in a normal pattern library, such as {0.01kW / min, 0.015kW / min}. If the similarity is below a threshold of 0.7, the outlier is confirmed as a true anomaly. The pattern matching algorithm quantifies the difference between the anomaly and the normal pattern by calculating the Euclidean distance or cosine similarity of the slope sets.
[0164] Specifically, assuming that the slope set of anomalies in a subsystem of an industrial park differs significantly from the normal pattern, a set of detection results is generated, and the anomaly is marked as a "true anomaly" with an identifier such as A-001. This marking facilitates subsequent maintenance personnel in quickly locating the problem area.
[0165] In one possible implementation, the above analysis proceeds from feature vector decomposition to anomaly detection, forming a complete analysis chain.
[0166] Preferably, the combined analysis of periodic frequency and trend slope can verify the authenticity of anomalies from multiple dimensions.
[0167] For example, if an anomaly point exhibits both atypical frequency and abnormal trend slope, it indicates that it may originate from line overload rather than temporary interference.
[0168] It should be noted that this multi-faceted analysis improves the accuracy of anomaly detection and provides a reliable basis for optimizing power grid operation.
[0169] The technical solution provided in this application offers at least the following advantages: by combining energy consumption data in the time dimension with energy flow data in the spatial dimension, a spatial interaction feature matrix reflecting the connectivity and intensity of energy flow between energy-consuming nodes is extracted. By constructing gradient vector fields in both time and space dimensions, and combining this with energy balance analysis of AC nodes, key features are extracted and the energy transfer process between subsystems is tracked to accurately identify gradient abrupt changes or abnormal flow points, thereby finding abnormal energy-consuming nodes. Compared to traditional solutions that rely heavily on single-dimensional statistical analysis or rule thresholds, making them difficult to adapt to complex scenarios of dynamic interaction between multiple subsystems, this application provides comprehensive monitoring of smart energy systems in both time and space dimensions, enabling timely detection of abnormal flow directions and improving system operating efficiency and security.
[0170] The foregoing primarily describes the solutions provided by the embodiments of this application from a methodological perspective. To achieve the aforementioned functions, it includes corresponding hardware structures and / or software modules for executing each function. Those skilled in the art should readily recognize that, in conjunction with the units and algorithm steps of the various examples described in the embodiments disclosed herein, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0171] In an exemplary embodiment, this application also provides an energy consumption anomaly detection device. Figure 4 This is a schematic diagram illustrating the composition of the energy consumption anomaly detection device provided in an embodiment of this application. Figure 4 As shown, the energy consumption anomaly detection device includes a processing unit 401 and a determination unit 402.
[0172] Processing unit 401 is used to acquire energy consumption data and energy flow data of each energy-consuming node in the smart energy system, and extract a spatial interaction feature matrix based on the energy consumption data and energy flow data; the spatial interaction feature matrix is used to reflect the energy flow connectivity and energy flow intensity between each energy-consuming node; determining unit 402 is used to determine abnormal candidate nodes in the smart energy system based on the spatial interaction feature matrix, and obtain an abnormal candidate node set; the energy flow connectivity of the abnormal candidate nodes is less than a first preset threshold, and the energy flow intensity is less than a second preset threshold; processing unit 401 is also used to extract the energy anomaly propagation feature vector corresponding to the abnormal candidate node set; the energy anomaly propagation feature vector is used to reflect the energy flow intensity and energy gradient distribution uniformity of each abnormal candidate node; determining unit 402 is also used to use a pattern matching algorithm to compare the similarity between the energy anomaly propagation feature vector and the energy normal propagation feature vector corresponding to the normal energy consumption pattern library through a pre-established normal energy consumption pattern library; if the similarity is lower than a third preset threshold, the abnormal candidate node is determined to be a real anomaly, and the final anomaly detection result is generated.
[0173] In one possible implementation, the processing unit 401 is specifically used to: construct an energy transfer network between energy-consuming nodes using a graph convolution algorithm based on the trend slope and abrupt change time points of energy consumption data, as well as the flow direction intensity and flow direction angle in energy flow data, generate a weighted adjacency matrix describing the flow direction connectivity and flow direction intensity between nodes, and obtain a spatial interaction feature matrix.
[0174] In one possible implementation, the determining unit 402 is specifically used for: obtaining the flow direction intensity and energy inflow / outflow deviation of each node from the spatial interaction feature matrix; calculating the deviation vector using a vector decomposition method; if the magnitude of the deviation vector is greater than a fourth preset threshold, it is marked as a node to be optimized, thus obtaining a set of nodes to be optimized; for the set of nodes to be optimized, calculating the gradient magnitude and flow direction angle of each node using a gradient calculation method; obtaining a set of node feature vectors by vector synthesis, containing the gradient magnitude and flow direction angle; calculating the uniformity of gradient distribution and flow direction connectivity between nodes using a graph analysis method based on the set of node feature vectors; generating an energy balance vector containing the uniformity of distribution and connectivity features, thus obtaining a set of energy balance vectors; if the connectivity feature of a vector in the energy balance vector set is less than a fifth preset threshold, filtering abnormal candidate nodes using an anomaly detection algorithm, thus obtaining a set of abnormal candidate nodes.
[0175] In one possible implementation, the processing unit 401 is specifically used to: for the set of abnormal candidate nodes, adopt a gradient field modeling method, combine the volatility amplitude and periodic amplitude of energy consumption data, and the gradient amplitude and flow direction angle of energy flow data, calculate the local extreme values of the gradient and the flow direction bifurcation points of each node in the time and space dimensions, and generate a gradient vector field; adopt a gradient mutation detection algorithm to detect whether there are gradient mutation points in the gradient vector field. If the gradient amplitude change rate of any region in the gradient vector field is greater than a sixth preset threshold, it is marked as an abnormal flow direction point, and an abnormal point location set is obtained; based on the gradient mutation points in the abnormal point location set, combined with an energy path tracing algorithm, analyze the flow direction bifurcation points and flow direction intensity between the abnormal points and adjacent nodes, calculate the propagation direction and gradient distribution uniformity of the abnormal flow direction, and obtain the energy anomaly propagation feature vector.
[0176] It should be noted that, Figure 4 The module division shown is illustrative and represents only one logical functional division; in actual implementation, other division methods are possible. For example, two or more functions can be integrated into a single processing module. These integrated modules can be implemented in hardware or as software functional units.
[0177] In an exemplary embodiment, this application also provides a computer-readable storage medium including software instructions that, when run on an electronic device, cause the electronic device to perform any of the methods provided in the above embodiments.
[0178] In an exemplary embodiment, this application also provides a computer program product containing computer execution instructions, which, when run on an electronic device, causes the electronic device to perform any of the methods provided in the above embodiments.
[0179] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented using software programs, implementation can be, in whole or in part, in the form of a computer program product. This computer program product includes one or more computer-executable instructions. When these computer-executable instructions are loaded and executed on a computer, all or part of the flow or function according to the embodiments of this application is generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer-executable instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, computer-executable instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device containing one or more servers, data centers, etc., that can be integrated with the medium. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a solid-state disk (SSD), etc.
[0180] Although this application has been described herein in conjunction with various embodiments, those skilled in the art, by reviewing the accompanying drawings, disclosure, and appended claims, will understand and implement other variations of the disclosed embodiments in carrying out the claimed application. In the claims, the word "comprising" does not exclude other components or steps, and "a" or "an" does not exclude multiple instances. A single processor or other unit can implement several functions listed in the claims. While different dependent claims may recite certain measures, this does not mean that these measures cannot be combined to produce good results.
[0181] Although this application has been described in conjunction with specific features and embodiments, it is obvious that various modifications and combinations can be made thereto without departing from the spirit and scope of this application. Accordingly, this specification and drawings are merely exemplary illustrations of this application as defined by the appended claims, and are considered to cover any and all modifications, variations, combinations, or equivalents within the scope of this application. Clearly, those skilled in the art can make various alterations and modifications to this application without departing from the spirit and scope of this application. Thus, if such modifications and modifications of this application fall within the scope of the claims of this application and their equivalents, this application is also intended to include such modifications and modifications.
[0182] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for real-time detection of energy consumption anomalies in smart energy, characterized in that, Applied to a smart energy system, the smart energy system comprising multiple energy-consuming nodes, the method includes: The energy consumption data and energy flow data of each energy-consuming node in the smart energy system are acquired, and a spatial interaction feature matrix is extracted based on the energy consumption data and the energy flow data; the spatial interaction feature matrix is used to reflect the connectivity and intensity of energy flow between each energy-consuming node. Based on the spatial interaction feature matrix, abnormal candidate nodes in the smart energy system are determined to obtain an abnormal candidate node set; the energy flow connectivity of the abnormal candidate nodes is less than a first preset threshold, and the energy flow intensity is less than a second preset threshold. Extract the energy anomaly propagation feature vector corresponding to the set of anomalous candidate nodes; the energy anomaly propagation feature vector is used to reflect the energy flow intensity and energy gradient distribution uniformity of each anomalous candidate node; A pattern matching algorithm is used to compare the similarity between the energy anomaly propagation feature vector and the corresponding energy normal propagation feature vector in the normal energy consumption pattern library. If the similarity is lower than a third preset threshold, the abnormal candidate node is determined to be a real anomaly, and the final anomaly detection result is generated.
2. The method according to claim 1, characterized in that, The step of extracting a spatial interaction feature matrix based on the energy consumption data and the energy flow data includes: Based on the trend slope and abrupt change time points of the energy consumption data, as well as the flow intensity and flow angle in the energy flow data, a graph convolution algorithm is used to construct an energy transfer network between energy-consuming nodes, generating a weighted adjacency matrix describing the flow connectivity and flow intensity between nodes, thus obtaining the spatial interaction feature matrix.
3. The method according to claim 1, characterized in that, The step of determining abnormal candidate nodes in the smart energy system based on the spatial interaction feature matrix includes: The flow direction intensity and energy inflow / outflow deviation of each node are obtained from the spatial interaction feature matrix. The deviation vector is calculated using the vector decomposition method. If the magnitude of the deviation vector is greater than the fourth preset threshold, it is marked as a node to be optimized, thus obtaining a set of nodes to be optimized. For the set of nodes to be optimized, the gradient magnitude and flow direction angle of each node are calculated using a gradient calculation method. The node feature vector containing the gradient magnitude and flow direction angle is obtained through vector synthesis, resulting in a set of node feature vectors. Based on the set of node feature vectors, graph analysis is used to calculate the uniformity of gradient distribution and flow connectivity between nodes, generating an energy balance vector that includes the uniformity of distribution and connectivity features, thus obtaining a set of energy balance vectors. If the connectivity feature of a vector in the energy balance vector set is less than a fifth preset threshold, then anomaly candidate nodes are screened through an anomaly detection algorithm to obtain the anomaly candidate node set.
4. The method according to claim 1, characterized in that, The step of extracting the energy anomaly propagation feature vector corresponding to the set of anomalous candidate nodes includes: For the set of abnormal candidate nodes, a gradient field modeling method is adopted. Combining the volatility amplitude and period amplitude of the energy consumption data, and the gradient amplitude and flow direction angle of the energy flow data, the local extreme values of the gradient and the flow direction bifurcation points of each node in the time and space dimensions are calculated to generate a gradient vector field. A gradient mutation detection algorithm is used to detect whether there are gradient mutation points in the gradient vector field. If the gradient magnitude change rate of any region in the gradient vector field is greater than a sixth preset threshold, it is marked as an abnormal flow point, and a set of abnormal point locations is obtained. Based on the gradient abrupt change points in the set of anomaly locations, and combined with the energy path tracing algorithm, the flow direction bifurcation points and flow direction intensities between the anomaly points and adjacent nodes are analyzed, the propagation direction and gradient distribution uniformity of the abnormal flow direction are calculated, and the energy anomaly propagation feature vector is obtained.
5. A real-time energy consumption anomaly detection system for smart energy, characterized in that, The system includes an energy consumption anomaly detection device, which includes a processing unit and a determination unit. The processing unit is used to acquire energy consumption data and energy flow data of each energy-consuming node in the smart energy system, and extract a spatial interaction feature matrix based on the energy consumption data and the energy flow data; the spatial interaction feature matrix is used to reflect the connectivity and intensity of energy flow between each energy-consuming node. The determining unit is used to determine abnormal candidate nodes in the smart energy system based on the spatial interaction feature matrix, and obtain an abnormal candidate node set; the energy flow connectivity of the abnormal candidate nodes is less than a first preset threshold, and the energy flow intensity is less than a second preset threshold. The processing unit is further configured to extract the energy anomaly propagation feature vector corresponding to the set of abnormal candidate nodes; the energy anomaly propagation feature vector is used to reflect the energy flow intensity and energy gradient distribution uniformity of each abnormal candidate node. The determining unit is further configured to use a pattern matching algorithm to compare the similarity between the energy anomaly propagation feature vector and the energy normal propagation feature vector corresponding to the normal energy consumption pattern library through a pre-established normal energy consumption pattern library. If the similarity is lower than a third preset threshold, the abnormal candidate node is determined to be a real anomaly, and the final anomaly detection result is generated.
6. The system according to claim 5, characterized in that, The processing unit is specifically used for: Based on the trend slope and abrupt change time points of the energy consumption data, as well as the flow intensity and flow angle in the energy flow data, a graph convolution algorithm is used to construct an energy transfer network between energy-consuming nodes, generating a weighted adjacency matrix describing the flow connectivity and flow intensity between nodes, thus obtaining the spatial interaction feature matrix.
7. The system according to claim 5, characterized in that, The determining unit is specifically used for: The flow direction intensity and energy inflow / outflow deviation of each node are obtained from the spatial interaction feature matrix. The deviation vector is calculated using the vector decomposition method. If the magnitude of the deviation vector is greater than the fourth preset threshold, it is marked as a node to be optimized, thus obtaining a set of nodes to be optimized. For the set of nodes to be optimized, the gradient magnitude and flow direction angle of each node are calculated using a gradient calculation method. The node feature vector containing the gradient magnitude and flow direction angle is obtained through vector synthesis, resulting in a set of node feature vectors. Based on the set of node feature vectors, graph analysis is used to calculate the uniformity of gradient distribution and flow connectivity between nodes, generating an energy balance vector that includes the uniformity of distribution and connectivity features, thus obtaining a set of energy balance vectors. If the connectivity feature of a vector in the energy balance vector set is less than a fifth preset threshold, then anomaly candidate nodes are screened through an anomaly detection algorithm to obtain the anomaly candidate node set.
8. The system according to claim 5, characterized in that, The processing unit is specifically used for: For the set of abnormal candidate nodes, a gradient field modeling method is adopted. Combining the volatility amplitude and period amplitude of the energy consumption data, and the gradient amplitude and flow direction angle of the energy flow data, the local extreme values of the gradient and the flow direction bifurcation points of each node in the time and space dimensions are calculated to generate a gradient vector field. A gradient mutation detection algorithm is used to detect whether there are gradient mutation points in the gradient vector field. If the gradient magnitude change rate of any region in the gradient vector field is greater than a sixth preset threshold, it is marked as an abnormal flow point, and a set of abnormal point locations is obtained. Based on the gradient abrupt change points in the set of anomaly locations, and combined with the energy path tracing algorithm, the flow direction bifurcation points and flow direction intensities between the anomaly points and adjacent nodes are analyzed, the propagation direction and gradient distribution uniformity of the abnormal flow direction are calculated, and the energy anomaly propagation feature vector is obtained.
9. An electronic device, characterized in that, include: Processor and memory; The memory stores instructions that the processor can execute; When the processor is configured to execute the instructions, the electronic device performs the method as described in any one of claims 1-4.
10. A computer-readable storage medium, characterized in that, The readable storage medium includes: software instructions; When the software instructions are executed in an electronic device, the electronic device causes the electronic device to perform the method as described in any one of claims 1-4.
Citation Information
Patent Citations
Energy consumption anomaly detection method based on average neighbor distance anomaly factor
CN110378371A
Agricultural condition acquisition task allocation method and system, medium and equipment
CN111417084A