CN113052373A - Monthly runoff change trend prediction method based on improved ELM model - Google Patents
Monthly runoff change trend prediction method based on improved ELM model Download PDFInfo
- Publication number
- CN113052373A CN113052373A CN202110284457.XA CN202110284457A CN113052373A CN 113052373 A CN113052373 A CN 113052373A CN 202110284457 A CN202110284457 A CN 202110284457A CN 113052373 A CN113052373 A CN 113052373A
- Authority
- CN
- China
- Prior art keywords
- runoff
- value
- elm
- change trend
- ipso
- 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.)
- Withdrawn
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q10/00—Administration; Management
- G06Q10/04—Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/004—Artificial life, i.e. computing arrangements simulating life
- G06N3/006—Artificial life, i.e. computing arrangements simulating life based on simulated virtual individual or collective life forms, e.g. social simulations or particle swarm optimisation [PSO]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/044—Recurrent networks, e.g. Hopfield networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- Health & Medical Sciences (AREA)
- Biophysics (AREA)
- Artificial Intelligence (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Molecular Biology (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Life Sciences & Earth Sciences (AREA)
- Mathematical Physics (AREA)
- Software Systems (AREA)
- Biomedical Technology (AREA)
- Business, Economics & Management (AREA)
- Economics (AREA)
- Human Resources & Organizations (AREA)
- Strategic Management (AREA)
- Development Economics (AREA)
- Game Theory and Decision Science (AREA)
- Entrepreneurship & Innovation (AREA)
- Marketing (AREA)
- Operations Research (AREA)
- Quality & Reliability (AREA)
- Tourism & Hospitality (AREA)
- General Business, Economics & Management (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
A monthly runoff change trend prediction method based on an improved ELM model comprises the following steps: s1, constructing a runoff comprehensive index influencing the change trend of the monthly runoff and an influencing object thereof, obtaining an observed value in the previous period, and taking the observed value in a plurality of months in the previous period as a primary selection factor; s2, performing factor screening on the primary selection factors based on a partial mutual information method; s3, improving a particle swarm algorithm and constructing an IPSO-ELM model; and S4, predicting the change trend of the monthly runoff based on the IPSO-ELM model. Constructing a runoff comprehensive index for representing the whole runoff change trend of the basin and an influence object thereof, and realizing the comprehensive representation of the runoff change trend of the whole basin; obtaining a key factor set influencing the change of the monthly runoff process by adopting a partial mutual information method; the ELM parameters are optimized by combining 10-fold cross validation and the improved particle swarm optimization, and the IPSO-ELM model is constructed according to the optimized ELM parameters, so that the prediction effect of the runoff change trend of medium and long periods can be effectively improved.
Description
Technical Field
The invention relates to the technical field of hydrologic prediction, in particular to a monthly runoff change trend prediction method based on an improved ELM model.
Background
The timely and accurate medium and long term hydrological forecast can provide important basic data and scientific decision basis for efficient utilization of water resources, construction and operation of hydraulic engineering, flood prevention and drought control command decision and the like. At present, hydrologic prediction in medium and long term is still in exploration and development stages, and the prediction precision cannot meet the actual requirements of each production department.
The commonly used medium-and-long-term runoff prediction methods mainly comprise four categories, namely a cause analysis method, a statistical method, a prediction method based on an intelligent algorithm and a prediction method based on numerical weather forecast. Among them, the cause analysis method and the statistical method are typical methods of the hydrology department, have a certain applicable scope, but have many problems to be researched. For example, the physical cause of the long-term change of the runoff sequence is complex, and the objective rule of the runoff sequence is difficult to completely master. The statistical method is mainly linear, is difficult to adapt to the complex nonlinear characteristics of runoff change influencing factors, and has certain limitation. The comprehensive prediction method based on the intelligent algorithm and the numerical weather forecast is a new method developed in recent years, and is a new technology developed along with the development of computer information technology and the emergence of a new mathematical modeling method. The method has better nonlinear mapping, generalization and fault-tolerant capability, and is widely applied to the field of runoff prediction; the latter couples the numerical weather forecast product in a certain forecast period in hydrologic forecast, and has certain research significance in exploring the forecast period of the runoff forecasting.
The medium-long term runoff prediction model based on the intelligent algorithm is mainly used for constructing prediction models based on an artificial neural network, a support vector machine and the like according to the functional relation between input variables and output variables so as to carry out prediction analysis on the medium-long term runoff in the future. Although the prediction model based on the intelligent algorithm is widely applied, the model structure is relatively complex, parameters need to be initialized and continuously optimized and adjusted in the training process, the efficiency is relatively low, the BP neural network is easy to fall into the problem of local minimum value by adopting a gradient descent-based method, and the algorithm needs to be iterated for many times, so the overall efficiency is not high. An Extreme Learning Machine (ELM) is a single hidden layer feedforward neural network, and compared with a BP neural network and a support vector Machine, the Extreme Learning Machine has the advantages of simple parameter setting, high calculation speed, small error, strong generalization capability and the like, and is widely applied to the fields of hydrology and the like. However, the conventional ELM model input weight and hidden layer threshold are randomly given, which may cause partial hidden layer nodes to fail.
In addition, the screening of key factors influencing the runoff process change is also an important content needing to be researched in medium-long term runoff prediction. The factor screening method mainly comprises a priori knowledge method, a correlation coefficient method, a principal component analysis method and an information entropy method. The priori knowledge method mainly depends on manual experience, is strong in subjectivity and has certain limitations. The correlation coefficient method and the principal component analysis method belong to linear methods on the whole, are difficult to adapt to the complex nonlinear characteristics of medium and long term runoff process influence factors, and have a certain application range. The information entropy method, especially the mutual information method ignores variable distribution and is suitable for linear and nonlinear correlation relations among alternative factors. The partial mutual information method is an improvement on the basis of the mutual information method, can effectively avoid the influence on the selected factors, reduce redundant variables and reduce the computational complexity.
Disclosure of Invention
The invention aims to provide a monthly runoff change trend prediction method based on an improved ELM model, which constructs a runoff comprehensive index for representing the whole runoff change trend of a basin and an influence object thereof, and can realize the comprehensive representation of the whole runoff change trend of the basin; aiming at the characteristics that characteristic factors influencing the change of the long-term runoff process in the whole basin have high dimension, nonlinearity and the like, a factor screening method based on a partial mutual information method is adopted, so that the influence on selected factors can be effectively avoided, redundant variables are reduced, and the calculation complexity is reduced; the ELM parameters are optimized by combining 10-fold cross validation and the improved particle swarm optimization, and the IPSO-ELM model is constructed according to the optimized ELM parameters, so that the prediction effect of the runoff change trend of medium and long periods can be effectively improved.
In order to achieve the above object, according to one aspect of the present invention, the present invention provides the following technical solutions:
a monthly runoff change trend prediction method based on an improved ELM model comprises the following steps:
s1, constructing a runoff comprehensive index influencing the change trend of the monthly runoff and an influencing object thereof, obtaining an observed value in the previous period, and taking the observed value in a plurality of months in the previous period as a primary selection factor;
s2, performing factor screening on the primary selection factors based on a partial mutual information method;
s3, improving a particle swarm algorithm and constructing an IPSO-ELM model;
and S4, predicting the change trend of the monthly runoff based on the IPSO-ELM model.
The invention is further configured to: the step S1 constructs a runoff comprehensive index affecting the change trend of the monthly runoff and an affecting object thereof, obtains an early-stage observed value, and takes the observed value of a plurality of months in the early stage as a primary selection factor, specifically,
constructing a runoff comprehensive index reflecting the water flow rich and poor change of the drainage basin, a drainage basin monthly scale surface rainfall index representing the whole rainfall rich and poor situation of the drainage basin, a remote correlation climate index influencing the whole drainage basin and a vegetation index covering the whole drainage basin, obtaining the early observed values of the indexes, and taking the obtained observed values of a plurality of months in the early period as the primary selection factor of the change trend of the monthly runoff.
The invention is further configured to: the step S2 is to perform factor screening on the primary selection factors based on the partial mutual information method, that is, the primary selection factors in the step S1 are used as alternative input factors of the partial mutual information method, the runoff comprehensive index is used as a prediction object, partial mutual information values are calculated and are sorted according to the magnitude of the partial mutual information values, the front-ranked factors are the key factor sets of the prediction model, specifically,
a partial mutual information value PMI is defined,
x'=x-E[x|z] (2)
y'=y-E[y|z] (3)
where PMI is a partial mutual information value, fX',Y'(X ', Y') is the joint probability density function of variable X 'and variable Y', fX'(X ') is the edge probability density function of the variable X', fY'(Y ') is an edge probability density function of a variable Y', E is an expected value, x is an alternative input factor, namely a primary selection factor, Y is a prediction object, namely a runoff comprehensive index, z is a selected prediction factor set, x 'represents an x residual error excluding the influence of z, and Y' represents a Y residual error excluding the influence of z;
given N discrete samples, the partial mutual information values may then be defined in discrete form,
xi'=xi-E[xi|z] (5)
yi'=yi-E[yi|z] (6)
wherein N is the number of discrete samples, i is the number of observation samples, fX',Y'(xi',yi') is (x)i',yi') joint probability density estimation function, fX'(xi') is xiEstimate of edge probability density at fY'(yi') is yi' the edge probability density estimation function, E is the expectation, xiIs the ith alternative input factor, i.e. the ith primary factor, yiFor the ith prediction object, i.e. the ith runoff comprehensive index, xi' means x excluding influence of ziResidual, yi' means y excluding influence of ziResidual errors;
the edge probability density estimation function in the formula (4) selects a gaussian function as a kernel function, specifically,
wherein j is an observation sample number, xjIs the jth alternative input factor, yjFor the j-th predicted object, the method,is that the variable X is in XiThe density function estimated value is d is the dimension of a variable X, S is a covariance matrix of the variable X, lambda is the window width, det (S) is a determinant of S, and T is a transposed symbol;
according to different alternative input factors, a plurality of partial mutual information values are obtained, the partial mutual information values are sequentially sorted from large to small, and the candidate input factor set corresponding to the partial mutual information value which is sorted in the front is the key factor set of the prediction model.
The invention is further configured to: the step S3 is to improve the particle swarm algorithm and construct the IPSO-ELM model, namely to improve the particle swarm algorithm and to adopt the key factor set in the step S2 as the model input and construct the IPSO-ELM model with the runoff comprehensive index as the model output, and concretely comprises the following steps,
s3.1, improving a particle swarm algorithm;
s3.1.1, improving the parameters of the method,
inertia weight w and acceleration constant c1、c2For balancing local and global search capabilities of particles, the parameters w, c are used each time the particle swarm algorithm is iterated1And c2The improved algorithm of (1) is as follows,
wk=[(w0-w1)cos(πk/K)+(w0+w1)]/2 (8)
in the formula, w0Is the starting value of w, w1Is the final value of w, wkIs the value of the k iteration time of w, c10Is c1Starting value of c11Is c1C is the final value of20Is c2The initial value of (a) is,c21is c2K is the current value of the iteration times, and K is the upper limit value of the iteration times;
in an iterative process, c1Linear decreasing, c2Linearly increasing, and c10Greater than c20,c11Is less than c21Selecting w as a cosine function and gradually decreasing;
s3.1.2, performing mutation operation on the mixture,
the particles are reinitialized by the probability p, the particle update algorithm is,
in the formula, xijIs the position of the ith particle velocity vector as the jth dimension component, and a is [0,1 ]]The random number in the interior determines the variation direction of the particle, xminIs the lower limit of the particle, xmaxThe upper limit value of the particles is,
probability of variation pkThe definition is that,
in the formula, pkIs taken as the k-th iteration of p, p0Is the starting value of p, p1Is the final value of p, and p0<p1;
S3.2, constructing an IPSO-ELM model;
s3.2.1, using the key factor set obtained in the step S2 as input factors for constructing the IPSO-ELM model;
s3.2.2, ELM implied layer node number selection,
searching for required hidden layer nodes by adopting a trial-and-error method, namely, the number of the initial hidden layer nodes, gradually increasing the number of the hidden layer nodes of the ELM in a linear increasing mode, training the number of the nodes to be selected after each increase for multiple times, solving the mean root mean square error value of each stage, and finally selecting the required number of the hidden layer nodes;
s3.2.3, initializing ELM parameters, specifically comprising the following steps,
s3.2.3.1, given training sample [ xi,yi],xi∈Rn,RnRepresenting a sample space with n-dimensional feature vectors, i being 1,2, …, Q being the number of training samples; the key factor set obtained in step S2 corresponds to an n-dimensional feature vector;
s3.2.3.2, determining an incentive function, and determining the number C of hidden layer nodes according to the step S3.2.2;
s3.2.3.3, initialization QpIndividual dimension D population individual tr,g,r=1,2,…,QpWherein, the value range of any one dimension is [ -1,1 [ ]]G represents the number of iterations, D ═ C × (n + 1);
s3.2.3.4 population of individuals t in the population of particle swarmr,gInput weight matrix by ELMAnd an implicit layer bias matrix dr,gThe components of the composition are as follows,
s3.2.3.5 for each population individual tr,gCalculating the output matrix H of the ELM hidden layer, and passingCalculating to obtain the output weight of the ELMWherein H+Is the generalized inverse of matrix H, T is the desired output;
s3.2.4, selecting the IPSO fitness,
calculating the root mean square error of 10-fold cross validation as IPSO fitness, and searching the individual with the minimum average root mean square error;
s3.2.5, the process of the iterative update,
s3.1 is adopted to improve the particle swarm algorithm, the positions and the speeds are updated by using the formulas (13) and (14), mutation operators are introduced, the particle speeds and the positions are initialized with a certain probability before the particles are updated, the fitness value is calculated, and the individual extreme value and the group extreme value of the particles are updated;
in the formula (I), the compound is shown in the specification,is the velocity of the d-th dimensional component of the velocity vector at the kth iteration for the ith particle,is the velocity of the d-dimensional component of the velocity vector for the ith particle at the (k +1) th iteration,is the position of the d-dimensional component of the velocity vector of the ith particle at the kth iteration,is the position of the d-dimensional component of the velocity vector of the ith particle at the (k +1) th iteration,the d-th dimension component of the solution required for the individual of the ith particle at the kth iteration,is the d-dimensional component, r, of the desired position of the population of particles at the k-th iteration1,r2Is a random function for generating [0,1 ]]A random number in between;
s3.2.6, generating the parameters needed by ELM,
and judging whether a termination condition is reached, namely whether preset precision of the IPSO fitness value is reached or a set error value is met or a set iteration number is met, if the termination condition is reached, stopping iteration, obtaining the parameter combination required by the ELM, thus obtaining the IPSO-ELM model, and if the termination condition is not reached, returning to the step S3.2.3.4.
The invention is further configured to: the step S4 predicts the change trend of the monthly runoff based on the IPSO-ELM model, specifically,
and (4) inputting the key factor set in the step (S2) as model input into the IPSO-ELM model to obtain a runoff comprehensive index predicted value, so as to predict the medium-term and long-term runoff change trend.
The invention is further configured to: comprehensively evaluating the prediction result of the monthly runoff change trend of the IPSO-ELM model by adopting a plurality of evaluation indexes of average Absolute Percentage error MAPE (Mean Absolute Percentage error), root Mean square error RMSE (root Mean Squared error), deterministic coefficient DC (deterministic coefficient), relative error RE (relative error) and qualification rate QR (qualified rate),
in the formula:is at the tpThe drainage basin runoff comprehensive index observed value at each moment,is at the tpA basin runoff comprehensive index predicted value at each moment,is the observation mean value of the basin runoff comprehensive index, nsIs the total number of samples and is,
where QR is the predicted yield, mqFor predicting qualification times, npThe total number of times is forecasted.
Compared with the prior art, the invention has the advantages that:
(1) constructing a runoff comprehensive index for representing the whole runoff change trend of the basin and an influence object thereof, and realizing the comprehensive representation of the runoff change trend of the whole basin;
(2) aiming at the characteristics that characteristic factors influencing the change of the long-term runoff process in the whole basin have high dimension, nonlinearity and the like, a factor screening method based on a partial mutual information method is adopted, so that the influence on selected factors can be effectively avoided, redundant variables are reduced, and the calculation complexity is reduced;
(3) the ELM parameters are optimized by combining 10-fold cross validation and the improved particle swarm optimization, and the IPSO-ELM model is constructed according to the optimized ELM parameters, so that the prediction effect of the runoff change trend of medium and long periods can be effectively improved.
Drawings
FIG. 1 is a flow chart of a method for predicting the change trend of monthly runoff based on an improved ELM model according to the present invention;
FIG. 2 is a flowchart of the IPSO-ELM model construction according to an embodiment of the present invention;
FIG. 3 is a comparison of the prediction results of the models of IPSO-ELM, BPNN, SVM, ELM, and PSO-ELM according to the embodiment of the present invention;
FIG. 4 is a comparison of the relative errors of the IPSO-ELM and BPNN, SVM, ELM, and PSO-ELM models, according to an embodiment of the present invention.
Detailed Description
The present invention is further illustrated by the following examples, which are intended to be purely exemplary and are not intended to limit the scope of the invention, as various equivalent modifications of the invention will occur to those skilled in the art upon reading the present disclosure and fall within the scope of the appended claims.
As shown in fig. 1, a method for predicting a change trend of monthly runoff based on an improved ELM model comprises the following steps:
s1, constructing a runoff comprehensive index influencing the change trend of the monthly runoff and an influence object thereof, obtaining an observation value in the early stage, and taking the observation value in a plurality of months in the early stage as a primary selection factor, specifically, constructing a runoff comprehensive index reflecting the rich and withered change of the water condition of the drainage basin, a rainfall index of a monthly scale surface of the drainage basin representing the full rainfall rich and withered situation of the drainage basin, a remote-related climate index influencing the whole drainage basin and a vegetation index covering the whole drainage basin, obtaining the early observation value of each index, and taking the observation value in the plurality of months in the early stage as the primary selection factor of the change trend of the monthly runoff.
S2, performing factor screening on the primary selection factors based on a partial mutual information method, specifically,
a partial mutual information value PMI is defined,
x'=x-E[x|z] (2)
y'=y-E[y|z] (3)
where PMI is a partial mutual information value, fX',Y'(X ', Y') is the joint probability density function of variable X 'and variable Y', fX'(X ') is the edge probability density function of the variable X', fY'(Y ') is an edge probability density function of a variable Y', E is an expected value, x is an alternative input factor, namely a primary selection factor, Y is a prediction object, namely a runoff comprehensive index, z is a selected prediction factor set, x 'represents an x residual error excluding the influence of z, and Y' represents a Y residual error excluding the influence of z;
given N discrete samples, the partial mutual information values may then be defined in discrete form,
xi'=xi-E[xi|z] (5)
yi'=yi-E[yi|z] (6)
wherein N is the number of discrete samples, i is the number of observation samples, fX',Y'(xi',yi') is (x)i',yi') joint probability density estimation function, fX'(xi') is xiEstimate of edge probability density at fY'(yi') is yi' the edge probability density estimation function, E is the expectation, xiIs the ith alternative input factor, i.e. the ith primary factor, yiFor the ith prediction object, i.e. the ith runoff comprehensive index, xi' means x excluding influence of ziResidual, yi' means y excluding influence of ziResidual errors;
the edge probability density estimation function in the formula (4) selects a gaussian function as a kernel function, specifically,
wherein j is an observation sample number, xjIs the jth alternative input factor, yjFor the j-th predicted object, the method,is that the variable X is in XiThe density function estimated value is d is the dimension of a variable X, S is a covariance matrix of the variable X, lambda is the window width, det (S) is a determinant of S, and T is a transposed symbol;
according to different alternative input factors, a plurality of partial mutual information values are obtained, the partial mutual information values are sequentially sorted from large to small, and the candidate input factor set corresponding to the partial mutual information value which is sorted in the front is the key factor set of the prediction model.
S3, improving the particle swarm algorithm and constructing an IPSO-ELM model, specifically,
s3.1, improving a particle swarm algorithm;
s3.1.1, improving the parameters of the method,
inertia weight w and acceleration constant c1、c2For balancing local and global search capabilities of particles, the parameters w, c are used each time the particle swarm algorithm is iterated1And c2The improved algorithm of (1) is as follows,
wk=[(w0-w1)cos(πk/K)+(w0+w1)]/2 (8)
in the formula, w0Is the starting value of w, w1Is the final value of w, wkIs the value of the k iteration time of w, c10Is c1Starting value of c11Is c1C is the final value of20Is c2Starting value of c21Is c2K is the current value of the iteration times, and K is the upper limit value of the iteration times;
in an iterative process, c1Linear decreasing, c2Linearly increasing, and c10Greater than c20,c11Is less than c21Selecting w as a cosine function and gradually decreasing;
s3.1.2, performing mutation operation on the mixture,
the particles are reinitialized by the probability p, the particle update algorithm is,
in the formula, xijIs the ith particleThe velocity vector is the position of the j-th dimension component, and a is [0,1 ]]The random number in the interior determines the variation direction of the particle, xminIs the lower limit of the particle, xmaxThe upper limit value of the particles is,
probability of variation pkThe definition is that,
in the formula, pkIs taken as the k-th iteration of p, p0Is the starting value of p, p1Is the final value of p, and p0<p1;
S3.2, constructing an IPSO-ELM model;
s3.2.1, using the key factor set obtained in the step S2 as input factors for constructing the IPSO-ELM model;
s3.2.2, ELM implied layer node number selection,
searching for required hidden layer nodes by adopting a trial-and-error method, namely, the number of the initial hidden layer nodes, gradually increasing the number of the hidden layer nodes of the ELM in a linear increasing mode, training the number of the nodes to be selected after each increase for multiple times, solving the mean root mean square error value of each stage, and finally selecting the required number of the hidden layer nodes;
s3.2.3, initializing ELM parameters, specifically comprising the following steps,
s3.2.3.1, given training sample [ xi,yi],xi∈Rn,RnRepresenting a sample space with n-dimensional feature vectors, i being 1,2, …, Q being the number of training samples; the key factor set obtained in step S2 corresponds to an n-dimensional feature vector;
s3.2.3.2, determining an incentive function, and determining the number C of hidden layer nodes according to the step S3.2.2;
s3.2.3.3, initialization QpIndividual dimension D population individual tr,g,r=1,2,…,QpWherein, the value range of any one dimension is [ -1,1 [ ]]G represents the number of iterations, D ═ C × (n + 1);
s3.2.3.4 population of individuals t in the population of particle swarmr,gInput rights by ELMValue matrixAnd an implicit layer bias matrix dr,gThe components of the composition are as follows,
s3.2.3.5 for each population individual tr,gCalculating the output matrix H of the ELM hidden layer, and passingCalculating to obtain the output weight of the ELMWherein H+Is the generalized inverse of matrix H, T is the desired output;
s3.2.4, selecting the IPSO fitness,
calculating the root mean square error of 10-fold cross validation as IPSO fitness, and searching the individual with the minimum average root mean square error;
s3.2.5, the process of the iterative update,
s3.1 is adopted to improve the particle swarm algorithm, the positions and the speeds are updated by using the formulas (13) and (14), mutation operators are introduced, the particle speeds and the positions are initialized with a certain probability before the particles are updated, the fitness value is calculated, and the individual extreme value and the group extreme value of the particles are updated;
in the formula (I), the compound is shown in the specification,for the velocity of the d-dimensional component of the velocity vector of the ith particle at the kth iteration,Is the velocity of the d-dimensional component of the velocity vector for the ith particle at the (k +1) th iteration,is the position of the d-dimensional component of the velocity vector of the ith particle at the kth iteration,is the position of the d-dimensional component of the velocity vector of the ith particle at the (k +1) th iteration,the d-th dimension component of the solution required for the individual of the ith particle at the kth iteration,is the d-dimensional component, r, of the desired position of the population of particles at the k-th iteration1,r2Is a random function for generating [0,1 ]]A random number in between;
s3.2.6, generating the parameters needed by ELM,
and judging whether a termination condition is reached, namely whether preset precision of the IPSO fitness value is reached or a set error value is met or a set iteration number is met, if the termination condition is reached, stopping iteration, obtaining the parameter combination required by the ELM, thus obtaining the IPSO-ELM model, and if the termination condition is not reached, returning to the step S3.2.3.4.
And S4, predicting the change trend of the monthly runoff based on the IPSO-ELM model, specifically, inputting the key factor set in the step S2 as model input into the IPSO-ELM model to obtain a runoff comprehensive index predicted value, thereby predicting the change trend of the medium-long runoff.
Further, the average Absolute Percentage error MAPE (Mean Absolute Percentage error), the root Mean square error RMSE (root Mean Squared error), the deterministic coefficient DC (deterministic coefficient), the relative error RE (relative error) and the qualification rate QR (qualified rate) are adopted to comprehensively evaluate the prediction result of the change trend of the monthly runoff of the IPSO-ELM model,
in the formula:is at the tpThe drainage basin runoff comprehensive index observed value at each moment,is at the tpA basin runoff comprehensive index predicted value at each moment,is the observation mean value of the basin runoff comprehensive index, nsIs the total number of samples and is,
where QR is the predicted yield, mqFor predicting qualification times, npThe total number of times is forecasted.
ELM model: the ELM belongs to a forward neural network with three layers, but is different from the forward neural network in that the weights and the bias of an input layer are randomly given, and the weights of an output layer are solved through the generalized inverse of a matrix, so that the adjustment times of network parameters can be reduced, and the training time can be effectively saved.
Given an arbitrary NelmA different sample (X)i,ti). Wherein, Xi=[xi1,xi2,…,xin]T∈Rn,ti=[ti1,ti2,…,tim]T∈RmR is the sample space, and the objective function is defined as follows:
in the formula: n is a radical ofelmIs the total number of samples, g (x) is the activation function, WiAs a weight matrix between the input layer and the hidden layer, Wi=[wi1,wi2,...win]T,βiIs an output weight matrix, β, between the hidden layer and the output layeri=[βi1,βi2,…,βim]T,biBiasing for the ith hidden layer neuron, ojIs the net output value of the j sample, Wi·XjIs WiAnd XjAnd C is the number of hidden layer neurons.
The error between the predicted value and the true value is minimum, and can be expressed as:
that is to say the presence of betai,bi,WiSuch that:
expressed in a matrix as:
Hβ=T
in the formula: h is the output of the hidden node, β is the output weight, and T is the desired output.
According to the above principle, the algorithm steps of the conventional ELM are as follows:
(1) randomly assigning input weights WiAnd hidden layer bias bi,i=1,2,…,C;
(2) Calculating a hidden layer output matrix H;
The Yazhenjiang river basin is taken as an embodiment, example simulation is carried out to verify the effect of the invention,
constructing a runoff comprehensive index influencing the change trend of the monthly runoff and an influencing object thereof, obtaining an observation value in the previous period, taking the observation value in the previous period for a plurality of months as a primary selection factor, specifically, the runoff comprehensive index reflecting the rich change of the water condition of the Yangtze river basin, the rainfall index of the month scale surface of the basin representing the full rainfall rich situation of the Yangtze river basin, 21 remote-related climate indexes influencing the whole basin and a vegetation index covering the whole basin, specifically shown in Table 1, wherein candidate factors generated by the 24 objects comprise the runoff comprehensive index f of the Yangtze river basincom(fcom(t-1),fcom(t-2),...,fcom(t-12)), surface rainfall index frain(frain(t-1),frain(t-2),...,frain(t-12)), 21 remote-dependent climate indices fatm1(fatm1(t-1),fatm1(t-2),...,fatm1(t-12)),fatm2(fatm2(t-1),fatm2(t-2),...,fatm2(t-12)),...,fatm21(fatm21(t-1),fatm21(t-2),...,fatm21(t-12)) and vegetation index fndvi(fndvi(t-1),fndvi(t-2),...,fndvi(t-12)) and other observed values of 24 subjects in the previous 12 months, wherein the total number of observed values is 288(24 x 12) as candidate factors.
TABLE 1 influence object of long-term runoff process change in Yazhenjiang basin
And (4) adopting the factor screening method based on the partial mutual information method in the step S2 to carry out optimization on the candidate factors, wherein the screened optimized factors are 13, and the basin runoff comprehensive index: f. ofcom(t-12),fcom(t-1),fcom(t-11),fcom(t-2); surface rainfall index: f. ofrain(t-1),frain(t-12); climate index: f. ofatm16(t-5),fatm15(t-6),fatm1(t-1),fatm1(t-7),fatm10(t-4); vegetation index: f. ofndvi(t-12),fndvi(t-1)。
Constructing an IPSO-ELM model, as shown in FIG. 2, wherein a data set is 4 months to 7 months in 1998 and comprises 124 groups of samples in total of early stage basin runoff comprehensive indexes, precipitation, remote correlation climate indexes and NDVI vegetation index data, wherein: the data for the 10-fold cross-validation model was 100 sets of samples in total from 4-2006 to 7-2006 (90 sets were randomly selected for training and the remaining 10 sets were used for validation models), and the test data was 24 sets of samples from 8-2006 to 7-2008.
Selecting the number of nodes of the ELM hidden layer, and selecting the number of the nodes of the hidden layer by a trial and error method, wherein the specific method comprises the following steps: and selecting Sigmoid as an excitation function of the ELM, setting the number of the initial hidden layer nodes to be 5, and gradually increasing the number of the hidden layer nodes of the ELM in a linear growth mode, wherein the step length is 5. Since the total number of training samples is 90, the number of hidden layer nodes cannot exceed 90. And (3) for the number of nodes to be selected after each increase, training 50 times each time by adopting a 5-fold cross validation method, and solving the RMSE average value of each stage to select the optimal number of nodes of the hidden layer.
Initializing ELM parameters, wherein the population scale is 40, the maximum iteration number is 400, and the particle position interval is [ -2,2]Particle velocity interval [ -0.5,0.5 [)]Other parameters are set to c10Values of 2.2, c11Values of 1.2, c20Values of 0.3, c21Taking the value 2.2, p0Values of 0.01, p1Value of 0.28, w0Value 1, w1The value is 0.1, the learning rate is 0.1, and the training target is 0.001. The activation function of the ELM selects "sigmoid".
And selecting an IPSO fitness function, calculating the root mean square error of 10-fold cross validation as the fitness of the IPSO, and searching the individual with the minimum average root mean square error.
And (3) performing iterative updating, updating the position and the speed by using the formulas (13) and (14), introducing a mutation operator, initializing the speed and the position of the particle with a certain probability before updating the particle, calculating a fitness value, and updating the individual extremum and the population extremum of the particle.
Generating parameters required by the ELM and obtaining an IPSO-ELM model, judging whether a termination condition is reached, stopping iteration when the preset precision of the fitness value is reached or the minimum error value or the maximum iteration number is met, and obtaining a parameter generation combination required by the ELM, thereby obtaining the IPSO-ELM model; if the termination condition is not reached, the iteration is continued.
And inputting the 13 optimized factors screened by the partial mutual information method into an IPSO-ELM model to obtain a runoff comprehensive index predicted value, thereby predicting the medium-term and long-term runoff change trend.
The prediction result of the model is comprehensively evaluated by adopting a plurality of evaluation indexes such as average Absolute Percentage Error MAPE (MAPE), root Mean square Error RMSE (root Mean Squared Error), deterministic coefficient DC (deterministic coefficient), relative Error RE (relative Error) and qualification rate QR (qualified rate). Wherein: the prediction result pairs of models such as IPSO-ELM, BPNN, SVM, ELM and PSO-ELM are shown in FIG. 3, and the relative error pairs are shown in FIG. 4; the overall performance pairs are shown in table 2.
TABLE 2 comparison of the comprehensive Properties of the different models
As can be seen from fig. 3, fig. 4 and table 2, the prediction effect of the IPSO-ELM model is the best, and the main reasons are: (1) the BPNN and SVM models are relatively complex in structure, parameters need to be initialized and continuously optimized and adjusted in the training process, the overall efficiency is not high, and the ELM has the advantages of simple parameter setting, high calculation speed, small error, strong generalization capability and the like, so that the overall prediction effect is superior to the two common models; (2) aiming at the problem that partial hidden layer nodes are possibly invalid due to random giving of input weights and hidden layer thresholds of the traditional ELM model, K-fold cross validation and improved particle swarm optimization are combined, the ELM model parameter optimization speed is increased, and therefore the prediction effect is improved.
Claims (6)
1. A monthly runoff change trend prediction method based on an improved ELM model is characterized by comprising the following steps:
s1, constructing a runoff comprehensive index influencing the change trend of the monthly runoff and an influencing object thereof, obtaining an observed value in the previous period, and taking the observed value in a plurality of months in the previous period as a primary selection factor;
s2, performing factor screening on the primary selection factors based on a partial mutual information method;
s3, improving a particle swarm algorithm and constructing an IPSO-ELM model;
and S4, predicting the change trend of the monthly runoff based on the IPSO-ELM model.
2. The method for predicting the change trend of the monthly runoff based on the improved ELM model as claimed in claim 1, wherein: the step S1 is to construct a runoff comprehensive index and its influence object that influence the change trend of the monthly runoff, obtain a previous observation value, and use the observation value of several months in the previous period as a primary selection factor, specifically, construct a runoff comprehensive index that reflects the rich and withered change of the watershed water, a watershed monthly scale surface rainfall index that represents the full rainfall rich and withered situation of the watershed, a remote-related climate index that influences the full watershed, and a vegetation index that covers the full watershed, obtain the previous observation value of each index, and use the observation value of several months in the previous period as the primary selection factor of the change trend of the monthly runoff.
3. The method for predicting the change trend of the monthly runoff based on the improved ELM model as claimed in claim 1, wherein: the step S2 is to perform factor screening on the primary selection factors based on the partial mutual information method, that is, the primary selection factors in the step S1 are used as alternative input factors of the partial mutual information method, the runoff comprehensive index is used as a prediction object, partial mutual information values are calculated and are sorted according to the magnitude of the partial mutual information values, the front-ranked factors are the key factor sets of the prediction model, specifically,
a partial mutual information value PMI is defined,
x'=x-E[x|z] (2)
y'=y-E[y|z] (3)
where PMI is a partial mutual information value, fX',Y'(X ', Y') is the joint probability density function of variable X 'and variable Y', fX'(X ') is the edge probability density function of the variable X', fY'(Y ') is an edge probability density function of a variable Y', E is an expected value, x is an alternative input factor, namely a primary selection factor, Y is a prediction object, namely a runoff comprehensive index, z is a selected prediction factor set, x 'represents an x residual error excluding the influence of z, and Y' represents a Y residual error excluding the influence of z;
given N discrete samples, the partial mutual information values may then be defined in discrete form,
xi'=xi-E[xi|z] (5)
yi'=yi-E[yi|z] (6)
wherein N is the number of discrete samples, i is the number of observation samples, fX',Y'(xi',yi') is (x)i',yi') joint probability density estimation function, fX'(xi') is xiEstimate of edge probability density at fY'(yi') is yi' the edge probability density estimation function, E is the expectation, xiIs the ith alternative input factor, i.e. the ith primary factor, yiFor the ith prediction object, i.e. the ith runoff comprehensive index, xi' means x excluding influence of ziResidual, yi' means y excluding influence of ziResidual errors;
the edge probability density estimation function in the formula (4) selects a gaussian function as a kernel function, specifically,
wherein j is an observation sample number, xjIs the jth alternative input factor, yjFor the j-th predicted object, the method,is that the variable X is in XiThe density function estimated value is d is the dimension of a variable X, S is a covariance matrix of the variable X, lambda is the window width, det (S) is a determinant of S, and T is a transposed symbol;
according to different alternative input factors, a plurality of partial mutual information values are obtained, the partial mutual information values are sequentially sorted from large to small, and the candidate input factor set corresponding to the partial mutual information value which is sorted in the front is the key factor set of the prediction model.
4. The method of claim 3, wherein the method for predicting the change trend of the monthly runoff based on the improved ELM model comprises the following steps: the step S3 is to improve the particle swarm algorithm and construct the IPSO-ELM model, namely to improve the particle swarm algorithm and to adopt the key factor set in the step S2 as the model input and construct the IPSO-ELM model with the runoff comprehensive index as the model output, and concretely comprises the following steps,
s3.1, improving a particle swarm algorithm;
s3.1.1, improving the parameters of the method,
inertia weight w and acceleration constant c1、c2For balancing local and global search capabilities of particles, the parameters w, c are used each time the particle swarm algorithm is iterated1And c2The improved algorithm of (1) is as follows,
wk=[(w0-w1)cos(πk/K)+(w0+w1)]/2 (8)
in the formula, w0Is the starting value of w, w1Is the final value of w, wkIs the value of the k iteration time of w, c10Is c1Starting value of c11Is c1C is the final value of20Is c2Starting value of c21Is c2K is the current value of the iteration times, and K is the upper limit value of the iteration times;
in an iterative process, c1Linear decreasing, c2Linearly increasing, and c10Greater than c20,c11Is less than c21Selecting w as a cosine function and gradually decreasing;
s3.1.2, performing mutation operation on the mixture,
the particles are reinitialized by the probability p, the particle update algorithm is,
in the formula, xijIs the position of the ith particle velocity vector as the jth dimension component, and a is [0,1 ]]The random number in the interior determines the variation direction of the particle, xminIs the lower limit of the particle, xmaxThe upper limit value of the particles is,
probability of variation pkThe definition is that,
in the formula, pkIs taken as the k-th iteration of p, p0Is the starting value of p, p1Is the final value of p, and p0<p1;
S3.2, constructing an IPSO-ELM model;
s3.2.1, using the key factor set obtained in the step S2 as input factors for constructing the IPSO-ELM model;
s3.2.2, ELM implied layer node number selection,
searching for required hidden layer nodes by adopting a trial-and-error method, namely, the number of the initial hidden layer nodes, gradually increasing the number of the hidden layer nodes of the ELM in a linear increasing mode, training the number of the nodes to be selected after each increase for multiple times, solving the mean root mean square error value of each stage, and finally selecting the required number of the hidden layer nodes;
s3.2.3, initializing ELM parameters, specifically comprising the following steps,
s3.2.3.1, given training sample [ xi,yi],xi∈Rn,RnRepresenting a sample space with n-dimensional feature vectors, i being 1,2, …, Q being the number of training samples; the key factor set obtained in step S2 corresponds to an n-dimensional feature vector;
s3.2.3.2, determining an incentive function, and determining the number C of hidden layer nodes according to the step S3.2.2;
s3.2.3.3, initialization QpIndividual dimension D population individual tr,g,r=1,2,…,QpWherein, the value range of any one dimension is [ -1,1 [ ]]G represents the number of iterations, D ═ C × (n + 1);
s3.2.3.4 population of individuals t in the population of particle swarmr,gInput weight matrix by ELMAnd an implicit layer bias matrix dr,gThe components of the composition are as follows,
s3.2.3.5 for each population individual tr,gCalculating the output matrix H of the ELM hidden layer, and passingCalculating to obtain the output weight of the ELMWherein H+Is the generalized inverse of matrix H, T is the desired output;
s3.2.4, selecting the IPSO fitness,
calculating the root mean square error of 10-fold cross validation as IPSO fitness, and searching the individual with the minimum average root mean square error;
s3.2.5, the process of the iterative update,
s3.1 is adopted to improve the particle swarm algorithm, the positions and the speeds are updated by using the formulas (13) and (14), mutation operators are introduced, the particle speeds and the positions are initialized with a certain probability before the particles are updated, the fitness value is calculated, and the individual extreme value and the group extreme value of the particles are updated;
in the formula (I), the compound is shown in the specification,is the velocity of the d-th dimensional component of the velocity vector at the kth iteration for the ith particle,is the velocity of the d-dimensional component of the velocity vector for the ith particle at the (k +1) th iteration,is the position of the d-dimensional component of the velocity vector of the ith particle at the kth iteration,is the position of the d-dimensional component of the velocity vector of the ith particle at the (k +1) th iteration,the d-th dimension component of the solution required for the individual of the ith particle at the kth iteration,is the d-dimensional component, r, of the desired position of the population of particles at the k-th iteration1,r2Is a random function for generating [0,1 ]]A random number in between;
s3.2.6, generating the parameters needed by ELM,
and judging whether a termination condition is reached, namely whether preset precision of the IPSO fitness value is reached or a set error value is met or a set iteration number is met, if the termination condition is reached, stopping iteration, obtaining the parameter combination required by the ELM, thus obtaining the IPSO-ELM model, and if the termination condition is not reached, returning to the step S3.2.3.4.
5. The method of claim 4, wherein the method for predicting the change trend of the monthly runoff based on the improved ELM model comprises the following steps: the step S4 predicts the change trend of the monthly runoff based on the IPSO-ELM model, specifically,
and (4) inputting the key factor set in the step (S2) as model input into the IPSO-ELM model to obtain a runoff comprehensive index predicted value, so as to predict the medium-term and long-term runoff change trend.
6. The method for predicting the change trend of the monthly runoff based on the improved ELM model as claimed in claim 1, wherein: comprehensively evaluating the prediction result of the monthly runoff change trend of the IPSO-ELM model by adopting a plurality of evaluation indexes of average Absolute Percentage error MAPE (Mean Absolute Percentage error), root Mean square error RMSE (root Mean Squared error), deterministic coefficient DC (deterministic coefficient), relative error RE (relative error) and qualification rate QR (qualified rate),
in the formula:is at the tpThe drainage basin runoff comprehensive index observed value at each moment,is at the tpA moment of timeThe comprehensive index prediction value of the runoff of the drainage basin,is the observation mean value of the basin runoff comprehensive index, nsIs the total number of samples and is,
where QR is the predicted yield, mqFor predicting qualification times, npThe total number of times is forecasted.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110284457.XA CN113052373A (en) | 2021-03-17 | 2021-03-17 | Monthly runoff change trend prediction method based on improved ELM model |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110284457.XA CN113052373A (en) | 2021-03-17 | 2021-03-17 | Monthly runoff change trend prediction method based on improved ELM model |
Publications (1)
Publication Number | Publication Date |
---|---|
CN113052373A true CN113052373A (en) | 2021-06-29 |
Family
ID=76513010
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110284457.XA Withdrawn CN113052373A (en) | 2021-03-17 | 2021-03-17 | Monthly runoff change trend prediction method based on improved ELM model |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113052373A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113723707A (en) * | 2021-09-08 | 2021-11-30 | 南京工业职业技术大学 | Medium-and-long-term runoff trend prediction method based on deep learning model |
CN114139802A (en) * | 2021-11-30 | 2022-03-04 | 贵州乌江水电开发有限责任公司 | Real-time optimization scheduling method based on basin water regime change trend analysis model |
CN114154383A (en) * | 2021-12-01 | 2022-03-08 | 中国人民解放军国防科技大学 | Multi-robot-source search scheme generation method and system based on cognitive search strategy |
-
2021
- 2021-03-17 CN CN202110284457.XA patent/CN113052373A/en not_active Withdrawn
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113723707A (en) * | 2021-09-08 | 2021-11-30 | 南京工业职业技术大学 | Medium-and-long-term runoff trend prediction method based on deep learning model |
CN114139802A (en) * | 2021-11-30 | 2022-03-04 | 贵州乌江水电开发有限责任公司 | Real-time optimization scheduling method based on basin water regime change trend analysis model |
CN114139802B (en) * | 2021-11-30 | 2022-12-06 | 贵州乌江水电开发有限责任公司 | Real-time optimization scheduling method based on basin water regime change trend analysis model |
CN114154383A (en) * | 2021-12-01 | 2022-03-08 | 中国人民解放军国防科技大学 | Multi-robot-source search scheme generation method and system based on cognitive search strategy |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109063911B (en) | Load aggregation grouping prediction method based on gated cycle unit network | |
CN113052373A (en) | Monthly runoff change trend prediction method based on improved ELM model | |
CN110909926A (en) | TCN-LSTM-based solar photovoltaic power generation prediction method | |
CN106448151B (en) | Short-term traffic flow prediction method | |
Lu et al. | Generalized radial basis function neural network based on an improved dynamic particle swarm optimization and AdaBoost algorithm | |
CN111563706A (en) | Multivariable logistics freight volume prediction method based on LSTM network | |
CN111340273A (en) | Short-term load prediction method for power system based on GEP parameter optimization XGboost | |
CN113705877A (en) | Real-time monthly runoff forecasting method based on deep learning model | |
CN112765894B (en) | K-LSTM-based aluminum electrolysis cell state prediction method | |
CN106971237A (en) | A kind of Medium-and Long-Term Runoff Forecasting method for optimized algorithm of being looked for food based on bacterium | |
CN112257847A (en) | Method for predicting geomagnetic Kp index based on CNN and LSTM | |
Ugur et al. | Enhanced predictive models for construction costs: A case study of Turkish mass housing sector | |
CN113947182A (en) | Traffic flow prediction model construction method based on double-stage stack graph convolution network | |
CN110738363B (en) | Photovoltaic power generation power prediction method | |
Abdalla et al. | Deep learning weather forecasting techniques: literature survey | |
CN109408896B (en) | Multi-element intelligent real-time monitoring method for anaerobic sewage treatment gas production | |
CN113988415A (en) | Medium-and-long-term power load prediction method | |
CN116303786B (en) | Block chain financial big data management system based on multidimensional data fusion algorithm | |
CN117407802A (en) | Runoff prediction method based on improved depth forest model | |
CN116663745A (en) | LSTM drainage basin water flow prediction method based on PCA_DWT | |
Li et al. | A data-driven rutting depth short-time prediction model with metaheuristic optimization for asphalt pavements based on RIOHTrack | |
CN111310974A (en) | Short-term water demand prediction method based on GA-ELM | |
Weng | Research on the House Price Forecast Based on machine learning algorithm | |
CN115481816A (en) | Time-space convolution short-term traffic flow prediction method based on complementary integrated empirical mode decomposition | |
CN113723707A (en) | Medium-and-long-term runoff trend prediction method based on deep learning model |
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 | ||
WW01 | Invention patent application withdrawn after publication | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20210629 |