Power supply device and method for smart home equipment power supply
By using technical means of feature extraction, load analysis and power supply strategy optimization in the power supply power supply system of smart home equipment, the problem of inefficiency of existing power supply control methods is solved, and more efficient and accurate power optimization and electricity bill management are achieved.
Patent Information
- Application Number
- CN202510331690.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-20
- Publication Date
- 2025-05-09
- Estimated Expiration
- 2045-03-20
AI Technical Summary
The existing power supply power control methods are difficult to achieve accurate power optimization and cannot adapt to dynamic electricity price changes and load demands, resulting in low power supply efficiency.
Power supply devices including long-term feature extraction module, short-term feature extraction module, load analysis module, reward calculation module and power supply control module are used to optimize power supply strategies through technical means such as deep downsampling, sparse attention extraction, gated feature fusion and autoregressive decoding.
It improves the efficiency of power supply, adapts to dynamic electricity price changes and load demands, achieves more accurate power optimization, and reduces electricity and electricity consumption.
Smart Images

Figure CN119966012A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of power supply control, and in particular to a power supply device and method for a smart home device power supply. Background Art
[0002] Smart home devices refer to household appliances or electronic devices with functions such as networking, automatic control, and remote management. They usually rely on the Internet of Things and artificial intelligence for operation and optimization. The power supply of smart home devices refers to the energy system that powers smart home devices. In order to improve user comfort and optimize electricity costs, the power supply of smart home devices needs to be controlled.
[0003] Most of the existing power supply control methods are based on user settings, that is, they rely on the user to control the output power supply of the power supply through manual control, timing control or remote control. However, in actual application, the power supply control method based on user settings is more dependent on user operation, and it is difficult to achieve accurate power optimization, and it cannot adapt to dynamic changes in electricity prices and load demands, which may lead to low efficiency when the power supply is provided. Summary of the invention
[0004] The present invention provides a power supply device and method for a smart home device power supply, the main purpose of which is to solve the problem of low efficiency when supplying power.
[0005] To achieve the above object, the present invention provides a power supply device for a smart home device power supply, the device comprising a long-term feature extraction module, a short-term feature extraction module, a load analysis module, a reward calculation module and a power supply control module, wherein: A long-term feature extraction module is used to obtain the historical load data sequence of the smart home device, and perform deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain the long-term load time series feature; A short-term feature extraction module is used to perform window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series features; The load analysis module is used to perform gated feature fusion and autoregressive decoding on the long-term load time series characteristics and the short-term load time series characteristics to obtain an analysis load data sequence, wherein the load analysis module, when performing gated feature fusion and autoregressive decoding on the long-term load time series characteristics and the short-term load time series characteristics to obtain an analysis load data sequence, includes: performing key vector mapping on the long-term load time series characteristics to obtain a long-term key feature; performing query vector mapping on the short-term load time series characteristics to obtain a short-term query feature; and performing gated feature fusion on the long-term load time series characteristics and the short-term load time series characteristics according to the long-term key feature and the short-term query feature using the following gated fusion algorithm to obtain long and short load time series characteristics: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is an element-by-element multiplication symbol; autoregressive decoding is performed on the long and short load time series characteristics to obtain an analysis load data sequence; A reward calculation module, used to obtain an initial power supply strategy, and calculate the power incentive loss corresponding to the initial power supply strategy according to a pre-acquired stepped electricity price table and the analyzed load data sequence; The power supply control module is used to perform differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, and supply power to the smart home device according to the updated power supply strategy.
[0006] Optionally, when the long-term feature extraction module performs deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain the long-term load time series feature, it includes: Performing high-dimensional space projection on the historical load data sequence to obtain a historical load feature sequence; Position encoding is performed on the historical load characteristic sequence to obtain a coded load characteristic sequence; Performing deep convolution on the encoded load feature sequence to obtain a deep load feature sequence group; Performing point-by-point convolution on the deep load feature sequence group to obtain a convolution load feature sequence; Sparse attention extraction is performed on the convolutional load feature sequence to obtain long-term load time series features.
[0007] Optionally, when the long-term feature extraction module performs sparse attention extraction on the convolution load feature sequence to obtain the long-term load time series feature, it includes: Performing attention feature projection on the convolution load feature sequence to obtain a convolution query feature matrix, a convolution key feature matrix, and a convolution value feature matrix; The divergence information increment set corresponding to the convolution query feature matrix is calculated according to the convolution key feature matrix using the following divergence information increment algorithm: in, refers to the convolution query feature matrix The row feature vector is the convolution key feature matrix The attention scores of the row feature vectors, , is the feature index, is the exponential function symbol, refers to the convolution query feature matrix The The row eigenvector, refers to the convolution key feature matrix The The row eigenvector, is the transpose symbol, refers to the convolution query feature matrix, refers to the convolution key feature matrix, refers to the convolution key feature matrix The characteristic dimension of It refers to the convolution query feature matrix to the convolution key feature matrix The global average attention score of the row feature vector, refers to the convolution query feature matrix the number of rows, refers to the convolution key feature matrix the number of rows, is the logarithmic function symbol, is the first The divergence information increment; Performing threshold screening on the divergence information increment set to obtain a sparse information increment set; Filtering a sparse query feature matrix from the convolution query feature matrix according to the sparse information increment set; The long-term load time series characteristics of the convolution load feature sequence are calculated according to the sparse query feature matrix, the convolution key feature matrix and the convolution value feature matrix.
[0008] Optionally, when the short-term feature extraction module performs window attention extraction and multi-level window downsampling on the historical load data sequence to obtain the short-term load time series feature, it includes: Performing high-dimensional space projection on the historical load data sequence to obtain a historical load feature sequence; Position encoding is performed on the historical load characteristic sequence to obtain a coded load characteristic sequence; Initializing a time domain window of a fixed size, and using the time domain window to perform sliding window slicing on the coded load feature sequence to obtain a window load feature sequence; Performing window attention extraction on the window load feature sequence to obtain a window attention feature sequence; Performing time-series downsampling on the window attention feature sequence to obtain a downsampled window feature sequence; Iteratively updating the historical load feature sequence using the down-sampling window feature sequence, and returning to the step of window slicing the coded load feature sequence using the time domain window to obtain a window load feature sequence, until the number of iterative updates is equal to a preset iteration threshold, and using the down-sampling window feature sequence as a standard window feature sequence; The standard window feature sequence is dimensionally aligned and time-aligned to obtain short-term load time series features.
[0009] Optionally, when the short-term feature extraction module performs window attention extraction on the window load feature sequence to obtain the window attention feature sequence, it includes: Calculating the window attention weight of each window load feature in the window load feature sequence to obtain a window attention weight sequence; Performing an attention pooling operation on the window attention weight sequence to obtain a pooled attention weight sequence; Using the pooled attention weight sequence to perform feature weighting on the window load feature sequence to obtain a weighted attention feature sequence; Performing residual connection on the window load feature sequence using the weighted attention feature to obtain a residual attention feature sequence; The residual attention feature sequence is feature normalized and feed-forwarded to obtain a window attention feature sequence.
[0010] Optionally, when the load analysis module performs autoregressive decoding on the long and short load time series characteristics to obtain the analysis load data sequence, it includes: Performing linear dimensionality reduction on the long and short load time series characteristics to obtain reduced dimensionality load time series characteristics; Feedforward output is performed on the reduced-dimensional load time series feature to obtain a hidden state of the time series feature; Taking the historical load data at the end of the historical load data sequence as initial load data, and decoding the time series feature hidden state using the initial load data to obtain analysis load data; Update the time series characteristic hidden state according to the analyzed load data to obtain an updated characteristic hidden state; Recursively updating the time series feature hidden state using the updated feature hidden state, recursively updating the initial load data using the analyzed load data, and returning to the step of decoding the time series feature hidden state using the initial load data to obtain the analyzed load data; When the number of recursive updates is equal to a preset recursive threshold, all the analysis load data are collected into an analysis load data sequence.
[0011] Optionally, when the reward calculation module calculates the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired stepped electricity price table and the analyzed load data sequence, it includes: Obtaining a power load level table of the smart home device; Using the power load level table to map the analyzed load data sequence to a power supply state, to obtain an analyzed power supply state sequence; Using the power load level table to map the analyzed power supply state sequence to power supply load, to obtain a state load data sequence; Performing load extraction on the initial power supply strategy to obtain an initial load data sequence; Calculating the comfort loss value corresponding to the initial load data sequence according to the state load data sequence; Using the pre-acquired stepped electricity price table to map the initial load data sequence to an electricity price loss, to obtain an electricity price loss value; The electricity consumption incentive loss is calculated according to the comfort loss value and the electricity price loss value.
[0012] Optionally, when the reward calculation module calculates the comfort loss value corresponding to the initial load data sequence according to the state load data sequence, it includes: The comfort loss value is calculated using the following comfort loss function: in, is the comfort loss value, , is an index symbol, is the sequence length of the state load data sequence, is the total number of devices in the smart home device, It refers to the first The first state load data Load data of each device, is the first The initial load data The load data corresponding to each device, Refers to the smart home device The comfort weights preset for each device, is the absolute value symbol.
[0013] Optionally, when the power supply control module performs differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, the method includes: Obtaining a state load interval sequence corresponding to the analysis load data sequence; Initializing a power supply control action sequence, and updating the power supply control action sequence according to the power consumption incentive loss and the state load interval sequence to obtain an updated control action sequence; Using the update control action sequence to perform load control on the initial load data sequence of the initial power supply strategy to obtain a controlled load data sequence; Performing a global iterative update on the initial load data sequence using the control load data sequence, and returning to the step of calculating the comfort loss value corresponding to the initial load data sequence according to the state load data sequence using the comfort loss function; When the number of global iterative updates is equal to a preset global iterative threshold, the controlled load data sequence is used as an updated load data sequence, and an updated power supply strategy is generated according to the updated load data sequence.
[0014] In order to solve the above problems, the present invention also provides a power supply method for a smart home device power supply, the method comprising: Obtaining a historical load data sequence of a smart home device, and performing deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain a long-term load time series feature; Performing window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series characteristics; The long-term load time series characteristics and the short-term load time series characteristics are gated and fused and autoregressive decoded to obtain an analysis load data sequence, wherein the gated and fused long-term load time series characteristics and the short-term load time series characteristics are gated and fused and autoregressive decoded to obtain an analysis load data sequence, including: performing key vector mapping on the long-term load time series characteristics to obtain a long-term key characteristic; performing query vector mapping on the short-term load time series characteristics to obtain a short-term query characteristic; performing gated and fused long-term load time series characteristics and short-term load time series characteristics according to the long-term key characteristic and the short-term query characteristic using the following gated fusion algorithm to obtain long-short load time series characteristics: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is an element-by-element multiplication symbol; autoregressive decoding is performed on the long and short load time series characteristics to obtain an analysis load data sequence; Obtaining an initial power supply strategy, and calculating the power consumption incentive loss corresponding to the initial power supply strategy based on the pre-acquired tiered electricity price table and the analyzed load data sequence; The initial power supply strategy is subjected to differential error training and global iterative optimization according to the power consumption incentive loss to obtain an updated power supply strategy, and the smart home device is powered according to the updated power supply strategy.
[0015] The embodiment of the present invention obtains long-term load time series features by performing deep separable downsampling and sparse attention extraction on the historical load data sequence, which can reduce the processing complexity of the historical load data sequence while retaining local feature details, thereby improving the feature comprehensiveness of the long-term load time series features. By performing window attention extraction and multi-level window downsampling on the historical load data sequence, short-term load time series features are obtained, which can reduce the sampling redundancy of short-term features and improve feature extraction efficiency. Short-term features of different time granularities can be adaptively learned to increase the information content of short-term load time series features. By performing gated feature fusion and autoregressive decoding on the long-term load time series features and the short-term load time series features, an analysis load data sequence can be obtained, which can adaptively select the corresponding feature contribution according to the attention mechanism, while reducing the feature conflict between long-term features and short-term features, thereby improving the accuracy of load data analysis.
[0016] By calculating the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired stepped electricity price table and the analyzed load data sequence, the power consumption incentive loss of the initial power supply strategy can be calculated in combination with the comfort of user behavior habits and electricity price costs, thereby facilitating the subsequent optimization of the power supply strategy. By performing differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss, an updated power supply strategy is obtained, and the smart home device is powered according to the updated power supply strategy. The global power supply strategy can be updated according to the timing error of the power consumption incentive loss, thereby improving the comfort of power supply, reducing the power consumption and electricity cost of power supply, and improving the efficiency of power supply, thereby improving the accuracy of battery pack monitoring. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 A functional module diagram of a power supply device for a smart home device power supply provided by an embodiment of the present invention; Figure 2 A flowchart of generating an electrical data set sequence group provided by an embodiment of the present invention; Figure 3 A flowchart of extracting a feature sequence of graph events provided by an embodiment of the present invention; Figure 4 A schematic diagram of a flow chart of a power supply method for a smart home device power supply provided by an embodiment of the present invention; The purpose, features and advantages of the present invention will be further described with reference to the accompanying drawings in conjunction with the embodiments. DETAILED DESCRIPTION
[0018] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.
[0019] The embodiment of the present application provides a power supply device for a smart home device power supply. The execution subject of the power supply device for the smart home device power supply includes but is not limited to at least one of the electronic devices such as a server, a terminal, etc. that can be configured to execute the device provided in the embodiment of the present application. In other words, the power supply device for the smart home device power supply can be executed by software or hardware installed in a terminal device or a server device. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, etc. The server can be an independent server, or it can be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (Content Delivery Network, CDN), and big data and artificial intelligence platforms.
[0020] like Figure 1 , which is a functional module diagram of a power supply device for a smart home device power supply provided by an embodiment of the present invention.
[0021] The power supply device 100 of the smart home device power supply of the present invention can be installed in an electronic device. According to the functions to be implemented, the power supply device 100 of the smart home device power supply can include a long-term feature extraction module 101, a short-term feature extraction module 102, a load analysis module 103, a reward calculation module 104 and a power supply control module 105. The module of the present invention can also be called a unit, which refers to a series of computer program segments that can be executed by an electronic device processor and can complete fixed functions, which are stored in the memory of the electronic device.
[0022] In this embodiment, the functions of each module / unit are as follows: The long-term feature extraction module 101 is used to obtain the historical load data sequence of the smart home device, and perform deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain the long-term load time series feature.
[0023] In detail, the smart home device refers to household appliances or electronic devices with functions such as networking, automatic control, and remote management. The smart home devices include smart air conditioners, smart sockets, and smart light bulbs. The historical load data sequence refers to the changes in the power load data of each device in the smart home device in the past time period, wherein each historical load data in the historical load data sequence corresponds to the power load data of the smart home device in a fixed time period in the past time period.
[0024] Specifically, the historical load data sequence of the smart home device can be obtained through the load monitoring device corresponding to the smart home device. The load monitoring device can be a smart meter or a smart socket or other device used to monitor the power load of the device. The long-term load timing characteristics refer to the timing characteristics presented by the historical load data sequence within a longer time span. The long-term load timing characteristics can help analyze the global trend and periodic law of the power load, thereby optimizing the power supply control strategy.
[0025] In the embodiment of the present invention, when the long-term feature extraction module 101 performs deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain the long-term load time series feature, it includes: Performing high-dimensional space projection on the historical load data sequence to obtain a historical load feature sequence; Position encoding is performed on the historical load characteristic sequence to obtain a coded load characteristic sequence; Performing deep convolution on the encoded load feature sequence to obtain a deep load feature sequence group; Performing point-by-point convolution on the deep load feature sequence group to obtain a convolution load feature sequence; Sparse attention extraction is performed on the convolutional load feature sequence to obtain long-term load time series features.
[0026] Specifically, the high-dimensional space projection refers to projecting each load data in the historical load data sequence into a high-dimensional feature space, thereby enhancing the characterization capability of the load characteristics and improving the characteristic details of the load data. The load characteristics of different dimensions of the historical load data sequence can be extracted by calculating the load change rate, the frequency domain characteristics of the load, etc., and merged into historical load characteristics, thereby realizing high-dimensional space projection. The position encoding refers to mapping the position index vector corresponding to the load characteristic at each position in the historical load characteristic sequence.
[0027] In detail, the deep convolution refers to convolving each channel of the input with a convolution kernel in a single-channel mode, that is, convolving the historical load feature sequence in multiple single channels, and the point-by-point convolution refers to using a smaller convolution kernel to achieve multiple cross-channel information fusion, that is, through different small-size convolutions and weighted summation of the features of each channel, the deep load feature sequences of each channel are merged into a convolution load feature sequence of a single channel.
[0028] Specifically, the depth-separable downsampling can achieve efficient downsampling of the coding load feature sequence through depth-wise convolution and point-by-point convolution, significantly reducing the amount of calculation, while enhancing the ability to extract local time features and improving the accuracy of timing features.
[0029] In detail, when the long-term feature extraction module 101 performs sparse attention extraction on the convolution load feature sequence to obtain the long-term load time series feature, it includes: Performing attention feature projection on the convolution load feature sequence to obtain a convolution query feature matrix, a convolution key feature matrix, and a convolution value feature matrix; Calculating a divergence information increment set corresponding to the convolution query feature matrix according to the convolution key feature matrix; Performing threshold screening on the divergence information increment set to obtain a sparse information increment set; Filtering a sparse query feature matrix from the convolution query feature matrix according to the sparse information increment set; The long-term load time series characteristics of the convolution load feature sequence are calculated according to the sparse query feature matrix, the convolution key feature matrix and the convolution value feature matrix.
[0030] In detail, the attention feature projection refers to using the transformation matrix of the attention mechanism to project the convolution load feature sequence to the new query space, key space and value space respectively, thereby obtaining the convolution query feature matrix, the convolution key feature matrix and the convolution value feature matrix.
[0031] Specifically, the divergence information increment set is calculated using the following divergence information increment algorithm: in, refers to the convolution query feature matrix The row feature vector is the convolution key feature matrix The attention scores of the row feature vectors, , is the feature index, is the exponential function symbol, refers to the convolution query feature matrix The Row eigenvector, is the dot product symbol, refers to the convolution key feature matrix The The row eigenvector, is the transpose symbol, refers to the convolution query feature matrix, refers to the convolution key feature matrix, refers to the convolution key feature matrix The characteristic dimension of It refers to the convolution query feature matrix to the convolution key feature matrix The global average attention score of the row feature vector, refers to the convolution query feature matrix the number of rows, refers to the convolution key feature matrix the number of rows, is the logarithmic function symbol, is the first The divergence information increment.
[0032] Specifically, the divergence information increment algorithm can be used to measure the distribution differences between each convolution query feature in the convolution query feature matrix relative to the global average attention distribution, thereby realizing the screening of convolution query features, reducing the processing time of long sequence features, and improving feature extraction efficiency.
[0033] In detail, the threshold screening refers to screening out the divergence information increments greater than a preset value or several divergence information increments with higher numerical rankings in the divergence information increment set as sparse information increments and aggregating them into a sparse information increment set.
[0034] Specifically, the sparse query feature matrix refers to a feature matrix in the convolution query feature matrix composed of convolution query feature vectors corresponding to each sparse information increment in the sparse information increment set. The attention mechanism can be used to calculate the long-term load time series characteristics based on the sparse query feature matrix, the convolution key feature matrix and the convolution value feature matrix.
[0035] In an embodiment of the present invention, long-term load time series features are obtained by performing deep separable downsampling and sparse attention extraction on the historical load data sequence, which can reduce the processing complexity of the historical load data sequence while retaining local feature details, thereby improving the feature comprehensiveness of the long-term load time series features.
[0036] The short-term feature extraction module 102 is used to perform window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series features.
[0037] In detail, the short-term load timing characteristics refer to the timing characteristics presented by the historical load data sequence within a shorter time span. The terminal load timing characteristics can help analyze the local trend and load mutation of the power load, thereby optimizing the power supply control strategy.
[0038] In the embodiment of the present invention, when the short-term feature extraction module 102 performs window attention extraction and multi-level window downsampling on the historical load data sequence to obtain the short-term load time series feature, it includes: Performing high-dimensional space projection on the historical load data sequence to obtain a historical load feature sequence; Position encoding is performed on the historical load characteristic sequence to obtain a coded load characteristic sequence; Initializing a time domain window of a fixed size, and using the time domain window to perform sliding window slicing on the coded load feature sequence to obtain a window load feature sequence; Performing window attention extraction on the window load feature sequence to obtain a window attention feature sequence; Performing time-series downsampling on the window attention feature sequence to obtain a downsampled window feature sequence; Iteratively updating the historical load feature sequence using the down-sampling window feature sequence, and returning to the step of window slicing the coded load feature sequence using the time domain window to obtain a window load feature sequence, until the number of iterative updates is equal to a preset iteration threshold, and using the down-sampling window feature sequence as a standard window feature sequence; The standard window feature sequence is dimensionally aligned and time-aligned to obtain short-term load time series features.
[0039] In detail, the high-dimensional space projection and the position encoding method are consistent with the high-dimensional space projection and position encoding method in the long-term feature extraction module 101, which will not be repeated here. The iteration threshold can be 5.
[0040] Specifically, the fixed-size time domain window refers to a time domain window with a preset fixed time period size, for example, fifteen minutes is used as the time domain window, and the sliding window slicing refers to moving the time domain window according to a preset fixed step size, and taking the coded load feature in the coded load feature sequence corresponding to each step in the time domain window as the window load feature, thereby forming a window load feature sequence, wherein the step size can be ten minutes.
[0041] For details, refer to Figure 2 As shown, when the short-term feature extraction module 102 performs window attention extraction on the window load feature sequence to obtain the window attention feature sequence, it includes: S21, calculating the window attention weight of each window load feature in the window load feature sequence to obtain a window attention weight sequence; S22, performing an attention pooling operation on the window attention weight sequence to obtain a pooled attention weight sequence; S23, using the pooled attention weight sequence to perform feature weighting on the window load feature sequence to obtain a weighted attention feature sequence; S24, performing residual connection on the window load feature sequence using the weighted attention feature to obtain a residual attention feature sequence; S25. Perform feature normalization and feed-forward output on the residual attention feature sequence to obtain a window attention feature sequence.
[0042] In detail, the window attention weight calculation refers to using the attention mechanism to calculate the attention weights corresponding to the load features of each window. The attention pooling is a convergence method based on the attention mechanism. It can extract key information and perform effective aggregation when processing sequence data. Attention pooling calculates the weight of each element in the sequence to determine its contribution to the aggregation result.
[0043] Specifically, a layer normalization method can be used to perform feature normalization operations, and a multi-layer perceptron network can be used for feedforward output. The temporal downsampling refers to using a patch merging network to sequentially perform window merging, linear dimensionality reduction, and layer normalization operations on the window attention feature sequence, thereby achieving feature downsampling.
[0044] In detail, the dimension alignment refers to aligning the feature dimension of the standard window feature sequence with the feature dimension of the long-term load time series feature, and the time alignment refers to aligning the time length of the standard window feature sequence with the time length of the long-term load time series feature. Among them, the dimension alignment can be performed using a convolutional layer or a feedforward neural network, and the time alignment can be performed using methods such as feature difference or deconvolution. By performing the dimension alignment and the time alignment, the subsequent feature fusion of the long-term load time series feature and the short-term load time series feature can be facilitated.
[0045] In an embodiment of the present invention, by performing window attention extraction and multi-level window downsampling on the historical load data sequence, short-term load time series characteristics are obtained, which can reduce the sampling redundancy of short-term characteristics, improve feature extraction efficiency, and adaptively learn short-term characteristics of different time granularities, thereby increasing the amount of information in short-term load time series characteristics.
[0046] The load analysis module 103 is used to perform gated feature fusion and autoregressive decoding on the long-term load time series characteristics and the short-term load time series characteristics to obtain an analysis load data sequence.
[0047] In detail, the analyzed load data sequence refers to the power load data of each device of the smart home device in a future period of time obtained by analyzing the long-term time series characteristics and short-term time series characteristics of the historical load data sequence.
[0048] In the embodiment of the present invention, referring to Figure 3 As shown, when the load analysis module 103 performs gated feature fusion and autoregressive decoding on the long-term load time series features and the short-term load time series features to obtain the analyzed load data sequence, it includes: S31, performing key vector mapping on the long-term load time series characteristics to obtain long-term key characteristics; S32, performing query vector mapping on the short-term load time series characteristics to obtain short-term query characteristics; S33, performing gated feature fusion on the long-term load time series feature and the short-term load time series feature according to the long-term key feature and the short-term query feature to obtain long and short load time series features; S34, performing autoregressive decoding on the long and short load time series characteristics to obtain an analysis load data sequence.
[0049] In detail, the key vector mapping refers to projecting the long-term load time series features using the pre-trained key vector projection matrix, and using the results as long-term key features, and the query vector mapping refers to projecting the short-term load time series features using the pre-trained query vector projection matrix, and using the results as short-term query features, wherein the key vector projection matrix and the query vector projection matrix are learned by the attention mechanism.
[0050] Specifically, the long and short load timing characteristics are calculated using the following gated fusion algorithm: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is the element-wise multiplication symbol.
[0051] In detail, by using the gated fusion algorithm to perform feature fusion of the long-term load timing features and the short-term load timing features, the corresponding feature contribution can be adaptively selected according to the attention mechanism to improve the analysis accuracy, while reducing the feature conflict between long-term features and short-term features and improving the generalization ability.
[0052] Specifically, when the load analysis module 103 performs autoregressive decoding on the long and short load time series characteristics to obtain the analyzed load data sequence, it includes: Performing linear dimensionality reduction on the long and short load time series characteristics to obtain reduced dimensionality load time series characteristics; Feedforward output is performed on the reduced-dimensional load time series feature to obtain a hidden state of the time series feature; Taking the historical load data at the end of the historical load data sequence as initial load data, and decoding the time series feature hidden state using the initial load data to obtain analysis load data; Update the time series characteristic hidden state according to the analyzed load data to obtain an updated characteristic hidden state; Recursively updating the time series feature hidden state using the updated feature hidden state, recursively updating the initial load data using the analyzed load data, and returning to the step of decoding the time series feature hidden state using the initial load data to obtain the analyzed load data; When the number of recursive updates is equal to a preset recursive threshold, all the analysis load data are collected into an analysis load data sequence.
[0053] In detail, the linear dimensionality reduction refers to reducing the long and short load time series features into the same data dimension as the historical load data sequence using a projection matrix, and a multi-layer perceptron network can be used for feedforward output.
[0054] Specifically, the decoder of the Transformer trained with historical load data pre-labeled with analysis load data can be used for decoding, and the state can be updated using self-attention or cross-attention.
[0055] In detail, the recursion threshold is equal to the sequence length of the analysis load data sequence, and each analysis load data in the analysis load data sequence is sorted from front to back according to the decoded timestamp.
[0056] In an embodiment of the present invention, by performing gated feature fusion and autoregressive decoding on the long-term load time series features and the short-term load time series features, an analysis load data sequence is obtained, and the corresponding feature contribution can be adaptively selected according to the attention mechanism, while reducing the feature conflict between long-term features and short-term features, thereby improving the accuracy of load data analysis.
[0057] The reward calculation module 104 is used to obtain an initial power supply strategy, and calculate the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired stepped electricity price table and the analyzed load data sequence.
[0058] In detail, the initial power supply strategy is the initial default power supply strategy of the power supply of the smart home device, for example, turning on fixed smart home devices within a preset time period and configuring corresponding device power supply loads.
[0059] Specifically, the tiered electricity price table refers to a data table that divides electricity charges into different tiered levels according to different electricity consumption of users. The tiered electricity price table is used to describe the corresponding relationship between electricity prices and electricity charges. As electricity consumption increases, electricity charges will also increase step by step.
[0060] In detail, the electricity consumption incentive loss is a loss value used to guide the initial power supply strategy to be optimized in the direction of reducing electricity costs and improving user comfort.
[0061] In the embodiment of the present invention, when the reward calculation module 104 calculates the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired tiered electricity price table and the analyzed load data sequence, it includes: Obtaining a power load level table of the smart home device; Using the power load level table to map the analyzed load data sequence to a power supply state, to obtain an analyzed power supply state sequence; Using the power load level table to map the analyzed power supply state sequence to power supply load, to obtain a state load data sequence; Performing load extraction on the initial power supply strategy to obtain an initial load data sequence; Calculating the comfort loss value corresponding to the initial load data sequence according to the state load data sequence; Using the pre-acquired stepped electricity price table to map the initial load data sequence to an electricity price loss, to obtain an electricity price loss value; The electricity consumption incentive loss is calculated according to the comfort loss value and the electricity price loss value.
[0062] In detail, the power load level table is a mapping relationship table for recording the power status level of each device in the smart home device and the corresponding power consumption wattage. For example, when the analysis load data of the smart fan is 20w to 40w, excluding 40w, the corresponding analysis power supply state is low wind; when the analysis load data is 40w to 70w, excluding 70w, the corresponding analysis power supply state is medium wind. The power supply status mapping refers to analyzing the energy consumption level of the smart home device corresponding to each analysis load data in the analysis load data sequence; the power supply load mapping refers to analyzing the minimum load data corresponding to the energy consumption level of the smart home device. For example, when the analysis load data of the smart fan is 30w, the corresponding state load data is 20w.
[0063] Specifically, the comfort loss value is calculated using the following comfort loss function: in, is the comfort loss value, , is an index symbol, is the sequence length of the state load data sequence, is the total number of devices in the smart home device, It refers to the first The first state load data Load data of each device, is the first The initial load data The load data corresponding to each device, Refers to the smart home device The comfort weights preset for each device, is the absolute value symbol.
[0064] In detail, the comfort loss function can determine the comfort of the initial power supply strategy by combining factors such as user load expectations and equipment load change rate, thereby facilitating the optimization of the power supply strategy towards reducing electricity costs and improving user comfort. The electricity price loss mapping of the initial load data sequence using the pre-acquired stepped electricity price table to obtain the electricity price loss value refers to calculating the overall electricity price loss corresponding to the initial load data sequence in the stepped electricity price table. The electricity price loss value can be obtained by calculating the product of the total load of the initial load data sequence in each step time period and the corresponding electricity price.
[0065] Specifically, calculating the electricity consumption incentive loss according to the comfort loss value and the electricity price loss value means taking the weighted sum of the comfort loss value and the electricity price loss value as the electricity consumption incentive loss.
[0066] In an embodiment of the present invention, by calculating the electricity incentive loss corresponding to the initial power supply strategy based on the pre-acquired stepped electricity price table and the analyzed load data sequence, the electricity incentive loss of the initial power supply strategy can be calculated in combination with the comfort level of the user's behavioral habits and the electricity price, thereby facilitating the subsequent optimization of the power supply strategy.
[0067] The power supply control module 105 is used to perform differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, and supply power to the smart home device according to the updated power supply strategy.
[0068] In detail, the updated power supply strategy refers to a power supply load control sequence obtained by iterative optimization that has advantages in terms of user comfort and electricity price, for example, power is allocated to each device of the smart home device power supply in a fixed time period.
[0069] In the embodiment of the present invention, when the power supply control module 105 performs differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, it includes: Obtaining a state load interval sequence corresponding to the analysis load data sequence; Initializing a power supply control action sequence, and updating the power supply control action sequence according to the power consumption incentive loss and the state load interval sequence to obtain an updated control action sequence; Using the update control action sequence to perform load control on the initial load data sequence of the initial power supply strategy to obtain a controlled load data sequence; Performing a global iterative update on the initial load data sequence using the control load data sequence, and returning to the step of calculating the comfort loss value corresponding to the initial load data sequence according to the state load data sequence using the comfort loss function; When the number of global iterative updates is equal to a preset global iterative threshold, the controlled load data sequence is used as an updated load data sequence, and an updated power supply strategy is generated according to the updated load data sequence.
[0070] In detail, each power supply control action in the power supply control action sequence is an action used to control each initial load data in the initial load data sequence to perform power changes, such as maintaining the load unchanged, increasing the load, and reducing the load. When the power supply control action sequence is just initialized, the corresponding power supply control actions are to maintain the load unchanged.
[0071] Specifically, the action update refers to updating the power supply control action sequence in the direction of reducing the power consumption incentive loss, and it must meet the requirements of the updated initial load data sequence, that is, the control load data sequence meets the requirements of the state load interval sequence. The action update can be performed using the gradient descent method and the mathematical expectation method.
[0072] In detail, the load control refers to updating the corresponding initial load data in the initial load data sequence by maintaining the load unchanged, increasing the load, and reducing the load according to each update control action in the update control action sequence, and the global iteration threshold can be 100.
[0073] Specifically, the power supply control module 105 executes the power supply for the smart home device according to the updated power supply strategy, which means extracting the start and stop timestamps of each device and the power value assigned to each start and stop timestamp from the updated power supply strategy, and allocating the corresponding power supply voltage and power supply current to each device at the corresponding time according to the correspondence between the start and stop timestamps and the power values.
[0074] In an embodiment of the present invention, by performing differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss, an updated power supply strategy is obtained, and the smart home device is powered according to the updated power supply strategy. The global power supply strategy can be updated according to the timing error of the power consumption incentive loss, thereby improving the comfort of power supply, reducing the power consumption and electricity cost of power supply, and improving the efficiency of power supply.
[0075] Reference Figure 4FIG. 1 is a flow chart of a power supply method for a smart home device power supply provided by an embodiment of the present invention. In this embodiment, the power supply method for a smart home device power supply includes: S1. Obtain a historical load data sequence of a smart home device, and perform deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain a long-term load time series feature; S2, performing window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series characteristics; S3, performing gated feature fusion and autoregressive decoding on the long-term load time series features and the short-term load time series features to obtain an analysis load data sequence, wherein the performing gated feature fusion and autoregressive decoding on the long-term load time series features and the short-term load time series features to obtain an analysis load data sequence includes: performing key vector mapping on the long-term load time series features to obtain long-term key features; performing query vector mapping on the short-term load time series features to obtain short-term query features; performing gated feature fusion on the long-term load time series features and the short-term load time series features according to the long-term key features and the short-term query features using the following gated fusion algorithm to obtain long and short load time series features: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is an element-by-element multiplication symbol; autoregressive decoding is performed on the long and short load time series characteristics to obtain an analysis load data sequence; S4, obtaining an initial power supply strategy, and calculating the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired stepped electricity price table and the analyzed load data sequence; S5. Perform differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, and supply power to the smart home device according to the updated power supply strategy.
[0076] The embodiment of the present invention obtains long-term load time series features by performing deep separable downsampling and sparse attention extraction on the historical load data sequence, which can reduce the processing complexity of the historical load data sequence while retaining local feature details, thereby improving the feature comprehensiveness of the long-term load time series features. By performing window attention extraction and multi-level window downsampling on the historical load data sequence, short-term load time series features are obtained, which can reduce the sampling redundancy of short-term features and improve feature extraction efficiency. Short-term features of different time granularities can be adaptively learned to increase the information content of short-term load time series features. By performing gated feature fusion and autoregressive decoding on the long-term load time series features and the short-term load time series features, an analysis load data sequence can be obtained, which can adaptively select the corresponding feature contribution according to the attention mechanism, while reducing the feature conflict between long-term features and short-term features, thereby improving the accuracy of load data analysis.
[0077] By calculating the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired stepped electricity price table and the analyzed load data sequence, the power consumption incentive loss of the initial power supply strategy can be calculated in combination with the comfort of user behavior habits and electricity price costs, thereby facilitating the subsequent optimization of the power supply strategy. By performing differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss, an updated power supply strategy is obtained, and the smart home device is powered according to the updated power supply strategy. The global power supply strategy can be updated according to the timing error of the power consumption incentive loss, thereby improving the comfort of power supply, reducing the power consumption and electricity cost of power supply, and improving the efficiency of power supply, thereby improving the accuracy of battery pack monitoring.
[0078] In detail, the power supply method of the smart home device power supply in the embodiment of the present invention adopts the same method as above when used. Figure 1 The same technical means as the power supply device of the smart home device power supply described in the invention can produce the same technical effects, so I will not go into details here.
[0079] The present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor of an electronic device, the computer program can implement: Obtaining a historical load data sequence of a smart home device, and performing deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain a long-term load time series feature; Performing window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series characteristics; The long-term load time series characteristics and the short-term load time series characteristics are gated and fused and autoregressive decoded to obtain an analysis load data sequence, wherein the gated and fused long-term load time series characteristics and the short-term load time series characteristics are gated and fused and autoregressive decoded to obtain an analysis load data sequence, including: performing key vector mapping on the long-term load time series characteristics to obtain a long-term key characteristic; performing query vector mapping on the short-term load time series characteristics to obtain a short-term query characteristic; performing gated and fused long-term load time series characteristics and short-term load time series characteristics according to the long-term key characteristic and the short-term query characteristic using the following gated fusion algorithm to obtain long-short load time series characteristics: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is an element-by-element multiplication symbol; autoregressive decoding is performed on the long and short load time series characteristics to obtain an analysis load data sequence; Obtaining an initial power supply strategy, and calculating the power consumption incentive loss corresponding to the initial power supply strategy based on the pre-acquired tiered electricity price table and the analyzed load data sequence; The initial power supply strategy is subjected to differential error training and global iterative optimization according to the power consumption incentive loss to obtain an updated power supply strategy, and the smart home device is powered according to the updated power supply strategy.
[0080] In the several embodiments provided by the present invention, it should be understood that the disclosed devices, apparatuses and devices can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.
[0081] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0082] In addition, each functional module in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional modules.
[0083] It is obvious to those skilled in the art that the present invention is not limited to the details of the above exemplary embodiments, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.
[0084] Therefore, no matter from which point of view, the embodiments should be regarded as illustrative and non-restrictive, and the scope of the present invention is limited by the appended claims rather than the above description, so it is intended that all changes falling within the meaning and scope of the equivalent elements of the claims are included in the present invention. Any attached figure mark in the claims should not be regarded as limiting the claims involved.
[0085] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Artificial Intelligence (AI) is the theory, device, technology and application device that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.
[0086] In addition, it is clear that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. The multiple units or devices stated in the device embodiment can also be implemented by one unit or device through software or hardware. The words first, second, etc. are used to indicate names, and do not indicate any particular order.
[0087] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present invention.
Claims
1. A power supply device for a smart home device, characterized in that: The device includes a long-term feature extraction module, a short-term feature extraction module, a load analysis module, a reward calculation module and a power supply control module, wherein: A long-term feature extraction module is used to obtain the historical load data sequence of the smart home device, and perform deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain the long-term load time series feature; A short-term feature extraction module is used to perform window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series features; The load analysis module is used to perform gated feature fusion and autoregressive decoding on the long-term load time series characteristics and the short-term load time series characteristics to obtain an analysis load data sequence, wherein the load analysis module, when performing gated feature fusion and autoregressive decoding on the long-term load time series characteristics and the short-term load time series characteristics to obtain an analysis load data sequence, includes: performing key vector mapping on the long-term load time series characteristics to obtain a long-term key feature; performing query vector mapping on the short-term load time series characteristics to obtain a short-term query feature; and performing gated feature fusion on the long-term load time series characteristics and the short-term load time series characteristics according to the long-term key feature and the short-term query feature using the following gated fusion algorithm to obtain long and short load time series characteristics: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is an element-by-element multiplication symbol; autoregressive decoding is performed on the long and short load time series characteristics to obtain an analysis load data sequence; A reward calculation module, used to obtain an initial power supply strategy, and calculate the power consumption incentive loss corresponding to the initial power supply strategy according to a pre-acquired stepped electricity price table and the analyzed load data sequence; The power supply control module is used to perform differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, and supply power to the smart home device according to the updated power supply strategy.
2. The power supply device for a smart home device according to claim 1, characterized in that: When the long-term feature extraction module performs deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain the long-term load time series feature, it includes: Performing high-dimensional space projection on the historical load data sequence to obtain a historical load feature sequence; Position encoding is performed on the historical load characteristic sequence to obtain a coded load characteristic sequence; Performing deep convolution on the encoded load feature sequence to obtain a deep load feature sequence group; Performing point-by-point convolution on the deep load feature sequence group to obtain a convolution load feature sequence; Sparse attention extraction is performed on the convolutional load feature sequence to obtain long-term load time series features.
3. The power supply device for a smart home device power supply as claimed in claim 2, characterized in that: When the long-term feature extraction module performs sparse attention extraction on the convolution load feature sequence to obtain the long-term load time series feature, it includes: Performing attention feature projection on the convolution load feature sequence to obtain a convolution query feature matrix, a convolution key feature matrix, and a convolution value feature matrix; The divergence information increment set corresponding to the convolution query feature matrix is calculated according to the convolution key feature matrix using the following divergence information increment algorithm: in, refers to the convolution query feature matrix The row feature vector is the convolution key feature matrix The attention scores of the row feature vectors, , is the feature index, is the exponential function symbol, refers to the convolution query feature matrix The The row eigenvector, refers to the convolution key feature matrix The The row eigenvector, is the transpose symbol, refers to the convolution query feature matrix, refers to the convolution key feature matrix, refers to the convolution key feature matrix The characteristic dimension of It refers to the convolution query feature matrix to the convolution key feature matrix The global average attention score of the row feature vector, refers to the convolution query feature matrix the number of rows, refers to the convolution key feature matrix the number of rows, is the logarithmic function symbol, is the first The divergence information increment; Performing threshold screening on the divergence information increment set to obtain a sparse information increment set; Filtering a sparse query feature matrix from the convolution query feature matrix according to the sparse information increment set; The long-term load time series characteristics of the convolution load feature sequence are calculated according to the sparse query feature matrix, the convolution key feature matrix and the convolution value feature matrix.
4. The power supply device for a smart home device according to claim 1, characterized in that: When the short-term feature extraction module performs window attention extraction and multi-level window downsampling on the historical load data sequence to obtain the short-term load time series feature, it includes: Performing high-dimensional space projection on the historical load data sequence to obtain a historical load feature sequence; Position encoding the historical load characteristic sequence to obtain a coded load characteristic sequence; Initializing a time domain window of a fixed size, and using the time domain window to perform sliding window slicing on the coded load feature sequence to obtain a window load feature sequence; Performing window attention extraction on the window load feature sequence to obtain a window attention feature sequence; Performing time-series downsampling on the window attention feature sequence to obtain a downsampled window feature sequence; Iteratively updating the historical load feature sequence using the down-sampling window feature sequence, and returning to the step of window slicing the coded load feature sequence using the time domain window to obtain a window load feature sequence, until the number of iterative updates is equal to a preset iteration threshold, and using the down-sampling window feature sequence as a standard window feature sequence; The standard window feature sequence is dimensionally aligned and time aligned to obtain short-term load time series features.
5. The power supply device for a smart home device according to claim 1, characterized in that: When the short-term feature extraction module performs window attention extraction on the window load feature sequence to obtain the window attention feature sequence, it includes: Calculating the window attention weight of each window load feature in the window load feature sequence to obtain a window attention weight sequence; Performing an attention pooling operation on the window attention weight sequence to obtain a pooled attention weight sequence; Using the pooled attention weight sequence to perform feature weighting on the window load feature sequence to obtain a weighted attention feature sequence; Performing residual connection on the window load feature sequence using the weighted attention feature to obtain a residual attention feature sequence; The residual attention feature sequence is feature normalized and feed-forwarded to obtain a window attention feature sequence.
6. The power supply device for a smart home device according to claim 1, characterized in that: When the load analysis module performs autoregressive decoding on the long and short load time series characteristics to obtain the analysis load data sequence, it includes: Performing linear dimension reduction on the long and short load time series characteristics to obtain reduced dimension load time series characteristics; Feedforward output is performed on the reduced-dimensional load time series feature to obtain a hidden state of the time series feature; Taking the historical load data at the end of the historical load data sequence as initial load data, and decoding the time series feature hidden state using the initial load data to obtain analysis load data; Update the time series characteristic hidden state according to the analyzed load data to obtain an updated characteristic hidden state; Recursively updating the time series feature hidden state by using the updated feature hidden state, recursively updating the initial load data by using the analyzed load data, and returning to the step of decoding the time series feature hidden state by using the initial load data to obtain the analyzed load data; When the number of recursive updates is equal to a preset recursive threshold, all the analysis load data are collected into an analysis load data sequence.
7. The power supply device for a smart home device according to claim 1, characterized in that: When the reward calculation module calculates the power consumption incentive loss corresponding to the initial power supply strategy according to the pre-acquired stepped electricity price table and the analyzed load data sequence, it includes: Obtaining a power load level table of the smart home device; Using the power load level table to map the analyzed load data sequence to a power supply state, to obtain an analyzed power supply state sequence; Using the power load level table to map the analyzed power supply state sequence to power supply load, to obtain a state load data sequence; Performing load extraction on the initial power supply strategy to obtain an initial load data sequence; Calculating the comfort loss value corresponding to the initial load data sequence according to the state load data sequence; Using the pre-acquired stepped electricity price table to map the initial load data sequence to an electricity price loss, to obtain an electricity price loss value; The electricity consumption incentive loss is calculated according to the comfort loss value and the electricity price loss value.
8. The power supply device for a smart home device according to claim 7, characterized in that: When the reward calculation module calculates the comfort loss value corresponding to the initial load data sequence according to the state load data sequence, include: The comfort loss value is calculated using the following comfort loss function: in, is the comfort loss value, , is an index symbol, is the sequence length of the state load data sequence, is the total number of devices in the smart home device, It refers to the first The first state load data Load data of each device, is the first The initial load data The load data corresponding to each device, Refers to the smart home device The comfort weights preset for each device, is the absolute value symbol.
9. The power supply device for a smart home device according to claim 1, characterized in that: When the power supply control module performs differential error training and global iterative optimization on the initial power supply strategy according to the power consumption incentive loss to obtain an updated power supply strategy, it includes: Obtaining a state load interval sequence corresponding to the analysis load data sequence; Initializing a power supply control action sequence, and updating the power supply control action sequence according to the power consumption incentive loss and the state load interval sequence to obtain an updated control action sequence; Using the update control action sequence to perform load control on the initial load data sequence of the initial power supply strategy to obtain a controlled load data sequence; Performing a global iterative update on the initial load data sequence using the control load data sequence, and returning to the step of calculating the comfort loss value corresponding to the initial load data sequence according to the state load data sequence using the comfort loss function; When the number of global iterative updates is equal to a preset global iterative threshold, the controlled load data sequence is used as an updated load data sequence, and an updated power supply strategy is generated according to the updated load data sequence.
10. A power supply method for a smart home device power supply, characterized in that: The method comprises: Obtaining a historical load data sequence of a smart home device, and performing deep separable downsampling and sparse attention extraction on the historical load data sequence to obtain a long-term load time series feature; Performing window attention extraction and multi-level window downsampling on the historical load data sequence to obtain short-term load time series characteristics; The long-term load time series characteristics and the short-term load time series characteristics are gated and fused and autoregressive decoded to obtain an analysis load data sequence, wherein the gated and fused long-term load time series characteristics and the short-term load time series characteristics are gated and fused and autoregressive decoded to obtain an analysis load data sequence, including: performing key vector mapping on the long-term load time series characteristics to obtain a long-term key characteristic; performing query vector mapping on the short-term load time series characteristics to obtain a short-term query characteristic; performing gated and fused long-term load time series characteristics and short-term load time series characteristics according to the long-term key characteristic and the short-term query characteristic using the following gated fusion algorithm to obtain long-short load time series characteristics: in, refers to the long and short load timing characteristics, is the normalization function symbol, is the short-term query feature, refers to the short-term load timing characteristics, refers to the long-term bond characteristics, refers to the long-term load timing characteristics, refers to the characteristic dimension of the long-term load time series characteristics, is an element-by-element multiplication symbol; autoregressive decoding is performed on the long and short load time series characteristics to obtain an analysis load data sequence; Obtaining an initial power supply strategy, and calculating the power consumption incentive loss corresponding to the initial power supply strategy based on the pre-acquired tiered electricity price table and the analyzed load data sequence; The initial power supply strategy is subjected to differential error training and global iterative optimization according to the power consumption incentive loss to obtain an updated power supply strategy, and the smart home device is powered according to the updated power supply strategy.
Citation Information
Patent Citations
K-means based multi-branch AGCNN short-term power load prediction method
CN114091776A
Power load prediction method and system based on multi-modal and multi-scale feature fusion
CN119154260A
Comprehensive energy system short-term multi-element load prediction method fusing deep learning combination model
CN119476713A
Method, device and equipment for flexibly adjusting load of refrigerating system of central air conditioner
CN119577372A
Load prediction model training method and apparatus, storage medium, and device
WO2022077693A1
Cited By
Model training method, electric load prediction method, equipment and storage medium
CN120354380A