Super-image-based electricity consumption prediction method and terminal
By constructing a hyperimage and aligning the power consumption data set based on the time-delay estimation algorithm based on the smoothness metric, the accuracy and reliability problems caused by the time axis alignment deviation in the power consumption prediction are solved, and higher prediction accuracy and model stability are achieved.
Patent Information
- Application Number
- CN202510311030.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-17
- Publication Date
- 2025-07-25
- Estimated Expiration
- 2045-03-17
AI Technical Summary
The existing electricity consumption prediction methods face uncertainties such as climate change, market fluctuations and policy adjustments, and the timeline alignment deviation between electricity consumption and influencing factors affects the reliability of the model and the accuracy of the prediction results.
By mapping the influencing factors of the electricity consumption data set into voxel coordinates and the electricity consumption components to voxel values, a super image is constructed, and a delay estimation calculation method is constructed based on the smoothness metric of the super image, the alignment of the electricity consumption data set is realized, and the aligned data set is used for prediction.
It significantly improves the accuracy and reliability of power consumption prediction, improves the overall quality of the data set and the robustness of the prediction model.
Smart Images

Figure CN120373518A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of power consumption prediction, and particularly to a power consumption prediction method and a terminal based on hyper-images. Background Art
[0002] Power consumption prediction, as an important part of energy management, is of great significance for ensuring the safe and stable operation of the power system. With the rapid development of China's economy, the demand for electricity is continuously rising, and the contradiction between power supply and demand is becoming increasingly prominent. Accurately predicting the electricity demand helps to optimize the allocation of power resources, improve the operation efficiency of the power system, and reduce the operation cost. With the construction of the global energy Internet and the wide access of clean energy, power consumption prediction is facing unprecedented challenges and opportunities.
[0003] For a long time, power consumption prediction has been a research hotspot in the power industry. It is not only related to the safe and stable operation of the power system, but also closely related to multiple aspects such as the operation efficiency of the power market, the formulation of energy policies, and environmental protection. Traditional power consumption prediction methods, such as time series analysis, regression analysis, etc., although can meet the requirements to a certain extent, but in the face of uncertain influencing factors such as climate change, market fluctuations, and policy adjustments, their prediction accuracy and adaptability are often difficult to meet the requirements of modern power systems. In recent years, with the rapid development of technologies such as big data and deep learning, power consumption prediction has entered a new development stage. The application of these technologies enables power consumption prediction to more accurately capture the dynamic changes of power consumption and better cope with various complex situations. However, these methods still have some challenges in power consumption prediction. For example, due to the changes in the power consumption collection process, sensor delay, and meteorological acquisition environment, there is an alignment deviation in the time axis between power consumption and influencing factors. This situation will seriously damage the stable quantitative relationship between power consumption and influencing factors, and affect the overall reliability of the model and the accuracy of the prediction results. Based on this, there is an urgent need for a power consumption prediction method that can solve the above problems. Summary of the Invention
[0004] The technical problem to be solved by the present invention is: to provide a power consumption prediction method and a terminal based on hyper-images, which can improve the actual effect and reliability in terms of power consumption prediction accuracy and prediction performance.
[0005] To solve the above technical problem, the technical solution adopted by the present invention is:
[0006] A power consumption prediction method based on hyper-images, comprising the steps of:
[0007] Collect the power consumption data set of multi-source time series, map the influencing factor components of the power consumption data set to voxel coordinates, map the power consumption components of the power consumption data set to voxel value vectors, and construct a hyperimage corresponding to the time series according to the voxel coordinates and the voxel value vectors;
[0008] Construct a time delay estimation algorithm based on the smoothness metric of the hyperimage, estimate the time delay between time series by minimizing the smoothness metric of the hyperimage, and perform alignment of the power consumption data set;
[0009] Use the aligned power consumption data set for power consumption prediction.
[0010] To solve the above technical problems, another technical solution adopted by the present invention is:
[0011] A power consumption prediction terminal based on a hyperimage, including a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein when the processor executes the computer program, each step of the above-mentioned power consumption prediction method based on a hyperimage is implemented.
[0012] The beneficial effects of the present invention are as follows: Map the influencing factor sequence in the power consumption data set to voxel coordinates, map the power consumption sequence to voxel values, and construct a hyperimage corresponding to the multi-source time series; Based on the time delay estimation algorithm of hyperimage smoothness, estimate the time delay between time series by minimizing the smoothness metric of the hyperimage, and realize the alignment of the power consumption data set; Perform power consumption prediction experiments on the power consumption data set after time series alignment. Therefore, through the time series alignment processing of the power consumption data set, the present invention significantly improves the overall quality of the data set and the robustness of the prediction model, and effectively improves the accuracy and reliability of power consumption prediction. Description of the Drawings
[0013] Figure 1 It is a flowchart of a power consumption prediction method based on a hyperimage according to an embodiment of the present invention;
[0014] Figure 2 It is a schematic diagram of constructing a hyperimage according to an embodiment of the present invention;
[0015] Figure 3 It is a schematic diagram of a power consumption prediction process according to an embodiment of the present invention;
[0016] Figure 4 It is a change diagram of power consumption and each influencing factor in the data set according to an embodiment of the present invention;
[0017] Figure 5 It is the power consumption prediction results of each prediction model before and after data set alignment according to an embodiment of the present invention;
[0018] Figure 6 Schematic diagram of a power consumption prediction terminal based on a hyperimage according to an embodiment of the present invention.
[0019] Label description:
[0020] 1. A power consumption prediction terminal based on a hyperimage; 2. Memory; 3. Processor. Specific implementation manner
[0021] To describe the technical content, achieved objectives and effects of the present invention in detail, the following is described in conjunction with the implementation manners and with reference to the accompanying drawings.
[0022] Please refer to Figure 1 , an embodiment of the present invention provides a power consumption prediction method based on a hyperimage, including the steps of:
[0023] Collect a power consumption data set of a multivariate time series, map the influencing factor components of the power consumption data set to voxel coordinates, map the power consumption components of the power consumption data set to a voxel value vector, and construct a hyperimage corresponding to the time series according to the voxel coordinates and the voxel value vector;
[0024] Construct a time delay estimation algorithm based on the smoothness metric of the hyperimage, estimate the time delay between time series by minimizing the smoothness metric of the hyperimage, and perform alignment of the power consumption data set;
[0025] Use the aligned power consumption data set for power consumption prediction.
[0026] As can be seen from the above description, the beneficial effects of the present invention are as follows: Map the influencing factor sequence in the power consumption data set to voxel coordinates, map the power consumption sequence to voxel values, and construct a hyperimage corresponding to the multivariate time series; Based on the time delay estimation algorithm of hyperimage smoothness, estimate the time delay between time series by minimizing the smoothness metric of the hyperimage, and achieve alignment of the power consumption data set; Perform a power consumption prediction experiment on the power consumption data set after time series alignment. Therefore, through the time series alignment processing of the power consumption data set, the overall quality of the data set and the robustness of the prediction model are significantly improved, and the accuracy and reliability of power consumption prediction are effectively enhanced.
[0027] Further, constructing a time delay estimation algorithm based on the smoothness metric of the hyperimage includes:
[0028] Construct a hyperimage response map based on the local neighborhood covariance matrix according to the hyperimage;
[0029] Measure the smoothness of the hyperimage according to the F norm of the hyperimage response map.
[0030] As described above, a super-image response map based on the local neighborhood covariance matrix is constructed on the basis of the super-image for the smoothness strategy of the super-image. In this way, it is convenient for subsequent temporal alignment of the data set based on smoothness.
[0031] Further, constructing a super-image response map based on the local neighborhood covariance matrix according to the super-image includes:
[0032] Taking a neighborhood window centered on each voxel in the super-image, moving the neighborhood window in one direction, and statistically calculating the overall change of the voxel values at the same relative position in the window before and after the movement to obtain the deviation accumulation value of the voxel values;
[0033] Determining the local neighborhood covariance matrix of the voxel according to the deviation accumulation value of the voxel value, and obtaining the super-image response map by calculating the trace of the local neighborhood covariance matrix.
[0034] As described above, the super-image response map is a super-image with the same resolution as the super-image, and its voxel value is the trace of the local neighborhood covariance matrix. That is, each voxel in the original super-image has a local neighborhood covariance matrix, and then the trace of each local neighborhood covariance matrix is calculated and the result is recorded in the voxel position corresponding to the super-image response map. This is convenient for further calculating the smoothness of the super-image.
[0035] Further, measuring the smoothness of the super-image according to the Frobenius norm of the super-image response map includes:
[0036]
[0037] In the formula, represents the smoothness measure of the super-image, H d represents the super-image response map, represents the voxel coordinates corresponding to the influencing factor at the i-th moment of the super-image, and d represents the time-delay vector.
[0038] As described above, by calculating the smoothness, it is convenient to obtain the time delay between the electricity consumption and the influencing factors after minimizing the smoothness measure of the super-image, thereby eliminating the alignment deviation between the multivariate time series, improving the data quality in the data set, and enhancing the accuracy of electricity consumption prediction.
[0039] Further, constructing a time-delay estimation algorithm based on the smoothness measure of the super-image includes:
[0040] Estimating the components of the time-delay vector one by one through serial search based on the smoothness measure of the super-image:
[0041]
[0042] In the formula, denotes the estimated value of the time-delay component of the m-th influencing factor, d m denotes the time-delay component of the m-th influencing factor, and M denotes the number of influencing factors;
[0043] Search and update each component of the time-delay vector using the serial search algorithm estimated by the time-delay vector.
[0044] As can be seen from the above description, searching and updating each component of the time-delay vector using the serial search algorithm estimated by the time-delay vector can effectively improve the estimation efficiency of the time-delay vector.
[0045] Furthermore, using the aligned electricity consumption dataset for electricity consumption prediction includes:
[0046] Divide the aligned electricity consumption dataset into a first training set, a first validation set, and a first test set, and use the first training set and the first validation set for model training;
[0047] Generate an electricity consumption prediction model based on the trained model and the first test set;
[0048] Calculate a first prediction result through the electricity consumption prediction model.
[0049] As can be seen from the above description, aligning the electricity consumption dataset can improve the data quality of the electricity consumption dataset, and making predictions based on this can improve the prediction performance of the electricity consumption prediction model.
[0050] Furthermore, using the aligned electricity consumption dataset for electricity consumption prediction, the following includes:
[0051] Use the electricity consumption dataset before alignment for electricity consumption prediction to obtain a second prediction result;
[0052] Determine the electricity consumption prediction accuracy of the aligned electricity consumption dataset by comparing the first prediction result and the second prediction result.
[0053] As can be seen from the above description, before and after time series alignment of the electricity consumption dataset, electricity consumption prediction experiments are respectively carried out, and by comparing the prediction effects of the prediction models before and after time series alignment, the effectiveness of the alignment operation in improving the prediction effect and accuracy is verified.
[0054] Furthermore, mapping the influencing factor components of the electricity consumption dataset to voxel coordinates and mapping the electricity consumption components of the electricity consumption dataset to voxel value vectors includes:
[0055] Normalize the influencing factor components of the electricity consumption dataset to the size range required for constructing the superimage, and normalize the electricity consumption components of the electricity consumption dataset to 0-255;
[0056] Project the influence factor component into the voxel coordinates of the hyperimage, and project the power consumption component corresponding to the voxel coordinates into the voxel value vector of the hyperimage.
[0057] As can be seen from the above description, component normalization facilitates the projection of voxel coordinates and their voxel value vectors.
[0058] Further, projecting the power consumption component corresponding to the voxel coordinates into the voxel value vector of the hyperimage includes:
[0059] Allocate the voxel value vector to the corresponding voxel coordinates in combination with the interpolation method.
[0060] As can be seen from the above description, there must be non-integers after the influence factor component is normalized. Therefore, the interpolation method is needed to map the corresponding power consumption vector to the corresponding voxel coordinates to improve the accuracy of data mapping.
[0061] Please refer to Figure 6 , another embodiment of the present invention provides a power consumption prediction terminal based on a hyperimage, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements each step of the above-mentioned power consumption prediction method based on a hyperimage.
[0062] The above-mentioned power consumption prediction method and terminal based on a hyperimage of the present invention are applicable to improving the actual effect and reliability in terms of power consumption prediction accuracy and prediction performance. The following is illustrated by specific embodiments:
[0063] Please refer to Figures 1 to 5 , Embodiment 1 of the present invention is:
[0064] A power consumption prediction method based on a hyperimage, characterized by including the steps of:
[0065] S1. Collect a power consumption data set of a multivariate time series, map the influence factor components of the power consumption data set into voxel coordinates, map the power consumption components of the power consumption data set into voxel value vectors, and construct a hyperimage corresponding to the time series according to the voxel coordinates and the voxel value vectors.
[0066] In this embodiment, appropriate influencing factor components in the power consumption dataset are selected and mapped to voxel coordinates, and the power consumption component is mapped to the voxel value vector of the hyperimage, constructing a hyperimage corresponding to the multivariate time series, where the spatial hierarchical information of the time series is recorded in the hyperimage. The multivariate time series consists of a power consumption series and its influencing factor series. The construction process of the hyperimage adopts the methods of component projection and interpolation. When selecting appropriate influencing factors in the power consumption dataset, the correlation between each influencing factor and the power consumption needs to be considered. The present invention selects to calculate the information gain of each influencing factor on the power consumption and selects appropriate influencing factors according to the magnitude of the information gain.
[0067] Specifically, first, it is clear that due to sensor delay or changes in the acquisition environment, there is inevitably an alignment deviation on the time axis between the power consumption and the influencing factors. At this time, the power consumption prediction task can be expressed as follows:
[0068]
[0069] In the formula, N represents the number of model training samples; y i represents the true measured value of the power consumption; x m,i represents the historical data of the m-th influencing factor, M represents the number of influencing factors, Θ represents the parameters of the time-delay embedding model, fe(·) represents that the time-delay embedding model is usually approximated by a deep learning model, and Γ(·) represents the deviation metric between y i and its estimated value ;
[0070] Among them, y j represents the measured value of the power consumption at the j-th moment, L0 represents the prediction length, and i, j ∈ I both represent time indices; x m,j represents the measured value of the m-th influencing factor at the j-th moment, L m represents the historical data length, d = [d1,..., d M T , d ∈ Z represents the time-delay vector, which is used to parameterize the alignment deviation between the power consumption and the influencing factors, and d m (m ∈ 1, 2,..., M) represents the time-delay component of the m-th influencing factor.
[0071] The key to solving the time series alignment deviation problem lies in accurate time-delay estimation. The common time-delay estimation methods construct time-delay metrics based on the time sequence information of the time series, but these methods ignore the information at the spatial hierarchical level of the time series, that is, similar influencing factors correspond to similar prediction targets. Therefore, the present invention constructs a hyperimage based on the spatial hierarchical information of the time series, constructs a time-delay metric based on the smoothness of the hyperimage, and realizes the alignment of the multivariate time series.
[0072] Map the influencing factor components in the multivariate time series to voxel coordinates, map the electricity consumption component to a voxel value vector, and construct a multi-channel hyperimage MH corresponding to the multivariate time series: That is:
[0073]
[0074] In the formula, and h i respectively represent the voxel coordinates corresponding to the influencing factors at the i-th moment of the hyperimage and the voxel value vector at the i-th moment.
[0075] And,
[0076]
[0077] In the formula, and h i respectively represent the mapping values of the influencing factor component and the electricity consumption component; represents the set of ranges after each influencing factor is normalized, which is a non-negative integer;
[0078] It can be seen from the above formula that the electricity consumption and the m-th influencing factor are respectively normalized to the ranges of [0, 255] and [0, W m , that is, the hyperimage is an 8-bit special image with a resolution of , that is, the resolution of the hyperimage is W1×W2×…×W m . It should be noted that since there will be non-integers in the voxel coordinates after normalization, it is necessary to allocate the corresponding target value vector h i to the appropriate voxel positions through an interpolation method. Among them, the voxel with coordinates is called voxel Among them, the dimension of the voxel value vector of the hyperimage is equal to the prediction length. There must be non-integers after the influencing factor components are normalized. Therefore, an interpolation method is required to map the corresponding electricity consumption vector to the corresponding voxel coordinates. The interpolation method can be selected as the forward interpolation method or the nearest neighbor interpolation method.
[0079] In this embodiment, the prediction of electricity consumption is realized by constructing a time-delay embedding model, and a deep learning model is used to approximate the time-delay embedding model. Therefore, the voxel value vector of the hyperimage directly corresponds to the electricity consumption component in the multivariate time series, specifically the output value vector of the prediction model. Due to the existence of this correspondence, the dimension of the voxel value vector of the hyperimage is consistent with the prediction length. To simplify the calculation and facilitate the rapid search for time delay, the voxel value vector of the hyperimage is simplified, and the dimension of the voxel value vector of the hyperimage is reduced to 1, that is, the voxel value vector degenerates into a scalar.
[0080] At the same time, {y i} Low-dimensional projection and {y i+1} can effectively estimate and {y i} The time delay between them, so the metric of the time delay vector can be constructed through the local smoothness of the single-channel hyperimage. Single-channel hyperimage SH: Satisfy:
[0081]
[0082] S2. Construct a time delay estimation algorithm based on the smoothness metric of the hyperimage, estimate the time delay between time series by minimizing the smoothness metric of the hyperimage, and align the power consumption data set in time series.
[0083] Among them, after constructing the hyperimage, take a neighborhood window centered on each voxel in the hyperimage, move this window in a certain direction, and count the overall change of the voxel values at the same relative position before and after the movement within the window, and so on, to obtain the local neighborhood covariance matrix of each voxel. By calculating the trace of the local neighborhood covariance matrix of each voxel in the hyperimage, the hyperimage response map is obtained; calculate the F-norm of the hyperimage response map, and use the F-norm as the standard to measure the smoothness of the hyperimage to realize the measurement of the smoothness of the hyperimage. Among them, the hyperimage response map is a hyperimage with the same resolution as the hyperimage, and its voxel value is the trace of the local neighborhood covariance matrix. That is, each voxel in the original hyperimage has a local neighborhood covariance matrix, and then calculate the trace of each local neighborhood covariance matrix and record the result in the voxel position corresponding to the hyperimage response map.
[0084] The spatial hierarchical information of the time series is manifested on the hyperimage as when the time series is aligned, the hyperimage has the characteristics of the maximum smoothness and the minimum smoothness metric; using the above characteristics, a time delay estimation algorithm based on the hyperimage smoothness metric is realized, that is, the time delay between time series is estimated by minimizing the smoothness metric of the hyperimage, and the alignment of multivariate time series is realized.
[0085] Among them, the time delay estimation algorithm based on the hyperimage smoothness metric is specifically the serial time delay estimation based on the hyperimage smoothness metric, which specifically includes:
[0086] When searching for the time delay of a certain influencing factor component, fix values randomly for the time delay components of the remaining influencing factor sequences, then construct a hyperimage corresponding to the time series, measure and record its smoothness; when the time delay of this influencing factor component is the true time delay, the smoothness measure of the hyperimage reaches the minimum value; the same operation is performed for the time delay searches of the remaining influencing factor components, and finally the exact time delays between all influencing factor components and the power consumption component are obtained. According to the time delay results of each influencing factor and the power consumption, align the power consumption data set in a time series.
[0087] Taking two influencing factor sequences A and B as an example: when searching for the time delay between sequence A and the power consumption, fix the time delay component of sequence B, and then continuously adjust the time delay component k of sequence A within a certain time delay range A , construct hyperimages at different time delays, measure and record their smoothness, and obtain the time delay component k when the smoothness measure is minimized A ; after obtaining k A , eliminate the alignment deviation between sequence A and the power consumption, and then continue to search for the time delay component k of sequence B according to the above steps B , and finally obtain k A and k B .
[0088] It should be noted that after aligning the power consumption data set in a time series, an appropriate method should be selected for verification, which can be determined according to the specific situation.
[0089] In this embodiment, the time delay estimation based on the smoothness measure of the hyperimage mainly includes the construction of the smoothness measure of the hyperimage and the design of the time delay estimation algorithm. The specific steps are as follows:
[0090] (1) Construct the smoothness measure of the hyperimage, which specifically includes:
[0091] In order to measure the smoothness of the hyperimage, a hyperimage smoothness response map based on the local neighborhood covariance matrix is proposed.
[0092] Take a neighborhood window centered on each voxel in the hyperimage, move this window in a certain direction, and statistically calculate the overall change of the voxel values at the same relative positions before and after the movement within the window, that is:
[0093]
[0094] In the formula, E(Δg) represents the deviation accumulation of the voxel values, Δg = [Δg1,..., Δg M represents the offset of the window, represents the window function, and in this embodiment, a Gaussian window function is taken. To simplify the formula, perform a Taylor expansion on in the calculation formula of the deviation accumulation of the voxel values and substitute it back into the formula. Finally, the formula is obtained as follows:
[0095]
[0096] wherein, is the partial derivative of, that is, the gradient of the voxel in each direction in the super-image, is the local neighborhood covariance matrix of the voxel , and its specific form is:
[0097]
[0098] Define the response map H of the super-image SH d :
[0099]
[0100] wherein, tr(·) represents the trace of a matrix; λ m represents the eigenvalue of the matrix , λ m ≥0, m = 1, …, M; that is, the response map H d is a super-image with the same resolution as the super-image SH, and the value of its voxel is the trace of.
[0101] In this embodiment, the smoothness of the super-image is measured based on the F-norm of the response map H d . Let represent the smoothness measure of the super-image, then there is:
[0102]
[0103] (2) Design of the time delay estimation algorithm, specifically including:
[0104] When the influence factor sequence and the power consumption sequence are aligned, the time series corresponding to the super-image is the smoothest. Therefore, the time delay vector between the time series can be estimated by minimizing the smoothness measure of the super-image, that is
[0105]
[0106] When estimating the time delay vector d, it is necessary to simultaneously search for the optimal values of each time delay component d m in the time delay space, and the computational complexity is relatively high. Therefore, in this embodiment, after randomly selecting a component d m of the time delay vector d, fixed values are randomly assigned to the remaining components of d. When d mWhen obtaining the true time delay, the smoothness metric reaches its minimum value. Therefore, to effectively improve the estimation efficiency of the time delay vector, in this embodiment, a serial search strategy is adopted to estimate the components of the time delay vector d one by one, namely, the serial search algorithm for estimating the time delay vector d, and the formula is as follows:
[0107]
[0108] Use the serial search algorithm for estimating the time delay vector d to search for and update each component of the time delay vector d, so as to realize the estimation of the time delay vector d. Among them, d in the search m Generally starts from 0 and takes different values within a suitable time delay search range.
[0109] S3. Use the aligned electricity consumption dataset to predict electricity consumption.
[0110] Specifically, select multiple prediction models, optimize the parameters of each model, and configure the input and output parameters of the model; in addition, clarify the historical data window size and prediction step length of the training samples, and adjust the sampling frequency, etc.
[0111] As Figure 3 shown, divide the dataset into three parts: training, validation, and test sets. Use all influencing factors and electricity consumption sequences in the dataset to conduct electricity consumption prediction experiments; by comparing the prediction effects before and after time series alignment, evaluate and confirm the actual effect and reliability of the proposed time series alignment method in improving prediction performance and accuracy.
[0112] In this embodiment, by comparing the prediction effects before and after time series alignment, the improvement degree of the alignment method on prediction performance can be intuitively quantified. Specifically, if the prediction error after alignment is significantly reduced (such as the decrease of MSE and MAE, and the increase of R2), it indicates that the proposed alignment method effectively eliminates the time delay deviation in the original data and improves the quality of the dataset. This improvement in data quality can directly improve the time series alignment relationship between the influencing factors and electricity consumption, so that the prediction model can more accurately capture the internal law between variables, and finally improve the accuracy of electricity consumption prediction and the overall prediction ability of the model.
[0113] In this embodiment, the purpose of selecting multiple prediction models is to ensure the effectiveness and reliability of the experimental results by comparing the electricity consumption prediction performances of different prediction models; the prediction conditions of the dataset before and after time series alignment should be the same; it should be noted that the historical data window size, prediction length, etc. of the model are not unique and can be adjusted according to specific situations.
[0114] The following is an illustration of this embodiment in combination with practical applications:
[0115] The research dataset of this embodiment comes from the electricity consumption data in Fujian Province and the local meteorological factor data, with a duration from March 1, 2019 to March 31, 2023. Among them, the dataset includes electricity consumption, daily average temperature, daily average humidity, daily average wind speed, and daily average apparent temperature, with a sampling interval of one day. Figure 4 The change images of electricity consumption and various influencing factors in the dataset are plotted.
[0116] After obtaining the electricity consumption dataset, data preprocessing is first carried out. Then, the time series alignment is performed using the time delay estimation algorithm based on hyperimage smoothness metric. Data preprocessing includes two key steps: identifying and removing obvious outliers in the dataset and handling missing items in the dataset. Table 1 shows the time delays between various influencing factors and electricity consumption obtained by the time delay estimation algorithm proposed in this embodiment.
[0117] Table 1 Time delays of influencing factors on electricity consumption
[0118] Daily average temperature Daily average humidity Daily average wind speed Daily average perceived temperature Time delay 18 4 3 17
[0119] After obtaining the time delays between various influencing factors and electricity consumption, the electricity consumption dataset is aligned in time series according to the specific time delays of various influencing factors.
[0120] The same operations are performed on the electricity consumption dataset before and after time series alignment. The dataset is divided into training, validation, and test sets. Among them, the data of the last three months are used for testing, and 80% and 20% of the remaining data are used for training and validation of the model respectively. At the same time, the historical data window size of the input data of the prediction model is set to 20 days, the sampling frequency is 1 day, and the prediction step is 5 days.
[0121] Among them, the selected prediction models include Transformer, PatchTST, TimesNet, iTransformer, MICN, and Crossformer.
[0122] In this embodiment, the mean squared error (MSE), mean absolute error (MAE), normalized root mean square error (NRMSE), and coefficient of determination (R-squared, R 2 ) are used as error indicators to evaluate the electricity consumption prediction effect of the prediction model before and after dataset alignment. Among them, the smaller the first three indicators, the higher the prediction accuracy, and the larger the R 2 , the better the model fitting effect. At the same time, to visually display the prediction effect, Figure 5Shows the prediction results of different models on the test set before and after aligning the electricity consumption dataset.
[0123] The evaluation results are shown in Table 2, where the bold fonts in MSE, MAE, and NRMSE are the smaller values, and the bold fonts in R 2 are the larger values. The results in Table 2 show that for all models except the MAE error metric of Transformer, the first three error metrics on the electricity consumption dataset after time series alignment are smaller than those on the electricity consumption dataset before time series alignment; after time series alignment, compared with the error metric R 2 before alignment, the R 2 values after alignment are higher. This indicates that after the time series alignment operation, the error of the electricity consumption prediction model is smaller, the fitting effect of the model is better, and the prediction accuracy is higher.
[0124] Table 2 Error metrics of each prediction model before and after dataset alignment
[0125]
[0126] The electricity consumption prediction method based on hyperimage proposed in this embodiment mainly includes mapping the electricity consumption component in the electricity consumption dataset to a voxel value vector, mapping the influencing factor component to voxel coordinates to construct a hyperimage corresponding to the time series. Then construct the smoothness metric of the hyperimage, and further construct the time delay metric based on this smoothness metric to obtain an accurate time delay estimate between the influencing factors and the electricity consumption, thereby realizing the alignment of the electricity consumption dataset. On this basis, multiple prediction models are used to realize the prediction of electricity consumption. Through the alignment operation of the time series, the data quality of the dataset is effectively improved, and the prediction accuracy of the electricity consumption prediction model is improved.
[0127] Please refer to Figure 6 , Embodiment 2 of the present invention is:
[0128] An electricity consumption prediction terminal 1 based on hyperimage, including a memory 2, a processor 3, and a computer program stored on the memory 2 and executable on the processor 3. When the processor 3 executes the computer program, it realizes each step of the electricity consumption prediction method based on hyperimage in Embodiment 1.
[0129] In summary, a power consumption prediction method and terminal based on hyper-images provided by the present invention belong to the field of power consumption prediction. It includes: mapping the influence factor sequence in the power consumption data set to voxel coordinates, mapping the power consumption sequence to voxel values, and constructing a hyper-image corresponding to the multivariate time series; constructing a hyper-image response map based on the local neighborhood covariance matrix on the basis of the hyper-image for smoothness measurement of the hyper-image; designing a time-delay estimation algorithm based on hyper-image smoothness, estimating the time delay between time series by minimizing the smoothness measurement of the hyper-image, and realizing the alignment of the power consumption data set; respectively conducting power consumption prediction experiments on the power consumption data set before and after time series alignment to achieve power consumption prediction. By processing the time series alignment of the power consumption data set, the present invention significantly improves the overall quality of the data set and the robustness of the prediction model, and effectively improves the accuracy and reliability of power consumption prediction.
[0130] The above are only the embodiments of the present invention, and do not limit the patent scope of the present invention accordingly. Any equivalent transformation made by using the content of the specification and drawings of the present invention, or directly or indirectly applied in the related technical fields, shall be equally included in the patent protection scope of the present invention.
Claims
1. A method for predicting electricity consumption based on a hyperimage, characterized in that, Including the steps: Collect the electricity consumption data set of the multivariate time series, map the influencing factor components of the electricity consumption data set to voxel coordinates, map the electricity consumption components of the electricity consumption data set to voxel value vectors, and construct a hyperimage corresponding to the time series according to the voxel coordinates and the voxel value vectors; Construct a time delay estimation algorithm based on the smoothness metric of the hyperimage, estimate the time delay between time series by minimizing the smoothness metric of the hyperimage, and align the electricity consumption data set; Use the aligned electricity consumption data set for electricity consumption prediction.
2. The method for predicting power consumption based on super images according to claim 1, wherein Constructing a time delay estimation algorithm based on the smoothness metric of the hyperimage, previously including: Construct a hyperimage response map based on the local neighborhood covariance matrix according to the hyperimage; Measure the smoothness of the hyperimage according to the F-norm of the hyperimage response map.
3. The method for predicting power consumption based on super image according to claim 2, characterized in that Constructing a hyperimage response map based on the local neighborhood covariance matrix according to the hyperimage, including: Take a neighborhood window centered on each voxel in the hyperimage, move the neighborhood window in one direction, and statistically calculate the overall change of the voxel values at the same relative positions before and after the movement within the window to obtain the deviation accumulation value of the voxel values; Determine the local neighborhood covariance matrix of the voxel according to the deviation accumulation value of the voxel values, and obtain the hyperimage response map by calculating the trace of the local neighborhood covariance matrix.
4. The power consumption prediction method based on super image according to claim 2, wherein Measuring the smoothness of the hyperimage according to the F-norm of the hyperimage response map, including: In the formula, represents the smoothness metric of the hyperimage, and H d represents the hyperimage response map, represents the voxel coordinates corresponding to the influencing factors of the hyperimage at the i-th moment, and d represents the time delay vector.
5. The power consumption prediction method based on super-image according to claim 4, characterized in that Constructing a time delay estimation algorithm based on the smoothness metric of the hyperimage, including: Estimate the components of the time delay vector one by one based on the smoothness metric of the hyperimage through serial search: In the formula, represents the estimated value of the time delay component of the m-th influencing factor, and d m represents the time delay component of the m-th influencing factor, and M represents the number of influencing factors; Use the serial search algorithm for time delay vector estimation to search for and update each component of the time delay vector.
6. The power consumption prediction method based on superimage according to claim 1, wherein Using the aligned electricity consumption data set for electricity consumption prediction, including: Divide the aligned electricity consumption data set into a first training set, a first validation set and a first test set, and use the first training set and the first validation set for model training; Generate an electricity consumption prediction model according to the trained model and the first test set; Calculate the first prediction result through the electricity consumption prediction model.
7. The power consumption prediction method based on super-image according to claim 6, wherein, Using the aligned electricity consumption data set for electricity consumption prediction, afterwards including: Use the electricity consumption data set before alignment for electricity consumption prediction to obtain a second prediction result; Determine the electricity consumption prediction accuracy of the aligned electricity consumption data set by comparing the first prediction result and the second prediction result.
8. A method for predicting power consumption based on super images according to claim 1, characterized in that Mapping the influencing factor components of the electricity consumption data set to voxel coordinates and mapping the electricity consumption components of the electricity consumption data set to voxel value vectors, including: Normalize the influencing factor components of the electricity consumption data set to the size range required for constructing the hyperimage, and normalize the electricity consumption components of the electricity consumption data set to 0-255; Project the influencing factor components into the voxel coordinates of the hyperimage, and project the electricity consumption components corresponding to the voxel coordinates into the voxel value vectors of the hyperimage.
9. The power consumption prediction method based on super-image according to claim 1, wherein Projecting the electricity consumption components corresponding to the voxel coordinates into the voxel value vectors of the hyperimage, including: Allocate the voxel value vectors to the corresponding voxel coordinates by combining the interpolation method.
10. A power consumption prediction terminal based on a hyperimage, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements each step of the method for predicting power consumption based on super images according to any one of claims 1 to 9.
Citation Information
Patent Citations
Image processing method and system
CN107273904A
Daily power consumption prediction method based on VMD decomposition and LSTM network
CN112651543A
Electricity consumption analysis method and system based on machine learning, and electronic equipment
CN116894687A
Electricity consumption prediction method and system considering significant influence factors
CN119599158A
Method for obtaining spatial images through MRI and processing the resulting spatial images and product
US20100092058A1