Method and system for extracting advanced semantic information from hierarchical power utilization sequence
By using a hierarchical encoder and a timing encoder in the processing of electrically used sequence data, combining mask reconstruction and dual-view comparison learning tasks, the problem of lack of effective utilization of hierarchical relationships and exogenous variables in the prior art is solved, and the extraction of high-level semantic information and the completion of a variety of downstream tasks are realized.
Patent Information
- Application Number
- CN202411641074.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2025-03-04
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art lacks effective methods to utilize hierarchical relationships and exogenous variables when processing power-use sequence data, resulting in poor performance in downstream tasks.
The hierarchical encoder and timing encoder are used to model the dependencies between different levels and timing dependencies at different times, and train them through mask reconstruction tasks and dual-view comparison learning tasks to extract high-level semantic information in the power consumption sequence.
The machine understands the power sequence, which can be used to complete a variety of downstream tasks related to the power system, and improves the capabilities and generalization of the model in the power system scenario.
Smart Images

Figure CN119557698A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of time series data processing, and in particular to a method and system for extracting high-level semantic information from a hierarchical electricity consumption sequence. Background Art
[0002] With the development of smart grids in power systems, the volume of electricity consumption sequence data has increased rapidly. This rich data lays the foundation for a variety of applications in power systems, including demand-side management, grid stability, and consumer behavior analysis. At the same time, these applications have spawned a variety of tasks. These tasks include load forecasting, clock anomaly detection, power theft detection, and detection of elderly people living alone.
[0003] As society develops towards modernization, electricity consumption increases rapidly, bringing opportunities and challenges to the development and application of smart grids. On the one hand, the economic benefits brought by the large amount of electricity use are considerable. On the other hand, unreasonable power planning may have an adverse impact on the environment. Therefore, given the large amount of data and the variety of tasks, it is urgent to study effective methods for modeling electricity sequence data to improve economic benefits while following the low-carbon principle.
[0004] Recently, there have been many studies on pre-training methods for electricity usage sequence data. These methods adopt the "pre-training and then fine-tuning" paradigm to deal with the dilemma of limited labeled data, and the pre-trained models can easily adapt to new tasks, such as PatchTST, TS2Vec, CoST, etc. However, these pre-training methods only utilize small-scale data and a small number of users (nodes), and do not consider the hierarchical relationship of electricity usage sequences, resulting in poor performance on downstream tasks.
[0005] At the same time, many researchers have begun to apply large language models (LLMs) to electricity consumption sequence modeling, either by using pre-trained LLMs to encode electricity consumption sequences or integrating additional descriptions related to electricity consumption sequences. However, these methods are limited in their capabilities in power system scenarios due to the lack of sufficient power system pre-training data and domain-specific knowledge. In addition, these methods are not customized for power system scenarios, thus ignoring the unique characteristics of electricity consumption sequence data. Therefore, in the existing power system literature, the study of how to extract semantics from electricity consumption sequence data still leaves a clear research gap. Summary of the invention
[0006] In order to solve the problem of lack of data for annotating power consumption sequences and diverse downstream tasks, the present invention proposes a method and system for extracting high-level semantic information from hierarchical power consumption sequences. A hierarchical encoder and a temporal encoder are used to model the dependencies between different levels and the temporal dependencies at different times, respectively. A mask reconstruction task combining random mask and causal mask, as well as a dual-view contrast learning task are designed to achieve machine understanding of power consumption sequences, which can be used to complete a variety of downstream tasks related to the power system.
[0007] The present invention adopts the following technical solution:
[0008] In a first aspect, the present invention provides a method for extracting high-level semantic information from a hierarchical power usage sequence, comprising:
[0009] The electricity consumption sequence windows of cities, regions and users are regarded as node features, and the intermediate node features are generated according to the user node features, and a hierarchical graph consisting of city nodes, regional nodes, user nodes and intermediate nodes is constructed;
[0010] The temporal encoder enhanced by exogenous variables extracts the temporal semantic representation of the power consumption sequence of nodes in the hierarchical graph;
[0011] Hierarchical enhancement of temporal semantic representation through hierarchical encoders;
[0012] The hierarchically enhanced temporal semantic representation is used for mask reconstruction tasks and dual-view contrast learning tasks, and the temporal encoder and hierarchical encoder enhanced by the exogenous variables are trained;
[0013] The trained exogenous variable enhanced temporal encoder and hierarchical encoder are used to extract the hierarchical enhanced temporal semantic representation in the electricity consumption sequence as high-level semantic information.
[0014] Furthermore, in the hierarchical graph, there are bidirectional edges between regional nodes and city nodes, bidirectional edges between intermediate nodes and regional nodes, and unidirectional edges between user nodes and regional nodes, and the unidirectional edges are directed from regional nodes to user nodes.
[0015] Furthermore, the said time series encoder enhanced by exogenous variables extracts the time series semantic representation of the power consumption sequence of the nodes in the hierarchical graph, including:
[0016] The power sequence window The sliding window is divided into segments to obtain the power consumption sequence window converted into a matrix form, and the embedded representation of the power consumption sequence window is obtained after linear projection;
[0017] Introduce exogenous variables corresponding to each time point in the electricity consumption sequence window The exogenous variables are external environmental factors that affect electricity consumption, and the exogenous variables are encoded into learnable embedded representations; The power consumption sequence window of each node starts from time T a At time T b Total T w time points, each time point has K different external variables;
[0018] The power consumption sequence representation considering the influence of the exogenous variables is obtained according to the embedded representation of the power consumption sequence window and the embedded representation of the corresponding exogenous variables;
[0019] The time series encoder is used to extract the time series features of the power consumption sequence considering the influence of exogenous variables, and the time series semantic representation of the power consumption sequence of the node is obtained.
[0020] Furthermore, the calculation formula for the electricity consumption sequence considering the influence of exogenous variables is as follows:
[0021]
[0022] Among them, u i h is the electricity consumption sequence considering the influence of exogenous variables. i is the embedding representation of the power sequence window, K is the number of exogenous variables, Power sequence window x i A learnable embedding representation of the k-th exogenous variable.
[0023] Furthermore, the temporal encoder adopts a Transformer encoder.
[0024] Furthermore, the hierarchical encoder adopts the R-GCN model.
[0025] Furthermore, the mask reconstruction task is specifically:
[0026] Power sequence window x i The segmentation result p i Randomly select a masking method from random masking and causal masking to obtain the segmentation result after masking;
[0027] Based on the masked segmentation results, a linear layer is used to reconstruct the power sequence window. Compute the reconstruction loss.
[0028] Furthermore, the dual-view contrast learning task is specifically:
[0029] For the power consumption sequence windows corresponding to the nodes in the hierarchical graph, construct positive and negative sample pairs, where the power consumption sequence windows obtained after the offset of the time step δ of the same node are used as positive samples, the power consumption sequence windows obtained after the offset greater than the time step δ of the same node are used as negative samples, and the power consumption sequence windows corresponding to different nodes at the same starting time are used as negative samples;
[0030] The contrastive learning loss is calculated based on the positive and negative sample pairs constructed from two perspectives.
[0031] In a second aspect, the present invention provides a system for extracting high-level semantic information from a hierarchical power usage sequence, which is used to implement the above-mentioned method for extracting high-level semantic information from a hierarchical power usage sequence.
[0032] Compared with the prior art, the present invention has the following beneficial effects: the present invention provides a framework for extracting high-level semantic information from power consumption sequences, models the time series characteristics of power consumption sequence windows through a time series encoder, and models the dependencies of different levels through a hierarchical encoder. In addition, the training of the power system base model is realized through two self-supervised tasks, providing a basic model for machines to understand power consumption sequences and complete various downstream tasks related to the power system. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] Figure 1 It is a schematic diagram of the model architecture of the present invention;
[0034] Figure 2 It is a schematic diagram of the construction of the hierarchical graph;
[0035] Figure 3 It is a schematic diagram of a temporal encoder enhanced by exogenous variables;
[0036] Figure 4 It is a schematic diagram of the R-GCN network;
[0037] Figure 5 It is a schematic diagram of self-supervised learning tasks. DETAILED DESCRIPTION
[0038] The present invention is further described below in conjunction with the accompanying drawings and embodiments. The accompanying drawings are only schematic diagrams of the present invention, and some of the block diagrams shown in the accompanying drawings are functional entities, which do not necessarily correspond to physically or logically independent entities, and these functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0039] like Figure 1 The figure shows a schematic diagram of the model architecture. The forward propagation of this model mainly consists of the following processes:
[0040] 1. Hierarchical graph construction.
[0041] The electricity consumption sequence of cities, regions and users naturally forms a hierarchical relationship. Due to the disparity in the number of users and regions, there will be a large number of user-region edges, which increases the difficulty of hierarchical modeling. In order to solve this problem, the present invention adopts a method of constructing intermediate nodes to sparse the edges and obtain a hierarchical graph between users (intermediate nodes)-regions-cities.
[0042] like Figure 2 Specifically, we first cluster the user's electricity usage sequence using a clustering method to obtain each cluster after aggregation, and then aggregate the electricity usage sequence of each cluster as the electricity usage sequence of the intermediate node, and use the intermediate node-region edge to represent the user-region edge. By sparsely processing the edges, we can obtain a hierarchical graph. in It is a node set of user nodes, regional nodes, city nodes, and intermediate nodes generated based on user power consumption sequence clustering. The feature x of each node i is the power consumption sequence window of the node i, ε is a set of directed edges, It is a set of attributes for each edge, used to indicate the direction (user→region or region→user). In the figure, there are bidirectional edges between regional nodes and city nodes, bidirectional edges between intermediate nodes and regional nodes, and unidirectional edges between user nodes and regional nodes, from regional nodes to user nodes.
[0043] 2. Extract the temporal semantic representation of the power consumption sequence of the nodes in the hierarchical graph through the temporal encoder.
[0044] like Figure 3 As shown in Figure 2, the calculation process of the temporal encoder enhanced by exogenous variables includes:
[0045] (1) Block processing.
[0046] Due to the semantic sparsity of the power consumption sequence, the present invention converts the power consumption sequence window x of each node in the hierarchical graph into i Use sliding window to split into N p The length of the segment is P, and the power sequence window x is obtained. i The segmentation results in T w represents the power sequence window length, S represents the step length, and the last segment whose length is less than P is padded with 0. This method has been proven to be effective in many works. i Apply linear projection to obtain the embedding representation of the power usage sequence Where d represents the dimension of the embedding representation.
[0047] (2) External variable encoding.
[0048] To effectively interact with exogenous variables, we use learnable embeddings To simulate exogenous variables, the exogenous variables represent external environmental factors that may affect electricity consumption, such as weather type variables and temperature variables, where K represents the number of exogenous variables, M k Indicates the number of value types of the kth exogenous variable (for example, assuming that the value types of the weather type variable include sunny and rainy days, the number of value types of the weather type variable is 2). Corresponding to p i The kth exogenous variable
[0049] The embedded representation of the exogenous variable can be obtained from E Then, the electricity consumption sequence considering the influence of exogenous variables can be expressed as
[0050] (3) Time encoder.
[0051] In order to simulate complex time dependencies and interactions with exogenous variables, this embodiment uses the Transformer encoder to i Perform enhanced coding to obtain enhanced time representation As the time-series semantic representation of the power consumption sequence of node i in the hierarchical graph, the time-series semantic representation of the power consumption sequence of all nodes in the hierarchical graph is recorded as
[0052] 3. Perform hierarchical enhancement on temporal semantic representation through hierarchical encoders.
[0053] The present invention uses graph neural networks (GNNs) to simulate the complex correlations between different levels. Considering that the correlations between different edges in the hierarchical graph are different, the present invention uses R-GCN to integrate the information between the power consumption sequences of different levels and nodes. Figure 4 As shown, specifically, R-GCN is used to consider each node in the graph Update the temporal semantic representation by using the neighboring nodes in The hierarchical enhanced temporal semantic representation is denoted as Then, use z i to perform self-supervised pre-training.
[0054] 4. The hierarchically enhanced temporal semantic representation is used for mask reconstruction tasks and dual-view contrast learning tasks to train the temporal encoder and hierarchical encoder, such as Figure 5 shown.
[0055] (1) Mask reconstruction task.
[0056] The present invention adopts a mask reconstruction strategy to model time dependency within the power consumption sequence window. However, existing random masking methods encounter a problem: they reconstruct the missing parts based on the known surrounding parts without considering predicting the future parts based only on the past parts, which not only reduces the difficulty of the pre-training stage, but also lacks consistency between the pre-training task and the prediction task.
[0057] To solve this problem, the present invention proposes a new method combining random masking and causal masking, such as Figure 5 (left figure). Specifically, the power sequence x i The segmentation result p i Randomly select a masking method from the random mask and the causal mask to obtain the masked segmentation result masked p i ,This approach not only retains the benefits of the random mask strategy, but also ensures that the model learns to predict the future part only based on past information, thereby more comprehensively capturing the temporal dependencies within the segment window of the electricity usage sequence.,The above expression is :
[0058]
[0059] Among them, Mask r and Mask c denote random mask and causal mask respectively, α∈[0,1] is a uniformly distributed variable, and each p i Assign a random value α.
[0060] Based on the masked p i The linear layer reconstruction uses the electrical sequence x i , and record the reconstructed power consumption sequence as The corresponding reconstruction loss is:
[0061]
[0062] Where N represents the number of nodes in the hierarchical graph.
[0063] (2) Dual-view contrast learning task.
[0064] The goal of contrastive learning is to learn representations by bringing positive pairs closer and pushing negative pairs further away in the latent space. Inspired by this, in order to make the model aware of the differences between power usage sequence windows, this paper adopts dual-view contrastive learning (DVCL) to identify subtle differences in power usage behaviors in power usage sequences.
[0065] The positive sample pairs and negative sample pairs of contrastive learning are determined from two views: one is the time view, which is based on the time difference between two windows. The other is the node view, which depends on whether the two power consumption sequence windows belong to the same node. For the same node, the smaller the time difference between the two windows, the closer their representations may be. On the contrary, windows from different nodes or windows with large time differences in the same node may have more different representations. In general, the present invention considers adjacent windows of the same node to be positive samples, while windows from different nodes or non-adjacent windows of the same node are negative samples. Figure 5 (right figure) as shown, for Figure The power consumption sequence window V of a node in , the original start timestamp of this window is T a .
[0066] The positive sample is: The same node in T gets another a +δ starts the power sequence window V + as a positive sample.
[0067] Its negative sample is: Different nodes in T a The power sequence window P starts - as node negative samples; and, for graph The same node in T gets another one from T after a shift greater than the time step δ. c Start of power sequence window V - As negative samples, where |T c -T a |>>δ.
[0068] In the mathematical definition of the present invention, given a time series window x of a node i , by shifting it by δ time steps to obtain the positive sample The time series windows of other nodes are used as negative samples Therefore, there are a total of B-1 negative examples in each batch of training, where B is the batch size during pre-training. The DVCL loss is:
[0069]
[0070] Where I is a Boolean vector (consisting of 0 and 1) used to select the above two types of negative samples, sim(·) is the cosine similarity function, and τ represents the temperature coefficient.
[0071] After the training is completed, for the hierarchical graph to be inferred, the temporal semantic representation of the power consumption sequence of the nodes in the hierarchical graph is extracted through the temporal encoder enhanced by exogenous variables; the temporal semantic representation is hierarchically enhanced through the hierarchical encoder; the hierarchically enhanced temporal semantic representation is used as high-level semantic information, which can be used for downstream tasks.
[0072] The technical effect of the present invention is verified by experiments below.
[0073] (1) Dataset.
[0074] This embodiment conducts experiments on five real-world hierarchical power time series datasets, one of which is collected from a real scenario, and the other four are collected from CSISO, ISONE, NYISO, and PJM datasets. This experiment includes four typical time series analysis tasks on these datasets to evaluate the effectiveness of the method of the present invention in intra-domain and cross-domain settings. The four typical time series analysis tasks are prediction, missing value filling, anomaly detection, and classification, and these tasks include different sampling frequencies (5 minutes, 15 minutes, 1 hour, 1 day). In addition, it covers a variety of application scenarios in power systems (load forecasting, solar power generation forecasting, power theft detection, and consumer analysis, etc.).
[0075] Tables 1 and 2 summarize the detailed descriptions of the above datasets.
[0076] Table 1 Description of private datasets
[0077]
[0078]
[0079] Table 2 Description of public datasets
[0080]
[0081]
[0082] (2)Benchmark.
[0083] The present invention is compared with 8 state-of-the-art methods: including large language model (LLM) enhanced models: GPT4TS, Time-LLM, UniTime; pre-trained models: PatchTST, CoST, TS2Vec; supervised models: DLinear, TimesNet. In order to make a fair and comprehensive comparison, all models are reproduced using the official implementation, and different output heads are used according to different downstream tasks. Due to the large scale of the power sequence window dataset, the number of training cycles is increased and the learning rate is reduced to allow the parameters of the model to be fully learned.
[0084] (3) Experiments on downstream tasks.
[0085] Comparing the test results of the present invention and the baseline model on multiple downstream tasks, as shown in Tables 3 and 4, the model of the present invention is superior to the baseline comparison model in all indicators of all downstream tasks.
[0086] Table 3 Private datasets
[0087]
[0088]
[0089] Table 4 Public datasets
[0090]
[0091] On private datasets, among the results of 15 major categories of downstream tasks, 14 tasks of the present invention are comprehensively superior to the baseline comparison model. It not only leads in the means of different tasks, but also achieves performance close to SOTA at different levels (especially at the macro level). This highlights the ability of the present invention in modeling temporal dependencies, exogenous variables, and hierarchical interactions, and also reflects the superior effects of the two pre-training tasks. It can also be noted that on most downstream tasks, the fine-tuned version of the present invention is also superior to most baseline models, proving that the present invention has a strong representation learning ability. In the verification results of public datasets, the present invention is still comprehensively superior to the baseline comparison model, which further reflects the generalization and robustness of the present invention.
[0092] In this embodiment, a system for extracting high-level semantic information from a hierarchical power usage sequence is also provided. The system is used to implement the above-mentioned embodiment, and the descriptions that have been made will not be repeated. The terms "module", "unit", etc. used below can be a combination of software and / or hardware that implements predetermined functions. Although the systems described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware, is also possible.
[0093] The system comprises:
[0094] A hierarchical graph construction module is used to regard the electricity consumption sequence windows of cities, regions and users as node features, generate intermediate node features based on user node features, and construct a hierarchical graph consisting of city nodes, regional nodes, user nodes, and intermediate nodes;
[0095] An exogenous variable enhanced temporal encoder module, which is used to extract a temporal semantic representation of the power consumption sequence of nodes in a hierarchical graph through an exogenous variable enhanced temporal encoder;
[0096] A hierarchical encoder module, which is used to hierarchically enhance the temporal semantic representation through a hierarchical encoder;
[0097] A training module, which is used to use the hierarchically enhanced temporal semantic representation for mask reconstruction tasks and dual-view contrast learning tasks, and to train the exogenous variable enhanced temporal encoder and hierarchical encoder;
[0098] The high-level semantic information extraction module is used to extract the hierarchical enhanced temporal semantic representation in the power consumption sequence as high-level semantic information by using the trained exogenous variable enhanced temporal encoder and hierarchical encoder.
[0099] The implementation process of the functions and effects of each module in the above-mentioned system is specifically detailed in the implementation process of the corresponding steps in the above-mentioned method, which will not be repeated here. For the system embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The system embodiment described above is only schematic, wherein the modules described as separate components may or may not be physically separated, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of the present invention. Ordinary technicians in this field can understand and implement it without paying creative work.
[0100] The embodiments of the system of the present invention can be applied to any device with data processing capabilities, and the device with data processing capabilities can be a device or apparatus such as a computer. The system embodiments can be implemented by software, or by hardware or a combination of software and hardware. Taking software implementation as an example, as a device in a logical sense, the corresponding computer program instructions in the non-volatile memory are read into the memory by the processor of any device with data processing capabilities and run.
[0101] Obviously, the above-described embodiments and drawings are only some examples of the present application. For those of ordinary skill in the art, the present application can also be applied to other similar situations based on these drawings without creative work. In addition, it is understandable that, although the work done in this development process may be complicated and lengthy, for those of ordinary skill in the art, certain changes in design, manufacturing or production based on the technical content disclosed in this application are only conventional technical means and should not be regarded as insufficient content disclosed in this application. Without departing from the concept of the present application, several variations and improvements can also be made, which all belong to the scope of protection of the present application. Therefore, the scope of protection of the present application shall be subject to the attached claims.
Claims
1. A method for extracting high-level semantic information from hierarchical power usage sequences, characterized in that: include: The electricity consumption sequence windows of cities, regions and users are regarded as node features, and the intermediate node features are generated according to the user node features, and a hierarchical graph consisting of city nodes, regional nodes, user nodes and intermediate nodes is constructed; The temporal encoder enhanced by exogenous variables extracts the temporal semantic representation of the power consumption sequence of nodes in the hierarchical graph; Hierarchical enhancement of temporal semantic representation through hierarchical encoders; The hierarchically enhanced temporal semantic representation is used for mask reconstruction tasks and dual-view contrast learning tasks, and the temporal encoder and hierarchical encoder enhanced by the exogenous variables are trained; The trained exogenous variable enhanced temporal encoder and hierarchical encoder are used to extract the hierarchical enhanced temporal semantic representation in the electricity consumption sequence as high-level semantic information.
2. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 1, characterized in that: In the hierarchical graph, there are bidirectional edges between regional nodes and city nodes, bidirectional edges between intermediate nodes and regional nodes, and unidirectional edges between user nodes and regional nodes, and the unidirectional edges are from regional nodes to user nodes.
3. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 1, characterized in that: The time series encoder enhanced by exogenous variables extracts the time series semantic representation of the power consumption sequence of the nodes in the hierarchical graph, including: The power consumption sequence window is divided into segments using a sliding window, and the power consumption sequence window is converted into a matrix form. The embedded representation of the power consumption sequence window is obtained after linear projection; Introducing exogenous variables corresponding to each time point in the electricity consumption sequence window, the exogenous variables are external environmental factors that affect electricity consumption, and encoding the exogenous variables into learnable embedded representations; The power consumption sequence representation considering the influence of the exogenous variables is obtained according to the embedded representation of the power consumption sequence window and the embedded representation of the corresponding exogenous variables; The time series encoder is used to extract the time series features of the power consumption sequence considering the influence of exogenous variables, and the time series semantic representation of the power consumption sequence of the node is obtained.
4. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 3, characterized in that: The calculation formula for the electricity consumption sequence considering the influence of exogenous variables is as follows: Among them, u i h is the electricity consumption sequence considering the influence of exogenous variables. i is the embedding representation of the power sequence window, K is the number of exogenous variables, For the power sequence window x i A learnable embedding representation of the k-th exogenous variable.
5. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 3, characterized in that: The temporal encoder adopts a Transformer encoder.
6. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 1, characterized in that: The hierarchical encoder adopts the R-GCN model.
7. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 1, characterized in that: The mask reconstruction task is specifically: For the power sequence window x i The segmentation result p i Randomly select a masking method from random masking and causal masking to obtain the segmentation result after masking; Based on the masked segmentation results, a linear layer is used to reconstruct the power sequence window. Compute the reconstruction loss.
8. The method for extracting high-level semantic information from hierarchical power usage sequences according to claim 1, characterized in that: The dual-view contrast learning task is specifically: For the power consumption sequence windows corresponding to the nodes in the hierarchical graph, construct positive and negative sample pairs, where the power consumption sequence windows obtained after the offset of the time step δ of the same node are used as positive samples, the power consumption sequence windows obtained after the offset greater than the time step δ of the same node are used as negative samples, and the power consumption sequence windows corresponding to different nodes at the same starting time are used as negative samples; The contrastive learning loss is calculated based on the positive and negative sample pairs constructed from two perspectives.
9. A system for extracting high-level semantic information from hierarchical power usage sequences, characterized in that: include: A hierarchical graph construction module is used to regard the electricity consumption sequence windows of cities, regions and users as node features, generate intermediate node features based on user node features, and construct a hierarchical graph consisting of city nodes, regional nodes, user nodes, and intermediate nodes; An exogenous variable enhanced temporal encoder module, which is used to extract a temporal semantic representation of the power consumption sequence of nodes in a hierarchical graph through an exogenous variable enhanced temporal encoder; A hierarchical encoder module, which is used to hierarchically enhance the temporal semantic representation through a hierarchical encoder; A training module, which is used to use the hierarchically enhanced temporal semantic representation for mask reconstruction tasks and dual-view contrast learning tasks, and to train the exogenous variable enhanced temporal encoder and hierarchical encoder; The high-level semantic information extraction module is used to extract the hierarchical enhanced temporal semantic representation in the power consumption sequence as high-level semantic information by using the trained exogenous variable enhanced temporal encoder and hierarchical encoder.
Citation Information
Patent Citations
Method and system for extracting advanced semantic information of intracranial electroencephalogram data
CN117257231A
Time sequence anomaly detection method based on mask attention network and generative model
CN118861918A