CN116780524B - Industrial enterprise short-term load prediction method based on LSTM deep learning - Google Patents

Industrial enterprise short-term load prediction method based on LSTM deep learning Download PDF

Info

Publication number
CN116780524B
CN116780524B CN202310795236.8A CN202310795236A CN116780524B CN 116780524 B CN116780524 B CN 116780524B CN 202310795236 A CN202310795236 A CN 202310795236A CN 116780524 B CN116780524 B CN 116780524B
Authority
CN
China
Prior art keywords
data
numerical data
lstm
active power
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202310795236.8A
Other languages
Chinese (zh)
Other versions
CN116780524A (en
Inventor
耿庆庆
张云飞
李军
刘同海
常琼林
白瑞峰
张若昕
孙瑾睿
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shaanxi Guanglin Huicheng Energy Technology Co ltd
Original Assignee
Shaanxi Guanglin Huicheng Energy Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shaanxi Guanglin Huicheng Energy Technology Co ltd filed Critical Shaanxi Guanglin Huicheng Energy Technology Co ltd
Priority to CN202310795236.8A priority Critical patent/CN116780524B/en
Publication of CN116780524A publication Critical patent/CN116780524A/en
Application granted granted Critical
Publication of CN116780524B publication Critical patent/CN116780524B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J3/00Circuit arrangements for ac mains or ac distribution networks
    • H02J3/003Load forecast, e.g. methods or systems for forecasting future load demand
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/10Pre-processing; Data cleansing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/211Selection of the most significant subset of features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/27Regression, e.g. linear or logistic regression
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/044Recurrent networks, e.g. Hopfield networks
    • G06N3/0442Recurrent networks, e.g. Hopfield networks characterised by memory or gating, e.g. long short-term memory [LSTM] or gated recurrent units [GRU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J2203/00Indexing scheme relating to details of circuit arrangements for AC mains or AC distribution networks
    • H02J2203/10Power transmission or distribution systems management focussing at grid-level, e.g. load flow analysis, node profile computation, meshed network optimisation, active network management or spinning reserve management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • Evolutionary Computation (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Molecular Biology (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Power Engineering (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention relates to the technical field of power data processing, and discloses an industrial enterprise short-term load prediction method based on LSTM deep learning, which comprises the following steps: acquiring time sequence operation data and alternative characteristic information of an industrial enterprise; processing the data to obtain numerical data; carrying out correlation analysis on the numerical data, and establishing an optimal feature set; preprocessing the optimal feature set to establish a complete data set; scaling the complete data set to obtain a scaled complete data set; constructing an initial LSTM architecture, and optimizing training parameters by using search data to obtain a trained LSTM prediction model; and carrying out short-term load calculation on the industrial enterprise to be predicted by using the LSTM prediction model, and analyzing a calculation result. The method realizes modeling of the industrial load short-term load prediction model, can accurately predict the short-term load, meets the requirements of industrial enterprises on the short-term load prediction precision, and has practical value for guiding the operation of the industrial enterprises.

Description

Industrial enterprise short-term load prediction method based on LSTM deep learning
Technical Field
The invention relates to the technical field of power data processing, in particular to an industrial enterprise short-term load prediction method based on LSTM deep learning.
Background
The short-term load prediction is used as an important guide for daily operation of industrial enterprises, and has important significance and practical value for accurately and efficiently predicting the short-term load prediction. For the power loads of different industrial enterprises, the personalized short-term load prediction of the industrial enterprises is relatively difficult to realize through a single physical mathematical model due to the influence of comprehensive factors such as production plans, industry distribution, weather, emergencies and the like.
With the rapid development of computer technology, various algorithms are widely applied to different fields of various industries. The commonly used algorithms can be divided into three categories, namely a traditional algorithm, a fuzzy prediction and basic machine learning method and a deep learning algorithm. These algorithms all require preprocessing of the collected historical data prior to application, which can interfere with the accuracy of the short-term load predictions due to the large amount of incomplete, noisy, ambiguous, random data present in the historical electrical load data. In addition, the level of the predictive model also determines the accuracy of the load prediction. Short-term load prediction belongs to the nonlinear regression problem, and the traditional prediction method is difficult to support efficient and accurate load analysis due to the fact that the traditional prediction method cannot process nonlinear relations and big data and lacks robustness. Although the modern fuzzy prediction theory and the basic machine learning method have the nonlinear capability in the learning load sequence, the analysis efficiency is not high under big data, the time sequence information in the sequence can not be fully utilized, and the method is difficult to be practical. The deep learning method provides a new idea for application of real-world complex time series data.
Therefore, an industrial enterprise Short-Term load prediction method based on LSTM (Long Short-Term Memory) deep learning is provided, so as to meet the industrial enterprise Short-Term load prediction requirement.
Disclosure of Invention
In view of the above, the invention provides an industrial enterprise short-term load prediction method based on LSTM deep learning, which aims to solve the problems that the traditional prediction method cannot process nonlinear data, lacks robustness and is difficult to support efficient and accurate load analysis.
The invention provides an industrial enterprise short-term load prediction method based on LSTM deep learning, which comprises the following steps:
step S100: acquiring time sequence operation data and alternative characteristic information of an industrial enterprise, wherein the time sequence operation data comprises active power and time information;
step S200: processing the time sequence operation data and the alternative characteristics to obtain time sequence operation numerical data and alternative characteristic numerical data, wherein the time sequence operation numerical data comprises active power numerical data;
step S300: performing correlation analysis on the alternative characteristic numerical data and the active power numerical data, and taking the data with strong correlation between the alternative characteristic numerical data and the active power numerical data as an optimal characteristic set;
step S400: preprocessing the optimal feature set to establish a complete data set; scaling the complete data set to obtain a scaled complete data set;
step S500: constructing an initial LSTM architecture according to the scaled complete data set, and optimizing training parameters by utilizing search data to obtain a trained LSTM prediction model;
step S600: and carrying out short-term load calculation on the industrial enterprise to be predicted by utilizing the LSTM prediction model, and analyzing a calculation result.
Further, in the step S200, the processing the time sequence operation data and the candidate feature to obtain time sequence operation numerical data and candidate feature numerical data includes:
performing data cleaning on the time sequence operation data and the alternative features;
the data cleansing includes:
the missing value processing is carried out, missing numerical value points are filled by adopting a median method, time sequence data under the same variable are arranged in sequence from small to large, and missing values in the sequence are filled by selecting median;
repeating value processing, namely directly deleting the sequence according to the time sequence data under the same variable if the frequency of occurrence of a certain number in the sequence data is more than or equal to 0.6 in the ratio of the sequence length; and if the frequency of occurrence of a certain number in the sequence data is less than 0.6 in the sequence length, not deleting the sequence.
Further, in the step S300, performing correlation analysis on the candidate feature numerical data and the active power numerical data includes:
and judging the correlation between the alternative characteristic numerical data and the active power numerical data based on a Pearson correlation coefficient method, wherein the calculation formula is as follows:
wherein each candidate feature numerical dataset is considered as a vector x= (X) 1 ,x 2 ,x 3 ...), the active power numerical dataset is regarded as a vector y= (Y 1 ,y 2 ,y 3 ...), P is a measure of similarity between two vectors, x i ,y i The corresponding data value in the vector is represented,representing the mean value of the vector elements;
further, in the step S300, taking the data with strong correlation between the candidate feature numerical data and the active power numerical data as the optimal feature set includes:
determining the correlation strength according to the size of P;
when P is more than or equal to 0.8 and less than or equal to 1.0, the alternative characteristic numerical data has extremely strong correlation with the active power numerical data;
when P is more than or equal to 0.6 and less than 0.8, the alternative characteristic numerical data has strong correlation with the active power numerical data;
when P is more than or equal to 0.4 and less than 0.6, the alternative characteristic numerical data and the active power numerical data have medium strength correlation;
when P is more than or equal to 0.2 and less than 0.4, the alternative characteristic numerical data and the active power numerical data have weak correlation;
when P is more than or equal to 0 and less than 0.2, the alternative characteristic numerical data has weak correlation with the active power numerical data.
Further, in the step S400, preprocessing the optimal feature set to create a complete data set, including:
and the complete data set is divided into a training set, a verification set and a test set by taking the optimal feature set and the active power numerical data as an abscissa and taking a time sequence as an ordinate, and taking the length of the ordinate as a standard under the principle of not changing the original sequence.
Further, in the step S400, scaling the complete data set to obtain a scaled complete data set, including:
and scaling the data in the complete data set by adopting a robust function method, wherein the calculation formula is as follows:
wherein Vi represents a certain sample value in the feature data set and the load data set; median represents the median of the column in which the sample is located; IQR represents the quartile range of the sample; vi' represents the normalized value of a sample, and the calculation formula of the IQR is:
IQR=Q 3 -Q 1 (3)
the data of the column where the sample is located is sorted from small to large, the data is divided into four parts, and the separation points are respectively marked as Q 1 、Q 2 、Q 3
Further, in step S500, an initial LSTM architecture is built according to the complete data set, and training parameters are optimized by using search data to obtain a trained LSTM prediction model, which includes:
the training parameters comprise a memory unit, the number of hidden layers and a dropout parameter;
the search data is obtained based on a random search method and a grid search method;
wherein the random search method is to determine the possible existence range of the optimal parameter through the parameter space in the random search CV provided by Scikit-learn;
the grid search method is characterized in that all possible values of the training parameters are arranged and combined on the basis of the random search method, all combined results are listed to generate a grid, and finally the optimal parameter value result is obtained through the cross-validation mode of the parameters of the estimation function.
Further, in step S600, short-term load calculation is performed on the industrial enterprise to be predicted by using the LSTM prediction model, including:
the LSTM accepts an x-value input sequence, maps the x-value input sequence to a corresponding order and outputs y, and the learning and training process needs to be performed for each step from t=1 to t=τ, and for each time point t, the LSTM parameters of each layer update their states by the following equation:
Γ u =σ(W u [a <t-1> ,x <t> ]+b u ) (5)
Γ f =σ(W f [a <t-1> ,x <t> ]+b f ) (6)
Γ o =σ(W o [a <t-1> ,x <t> ]+b o ) (7)
a <t> =Γ o *g(c <t> ) (9)
y <t> =g(W y a <t> +b y ) (10)
wherein x is <t> Input data representing step t; y is <t> Is the corresponding prediction result; a, a <t> Representing the state quantity of the transfer; sigma and g are excitation functions, and tan h and sigmoid functions are used; Γ -shaped structure u 、Γ f 、Γ o Control functions for updating information, reserving information and outputting information; c <t> Is cell status information.
Further, in step S600, short-term load calculation is performed on the industrial enterprise to be predicted by using the LSTM prediction model, and a calculation result is analyzed, where the analysis calculation result includes quantitative analysis of prediction accuracy;
the quantitative analysis refers to quantitative analysis of prediction accuracy by using RMSE and MSE, and the calculation formula is as follows:
wherein RMSE (Root Mean Squared Error, root mean square error) represents the sum of squares of the differences between the predicted value and the actual value, and then root number is calculated, and MSE (Mean Squared Error, mean square error) represents the sum of squares of the differences between the predicted value and the actual value, and then average; n represents the total number of predicted points; y is actual A value representing the actual point; y is predicted The value of the predicted point is indicated.
Compared with the prior art, the invention has the beneficial effects that: by using the LSTM deep learning model and selecting the optimal feature set which is strongly related to the active power, the modeling of the industrial load short-term load prediction model is realized, the features and modes of load data can be more accurately captured, and the prediction accuracy is improved, so that the method has practical value for guiding the operation of industrial enterprises. According to the method and the device, the load prediction accuracy is improved, the self-adaptive feature learning is realized, the model performance is improved through data preprocessing and scaling, and the fine support is provided for load scheduling and energy management of industrial enterprises.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to designate like parts throughout the figures. In the drawings:
FIG. 1 is a flowchart of an industrial enterprise short-term load prediction method based on LSTM deep learning provided by an embodiment of the invention;
fig. 2 is a thumbnail of an industrial enterprise short-term load prediction method based on LSTM deep learning according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art. It should be noted that, without conflict, the embodiments of the present invention and features of the embodiments may be combined with each other. The invention will be described in detail below with reference to the drawings in connection with embodiments.
In some embodiments of the present application, referring to fig. 1-2, a method for industrial enterprise short-term load prediction based on LSTM deep learning, comprises:
step S100: and acquiring time sequence operation data and alternative characteristic information of the industrial enterprise, wherein the time sequence operation data comprises active power and time information.
Step S200: and processing the time sequence operation data and the alternative characteristics to obtain time sequence operation numerical data and alternative characteristic numerical data, wherein the time sequence operation numerical data comprises active power numerical data.
Step S300: and carrying out correlation analysis on the candidate characteristic numerical data and the active power numerical data, and taking the data with strong correlation between the candidate characteristic numerical data and the active power numerical data as an optimal characteristic set.
Step S400: and preprocessing the optimal feature set to establish a complete data set. And scaling the complete data set to obtain a scaled complete data set.
Step S500: and constructing an initial LSTM architecture according to the scaled complete data set, and optimizing training parameters by utilizing search data to obtain a trained LSTM prediction model.
Step S600: and carrying out short-term load calculation on the industrial enterprise to be predicted by using the LSTM prediction model, and analyzing a calculation result.
Specifically, the present application obtains time series operation data and alternative feature information of an industrial enterprise through step S100. Then, the time series operation data and the alternative features are processed in step S200 to obtain numerical data. Next, in step S300, correlation analysis is performed on the candidate feature data and the active power data, and data strongly correlated with the active power is screened out as an optimal feature set. In step S400, the optimal feature set is preprocessed, a complete data set is established, and scaling is performed to obtain a scaled complete data set. Next, in step S500, an initial LSTM architecture is constructed using the scaled complete data set, and a trained LSTM prediction model is obtained through training parameter optimization. Finally, in step S600, the LSTM prediction model is used to perform short-term load calculation on the industrial enterprise to be predicted, and the calculation result is analyzed.
It will be appreciated that the model enables accurate industrial enterprise short-term load prediction. By utilizing the LSTM deep learning method, the model can capture the time dependency relationship of time sequence data and complex association between features, and the accuracy of load prediction is improved. Through correlation analysis and feature selection, the model can automatically screen out features strongly related to active power, and efficiency of the prediction model is improved. In addition, through data preprocessing and scaling, the model can adapt to different data ranges and distributions, and the robustness and generalization capability of the model are improved. Therefore, the industrial enterprise short-term load prediction method based on LSTM deep learning has the effects of improving prediction accuracy, automatic feature selection and adaptive data processing.
In some embodiments of the present application, processing the time series operation data and the alternative feature in step S200 to obtain time series operation numerical data and alternative feature numerical data includes: and data cleaning is carried out on the time sequence operation data and the alternative features. The data cleaning comprises the following steps: and (3) processing missing values, namely filling missing numerical value points by adopting a median method, arranging time sequence data under the same variable in a sequence from small to large, and selecting a median to fill the missing values in the sequence. Repeating the value processing, and directly deleting the sequence when the frequency of occurrence of a certain number in the sequence data is more than or equal to 0.6 in the sequence length according to the time sequence data under the same variable. If the frequency of occurrence of a certain number in the sequence data is less than 0.6 in the sequence length, the sequence is not deleted.
Specifically, when missing numerical value points appear, a median method is adopted to fill the missing numerical values, and the integrity and the accuracy of data are ensured. Meanwhile, for time series data under the same variable, the time series data are arranged in order from small to large, and the median is selected as the basis for filling the missing value, so that the order and consistency of the data are maintained. For time sequence data under the same variable, if the frequency of a certain number in the sequence is greater than or equal to 0.6, it is indicated that the number has high repeatability in the sequence and may cause unnecessary interference to the prediction model, so that the sequence is directly deleted. And when a number appears in the sequence with a frequency of less than 0.6, the sequence is preserved because of its low repeatability, possibly containing information useful for load prediction.
It will be appreciated that such a data cleansing process is beneficial for improving the accuracy and reliability of industrial enterprise short term load prediction models. By filling the missing value, the problem of inaccurate prediction results caused by data loss is avoided, and the integrity of the data is maintained. Meanwhile, by deleting the sequence with high repeatability, the possibility that the model is interfered by repeated data is reduced, and the robustness of the model is improved. The method is beneficial to improving the data quality of the model, thereby improving the accuracy and reliability of short-term load prediction.
In some embodiments of the present application, performing correlation analysis on the candidate feature numerical data and the active power numerical data in step S300 includes: and judging the correlation between the candidate characteristic numerical data and the active power numerical data based on the Pearson correlation coefficient method, wherein the calculation formula is as follows:
wherein each candidate feature numerical dataset is considered as a vector x= (X) 1 ,x 2 ,x 3 ...), the active power numerical dataset is regarded as a vector y= (Y 1 ,y 2 ,y 3 ...), P is a measure of similarity between two vectors, x i ,y i The corresponding data value in the vector is represented,representing the mean of the vector elements.
Specifically, the pearson correlation coefficient P typically ranges from-1 to 1, indicating that there is a positive correlation between the candidate feature and the active power when P approaches 1. When P approaches-1, it indicates that there is a negative correlation. When P approaches 0, no linear correlation is shown between the two.
It will be appreciated that by performing a correlation analysis it is possible to determine which alternative features have a strong correlation with active power, i.e. their trends are similar or opposite. The data with strong correlation is selected as the optimal feature set, so that the prediction accuracy and stability of the model can be improved. The correlation analysis is helpful for screening out features which have important influence on load prediction, and reducing the interference of irrelevant features on the model, so that the performance and reliability of the prediction model are improved. The analysis method can optimize the feature selection process, provide more accurate and effective input features for the short-term load prediction model, and further improve the accuracy of the prediction result.
In some embodiments of the present application, the step S300 uses, as the optimal feature set, data having a strong correlation between the candidate feature numerical data and the active power numerical data, including: and determining the correlation strength according to the size of P. When P is more than or equal to 0.8 and less than or equal to 1.0, the alternative characteristic numerical data has extremely strong correlation with the active power numerical data. When P is more than or equal to 0.6 and less than 0.8, the alternative characteristic numerical data has strong correlation with the active power numerical data. When P is more than or equal to 0.4 and less than 0.6, the alternative characteristic numerical data is related to the active power numerical data with medium intensity. When P is more than or equal to 0.2 and less than 0.4, the alternative characteristic numerical data and the active power numerical data have weak correlation. When P is more than or equal to 0 and less than 0.2, the alternative characteristic numerical data and the active power numerical data have weak correlation.
Specifically, data with strong correlation between the candidate feature numerical data and the active power numerical data is used as the optimal feature set, namely, the candidate feature numerical data and the active power numerical data are judged to have strong correlation when P is more than or equal to 0.6.
It will be appreciated that alternative features that are closely related to active power variation are identified to construct a more accurate predictive model. By determining the strength of the correlation according to the size of P, the characteristics with smaller contribution to the prediction result can be eliminated in the characteristic selection process, so that the efficiency and accuracy of the model are improved. The features with strong correlation are selected as the optimal feature set, so that the dimension of the feature space is reduced, the training efficiency of the model is improved, and the overfitting risk of the model can be reduced.
It can be understood that the process of feature selection is optimized, features with small influence on the prediction result are eliminated, and the prediction accuracy and stability of the model are improved. By selecting features closely related to active power as inputs, the model can better capture patterns and trends of load changes, thereby improving the predictive ability of industrial enterprises for short-term loads. This further promotes efficient use of energy resources and reduction of operating costs, having a positive impact on the operation and planning decisions of the industrial enterprise.
In some embodiments of the present application, preprocessing the optimal feature set in step S400 to create a complete data set includes: the optimal feature set and the active power numerical data are taken as the abscissa, the time sequence is taken as the ordinate to form a complete data set, and the complete data set is divided into a training set, a verification set and a test set by taking the length of the ordinate as a standard under the principle of not changing the original sequence.
Specifically, the training set is used to train the model, the validation set is used to adjust the parameters, and the test set is used to measure how well the model performs.
Specifically, the optimal feature set and the corresponding active power data are aligned according to a time sequence to form a complete data set. This alignment helps the model better learn the relationship between features and load and predict from the trend of time variation. Meanwhile, the mode of dividing the complete data set into a training set, a verification set and a test set can effectively evaluate and verify the model.
It can be appreciated that the training set is used to train the model, and the model can learn the association rule between the feature set and the corresponding active power data by inputting them, so as to improve the accuracy of prediction. The verification set is used for adjusting parameters of the model, the model can be optimized by evaluating the verification set, and the optimal parameter setting is selected so as to improve the performance and generalization capability of the model. The test set is used for measuring the performance of the model, and the prediction capability of the model on unknown data is evaluated by comparing the actual load data.
It will be appreciated that the beneficial effects of such data preprocessing and complete data set construction are to provide a reliable basis for model training and evaluation. By aligning and dividing the optimal feature set with the active power data, the model can learn and verify on the basis of sufficient data, thereby improving the accuracy and stability of prediction. Meanwhile, the training set, the verification set and the test set are divided, so that the training process and the performance of the model can be monitored, the overfitting is avoided, and a reliable method is provided for evaluating the prediction effect of the model in practical application.
In some embodiments of the present application, scaling the complete data set in step S400 to obtain a scaled complete data set includes: scaling the data in the complete data set by adopting a robust function method, wherein the calculation formula is as follows:
where Vi denotes a certain sample value in the feature data set and the load data set. median represents the median of the column in which the sample is located. IQR represents the quarter bit distance of the sample. Vi' represents the normalized value of a sample, and the calculation formula of the IQR is:
IQR=Q 3 -Q 1 (3)
the data of the column where the sample is located is sorted from small to large, the data is divided into four parts, and the separation points are respectively marked as Q 1 、Q 2 、Q 3
Specifically, the scaling method used in the robust function method is based on the calculation of the median and the quartile range. First, for each sample value in the complete dataset, the median and quartile range of the column in which the sample is located are calculated. The median represents the median value of the data, and the quartile range measures the degree of dispersion of the data. The samples were then normalized using the following calculation formula: normalized value= (sample value-median)/quantile. The normalized value represents the relative position of the sample on the column, which takes into account the difference between the sample and the median and the dispersion of the overall data. By the scaling method, the original data can be mapped to a relatively uniform scale, and dimensional differences among different features are reduced, so that the model can better understand and learn the features of the data.
It can be appreciated that the robustness and stability of the model is enhanced by the present method. By scaling with the median and the quartile range, the influence of outliers or extreme data on the model can be reduced, and the adaptability of the model to various data distribution conditions can be improved. In addition, the scaled data is also beneficial to improving the convergence speed and the prediction accuracy of the model, so that the model can capture potential relations and rules between the data more easily.
In some embodiments of the present application, in step S500, an initial LSTM architecture is built according to a complete data set, training parameters are optimized using search data, and a trained LSTM prediction model is obtained, including: the training parameters include memory cell, hidden layer number and dropout parameters. The search data is obtained based on a random search method and a grid search method. The random search method determines the possible existence range of the optimal parameters through the parameter space in Randomi zedSearchCV provided by Sci k it-l earn. The grid search method is based on a random search method by arranging and combining all possible values of training parameters, listing all combined results to generate a grid, and finally obtaining an optimal parameter value result by cross-verifying the parameters of an estimation function.
Specifically, the random search method utilizes the Randomi zedSearchCV function provided by Sci kit-l earn to determine the range of possible values of a parameter by defining a parameter space. In the range, the random search method randomly selects a group of parameter values for model training and evaluation, and then adjusts the parameter range according to the evaluation result to further perform random search. The process can gradually narrow the searching range of the parameters, and finally find the optimal parameter value. The grid search method is based on a random search method, possible values of all parameters are arranged and combined, and a grid with the values of the parameters is generated. And then, training and evaluating each parameter combination in a cross-validation mode to finally obtain an optimal parameter value result.
It can be appreciated that by combining the random search and the grid search, the parameter space can be searched comprehensively and efficiently, and the optimal training parameter combination can be found, so that the performance and the prediction accuracy of the LSTM model are improved. The optimized parameters can enable the model to better adapt to the characteristics and modes of data, so that accuracy of short-term load prediction is improved, and better generalization capability is achieved. Therefore, the industrial enterprises to be predicted can more accurately predict the load condition, make reasonable scheduling and decision, and improve the production efficiency and the energy utilization efficiency.
In some embodiments of the present application, performing short-term load calculation on an industrial enterprise to be predicted using the LSTM prediction model in step S600 includes:
LSTM accepts the x-value input sequence, LSTM maps the x-value input sequence to a corresponding order and outputs y, the learning training process is performed for each step from t=1 to t=τ, and for each time point t, LSTM parameters of each layer update their state by the following equation:
Γ u =σ(W u [a <t-1> ,x <t> ]+b u ) (5)
Γ f =σ(W f [a <t-1> ,x <t> ]+b f ) (6)
Γ o =σ(W o [a <t-1> ,x <t> ]+b o ) (7)
a <t> =Γ o *g(c <t> ) (9)
y <t> =g(W y a <t> +b y ) (10)
wherein x is <t> Representing the input data of step t. y is <t> Is its corresponding prediction result. a, a <t> Representing the state quantity of the transfer. Sigma, g are excitation functions, and tan h, sigmoid functions are preferably used. Γ -shaped structure u 、Γ f 、Γ o Control functions for updating information, preserving information and outputting information.c <t> Is cell status information.
It will be appreciated that by means of the calculation of the LSTM model and the parameter updating, the historical time series data can be used to predict the short-term load situation of the industrial enterprise. The LSTM model has certain memory capacity, can capture long-term dependency in data, and predicts according to the mode and the characteristics of historical data. Through gradual computation and state transfer of time steps, the LSTM model can gradually learn and extract key load prediction information.
In some embodiments of the present application, short-term load calculation is performed on an industrial enterprise to be predicted using an LSTM prediction model in step S600, and the calculation result is analyzed, wherein analyzing the calculation result includes quantitatively analyzing the prediction accuracy.
Quantitative analysis refers to quantitative analysis of prediction accuracy by using RMSE and MSE, and the calculation formula is as follows:
wherein RMSE represents the sum of squares of differences between the predicted value and the actual value, and root number is calculated after averaging, and MSE represents the sum of squares of differences between the predicted value and the actual value, and averaging. N represents the total number of predicted points. y is actual Representing the value of the actual point. y is predicted The value of the predicted point is indicated.
Specifically, the quantitative analysis prediction accuracy is to evaluate the accuracy of a model by calculating the difference between a predicted value and an actual value. The evaluation index includes a root mean square error RMSE and a mean square error MSE. RMSE represents the mean of the sum of squares of the differences between the predicted and actual values and MSE represents the mean of the sum of squares of the differences between the predicted and actual values. The smaller the values of the two values are, the more accurate the prediction result of the prediction model is.
It will be appreciated that by calculating RMSE and MSE, the prediction accuracy of the assessment model may be quantified. Smaller RMSE and MSE values indicate smaller differences in prediction results from actual values, i.e., higher prediction accuracy. The quantitative analysis is beneficial to evaluating the reliability and accuracy of the model and helping to judge the practical application value of the model in the aspect of industrial enterprise short-term load prediction.
According to the industrial enterprise short-term load prediction method based on LSTM deep learning in the embodiment, the LSTM deep learning model is used, the optimal feature set which is strongly related to active power is selected, industrial load short-term load prediction model modeling is achieved, features and modes of load data can be captured more accurately, and prediction accuracy is improved, so that the industrial enterprise short-term load prediction method has practical value for guiding operation of the industrial enterprise. According to the method and the device, the load prediction accuracy is improved, the self-adaptive feature learning is realized, the model performance is improved through data preprocessing and scaling, and the fine support is provided for load scheduling and energy management of industrial enterprises.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flowchart and/or block of the flowchart illustrations and/or block diagrams, and combinations of flowcharts and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
Finally, it should be noted that: the above embodiments are only for illustrating the technical aspects of the present invention and not for limiting the same, and although the present invention has been described in detail with reference to the above embodiments, it should be understood by those of ordinary skill in the art that: modifications and equivalents may be made to the specific embodiments of the invention without departing from the spirit and scope of the invention, which is intended to be covered by the claims.

Claims (7)

1. An industrial enterprise short-term load prediction method based on LSTM deep learning is characterized by comprising the following steps:
step S100: acquiring time sequence operation data and alternative characteristic information of an industrial enterprise, wherein the time sequence operation data comprises active power and time information;
step S200: processing the time sequence operation data and the alternative characteristics to obtain time sequence operation numerical data and alternative characteristic numerical data, wherein the time sequence operation numerical data comprises active power numerical data;
step S300: performing correlation analysis on the alternative characteristic numerical data and the active power numerical data, and taking the data with strong correlation between the alternative characteristic numerical data and the active power numerical data as an optimal characteristic set;
step S400: preprocessing the optimal feature set to establish a complete data set; scaling the complete data set to obtain a scaled complete data set;
step S500: constructing an initial LSTM architecture according to the scaled complete data set, and optimizing training parameters by utilizing search data to obtain a trained LSTM prediction model;
step S600: carrying out short-term load calculation on industrial enterprises to be predicted by utilizing the LSTM prediction model, and analyzing a calculation result;
in the step S300, performing correlation analysis on the candidate feature numerical data and the active power numerical data includes:
and judging the correlation between the alternative characteristic numerical data and the active power numerical data based on a Pearson correlation coefficient method, wherein the calculation formula is as follows:
wherein each candidate feature numerical dataset is considered as a vector x= (X) 1 ,x 2 ,x 3 ...), the active power numerical dataset is regarded as a vector y= (Y 1 ,y 2 ,y 3 ...), P is a measure of similarity between two vectors, x i ,y i The corresponding data value in the vector is represented,representing the mean value of the vector elements;
determining the correlation strength according to the size of P;
when P is more than or equal to 0.8 and less than or equal to 1.0, the alternative characteristic numerical data has extremely strong correlation with the active power numerical data;
when P is more than or equal to 0.6 and less than 0.8, the alternative characteristic numerical data has strong correlation with the active power numerical data;
when P is more than or equal to 0.4 and less than 0.6, the alternative characteristic numerical data and the active power numerical data have medium strength correlation;
when P is more than or equal to 0.2 and less than 0.4, the alternative characteristic numerical data and the active power numerical data have weak correlation;
when P is more than or equal to 0 and less than 0.2, the alternative characteristic numerical data has weak correlation with the active power numerical data.
2. The industrial enterprise short-term load prediction method based on LSTM deep learning according to claim 1, wherein the processing the time series operation data and the candidate feature in step S200 to obtain time series operation numerical data and candidate feature numerical data includes:
performing data cleaning on the time sequence operation data and the alternative features;
the data cleansing includes:
the missing value processing is carried out, missing numerical value points are filled by adopting a median method, time sequence data under the same variable are arranged in sequence from small to large, and missing values in the sequence are filled by selecting median;
repeating value processing, namely directly deleting the sequence according to the time sequence data under the same variable if the frequency of occurrence of a certain number in the sequence data is more than or equal to 0.6 in the ratio of the sequence length; and if the frequency of occurrence of a certain number in the sequence data is less than 0.6 in the sequence length, not deleting the sequence.
3. The industrial enterprise short-term load prediction method based on LSTM deep learning according to claim 1, wherein the preprocessing the optimal feature set in step S400, to create a complete data set, includes:
and the complete data set is divided into a training set, a verification set and a test set by taking the optimal feature set and the active power numerical data as an abscissa and taking a time sequence as an ordinate, and taking the length of the ordinate as a standard under the principle of not changing the original sequence.
4. The industrial enterprise short-term load prediction method based on LSTM deep learning according to claim 3, wherein scaling the complete data set in step S400 to obtain a scaled complete data set comprises:
and scaling the data in the complete data set by adopting a robust function method, wherein the calculation formula is as follows:
wherein Vi represents a certain sample value in the feature data set and the load data set; median represents the median of the column in which the sample is located; IQR represents the quartile range of the sample; vi' represents the normalized value of a sample, and the calculation formula of the IQR is:
IQR=Q 3 -Q 1 (3)
the data of the column where the sample is located is sorted from small to large, the data is divided into four parts, and the separation points are respectively marked as Q 1 、Q 2 、Q 3
5. The industrial enterprise short-term load prediction method based on LSTM deep learning according to claim 1, wherein in step S500, an initial LSTM architecture is built according to the complete data set, training parameters are optimized by using search data, and a trained LSTM prediction model is obtained, which includes:
the training parameters comprise a memory unit, the number of hidden layers and a dropout parameter;
the search data is obtained based on a random search method and a grid search method;
wherein the random search method is to determine the possible existence range of the optimal parameter through the parameter space in the random search CV provided by Scikit-learn;
the grid search method is characterized in that all possible values of the training parameters are arranged and combined on the basis of the random search method, all combined results are listed to generate a grid, and finally the optimal parameter value result is obtained through the cross-validation mode of the parameters of the estimation function.
6. The industrial enterprise short-term load prediction method based on LSTM deep learning according to claim 1, wherein the performing short-term load calculation on the industrial enterprise to be predicted by using the LSTM prediction model in step S600 includes:
LSTM accepts the x-value input sequence, LSTM maps the x-value input sequence to a corresponding order and outputs y, the learning training process is performed for each step from t=1 to t=τ, and for each time point t, LSTM parameters of each layer update their state by the following equation:
Γ u =σ(W u [a <t-1> ,x <t> ]+b u ) (5)
Γ f =σ(W f [a <t-1> ,x <t> ]+b f ) (6)
Γ o =σ(W o [a <t-1> ,x <t> ]+b o ) (7)
a <t> =Γ o *g(c <t> ) (9)
y <t> =g(W y a <t> +b y ) (10)
wherein x is <t> Input data representing step t; y is <t> Is the corresponding prediction result; a, a <t> Representing the state quantity of the transfer; sigma and g are excitation functions, using tanh,A sigmoid function; Γ -shaped structure u 、Γ f 、Γ o Control functions for updating information, reserving information and outputting information; c <t> Is cell status information.
7. The industrial enterprise short-term load prediction method based on LSTM deep learning according to claim 1, wherein in step S600, short-term load calculation is performed on the industrial enterprise to be predicted using the LSTM prediction model, and the calculation result is analyzed, wherein analyzing the calculation result includes quantitatively analyzing prediction accuracy;
the quantitative analysis refers to quantitative analysis of prediction accuracy by using RMSE and MSE, and the calculation formula is as follows:
the RMSE represents the sum of squares of the difference between the predicted value and the actual value, the root number is calculated after the average, and the MSE represents the sum of squares of the difference between the predicted value and the actual value and the average; n represents the total number of predicted points; y is actual A value representing the actual point; y is predicted The value of the predicted point is indicated.
CN202310795236.8A 2023-06-30 2023-06-30 Industrial enterprise short-term load prediction method based on LSTM deep learning Active CN116780524B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310795236.8A CN116780524B (en) 2023-06-30 2023-06-30 Industrial enterprise short-term load prediction method based on LSTM deep learning

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310795236.8A CN116780524B (en) 2023-06-30 2023-06-30 Industrial enterprise short-term load prediction method based on LSTM deep learning

Publications (2)

Publication Number Publication Date
CN116780524A CN116780524A (en) 2023-09-19
CN116780524B true CN116780524B (en) 2024-03-22

Family

ID=88006143

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310795236.8A Active CN116780524B (en) 2023-06-30 2023-06-30 Industrial enterprise short-term load prediction method based on LSTM deep learning

Country Status (1)

Country Link
CN (1) CN116780524B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109829587A (en) * 2019-02-12 2019-05-31 国网山东省电力公司电力科学研究院 Zonule grade ultra-short term and method for visualizing based on depth LSTM network
CN112001439A (en) * 2020-08-19 2020-11-27 西安建筑科技大学 GBDT-based shopping mall building air conditioner cold load prediction method, storage medium and equipment
CN114169645A (en) * 2021-12-31 2022-03-11 中国南方电网有限责任公司 Short-term load prediction method for smart power grid
CN114186739A (en) * 2021-12-02 2022-03-15 国网辽宁省电力有限公司沈阳供电公司 Platform area short-term load prediction method based on deep learning

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109829587A (en) * 2019-02-12 2019-05-31 国网山东省电力公司电力科学研究院 Zonule grade ultra-short term and method for visualizing based on depth LSTM network
CN112001439A (en) * 2020-08-19 2020-11-27 西安建筑科技大学 GBDT-based shopping mall building air conditioner cold load prediction method, storage medium and equipment
CN114186739A (en) * 2021-12-02 2022-03-15 国网辽宁省电力有限公司沈阳供电公司 Platform area short-term load prediction method based on deep learning
CN114169645A (en) * 2021-12-31 2022-03-11 中国南方电网有限责任公司 Short-term load prediction method for smart power grid

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于LSTM-AdaBoost的城市住宅区负荷预测;李龙祥等;《吉首大学学报(自然科学版)》;第42卷(第6期);第30-35页 *

Also Published As

Publication number Publication date
CN116780524A (en) 2023-09-19

Similar Documents

Publication Publication Date Title
CN112990556A (en) User power consumption prediction method based on Prophet-LSTM model
CN112036084A (en) Similar product life migration screening method and system
US11650968B2 (en) Systems and methods for predictive early stopping in neural network training
CN112364560B (en) Intelligent prediction method for working hours of mine rock drilling equipment
CN112116198A (en) Data-driven process industrial state perception network key node screening method
CN111415008B (en) Ship flow prediction method based on VMD-FOA-GRNN
CN116187835A (en) Data-driven-based method and system for estimating theoretical line loss interval of transformer area
CN115982141A (en) Characteristic optimization method for time series data prediction
CN113033898A (en) Electrical load prediction method and system based on K-means clustering and BI-LSTM neural network
CN116780524B (en) Industrial enterprise short-term load prediction method based on LSTM deep learning
Bidyuk et al. An Approach to Identifying and Filling Data Gaps in Machine Learning Procedures
CN116960962A (en) Mid-long term area load prediction method for cross-area data fusion
CN116431346A (en) Compensation method for main memory capacity of electronic equipment
CN116561569A (en) Industrial power load identification method based on EO feature selection and AdaBoost algorithm
CN113393023B (en) Mold quality evaluation method, apparatus, device and storage medium
CN114970813A (en) Dissolved oxygen concentration data restoration and prediction method
CN111062118B (en) Multilayer soft measurement modeling system and method based on neural network prediction layering
CN114238102A (en) Staged workload prediction method and system based on composite variable characteristics
CN117933497B (en) TSA-ARIMA-CNN-based enterprise carbon emission prediction method
Jain et al. Robust Simulation Optimization with Stratification
CN116307184B (en) Causal relationship-based air pollution treatment effect evaluation method
CN116720662B (en) Distributed energy system applicability evaluation method based on set pair analysis
CN116110526B (en) Prediction method for critical stress intensity factor of titanium alloy stress corrosion
CN111507639B (en) Financing risk analysis method and device
Abd Samad et al. Deterministic Mutation-Based Algorithm for Model Structure Selection in Discrete-Time System Identification

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant