A building energy consumption management system and method based on big data
By combining a big data management system with distributed sensor networks and edge computing, and employing technologies such as sliding window robust mean and self-attention mechanism, the problems of data processing delay and anomaly detection in building energy consumption monitoring systems have been solved. This has enabled efficient and accurate energy consumption prediction and alarm, and improved the real-time performance and intelligence level of building energy consumption management.
Patent Information
- Application Number
- CN202510472843.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-16
- Publication Date
- 2025-11-07
- Estimated Expiration
- 2045-04-16
AI Technical Summary
Existing building energy consumption monitoring systems suffer from high data processing latency, insufficient sensitivity in anomaly detection, and weak generalization ability of prediction models, making it difficult to adapt to complex and ever-changing building energy consumption scenarios. Furthermore, conventional threshold alarm mechanisms are susceptible to instantaneous fluctuations, resulting in a high false alarm rate and making it difficult to support accurate energy consumption diagnosis and dynamic optimization.
A building energy consumption management system based on big data is adopted. It realizes real-time acquisition and local preprocessing of multi-source energy consumption data at the minute level through distributed sensor network and edge computing module. It combines sliding window robust mean, absolute median difference statistics and adaptive substitution mechanism to eliminate noise and outliers. It integrates self-attention mechanism and residual time series modeling technology to generate multi-dimensional energy state anchor points for data stability verification. It also dynamically corrects predicted values through historical cluster centers and realizes highly sensitive anomaly classification alarm by combining multi-level threshold judgment mechanism.
It significantly improves the real-time performance, robustness, and intelligence of building energy consumption management, enhances data quality and processing efficiency, strengthens the model's generalization ability and prediction accuracy for complex scenarios, reduces false alarm rate, forms a closed-loop management process, and provides reliable technical support for dynamic monitoring, anomaly diagnosis, and energy-saving optimization of building energy consumption.
Smart Images

Figure CN120387905B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of intelligent buildings, in particular to a building energy consumption management system and method based on big data. BACKGROUND
[0002] With the acceleration of urbanization and the promotion of green building concepts, building energy consumption management has become an important link to achieve the goal of energy saving and carbon reduction. Traditional building energy consumption monitoring systems rely on single sensor data and use offline batch processing methods, which have problems such as high data processing delay, insufficient abnormality detection sensitivity, weak generalization ability of prediction models, and are difficult to adapt to complex and variable building energy consumption scenarios.
[0003] A building energy consumption prediction method based on artificial intelligence is disclosed in Chinese patent CN118211721B, which uses temperature sensors and humidity sensors and inputs energy bills through a raw data collection site and connects an energy supply management system and a weather station to obtain building energy consumption related data, which helps to improve the accuracy and comprehensiveness of the building energy consumption prediction model. The building energy consumption related data is detected and processed, the data is associated with the time stamp and the average time feature of the time stamp data is extracted, a linear regression model is constructed and the average time feature of the temperature data, humidity data and building characteristic data is input, a decision tree model is constructed and the characteristic data of the building, the historical energy consumption data of the building and the climate data of the region where the building is located are input, a visual interface is created and the final prediction results, performance indicators and actual energy consumption data of the two model integrations are displayed in real time, helping users to intuitively understand the building energy consumption situation.
[0004] The existing technology based on cloud centralized computing energy consumption analysis method can process massive data, but is limited by network transmission bandwidth and cloud computing power, and has low real-time performance and edge response efficiency. The conventional threshold alarm mechanism is easily disturbed by instantaneous fluctuations and has a high false alarm rate, which is difficult to support accurate energy consumption diagnosis and dynamic optimization. In addition, building energy consumption is influenced by regional environment, equipment operating state and user behavior, etc. The traditional time series prediction model often ignores the correlation of multi-dimensional features, resulting in limited prediction accuracy and difficulty in meeting the needs of refined management. In this background, there is an urgent need for an energy consumption management system that integrates edge intelligence, big data analysis and dynamic correction mechanism to realize real-time data acquisition, efficient preprocessing, accurate prediction and intelligent decision-making closed-loop management, and provide reliable technical support for building energy saving optimization. SUMMARY
[0005] The present application aims to solve the problems in the background art and provides a building energy consumption management system and method based on big data.
[0006] The technical solution of the present application is a building energy consumption management method based on big data, which comprises the following specific implementation steps:
[0007] S1, collecting energy consumption data in a building;
[0008] S2, constructing a window sequence for the energy consumption data through a sliding window, calculating a robust mean and an absolute median deviation to eliminate extreme value interference, evaluating data anomalies based on a normalized deviation and using an exponential decay weight for adaptive replacement, dynamically updating statistics and window parameters to maintain adaptive ability, generating multi-dimensional energy consumption features using z-score normalization, and constructing multi-dimensional energy state anchor points by combining finite field coding and a pre-set hash function;
[0009] S3, generating finite field coding data from the multi-dimensional energy state anchor points and the multi-dimensional energy consumption features, solving a linear equation to achieve data stability verification, constructing an energy consumption prediction model, extracting local trends and long-term dependencies using multi-scale residual convolution and self-attention mechanisms based on a time series feature matrix, dynamically weighting and fusing correction prediction bias after outputting a basic prediction value through a multi-layer perception, and generating an energy consumption prediction value;
[0010] S4, calculating the absolute error between the prediction value and the actual energy consumption value, normalizing the error based on the sliding window standard deviation to generate a standardized error index, dividing the abnormality level, triggering a decision mechanism based on consecutive abnormalities within the sliding window, determining abnormal persistence according to an effective trigger rate threshold, and triggering a hierarchical alarm strategy according to the abnormality level;
[0011] S5, visualizing the energy consumption data, energy consumption prediction value, abnormality level, abnormality persistence, and alarm strategy.
[0012] Preferably, the adaptive replacement process is as follows:
[0013] S21, based on the energy consumption data S = {s1, s2,..., s i ,…,s t}, a window sequence with a length of w is constructed in a sliding window manner: W t = {s t-w+1 ,s t-w+2 ,…,s t};
[0014] wherein s i represents the original energy consumption value collected at the i-th moment; w represents the window length; W t represents the consecutive observation data within the current window;
[0015] S22, calculating the robust statistical mean and local fluctuation amplitude:
[0016] σ t = median(|s′ i - μ t |); s′i ∈W′ t ;
[0017] where W t ' denotes W t with 10% upper and lower outliers removed; s' i denotes the i-th data value in W t ; μ t denotes the robust mean; σ t denotes the absolute median deviation based on μ t ; median() denotes the median function;
[0018] S23, evaluate the degree of deviation of the current value s t from the robust mean:
[0019] Calculate the discriminant function:
[0020] where δ t denotes the normalized deviation; ε denotes a small constant to prevent division by zero; θ t denotes the dynamic threshold; k denotes an empirical coefficient; Var(W t ) denotes the variance within the current window; accept denotes that the current data s t is normal; filter denotes that the current data s t is judged to be abnormal;
[0021] S24, if the current data s t is judged to be abnormal, i.e., filter, then perform adaptive replacement:
[0022]
[0023] where exp() denotes the natural exponential function; denotes the replacement value; w i denotes the decay weight given to the time distance; α denotes the decay speed control factor.
[0024] Preferably, the construction process of the multi-dimensional energy state anchor point is as follows:
[0025] S31, encode the multi-dimensional energy consumption feature x i to obtain the encoded data Dc = H(data) ∈ GF(p) n ;
[0026] where data is the multi-dimensional energy consumption feature x iThe binary encoded data; H() is a preset hash function with an output length of n×log2p; p is a predefined large prime number satisfying p≡3mod 4; n is the set number of variables; GF(p) n Let represent an n-dimensional vector space consisting of elements {0,1,2,…,p-1} on the finite field GF(p);
[0027] S32. Define the linear equation S·EⅠ=Dc, and solve it to obtain the first-order coded tuple EⅠ=S -1 ·Dc={z1,z2,…,z i ,…,z n};
[0028] Where S is a pre-defined invertible n×n matrix over the finite field GF(p); z i Let S be any solution to the equation S·EⅠ=Dc;
[0029] S33. Calculate the second-order coded tuple EⅡ={y1,y2,…,y i ,…,y n};
[0030] Among them, y i c is any element in the second-order coded tuple EⅡ; i For a predefined constant vector c = [c1, c2, ..., c i ,…,c n The elements in ], c∈GF(p) n ;
[0031] S34. Define the linear equation B·A=EⅡ, and solve it to obtain the multidimensional energy state anchor point A=B. -1 EⅡ;
[0032] Where B is a pre-defined invertible n×n matrix over the finite field GF(p).
[0033] Preferably, the verification process for data stability is as follows:
[0034] S41. Calculate the decoded tuple D = B·A = {d1, d2, ..., d...} i ,…,d n};
[0035] Where, d i For any element in the decoded tuple D;
[0036] S42. Calculate the decoding factor fd:
[0037] S43. Calculate the verification factor fc = S·fd;
[0038] S43, calculate the secondary encoding data Dc'=H(data');
[0039] wherein data' is the received multi-dimensional energy consumption feature x i encoded in binary;
[0040] S44, if fc=Dc', the verification is passed, i.e., the received multi-dimensional energy consumption feature x i has stability and data positioning has reliability; otherwise, an alarm is immediately given.
[0041] Preferably, the model architecture of the energy consumption prediction model comprises:
[0042] Input layer: construct a time series feature matrix, and concatenate the multi-dimensional feature vectors of consecutive N time steps in a sliding time window into a two-dimensional input matrix X t :
[0043] wherein x t represents the multi-dimensional energy consumption feature vector extracted at the t-th time; T represents the transpose operation of the matrix; represents an N-row d-column real matrix; d represents the feature dimension at each time;
[0044] Time series feature residual modeling layer: introduce multi-scale convolution and residual connection, use one-dimensional convolution to perform multi-scale processing on the input time series, and combine the features of different convolution scales by combining residual networks: H1=ReLU(Conv k'=3 (X t ))+Conv k'=5 (X t );
[0045] wherein H1 represents the feature representation after convolution and activation; d' represents the output dimension after convolution; Conv k' represents one-dimensional convolution operation; k' represents the size of the convolution kernel; ReLU() represents the ReLU activation function;
[0046] Key dependency extraction layer: introduce a self-attention mechanism, and output a feature representation H2:
[0047]
[0048] Q=H1W Q ; K=H1W K ; V=H1W V ;
[0049] wherein Attention(Q,K,V) represents a self-attention operation; Q, K, and V represent query, key, and value matrices obtained by linear transformation; WQ ,W K ,W V denotes a weight matrix; d k denotes the dimension of the query vector; softmax() denotes the softmax function;
[0050] Prediction layer: using multi-layer perception to regress the next time step energy consumption value
[0051] wherein, denotes the feature representation of time step t obtained from the self-attention mechanism;
[0052] Dynamic prediction correction layer: dynamically weighted fusion of historical clustering centers to correct the prediction bias and generate energy consumption prediction value.
[0053] Preferably, the generation process of dynamically weighted fusion of historical clustering centers to correct the prediction bias and generate energy consumption prediction value is as follows:
[0054] S61, constructing a historical feature clustering dictionary: by clustering analysis on a large number of historical building energy consumption features, a set of typical energy consumption mode vectors, i.e. clustering centers, are formed:
[0055] wherein, C j denotes the center vector of the jth energy consumption mode; N j denotes the number of samples in the jth class; denotes the sample belonging to the jth class; M denotes the total number of energy consumption mode categories;
[0056] S62, calculating the similarity between the current feature and the historical feature: the feature vector of the current time step after modeling is matched with each historical mode for similarity:
[0057] wherein, j * denotes the closest historical feature center; ||·||2 denotes the Euclidean distance;
[0058] S63, dynamic prediction fusion:
[0059] wherein, denotes the basic prediction value; denotes the average energy consumption value corresponding to the historical clustering center j * ; λ denotes the weighting coefficient, λ∈[0,1]; denotes the final prediction value after fusion correction.
[0060] Preferably, the abnormal level division process is as follows:
[0061] S71, dynamic deviation calculation and normalization processing: at each time step t+1, record the actual energy consumption value and compare it with the predicted value to obtain the absolute error ε t+1 :
[0062] S72, introduce sliding standard deviation normalization processing:
[0063] where e t+1 represents the normalized error index; σ [t-W,t] represents the standard deviation of the actual energy consumption of the past W time steps;
[0064] S73, based on the normalized error index e t+1 , define the anomaly discrimination as a multi-level rule:
[0065]
[0066] where θ1 and θ1 are dynamic threshold values set using the 95% and 99% quantile of the history, respectively; Level(t+1) is the anomaly level at time t+1.
[0067] Preferably, the continuous anomaly trigger judgment mechanism based on the sliding window is:
[0068] Define the anomaly level sequence of the past M time steps as {Level(t+1-M+1),...,Level(t+1)}, if the following conditions are met, it is considered that the anomaly is valid:
[0069]
[0070] where I() represents the indicator function; γ represents the valid trigger rate threshold, γ∈[0,1]; M represents the sliding window width.
[0071] The technical scheme of the present application: a building energy consumption management system based on big data, which is used to execute the above-mentioned building energy consumption management method based on big data, comprising:
[0072] A multi-source energy consumption data acquisition module is used to construct a distributed sensor network inside the building and acquire building energy consumption data.
[0073] An edge data processing module is used to perform preliminary data filtering locally.
[0074] An intelligent analysis and prediction module is used to construct an energy consumption prediction model using a big data processing engine and output energy consumption prediction values.
[0075] An intelligent optimization decision module is used to develop an alarm strategy based on energy consumption prediction values.
[0076] The visualization and alarm module is used to visualize data and issue timely alarms.
[0077] Compared with the prior art, the above-mentioned technical solution of the present invention has the following beneficial technical effects:
[0078] This invention designs a building energy consumption management system and method based on big data. It achieves real-time acquisition and local preprocessing of multi-source energy consumption data at the minute level through a distributed sensor network and edge computing module. It employs a sliding window robust mean, absolute median difference statistics, and adaptive substitution mechanism to eliminate noise and outliers, significantly improving data quality and processing efficiency. It integrates a self-attention mechanism and residual time-series modeling technology, combined with finite-field coding to generate multi-dimensional energy state anchor points for data stability verification. Furthermore, it dynamically corrects predicted values through historical cluster centers, effectively enhancing the model's generalization ability and prediction accuracy for complex scenarios. Based on a normalized deviation and multi-level threshold judgment mechanism, combined with sliding window statistics and continuous triggering rules, it achieves a highly sensitive anomaly classification alarm and linkage control strategy, significantly reducing the false alarm rate. This invention forms a closed-loop management process through multi-dimensional feature integration and visual feedback, providing reliable technical support for dynamic monitoring, anomaly diagnosis, and energy-saving optimization of building energy consumption, thus improving the real-time performance, robustness, and intelligence of energy consumption management. Attached Figure Description
[0079] Figure 1 This is a system architecture diagram of a building energy consumption management system based on big data proposed in this invention;
[0080] Figure 2 This is a flowchart of a building energy consumption management method based on big data proposed in this invention. Detailed Implementation
[0081] Example 1, as Figure 1 As shown, the present invention proposes a building energy consumption management system based on big data, including: a multi-source energy consumption data acquisition module, an edge data processing module, an intelligent analysis and prediction module, an intelligent optimization decision-making module, and a visualization display and alarm module.
[0082] A multi-source energy consumption data acquisition module constructs a distributed sensor network within the building to collect building energy consumption data;
[0083] The edge data processing module performs preliminary data filtering locally (including but not limited to removing noise, duplicate values, and obvious outliers);
[0084] The intelligent analysis and prediction module uses a big data processing engine to build an energy consumption prediction model and outputs predicted energy consumption values.
[0085] The intelligent optimization decision module formulates an alarm strategy based on the energy consumption prediction value.
[0086] The visual display and alarm module visually displays data and timely alarms.
[0087] Embodiment two, as Figure 2 shown, the present application proposes a building energy consumption management method based on big data, which is applied to the building energy consumption management system based on big data proposed in embodiment one, and the specific implementation steps are as follows:
[0088] S1, the multi-source energy consumption data acquisition module collects the energy consumption data of different areas in the building in real time through a plurality of sensor nodes (including but not limited to power, water meter, gas meter, and cooling and heating air conditioning load sensor) arranged in the building at a minute level frequency, and transmits the energy consumption data to the edge data processing module;
[0089] S2, the edge data processing module fuses the weighted window screening, robust statistical detection and edge intelligent judgment mechanism, realizes efficient, low-power and intelligent local preprocessing, filters the energy consumption data, and provides accurate and structured raw data stream for data processing, and the specific implementation process is as follows:
[0090] S21, the energy consumption data stream S={s1, s2,..., s i ,…,s t} is constructed in a sliding window manner, and the window sequence W t ={s t-w+1 ,s t-w+2 ,…,s t} with a length of w is constructed.
[0091] Wherein, s i represents the original energy consumption value collected at the i-th moment; w represents the window length; W t represents the continuous observation data in the current window.
[0092] S22, calculate the robust statistical mean and local fluctuation amplitude, introduce the robust mean (Trimmed Mean) and the absolute median difference (MAD) as the reference measure, and avoid extreme value interference:
[0093]
[0094] σ t =median(|s′ i -μ t |);
[0095] s′ i ∈W t ′;
[0096] Wherein, Wt represents the W t i represents the i-th data value in W t t represents the robust mean (a mean less sensitive to outliers); σ t represents the absolute median deviation (MAD) based on μ t , which measures the fluctuation amplitude; median() represents the median function;
[0097] S23, evaluate the degree of deviation of the current value s t from the robust mean:
[0098] Introduce a discriminant function:
[0099] θ t = k log (1 + Var (W t ));
[0100] where δ t represents the normalized deviation; ε represents a small constant to prevent division by zero; θ t represents the dynamic threshold; k represents an empirical coefficient; Var (W t ) represents the variance within the current window; accept represents that the current data s t is normal; filter represents that the current data s t is judged to be abnormal;
[0101] S24, if the current data s t is judged to be abnormal (i.e., filter), perform adaptive replacement:
[0102]
[0103] w i = exp (-α·i);
[0104] where exp() represents the natural exponential function; represents the replacement value; w i represents the decay weight given to the time distance; α represents the decay speed control factor;
[0105] S25, update the sliding window to W t+1 , and dynamically refresh the statistics robust mean μ t+1 , absolute median deviation σ t+1 , and dynamic threshold θ t+1 , to ensure adaptive ability under different time periods and regional conditions, and continuously perform rolling execution.
[0106] S26, the data normalization program is executed by using the z-score normalization method, and a data frame in a unified format is generated, based on which a multi-dimensional energy consumption feature x is constructed i = [t i , z i , T i , H i , U i , O i ];
[0107] Wherein, t i represents the time stamp; z i represents the spatial position information (floor / region code); T i , H i respectively represent the environment temperature and humidity; U i represents the regional energy consumption of region z i ; O i represents the user activity state (including but not limited to the number of devices turned on, the number of personnel);
[0108] S27, a multi-dimensional energy state anchor point is generated for the multi-dimensional energy consumption feature x i , and the generation process is as follows:
[0109] S2701, the multi-dimensional energy consumption feature x i is encoded to obtain the encoded data Dc=H(data)∈GF(p) n ;
[0110] Wherein, data is the binary encoded data of the multi-dimensional energy consumption feature x i ; H() is a pre-set hash function, and the output length is n×log2p; p is a pre-defined large prime number, which satisfies p≡3mod 4; n is a set variable; GF(p) n represents an n-dimensional vector space composed of elements {0,1,2,…,p-1} in the finite field (Galois field) GF(p);
[0111] S2702, the linear equation S·EⅠ=Dc is defined, and the first-order encoding tuple EⅠ=S -1 ·Dc={z1,z2,…,z i ,…,z n} is solved;
[0112] Wherein, S is a pre-set reversible n×n matrix in the finite field GF(p); z i is any solution of the equation S·EⅠ=Dc;
[0113] S2703, the second-order encoding tuple EⅡ={y1,y2,…,yi ,…,y n};
[0114]
[0115] Among them, y i c is any element in the second-order coded tuple EⅡ; i For a predefined constant vector c = [c1, c2, ..., c i ,…,c n The elements in ], c∈GF(p) n ;
[0116] S2704. Define the linear equation B·A=EⅡ, and solve it to obtain the multidimensional energy state anchor point A=B. -1 EⅡ;
[0117] Where B is a pre-defined invertible n×n matrix over the finite field GF(p);
[0118] S28. Let {multidimensional energy state anchor point A, multidimensional energy consumption characteristic x} i The data is then transmitted to the intelligent analysis and prediction module.
[0119] S3, the intelligent analysis and prediction module, leverages big data engines (including but not limited to Spark or Flink) to achieve efficient data processing and model task scheduling. Specifically, it processes data feature vectors x from edge devices. i After aggregation, under the control of the big data engine, the constructed energy consumption prediction model (integrating self-attention mechanism and residual time series modeling) is scheduled and executed to achieve high-precision prediction and anomaly early warning of large-scale building energy consumption;
[0120] To ensure the stability of the multidimensional energy consumption characteristics and the reliability of data positioning, it is necessary to first base the data on the received multidimensional energy state anchor point A and the multidimensional energy consumption characteristics x. i For multidimensional energy consumption characteristics x i Perform a verification operation. The verification process is as follows:
[0121] Calculate the decoded tuple D = B·A = {d1, d2, ..., d i ,…,d n};
[0122] Where, d i For any element in the decoded tuple D;
[0123] Calculate the decoding factor fd:
[0124] Calculate the check factor fc = S·fd;
[0125] Calculate the secondary encoded data Dc′=H(data′);
[0126] wherein data' is the received multi-dimensional energy consumption feature x i of the binary coded data;
[0127] If fc=Dc', the check passes, i.e. the received multi-dimensional energy consumption feature x i has stability and data positioning has reliability; otherwise, an alarm is immediately given;
[0128] In addition, the model architecture of the energy consumption prediction model is as follows:
[0129] (1) Input layer: Construct a time series feature matrix, and concatenate the multi-dimensional feature vectors of the continuous N time steps in the sliding time window into a two-dimensional input matrix X t :
[0130] wherein x t represents the multi-dimensional energy consumption feature vector extracted at the t time; T represents the transposition operation of the matrix; represents an N-row d-column real matrix, i.e. each element in the matrix is a real number, and for the building energy consumption prediction model, the matrix represents the multi-dimensional features containing N time steps, each time step is composed of d real feature values; d represents the feature dimension at each time;
[0131] (2) Time series feature residual modeling layer (Multi-Scale Residual Temporal Encoder, MSRTE): Introduce multi-scale convolution and residual connection, extract local trend and periodic change, use one-dimensional convolution to process the input time series in multiple scales, combine the features of different convolution scales by using residual network, and enhance the nonlinear modeling ability of the model: H1=ReLU(Conv k'=3 (X t ))+Conv k'=5 (X t );
[0132] wherein H1 represents the feature representation after convolution and activation, and the size is d' represents the output dimension after convolution; Conv k' represents one-dimensional convolution operation; k' represents the size of the convolution kernel (in this embodiment, two different sizes of convolution kernels k=3 and k=5 are used to extract features of different time scales, and through the addition operation (residual connection), the convolution features of two scales are combined); ReLU() represents the ReLU activation function;
[0133] (3) Key dependency extraction layer: introduce self-attention mechanism (Self-Attention), improve the modeling ability of long time span dependency by calculating the dependency between time steps, help the model focus on important parts of the input data, and give different attention weights to each time step:
[0134]
[0135] Q = H1W Q ;
[0136] K = H1W K ;
[0137] V = H1W V ;
[0138] wherein Attention(Q, K, V) represents the self-attention operation; Q, K, V represent the query (Query), key (Key) and value (Value) matrices obtained by linear transformation, generated by the feature matrix H1 of the previous step through trainable weight matrix W Q , K , V d k represents the dimension of the query vector; softmax() represents the softmax function;
[0139] Accordingly: after the self-attention mechanism, the key dependency extraction layer outputs the feature representation H2, the size is
[0140] (4) Prediction layer: use the features output by the above processing to predict energy consumption, use a multi-layer perceptron (MLP) to perform regression, and preliminarily predict the energy consumption value at the next time
[0141] wherein represents the feature representation of time step t obtained from the self-attention mechanism;
[0142] (5) Dynamic prediction correction layer: after preliminarily predicting the preliminary energy consumption value at the next time, although the model has obtained the key dependency feature representation H2 and the preliminary prediction value of the next time energy consumption , the building energy consumption is affected by many complex factors (including but not limited to regional differences, building types, and use habits), and only relying on current data modeling may have overfitting or insufficient generalization problem, therefore, introduce historical big data feature library D hist as an external reference mechanism to dynamically correct the current prediction and enhance the robustness and generalization ability of the model, specifically:
[0143] Building historical feature clustering dictionary: Through clustering analysis on the energy consumption characteristics of a large number of historical buildings, a set of typical energy consumption mode vectors (cluster centers) are formed:
[0144] wherein C j represents the center vector of the jth energy consumption mode; N j represents the number of samples in the jth class; represents the sample belonging to the jth class; M represents the total number of energy consumption mode categories, i.e. the total number of historical feature clusters;
[0145] Calculate the similarity between the current feature and the historical feature: the feature vector of the current time step after modeling is compared with each historical mode for similarity matching:
[0146] wherein j * represents the closest historical feature center; ||·||2 represents the Euclidean distance (L2 norm), which is used to measure the difference between two feature vectors;
[0147] Dynamic prediction fusion:
[0148] wherein, represents the basic prediction value; represents the average energy consumption value corresponding to the historical clustering center j * ; λ represents the weighting coefficient, which is used to control the fusion ratio of the basic prediction and the empirical prediction, λ ∈ [0, 1]; represents the final prediction value after fusion correction;
[0149] Accordingly: the final prediction value is transmitted to the intelligent optimization decision module;
[0150] S4, the intelligent optimization decision module realizes intelligent, interpretable and high-precision energy consumption anomaly detection and multi-level linkage alarm based on the dynamic deviation between the energy consumption prediction value and the actual observation value, combined with the historical fluctuation threshold and the adaptive multi-scale control mechanism, specifically:
[0151] S41, dynamic deviation calculation and normalization processing: at each time step t+1, the actual energy consumption value is recorded and compared with the prediction value output in step S3, to obtain the absolute error ε t+1 :
[0152] S42, in order to facilitate the error comparability between different time periods, sliding standard deviation normalization processing is introduced:
[0153] wherein et+1 denotes the normalized error indicator, i.e., the standardized degree of current abnormal intensity relative to historical volatility; σ [t-W,t] denotes the standard deviation of actual energy consumption in the past W time steps;
[0154] S43, based on the normalized error indicator e t+1 , define the abnormality discrimination as a multi-level rule:
[0155]
[0156] where θ1and θ1are dynamic thresholds set using historical 95%, 99% percentiles, respectively; Level(t+1) is the abnormality level at t+1 time;
[0157] It should be noted that the percentile (Percentile) represents the value at a certain percentage position in a set of data; the 95% percentile means that 95% of the data values are less than or equal to this value; the 99% percentile means that 99% of the data values are less than or equal to this value;
[0158] S44, to prevent false positives caused by instantaneous peak errors or data acquisition jitter, a continuous abnormality trigger determination mechanism in a sliding window is introduced: define the abnormality level sequence of the past M time steps as {Level(t+1-M+1),...,Level(t+1)}, if the following conditions are met, it is considered that the abnormality is valid:
[0159]
[0160] where I() denotes the indicator function; γ denotes the effective trigger rate threshold, γ∈[0,1], for example, γ=0.6 means that 60% of the past time steps are abnormal to trigger; M denotes the sliding window width;
[0161] It should be noted that the indicator function I() is also called the characteristic function, which is a function that only outputs 0 or 1, used to indicate whether a certain condition is true or not, defined as:
[0162] S45, according to the abnormality level Level(t+1) and its persistence, define different alarm strategies:
[0163] Strategy 1: Level 0; normal building energy consumption; no measures;
[0164] Strategy 2: Level 1; building energy consumption is slightly abnormal; send a prompt message to the administrator and record the log;
[0165] Strategy 3: Level 2; building energy consumption is severely abnormal; link air conditioning / illumination energy consumption strategy adjustment, push administrator SMS, automatically trigger remote shutdown / lock control, and initiate abnormality reporting process;
[0166] S46, transmitting the abnormality level Level(t+1), its persistence and the formulated alarm strategy to the visualization and alarm module;
[0167] S5, the visualization and alarm module displays the energy consumption data, the predicted value and the abnormality level Level(t+1), its persistence and the formulated alarm strategy using the built-in visualization device. abnormality level Level(t+1), its persistence and the formulated alarm strategy.
[0168] The embodiments of the present application are described in detail above with reference to the drawings, but the present application is not limited thereto, and various changes can be made within the knowledge of those skilled in the art without departing from the spirit of the present application.
Claims
1. A big data-based building energy consumption management method, characterized by, The specific implementation steps comprise the following steps: S1, collecting energy consumption data in the building; S2, constructing a window sequence for the energy consumption data through a sliding window, calculating a robust mean and an absolute median deviation to eliminate extreme value interference, evaluating data anomalies based on a normalized deviation and performing adaptive replacement using an exponential decay weight, dynamically updating statistics and window parameters to maintain adaptive capability, generating multi-dimensional energy consumption features x using z-score normalization i , combining finite field coding and a preset hash function to construct multi-dimensional energy state anchor points; The construction process of the multi-dimensional energy state anchor point is as follows: A1, a multi-dimensional energy consumption feature x i Encoding is performed to obtain encoded data Dc=H(data)∈GF(p) n ; wherein data is a multi-dimensional energy consumption feature x i ; H() is a preset hash function, the output length is n x log2p; p is a predefined large prime number, p≡3 mod 4; n is a set variable number; GF(p) n represents an n-dimensional vector space composed of elements {0, 1, 2,..., p-1} on the finite field GF(p). A2, define linear equation Se x El = Dc, solve to get first-order encoding tuple El = Se -1 x Dc = {z1, z2,..., z i ,..., z n} wherein Se is a preset invertible n x n matrix on a finite field GF(p); z i is any solution of the equation Se x Ei = Dc. A3, the second-order encoding tuple EII = {yl, y2,..., y i} is calculated. n} is calculated. ; Among them, y i c is any element in the second-order coded tuple EⅡ; i For a predefined constant vector c=[c1,c2,…,c i ,…,c n The elements in ], c∈GF(p) n ; A4, define linear equation B x A = E II, solve to get multi-dimensional energy state anchor point A = B -1 x E II; Wherein, B is a preset reversible n*n matrix on the finite field GF(p); S3, generating finite field coding data through the multi-dimensional energy state anchor point and the multi-dimensional energy consumption feature, and solving a linear equation to realize data stability verification, constructing an energy consumption prediction model, based on a time sequence feature matrix, using multi-scale residual convolution and self-attention mechanism to extract local trends and long-time dependencies, after outputting a basic prediction value by a multi-layer perception, combining a historical clustering center to dynamically weighted fusion correction prediction bias to generate an energy consumption prediction value; The verification process for realizing data stability verification is as follows: B1, compute the decoded tuples D = B x A = {d1, d2,..., d i ,…,d n} ; wherein d i is any element of the decoded tuple D; B2, compute the decoding factor fd: ; B3, calculating the verification factor fc=Se×fd; B4, calculating secondary encoding data ; wherein, is the received multi-dimensional energy consumption feature x i binary encoded data; B5. If then the check passes, i.e. the received multi-dimensional energy consumption feature x i has stability and data positioning has reliability; otherwise, an immediate alert is made; S4, generating a standardized error index by calculating the absolute error of the prediction value and the actual energy consumption value and performing normalization processing based on the sliding window standard deviation, dividing the abnormal level, based on the continuous abnormal trigger determination mechanism in the sliding window, determining the abnormal persistence according to the effective trigger rate threshold, and triggering the hierarchical alarm strategy according to the abnormal level; S5, visualizing the energy consumption data, the energy consumption prediction value, the abnormal level, the abnormal persistence and the alarm strategy.
2. The building energy consumption management method based on big data according to claim 1, characterized in that, The adaptive replacement process is as follows: S21. Based on energy consumption data S={s1,s2,...,s...} i ,…,s t Construct a window sequence of length w using a sliding window approach: W t ={s t-w+1 ,s t-w+2 ,…,s t }; wherein s i represents the original energy consumption value collected at the i th moment; w represents the window length; W t represents the continuous observation data within the current window; S22, calculating the robust statistical mean and the local fluctuation amplitude: ; ; ; wherein, represents the W t Data after removing the top and bottom 10% outliers; represents the i-th data value in represents the robust mean; represents the absolute median deviation based on t median() represents the median function; S23, the current value s t Assessing the degree of robust mean deviation: ; Computing the discriminant function: ; ; wherein, represents a normalized deviation; ε represents a small constant to prevent division by zero; θ t represents a dynamic threshold; k represents an empirical coefficient; Var(W t ) represents a variance within a current window; accept represents that the current data s t is normal; filter represents that the current data s t is judged to be abnormal; S24, if the current data s t is determined to be abnormal, i.e. filter, then adaptive replacement is performed: ; w i = exp(-a x i); where exp() denotes the natural exponential function; denotes a substitute value; w i denotes a decay weight given to the temporal distance; a denotes a decay speed control factor.
3. The building energy consumption management method based on big data according to claim 1, characterized in that, The model architecture of the energy consumption prediction model comprises: Input layer: Construct the time series feature matrix, and concatenate the multi-dimensional feature vectors of the continuous N time steps in the sliding time window into a two-dimensional input matrix X t : ; wherein x t represents the multi-dimensional energy consumption feature vector extracted at the t-th moment; T represents the transpose operation of the matrix; represents a real matrix of N rows and d columns; d represents the feature dimension at each moment; The time sequence feature residual modeling layer: multi-scale convolution and residual connection are introduced, one-dimensional convolution is used for multi-scale processing of the input time sequence, and residual network is combined to combine the features of different convolution scales: ; wherein H1 represents a feature representation after convolution and activation; represents the output dimension after convolution; represents a one-dimensional convolution operation; represents the size of a convolution kernel; ReLU() represents a ReLU activation function; Key dependency extraction layer: introducing a self-attention mechanism to output feature representation H2: ; ; ; ; wherein Attention(Q, K, V) represents a self-attention operation; Q, K, V represent query, key and value matrices obtained by linear transformation; W Q K V represents a weight matrix; d k represents the dimension of a query vector; softmax() represents a softmax function; Prediction layer: uses a multi-layer perceptron for regression, to preliminarily predict the energy consumption value at the next time instant : ; wherein, denotes the feature representation of time step t obtained from the self-attention mechanism; Dynamic prediction correction layer: combining a historical clustering center to dynamically weighted fusion correction prediction bias to generate an energy consumption prediction value.
4. The building energy consumption management method based on big data according to claim 3, characterized in that, The generation process of the energy consumption prediction value by combining a historical clustering center to dynamically weighted fusion correction prediction bias is as follows: S61, construct historical feature clustering dictionary: through clustering analysis on energy consumption features of a large number of historical buildings, a set of typical energy consumption mode vectors, i.e. clustering centers, are formed: ; where C j represents the center vector of the jth energy consumption pattern; N j represents the number of samples in the jth class; represents the sample belonging to the jth class; M represents the total number of energy consumption pattern classes; S62, calculating similarity of current feature and historical features: passing the current time step's modeled feature vector to the similarity matching function with each historical pattern: ; where j * represents the closest historical feature center; represents the Euclidean distance; S63, dynamic prediction fusion: ; wherein, represents the base prediction value; represents the historical cluster center j * corresponding average energy consumption value; λ represents a weighting coefficient, λ ∈ [0, 1]; represents the final prediction value after fusion correction.
5. The big data based building energy consumption management method according to claim 4, characterized in that, The abnormal level division process is as follows: S71, dynamic deviation calculation and normalization processing: at each time step t+1, record the actual energy consumption value , and compare it with the predicted value , to obtain the absolute error ε t+1 : ; S72, introduce sliding standard deviation normalization processing: ; where e t+1 denotes the normalized error indicator; denotes the actual energy consumption standard deviation over the past W time steps; S73, based on the normalized error indicator e t+1 , defining the anomaly discrimination as a multi-level rule: ; Wherein, θ1 and θ1 are dynamic threshold values set using historical 95%, 99% quantiles respectively; Level(t+1) is the abnormal level at t+1 time.
6. The big data based building energy consumption management method according to claim 5, characterized in that, The continuous abnormal trigger determination mechanism in the sliding window is as follows: Define the abnormal level sequence of the past M time steps as {Level(t+1−M+1),...,Level(t+1)}, if the following conditions are met, the abnormality is considered effective: ; wherein, denotes an indicator function; γ denotes an effective trigger rate threshold, γ ∈ [0, 1]; M denotes a sliding window width.
7. A big data-based building energy consumption management system for performing the big data-based building energy consumption management method of any one of claims 1-6. Comprise: A multi-source energy consumption data acquisition module for constructing a distributed sensor network inside a building to collect building energy consumption data; An edge data processing module for performing preliminary data filtering locally; An intelligent analysis and prediction module for constructing an energy consumption prediction model using a big data processing engine to output an energy consumption prediction value; An intelligent optimization decision module for developing an alarm strategy based on the energy consumption prediction value; A visual display and alarm module for visualizing the data and timely alarming.
Citation Information
Patent Citations
Building energy consumption prediction method based on artificial intelligence
CN118211721B
Intelligent building energy consumption monitoring system and method
CN111968356A
Block chain storage method based on linear coding
CN116865947A
Intelligent diagnosis and maintenance method, device and equipment for incinerator and storage medium
CN119027107A