Energy decomposition method, system and equipment based on low-frequency data driving and medium
By using a dual-branch neural network model driven by low-frequency data, the problem of insufficient generalization ability of non-intrusive load decomposition methods in cross-scenario applications is solved. Stable appliance state identification and power estimation are achieved on different residences or datasets, improving the accuracy and consistency of prediction.
Patent Information
- Application Number
- CN202511666609.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-14
- Publication Date
- 2026-02-10
AI Technical Summary
Existing non-intrusive load decomposition methods lack generalization ability when applied across different scenarios, making it difficult to maintain stable decomposition performance on unseen residences or datasets.
An energy decomposition method based on low-frequency data is adopted, using a dual-branch neural network model for feature extraction and prediction. By sharing the feature extraction layer, state prediction branch and power prediction branch, and combining the joint loss function and domain alignment layer, the collaborative processing of appliance state identification and power estimation is achieved.
It improves the model's cross-scenario generalization ability, ensures that the prediction results conform to the physical laws of appliance operation, improves the accuracy of appliance status identification and power estimation accuracy, and reduces the dependence on scene-specific labeled data.
Smart Images

Figure CN121502299A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power load monitoring technology, specifically to an energy decomposition method, system, device, and medium based on low-frequency data. Background Technology
[0002] Non-intrusive load monitoring technology collects total load data at the power inlet and analyzes it to obtain the operating status and energy consumption information of each electrical device. Compared with intrusive methods, non-intrusive methods have the advantages of low cost and simple deployment.
[0003] Traditional non-intrusive load monitoring methods include source separation methods and methods based on Hidden Markov Models (HMMs). Source separation methods use signal processing techniques to separate the load of each device in the total load, but their feature extraction capabilities are limited under low-frequency sampling conditions. HMM-based methods require establishing state transition models for different electrical appliances, but the model parameters depend on labeled data for specific scenarios, resulting in insufficient generalization ability on new residences or new datasets.
[0004] While existing load decomposition methods based on deep neural networks have achieved good results within a single dataset, their performance degrades significantly when applied across different datasets. Differences in sampling rates, equipment models, power usage habits, and electrical specifications between different datasets make direct model transfer difficult. Existing methods often rely on scene-specific labeled or synthetic data for training, limiting the practical application of these models. Summary of the Invention
[0005] In view of the above-mentioned problems, the present invention provides an energy decomposition method, system, device and medium based on low-frequency data driving.
[0006] Therefore, the technical problem solved by this invention is that existing non-intrusive load decomposition methods have insufficient generalization ability when applied across different scenarios, and it is difficult to maintain stable decomposition performance on unseen residences or datasets.
[0007] To solve the above-mentioned technical problems, the present invention provides the following technical solution: an energy decomposition method based on low-frequency data-driven methods, comprising, The total load power time series data at the power inlet is acquired, and the total load power time series data is preprocessed to obtain a standardized input feature sequence; The input feature sequence is input into a dual-branch neural network model for feature extraction and prediction. The dual-branch neural network model includes a shared feature extraction layer, a state prediction branch, and a power prediction branch. The shared feature extraction layer is used to extract temporal features from the input feature sequence; The state prediction branch outputs the operating state information of the target electrical appliance based on the time-series characteristics; The power prediction branch outputs an estimated power consumption value for the target electrical appliance based on the timing characteristics and the operating status information. The dual-branch neural network model is trained using a joint loss function, which includes a state classification loss term, a power regression loss term, and a constraint loss term used to constrain the consistency between the operating state information and the power consumption estimate.
[0008] As a preferred embodiment of the energy decomposition method based on low-frequency data driving according to the present invention, the preprocessing of the total load power time series data includes time alignment and resampling of the total load power time series data to obtain a power series with a fixed time interval. The power sequence is segmented by a sliding window to obtain multiple power window samples; The number of samples representing the on and off states of the target electrical appliance in the power window sample is balanced. The power window samples are normalized to obtain the standardized input feature sequence.
[0009] As a preferred embodiment of the energy decomposition method based on low-frequency data driven by the present invention, the step of extracting temporal features from the input feature sequence includes performing convolution operations on the input feature sequence through multiple one-dimensional convolutional layers to extract local temporal features; The temporal features are obtained by performing temporal modeling on the features after the convolution operation through a gated recurrent unit layer.
[0010] As a preferred embodiment of the energy decomposition method based on low-frequency data driven by the present invention, the step of outputting the operating status information of the target electrical appliance based on the time-series features includes extracting classification features from the time-series features to obtain a status feature representation. The state feature representation is activated by the Sigmoid activation function, and the probability value of the target electrical appliance being in the on state is output. Based on the comparison between the probability value and the learnable threshold, the operating status information of the target electrical appliance is determined.
[0011] As a preferred embodiment of the energy decomposition method based on low-frequency data driven by the present invention, the step of outputting the power consumption estimate of the target electrical appliance based on the time series features and the operating status information includes performing regression feature extraction on the time series features to obtain a preliminary power feature representation; Obtain the operating state information output by the state prediction branch; The operating status information is used as a gating signal to perform weighted adjustment on the preliminary power characteristic representation, resulting in a state-guided power characteristic representation; The state-guided power characteristic representation is processed by a regression layer to output an estimated power consumption value for the target appliance.
[0012] This preferred technical solution uses the operating status information output from the state prediction branch as a gating signal to weight and adjust the preliminary power characteristic representation in the power prediction branch, thus achieving explicit guidance of power prediction by state information. When the operating status information indicates that the target appliance is in the off state, the gating mechanism suppresses the contribution of the power characteristic to near zero; when the operating status information indicates that the target appliance is in the on state, the gating mechanism amplifies the contribution of the power characteristic and reverts to the specific energy consumption value. This state-guided power prediction mechanism ensures that the prediction results conform to the physical law that power approaches zero when the appliance is off and power reflects the actual energy consumption when the appliance is on, avoiding the contradictory situation where the state prediction indicates off but the power prediction value is too high, thereby improving the physical consistency and accuracy of the prediction.
[0013] As a preferred embodiment of the energy decomposition method based on low-frequency data driven by the present invention, the step of training the dual-branch neural network model through a joint loss function includes calculating the state classification loss term between the operating state information and the real state label. Calculate the power regression loss term between the estimated power consumption and the actual power label; Based on the value of the operating status information, the constraint loss term of the power consumption estimate is calculated. When the operating status information indicates that the target appliance is in the off state, the power consumption estimate is constrained to approach a set threshold. When the operating status information indicates that the target appliance is in the on state, the deviation between the estimated power consumption value and the actual power label is constrained. The joint loss function is obtained by weighting and combining the state classification loss term, the power regression loss term, and the constraint loss term. The parameters of the dual-branch neural network model are optimized based on the joint loss function.
[0014] As a preferred embodiment of the low-frequency data-driven energy decomposition method described in this invention, the dual-branch neural network model further includes a domain alignment layer. The dual-branch neural network model is trained using the joint loss function, and further includes: The domain alignment layer is applied to the feature output of the shared feature extraction layer to perform statistical alignment processing on the feature distributions from different data sources. Calculate the domain alignment loss term between feature distributions from different data sources; The domain alignment loss term is added to the joint loss function for weighted combination; The dual-branch neural network model is trained based on a joint loss function that includes the domain alignment loss term, so as to improve the generalization ability of the dual-branch neural network model in cross-scenario applications.
[0015] This preferred technical solution applies a domain alignment layer to the feature output of the shared feature extraction layer, statistically aligning the feature distributions from different residences or datasets. This ensures that features from different data sources possess consistent statistical properties in the intermediate feature space. Simultaneously, a domain alignment loss term is introduced into the joint loss function to constrain the differences in the covariance matrix of feature distributions from different data sources, achieving explicit alignment of feature distributions. Due to differences in sampling rates, appliance models, electricity usage habits, and electrical specifications among different residences or datasets, models trained using traditional methods experience significant performance degradation in new scenarios. This technical solution eliminates the impact of data distribution offset through a domain alignment mechanism, enabling the trained model to maintain stable appliance status recognition accuracy and power estimation precision even on unseen residences or datasets. This improves the model's cross-scenario generalization ability and reduces dependence on scene-specific labeled data.
[0016] This invention provides an energy splitting system based on low-frequency data.
[0017] To solve the above technical problems, the present invention provides the following technical solution: an energy decomposition system based on low-frequency data driving, comprising: a data acquisition module, used to acquire time series data of total load power at the power inlet; The preprocessing module is used to preprocess the total load power time series data to obtain a standardized input feature sequence; A two-branch neural network model, including a shared feature extraction layer, a state prediction branch, and a power prediction branch; The shared feature extraction layer is used to extract temporal features from the input feature sequence; The state prediction branch is used to output the operating state information of the target electrical appliance based on the time-series characteristics; The power prediction branch is used to output an estimated power consumption value of the target electrical appliance based on the time-series characteristics and the operating status information. The training module is used to train the dual-branch neural network model using a joint loss function, which includes a state classification loss term, a power regression loss term, and a constraint loss term used to constrain the consistency between the operating state information and the power consumption estimate.
[0018] The present invention provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the energy decomposition method based on low-frequency data drive.
[0019] The present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the energy decomposition method based on low-frequency data drive.
[0020] The beneficial effects of this invention are as follows: By using a dual-branch collaborative structure, the electrical appliance status identification and power estimation are realized simultaneously. The operating status information output by the status prediction branch can guide the prediction process of the power prediction branch, so that the prediction results conform to the physical law that "the power approaches zero when the appliance is off and the power reflects the actual energy consumption when the appliance is on", thus improving the physical consistency of the prediction.
[0021] By using a domain alignment layer to statistically align the feature distributions from different data sources and introducing a domain alignment loss term into the joint loss function, the trained model can maintain stable decomposition performance on unseen residences or datasets, thus improving the model's cross-scene generalization ability.
[0022] By introducing a constraint loss term into the joint loss function, the consistency between the operating state information and the power consumption estimate is constrained, thus avoiding the contradiction between the state prediction and the power prediction and improving the accuracy and reliability of the model prediction. Attached Figure Description
[0023] To more clearly illustrate the technical solutions of the embodiments of the present invention, 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 the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0024] Figure 1 This is a CNN network architecture diagram of an energy decomposition method based on low-frequency data, provided as an embodiment of the present invention.
[0025] Figure 2 This is a GRU network structure diagram of an energy decomposition method based on low-frequency data driven by an embodiment of the present invention. Detailed Implementation
[0026] To make the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the protection scope of the present invention.
[0027] Example 1, referring to Figures 1-2 This is one embodiment of the present invention, which provides an energy decomposition method based on low-frequency data driven, comprising: Step 1: Obtain the total load power time series data at the power inlet, and preprocess the total load power time series data to obtain a standardized input feature sequence; Step 2: Input the input feature sequence into a two-branch neural network model for feature extraction and prediction. The two-branch neural network model includes a shared feature extraction layer, a state prediction branch, and a power prediction branch. The shared feature extraction layer extracts temporal features from the input feature sequence. The state prediction branch outputs the operating state information of the target appliance based on the temporal features. The power prediction branch outputs an estimated power consumption value of the target appliance based on the temporal features and the operating state information. Step 3: Train the dual-branch neural network model using a joint loss function, which includes a state classification loss term, a power regression loss term, and a constraint loss term used to constrain the consistency between the operating state information and the power consumption estimate.
[0028] Specifically, traditional non-intrusive load decomposition methods have the following problems when processing low-frequency sampled data: First, methods that perform state identification or power estimation alone are prone to contradictory prediction results, such as determining that an appliance is in the off state but simultaneously predicting a high power consumption value, which does not conform to the physical laws of appliance operation; second, models trained for specific scenarios experience a significant performance degradation when applied to new residences or new datasets due to differences in sampling rate, appliance models, electricity usage habits, and voltage standards. This embodiment employs a dual-branch neural network model in step 2, enabling the state prediction branch and the power prediction branch to share the temporal features extracted by the feature extraction layer. By introducing operational state information into the power prediction process, the state information guides the power estimation. Simultaneously, in step 3, a constraint loss term constrains the consistency between the state information and the power estimate, ensuring that the power estimate approaches the background power threshold when the appliance is in the off state, and reflects the actual energy consumption when the appliance is in the on state, thus solving the problem of prediction results not conforming to physical laws.
[0029] The overall technical process of this embodiment is as follows: Step 1 involves time alignment, resampling, sliding window segmentation, and sample equalization of the total load power time series data to transform the original irregular sampled data into a standardized feature sequence suitable for neural network input, providing a unified data foundation for subsequent feature extraction and prediction. In Step 2, the shared feature extraction layer extracts time-series features that reflect the operating mode of electrical appliances from the input feature sequence. The state prediction branch determines the switching state of the target electrical appliance based on these time-series features and outputs a probability value. The power prediction branch, based on the time-series features and combined with the operating state information output by the state prediction branch, adjusts the power features through a gating mechanism and outputs a power consumption estimate, achieving collaborative prediction between the two branches. Step 3 trains the model using a joint loss function. The state classification loss term optimizes the accuracy of state recognition, the power regression loss term reduces the error of power estimation, and the constraint loss term enforces physical consistency constraints between the state information and the power estimate, enabling the model to learn a prediction strategy that conforms to the actual operating rules of electrical appliances during training. Through the coordinated operation of the above three steps, this embodiment achieves accurate decomposition of electrical appliance energy consumption under low-frequency sampling conditions.
[0030] Example 2, refer to Figures 1-2 As one embodiment of the present invention, based on the previous embodiment, a low-frequency data-driven energy decomposition method is provided, comprising: Step 1: Obtain the total load power time series data at the power inlet, and preprocess the total load power time series data to obtain a standardized input feature sequence, including the following steps A1-A4: A1: Time-align and resample the total load power time series data to obtain a power series with fixed time intervals; A2: The power sequence is segmented by a sliding window to obtain multiple power window samples; A3: Balance the number of samples representing the on and off states of the target electrical appliance in the power window sample; A4: Normalize the power window samples to obtain the standardized input feature sequence.
[0031] In this embodiment of the application, in A1, time alignment and resampling are achieved by: firstly, uniformly mapping the total load power time series data to a reference sequence with a resolution of 1 second, and then converting the reference sequence with a resolution of 1 second into a power sequence with equal intervals of 8 seconds through neat resampling, thereby obtaining the power sequence with the fixed time interval.
[0032] In an optional implementation, in A1, time alignment and resampling can be achieved by: aligning the timestamps of the total load power time series data, interpolating data with inconsistent sampling times to a unified time reference, and then converting the aligned data into a power series with fixed time intervals through a resampling operation.
[0033] In another alternative implementation, in A1, time alignment and resampling can also be achieved by: performing timestamp normalization on the total load power time series data, identifying and processing missing data segments in the time series, and then performing a resampling operation according to the target time resolution to obtain the power series at the fixed time interval.
[0034] In this embodiment of the application, in A2, the power sequence is segmented by a sliding window: the window length of the sliding window is set according to the typical power consumption behavior of the target electrical appliance, and the power sequence is segmented by a sliding method with a fixed step size to generate multiple power window samples.
[0035] In an optional implementation, in A2, segmenting the power sequence using a sliding window can be achieved by: setting a uniform window length and step size, and performing a sliding segmentation operation on the power sequence according to the window length and step size to obtain multiple power window samples.
[0036] In another optional implementation, in A2, segmenting the power sequence by sliding window can also be achieved by: determining the position of the sliding window based on the changes in power values in the power sequence, dynamically adjusting the starting position and length of the window, segmenting the power sequence, and obtaining multiple power window samples.
[0037] In this embodiment, in step 2, the dual-branch neural network model employs a one-dimensional convolutional neural network as the backbone network for the shared feature extraction layer. The one-dimensional convolutional neural network includes multiple convolutional layers and bidirectional gated recurrent unit layers. The multiple convolutional layers are used to extract local temporal features, and the bidirectional gated recurrent unit layers are used to model temporal dependencies. Based on the temporal features, the state prediction branch outputs the probability value of the target appliance being in the on state through a fully connected layer and a sigmoid activation function. The power prediction branch uses the probability value as a gating signal to weight and adjust the power features, and then outputs an estimated power consumption value through a regression layer.
[0038] In an optional implementation, in step 2, the dual-branch neural network model can be achieved by: using a gated recurrent unit network as the backbone network for the shared feature extraction layer, wherein the gated recurrent unit network includes convolutional layers and multiple gated recurrent unit layers, the convolutional layers are used for preliminary feature extraction, and the gated recurrent unit layers are used for temporal modeling; the state prediction branch and the power prediction branch process the temporal features through their respective fully connected layers, the state prediction branch outputs operating state information, and the power prediction branch combines the operating state information to output a power consumption estimate.
[0039] In another optional implementation, in step 2, the dual-branch neural network model can also: the shared feature extraction layer includes a multi-scale convolutional structure, and features at different time scales are extracted in parallel by convolutional layers with different kernel sizes; the state prediction branch determines the operating state information through a learnable threshold module after outputting the probability value; and the power prediction branch, after receiving the operating state information, performs gating adjustment by feature concatenation or element-wise multiplication, and outputs an estimated power consumption value.
[0040] In step 2, the shared feature extraction layer is used to extract temporal features from the input feature sequence, including the following steps B1-B2: B1: Extract local temporal features by performing convolution operations on the input feature sequence through multiple one-dimensional convolutional layers; B2: Temporal modeling is performed on the features after the convolution operation through a gated recurrent unit layer to obtain the temporal features.
[0041] In step 2, the state prediction branch outputs the operating state information of the target electrical appliance based on the time-series characteristics, including the following steps C1-C3: C1: Perform classification feature extraction on the time-series features to obtain state feature representation; C2: Activate the state feature representation using the Sigmoid activation function and output the probability value that the target electrical appliance is in the on state; C3: Based on the comparison result between the probability value and the learnable threshold, determine the operating status information of the target electrical appliance.
[0042] In step 2, the power prediction branch outputs an estimated power consumption value for the target appliance based on the timing characteristics and the operating status information, including the following steps D1-D4: D1: Perform regression feature extraction on the time-series features to obtain a preliminary power feature representation; D2: Obtain the operating state information output by the state prediction branch; D3: Using the operating status information as a gating signal, the preliminary power characteristic representation is weighted and adjusted to obtain a state-guided power characteristic representation; D4: The state-guided power characteristic representation is processed by a regression layer to output the power consumption estimate of the target appliance.
[0043] Step 3: Training the dual-branch neural network model using the joint loss function includes the following steps E1-E6: E1: Calculate the state classification loss term between the running state information and the actual state label; E2: Calculate the power regression loss term between the estimated power consumption and the actual power label; E3: Based on the value of the operating status information, calculate the constraint loss term of the power consumption estimate. When the operating status information indicates that the target appliance is in the off state, constrain the power consumption estimate to approach a set threshold. E4: When the operating status information indicates that the target appliance is in the on state, constrain the deviation between the estimated power consumption and the actual power label; E5: The state classification loss term, the power regression loss term, and the constraint loss term are weighted and combined to obtain the joint loss function; E6: Optimize the parameters of the dual-branch neural network model based on the joint loss function.
[0044] In this embodiment, in step 3, the joint loss function is calculated as follows: the state classification loss term uses binary cross-entropy loss to calculate the deviation between the operating state information and the true state label; the power regression loss term uses mean squared error loss to calculate the deviation between the power consumption estimate and the true power label; the constraint loss term is calculated using soft gating consistency, with the operating state information as a weighting coefficient. When the operating state information is close to 0, the constraint power consumption estimate approaches a set threshold; when the operating state information is close to 1, the deviation between the constraint power consumption estimate and the true power label is considered. The state classification loss term, the power regression loss term, and the constraint loss term are linearly weighted and combined using preset weighting coefficients to obtain the joint loss function. A stochastic gradient descent optimizer is used to optimize the parameters of the dual-branch neural network model based on the joint loss function.
[0045] In an optional implementation, in step 3, the joint loss function can be obtained by: using a weighted binary cross-entropy loss for the state classification loss term, assigning different weight coefficients to the samples representing the on and off states respectively; using log-cosh loss for the power regression loss term to calculate the deviation between the power consumption estimate and the true power label; calculating the constraint loss term in the same way as in the implementation of this application; weighting and combining the state classification loss term, the power regression loss term, and the constraint loss term to obtain the joint loss function; and using an adaptive moment estimation optimizer to optimize the parameters of the dual-branch neural network model based on the joint loss function.
[0046] In another optional implementation, in step 3, the joint loss function can also be implemented by: calculating the state classification loss term and the power regression loss term in the same way as in the implementation of this application; using a piecewise constraint method for the constraint loss term, calculating the squared error of the power consumption estimate exceeding a set threshold when the operating status information indicates the off state, and calculating the absolute error between the power consumption estimate and the true power label when the operating status information indicates the on state; weighting the state classification loss term, the power regression loss term, and the constraint loss term, wherein the weight coefficient of the constraint loss term gradually increases from a small value to a preset value during training; and optimizing the parameters of the dual-branch neural network model based on the joint loss function.
[0047] Furthermore, the dual-branch neural network model also includes a domain alignment layer. Training the dual-branch neural network model using the joint loss function further includes: The domain alignment layer is applied to the feature output of the shared feature extraction layer to perform statistical alignment processing on the feature distributions from different data sources. Calculate the domain alignment loss term between feature distributions from different data sources; The domain alignment loss term is added to the joint loss function for weighted combination; The dual-branch neural network model is trained based on a joint loss function that includes the domain alignment loss term, so as to improve the generalization ability of the dual-branch neural network model in cross-scenario applications.
[0048] Specifically, this invention proposes two deep learning architectures: such as Figure 1 As shown, one type is based on convolutional neural networks (CNNs), such as Figure 2As shown, another type is based on Gated Recurrent Units (GRUs). Both employ a dual-branch collaborative structure combining state branches and power branches, enabling both the classification of appliance operating states and the regression estimation of average power. Furthermore, the interaction constraints between state and power enhance physical consistency. In cross-domain application scenarios, CNNs can effectively capture local power features at different time scales, while GRUs possess stronger temporal modeling and memory capabilities, making them more suitable for cross-home migration and edge deployment under low-frequency conditions.
[0049] In the method of this invention, the load data first needs to be systematically acquired and preprocessed to ensure the stability and cross-scenario transferability of subsequent model training and inference.
[0050] Low-frequency total active power data is collected at the power inlet on the user side (such as the location of a smart meter), with a sampling period ranging from 1 to 60 seconds. Optional auxiliary electrical parameters such as voltage, current, and apparent power can also be collected to support subsequent multimodal feature fusion and robustness analysis.
[0051] Since different datasets or acquisition devices may have inconsistent sampling frequencies and timestamps, this invention first maps the original data to a 1-second resolution reference sequence, and then converts it into an 8-second equally spaced signal through neat resampling. This ensures the input consistency between different data sources and also takes into account the application scenarios of low-frequency sampling.
[0052] Normalization operations, such as subtracting the mean and dividing by the standard deviation, are performed on the power sequence within each sliding window to make the data distribution more concentrated, which helps the neural network converge faster. To eliminate isolated spikes and interference in the meter data, noise reduction techniques such as median filtering or low-pass filtering are further introduced to ensure the smoothness and stability of the input features.
[0053] In real-world electricity usage scenarios, most appliances are kept off for extended periods, leading to a severe imbalance in training samples. Directly using these samples for modeling can easily result in a bias where the model "always predicts off." This invention addresses this by employing methods such as random downsampling of the majority class or cost-sensitive sampling to ensure a near 1:1 ratio of "on" to "off" samples, thereby improving the model's recognition performance in the minority class (appliance on).
[0054] To address the different duty cycles and operating cycles of various electrical appliances, this invention sets an appropriate sliding window length based on the typical power consumption behavior of the target appliance. For example, microwave ovens typically have short operating times, so the window can be set to approximately 12 minutes; refrigerators, on the other hand, have longer compressor operating cycles, so the window length can be set to approximately 1.8 hours. Training, validation, and test sets are generated using a fixed-step sliding window method to capture the complete activation patterns of the electrical appliances.
[0055] After data preprocessing, this invention proposes a dual-branch collaborative transferable neural network structure, which is the core innovation that distinguishes it from existing technologies.
[0056] This invention provides two types of backbone options, namely one-dimensional convolutional neural networks (CNNs), such as... Figure 1 As shown, with the gated loop unit (GRU), as Figure 2 As shown. The former excels at capturing local temporal features and multi-scale power patterns, making it suitable for large-scale data analysis and cloud deployment; the latter has fewer parameters, possesses excellent temporal memory and modeling capabilities, and is particularly suitable for low-latency inference on edge devices.
[0057] In the network output layer design, a parallel structure of "state branch plus power branch" is adopted. The state branch is used to output the probability value (between 0 and 1) of the appliance being on / off, and the power branch is used to predict the average power consumption of the appliance. Unlike traditional methods, this invention achieves explicit guidance of the regression results by feeding back the state estimation results to the power estimation branch through information interaction between the feature layer and the decision layer. This design ensures that the prediction process conforms to the physical logic that "power consumption only occurs when the appliance is on," thereby improving the overall accuracy and robustness.
[0058] Explicit guidance and transferability: The interaction between the state branch and the power branch not only improves prediction performance within a single dataset, but more importantly, enhances the model's transferability across datasets and households. When the network faces new residences or datasets, state information can serve as an auxiliary signal, helping power estimation quickly adapt to the new load distribution and effectively reducing performance degradation caused by data distribution shifts.
[0059] To fully extract the time-series load characteristics of electrical appliances, this invention provides two types of backbone network structures: The CNN backbone consists of multiple layers of one-dimensional convolutions (1DConv), nonlinear activation functions, and stride / pooling control units. The convolutional kernels can extract short- and medium-range feature patterns from local time windows, such as the pulse characteristics of a microwave oven's rapid switching and the phased power curve of a dishwasher. Multi-scale dilated convolutions (DilatedConv) are introduced in the mid-to-late network to expand the receptive field without significantly increasing computation, covering long-term appliance behavior, such as the periodic start-stop of a refrigerator compressor. This design captures both transient abrupt features and models long-term dependencies, a core advantage of low-frequency NILM tasks.
[0060] The GRU backbone employs a lightweight gated recurrent unit (GRU) sequence modeling structure. Compared to traditional LSTM, GRU maintains temporal memory capabilities while requiring fewer parameters and offering higher computational efficiency, making it particularly suitable for edge deployments or rapid fine-tuning in small-sample scenarios. Through the gating mechanism of GRU units, the network can "remember" the operating modes of appliances over longer time series, avoiding the vanishing gradient problem and effectively extracting long-cycle load signals from appliances such as refrigerators and washing machines.
[0061] Two types of backbones can be flexibly selected according to the application environment: CNN backbones are suitable for centralized computing and large-scale parallel processing in the cloud, while GRU backbones are suitable for real-time recognition and low-power deployment at the edge.
[0062] Following the shared feature extraction layer, this invention designs a state classification branch, whose main function is to determine the operating state (on / off) of the appliance within a given time window: Classification layer design: On top of the temporal features extracted from the backbone, several convolutional / GRU and fully connected layers are connected, and the probability value (0–1) of the appliance being turned on is output through the Sigmoid function. This probabilistic output not only provides binary classification results, but also reflects the uncertainty of prediction.
[0063] Temperature calibration Sigmoid layer: Based on the traditional Sigmoid, a learnable temperature parameter is added to calibrate the output probability, making the probability value more consistent with the statistical distribution of actual electrical operation, thereby enhancing the interpretability of the prediction.
[0064] Learnable Threshold Module (ATL): Unlike existing methods that rely on manually setting fixed power thresholds, this invention introduces a lightweight learnable module that adaptively learns the "power-on discrimination threshold" for different scenarios using a small number of parameters. This module can automatically adjust the threshold for different residential appliance models, operating environments, and power grid conditions, thereby enhancing cross-domain adaptability.
[0065] The task of the power branch is to predict the average power of the appliance within a time window.
[0066] Linear regression output: A linear activation function is used in the regression head to ensure that the output power value has no upper limit constraint in theory, which is suitable for predicting continuous values of real energy consumption.
[0067] Residual connections: Introducing residual structures into deep regression modules prevents gradient decay or explosion during deep network training and improves the stability of power prediction.
[0068] State-Guided Gated Fusion (SGRF): This is one of the key innovations of this invention. It involves controlling the power-on probability of state branches. For p∈[0,1], a power branch is introduced as a "soft gating" mechanism. This is achieved by weighting the power prediction channel-by-channel or concatenating it with classification features, thus establishing the dependence of power prediction on the state outcome. For example, when p approaches 0, the power prediction is explicitly suppressed to near zero; when p approaches 1, the power prediction is amplified and regressed to a specific value based on the load pattern. This mechanism ensures that the prediction conforms to the physical consistency of "first determining whether the appliance is running, then estimating the operating intensity," effectively avoiding contradictions between the state and power prediction.
[0069] Due to significant differences in appliance models, sampling frequencies, and voltage standards across different countries, regions, and households, data distribution exhibits substantial shifts, making it difficult for traditional models to maintain stable performance across datasets. To address this issue, this invention introduces a cross-domain statistical alignment layer (DSN) into several feature layers: Principle: Using a normalization method similar to InstanceNorm or AdaIN, an explicit affine transformation is performed on the feature distributions of different residential inputs to align them in the intermediate feature space.
[0070] Results: It achieves consistent feature distribution across different scenarios without the need for complex adversarial training or additional domain discriminators, significantly improving the model's transferability and generalization ability.
[0071] To ensure the convergence stability of the network under short training rounds and cross-domain transfer, this invention introduces multiple regularization mechanisms during network training and inference: ReLU activation + Dropout: Avoid gradient vanishing and overfitting problems, and maintain training stability.
[0072] L2 regularization and early stopping strategy: effectively control model complexity in a small number of training epochs and prevent overfitting of training data.
[0073] Post-processing at the prediction end: Add minimum duration constraints and edge smoothing strategies to the output state sequence to eliminate short-term jitter or isolated false alarms, making the results more consistent with the actual operation of electrical appliances.
[0074] Joint Loss and Optimization Strategy The following provides the specific mathematical expression, physical meaning, and recommended optimization / training details (including sampling / regularization / scheduling and pseudocode) for each term of the joint loss function. The goal is to ensure the coupling, consistency constraints, cross-domain alignment, and training stability of state classification and power regression, facilitating the implementation of transferable and robust models in low-frequency NILM scenarios.
[0075] Specifically: Input sample index: (Small batch) Target power (actual value): Target status label (0 / 1): (For example, obtained from a sub-table or manually labeled by means of a threshold) Model output: State probabilities Power prediction Main loss weights: (Corresponding to state, power, consistency, domain alignment, and L2 regularization respectively) Used to train state branches, so that Close to reality : If the samples within a batch are imbalanced, modify the loss function above to a weighted BCE: in (On) and (Off) can be set to be inversely proportional to the class frequency, or dynamically weighted using the focal-loss style.
[0076] For the CNN backbone, use MSE (mean squared error): For GRU backbones (more robust to outliers), use log-cosh: (log-cosh approximates MSE when the error is small and MAE when the error is large, making it more robust.) This mandatory model satisfies physical consistency: when the state probability is small (close to 0), the power prediction should approximate the background noise; when the state probability is large (close to 1), the power prediction should approximate the true power. We recommend using soft-gated consistency. The specific forms that can be selected are: When the model predicts that the appliance is "off" but its power consumption is higher than a small threshold A penalty is applied when the background noise level is at an upper limit, such as 5–10W.
[0077] Complete example: This can significantly reduce the contradiction of "state prediction is off but power prediction is high", and enhance the physical interpretability.
[0078] To improve cross-residential / cross-dataset transferability, CORAL (CORrelationALignment) is applied to the intermediate feature F. The formula is: Let the source domain batch feature matrix... Target domain features Calculate the covariance matrix , CORAL loss: in: Similarly, calculate This loss term aligns with second-order statistics without adversarial training, making it robust and easy to implement.
[0079] L2 weight decay: Used for all trainable weight matrices .
[0080] Combine the items: For CNN: For GRU: initial: , , , , Feasible optimization strategy: First train for several rounds using only After basic convergence, gradually increase and This is to avoid alignment / consistency terms interfering with feature learning in the early stages of training.
[0081] If high state accuracy is found but poor regression is observed, the value can be temporarily increased. If a large number of cases occur where the status is "off but power is high", the power consumption can be increased. and Adjustment.
[0082] CNN: Optimizer SGD (momentum=0.9), initial lr=1e-2, weightdecay= .
[0083] GRU: Optimizer Adam (lr=1e-3).
[0084] Batch and Balance: batchsize=32; ensure that the on / off ratio of each batch is approximately 1:1 (through online sampling or batch-level resampling).
[0085] Training epochs: 10–50 epochs, with early stopping (patience=2–5, monitoring and validating lumped loss or F1 / RMSE).
[0086] Learning rate scheduling: lr*=0.1 when the validation loss stops decreasing.
[0087] Gradient clipping: clip-norm=1.0–5.0.
[0088] Checkpoints and Recovery: Save the optimal model on the validation set and record individual optimal points for state / regression in case of shifts in different tasks.
[0089] Data from multiple residences are used for joint training, while several residences / datasets are kept completely isolated for validation to ensure no scene migration is observed; both training and validation data undergo sample equalization to eliminate class bias.
[0090] When deployed to new residential buildings, freezing the first few layers of the backbone and fine-tuning only the DSN layer, ATL threshold module, and end header with 3–5 rounds of small samples can further improve the accuracy of specific sites.
[0091] During the online inference phase, a sliding window with a set step size is used to estimate the fusion power using the weighted average of overlapping regions, and the state sequence is output based on the threshold after temperature calibration.
[0092] At the edge, GRU backbone or pruned / quantized CNN is preferred; The entire CNN backbone can be deployed in the cloud to serve a large number of users and perform periodic model updates and distribution.
[0093] Example 3, an embodiment of the present invention, provides an energy decomposition method based on low-frequency data. To verify the beneficial effects of the present invention, scientific demonstration is conducted through experiments: This demonstrates the network's ability to transfer between datasets, with tests showing its ability to handle completely unknown appliances, operating cycles, and consumption. First, the results are presented when the model is trained using only REFIT houses and tested on house 2 from the REFIT dataset. This is shown in Table 1, where a performance drop in MW and DW can be observed due to the different brands / models of appliances between UK and US houses. Similar conclusions can be drawn from Table 2, which shows the results when the model is trained using only REFIT houses and tested on a single REFIT house.
[0094] Please note that in Table 2, the accuracy for refrigerators is missing due to the choice of window size; that is, in the REDD dataset, for this window size, there is always one refrigerator in the open state, meaning that the transferability from REDD to REFIT tends to predict that the refrigerator is always open. Table 3 shows the results of training on the REFIT house and testing on the unseen UK-DALE house 1. The UK-DALE dataset is similar to the REFIT dataset because it is also based in the UK and therefore has similar device types.
[0095] Table 1 shows the training performed on REFIT houses and the testing performed on houses 2, which were not seen in REDD.
[0096] Table 2 shows the training performed on a REDD house and the testing performed on a house 2 not seen in REFIT.
[0097] Table 3 shows the training performed in the REFIT house and the testing performed in the unseen UKDALE house 1.
[0098] The expression for the evaluation index of the load decomposition results is as follows: Example 4 is an embodiment of the present invention. This embodiment provides an energy decomposition system based on low-frequency data, including: a data acquisition module for acquiring time series data of total load power at the power inlet; The preprocessing module is used to preprocess the total load power time series data to obtain a standardized input feature sequence; A two-branch neural network model, including a shared feature extraction layer, a state prediction branch, and a power prediction branch; The shared feature extraction layer is used to extract temporal features from the input feature sequence; The state prediction branch is used to output the operating state information of the target electrical appliance based on the time-series characteristics; The power prediction branch is used to output an estimated power consumption value of the target electrical appliance based on the time-series characteristics and the operating status information. The training module is used to train the dual-branch neural network model using a joint loss function, which includes a state classification loss term, a power regression loss term, and a constraint loss term used to constrain the consistency between the operating state information and the power consumption estimate.
[0099] Traditional non-intrusive load decomposition methods often employ a single-branch structure, performing only state classification or power reconstruction, which can easily lead to contradictions between state judgments and power estimates in the prediction results. This embodiment utilizes a dual-branch neural network model to achieve collaborative operation between the state prediction branch and the power prediction branch. The power prediction branch uses operating state information as a gating signal to adjust power characteristics, achieving explicit guidance of power prediction by state information. Simultaneously, the constraint loss term in the joint loss function constrains the consistency between the operating state information and the power consumption estimate. When the operating state information indicates that the target appliance is in an off state, the power consumption estimate is constrained to approach a set threshold; when the operating state information indicates that the target appliance is in an on state, the power consumption estimate is constrained to maintain consistency with the actual power label. This ensures that the prediction results conform to the physical logic of appliance operation, improving the prediction robustness in weak signal scenarios and scenarios with multiple overlapping appliances.
[0100] The shared feature extraction layer of the dual-branch neural network model offers two backbone network implementations. When using a one-dimensional convolutional neural network as the backbone, local temporal features are extracted through multiple convolutional layers, combined with bidirectional gated recurrent unit layers to model temporal dependencies. This structure is suitable for cloud deployments and large-scale data processing scenarios. When using a gated recurrent unit network as the backbone, temporal modeling is achieved through a lightweight network structure, resulting in fewer parameters and higher computational efficiency, making it suitable for edge deployments and real-time inference scenarios. Both backbone networks can extract temporal features reflecting the operating mode of electrical appliances from the input feature sequence, achieving stable decomposition performance with fewer training epochs, and do not require training with synthetic data.
[0101] The preprocessing step, which balances the power window samples, addresses the severe imbalance between the number of on-state and off-state samples in practical applications. Since most appliances remain off for extended periods during the monitoring cycle, directly using the original sample distribution for training would lead to a bias in the bi-branch neural network model, consistently predicting the off state. By randomly downsampling the majority class or using cost-sensitive sampling, the ratio of samples representing the on-state to the off state is nearly balanced, preventing overfitting of the model to the majority class. Simultaneously, normalizing the power window samples eliminates the influence of differences in absolute power levels between different windows, allowing the bi-branch neural network model to focus on relative patterns of power change. This maintains consistency in data processing during training and testing, ensuring the comparability of evaluation metrics across different scenarios.
[0102] The dual-branch neural network model trained in this embodiment maintains stable state recognition accuracy and power estimation precision even on unseen residences or datasets. Due to differences in sampling rates, appliance models, electricity usage habits, and voltage standards among different residences or datasets, models trained using traditional methods often experience significant performance degradation in new scenarios, requiring re-collection and retraining of labeled data. This embodiment trains the dual-branch neural network model using a joint loss function, enabling the learned prediction strategy to generalize across scenarios. When deployed to new residences, it eliminates the need for re-labeling large amounts of data, significantly reducing the labor and time costs of practical applications.
[0103] In practical deployments, multi-task distillation can be used to further reduce model complexity at the edge. Specifically, a two-branch neural network model with a one-dimensional convolutional neural network as the backbone is used as the teacher model in the cloud, and a two-branch neural network model with a gated recurrent unit network as the backbone is used as the student model. Knowledge distillation transfers the knowledge learned by the teacher model to the student model, allowing the student model to achieve prediction performance close to that of the teacher model while maintaining a lightweight structure. Furthermore, the window length and step size of the sliding window can be dynamically adjusted based on the online estimated appliance duty cycle. A shorter window length is used for appliances with shorter operating cycles, and a longer window length is used for appliances with longer operating cycles, improving adaptability to appliances with different operating cycles. After outputting the prediction results, minimum duration and minimum interval constraints can be introduced to post-process the state prediction sequence, filtering out state changes with excessively short durations and reducing false detections and jitter caused by noise or short-term fluctuations. For scenarios that require simultaneous monitoring of multiple electrical appliances, the corresponding sliding window parameters and output layer parameters of the dual-branch neural network model can be maintained separately according to the appliance category. When a new type of appliance is connected, only the output layer parameters for that appliance need to be trained, without the need to retrain the shared feature extraction layer, which improves the scalability and maintenance efficiency of the system.
[0104] This embodiment also provides an electronic device applicable to an energy decomposition method based on low-frequency data, comprising: a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to implement the energy decomposition method based on low-frequency data as proposed in the above embodiment.
[0105] This embodiment also provides a storage medium storing a computer program that, when executed by a processor, implements an energy decomposition method based on low-frequency data drive as proposed in the above embodiments.
[0106] The storage medium proposed in this embodiment and the energy decomposition method based on low-frequency data driving proposed in the above embodiments belong to the same inventive concept. Technical details not described in detail in this embodiment can be found in the above embodiments, and this embodiment has the same beneficial effects as the above embodiments.
[0107] Based on the above description of the implementation methods, those skilled in the art can clearly understand that the present invention can be implemented using software and necessary general-purpose hardware, and of course, it can also be implemented using hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as a computer floppy disk, read-only memory (ROM), random access memory (RAM), flash memory, hard disk, or optical disk, etc., including several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods of the various embodiments of the present invention.
[0108] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. An energy decomposition method based on low-frequency data, characterized in that: include, The total load power time series data at the power inlet is acquired, and the total load power time series data is preprocessed to obtain a standardized input feature sequence; The input feature sequence is input into a dual-branch neural network model for feature extraction and prediction. The dual-branch neural network model includes a shared feature extraction layer, a state prediction branch, and a power prediction branch. The shared feature extraction layer is used to extract temporal features from the input feature sequence; The state prediction branch outputs the operating state information of the target electrical appliance based on the time-series characteristics; The power prediction branch outputs an estimated power consumption value for the target electrical appliance based on the timing characteristics and the operating status information. The dual-branch neural network model is trained using a joint loss function, which includes a state classification loss term, a power regression loss term, and a constraint loss term used to constrain the consistency between the operating state information and the power consumption estimate.
2. The energy decomposition method based on low-frequency data as described in claim 1, characterized in that: The preprocessing of the total load power time series data includes time alignment and resampling of the total load power time series data to obtain a power series with fixed time intervals; The power sequence is segmented by a sliding window to obtain multiple power window samples; The number of samples representing the on and off states of the target electrical appliance in the power window sample is balanced. The power window samples are normalized to obtain the standardized input feature sequence.
3. The energy decomposition method based on low-frequency data as described in claim 2, characterized in that: The step of extracting temporal features from the input feature sequence includes performing convolution operations on the input feature sequence through multiple one-dimensional convolutional layers to extract local temporal features. The temporal features are obtained by performing temporal modeling on the features after the convolution operation through a gated recurrent unit layer.
4. The energy decomposition method based on low-frequency data as described in claim 3, characterized in that: The output of the target electrical appliance's operating status information based on the time-series characteristics includes, The temporal features are subjected to classification feature extraction to obtain state feature representation; The state feature representation is activated by the Sigmoid activation function, and the probability value of the target electrical appliance being in the on state is output. Based on the comparison between the probability value and the learnable threshold, the operating status information of the target electrical appliance is determined.
5. The energy decomposition method based on low-frequency data as described in claim 4, characterized in that: The step of outputting the power consumption estimate of the target electrical appliance based on the time series features and the operating status information includes extracting regression features from the time series features to obtain a preliminary power feature representation. Obtain the operating state information output by the state prediction branch; The operating status information is used as a gating signal to perform weighted adjustment on the preliminary power characteristic representation, resulting in a state-guided power characteristic representation; The state-guided power characteristic representation is processed by a regression layer to output an estimated power consumption value for the target appliance.
6. The energy decomposition method based on low-frequency data as described in claim 5, characterized in that: The step of training the dual-branch neural network model using a joint loss function includes calculating a state classification loss term between the running state information and the real state label. Calculate the power regression loss term between the estimated power consumption and the actual power label; Based on the value of the operating status information, the constraint loss term of the power consumption estimate is calculated. When the operating status information indicates that the target appliance is in the off state, the power consumption estimate is constrained to approach a set threshold. When the operating status information indicates that the target appliance is in the on state, the deviation between the estimated power consumption value and the actual power label is constrained. The joint loss function is obtained by weighting and combining the state classification loss term, the power regression loss term, and the constraint loss term. The parameters of the dual-branch neural network model are optimized based on the joint loss function.
7. The energy decomposition method based on low-frequency data as described in claim 6, characterized in that: The dual-branch neural network model further includes a domain alignment layer. Training the dual-branch neural network model using the joint loss function also includes: The domain alignment layer is applied to the feature output of the shared feature extraction layer to perform statistical alignment processing on the feature distributions from different data sources. Calculate the domain alignment loss term between feature distributions from different data sources; The domain alignment loss term is added to the joint loss function for weighted combination; The dual-branch neural network model is trained based on a joint loss function that includes the domain alignment loss term, so as to improve the generalization ability of the dual-branch neural network model in cross-scenario applications.
8. An energy splitting system based on low-frequency data, employing the energy splitting method based on low-frequency data as described in any one of claims 1 to 7, characterized in that, include: The data acquisition module is used to acquire time series data of total load power at the power inlet. The preprocessing module is used to preprocess the total load power time series data to obtain a standardized input feature sequence; A two-branch neural network model, including a shared feature extraction layer, a state prediction branch, and a power prediction branch; The shared feature extraction layer is used to extract temporal features from the input feature sequence; The state prediction branch is used to output the operating state information of the target electrical appliance based on the time-series characteristics; The power prediction branch is used to output an estimated power consumption value of the target electrical appliance based on the time-series characteristics and the operating status information. The training module is used to train the dual-branch neural network model using a joint loss function, which includes a state classification loss term, a power regression loss term, and a constraint loss term used to constrain the consistency between the operating state information and the power consumption estimate.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the energy decomposition method based on low-frequency data drive according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the energy decomposition method based on low-frequency data drive according to any one of claims 1 to 7.