CN114925924A - Urban rail transit passenger flow short-time prediction method based on improved BP neural network - Google Patents

Urban rail transit passenger flow short-time prediction method based on improved BP neural network Download PDF

Info

Publication number
CN114925924A
CN114925924A CN202210597129.XA CN202210597129A CN114925924A CN 114925924 A CN114925924 A CN 114925924A CN 202210597129 A CN202210597129 A CN 202210597129A CN 114925924 A CN114925924 A CN 114925924A
Authority
CN
China
Prior art keywords
passenger flow
neural network
time
rail transit
whale
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.)
Pending
Application number
CN202210597129.XA
Other languages
Chinese (zh)
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.)
Yangzhou University
Original Assignee
Yangzhou University
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 Yangzhou University filed Critical Yangzhou University
Priority to CN202210597129.XA priority Critical patent/CN114925924A/en
Publication of CN114925924A publication Critical patent/CN114925924A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION 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/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • 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
    • 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
    • G06N3/084Backpropagation, e.g. using gradient descent
    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/01Detecting movement of traffic to be counted or controlled
    • G08G1/0104Measuring and analyzing of parameters relative to traffic conditions
    • G08G1/0125Traffic data processing
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02TCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
    • Y02T10/00Road transport of goods or passengers
    • Y02T10/10Internal combustion engine [ICE] based vehicles
    • Y02T10/40Engine management systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • Software Systems (AREA)
  • Human Resources & Organizations (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Biomedical Technology (AREA)
  • Mathematical Physics (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Strategic Management (AREA)
  • Biophysics (AREA)
  • Health & Medical Sciences (AREA)
  • Economics (AREA)
  • Development Economics (AREA)
  • Game Theory and Decision Science (AREA)
  • Analytical Chemistry (AREA)
  • Chemical & Material Sciences (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

The invention discloses an urban rail transit passenger flow short-time prediction method based on an improved BP neural network, which is characterized in that the passenger flow volume of a single station in pre-acquired rail transit AFC card swiping data is summarized according to time granularity in the operation time to be used as a pretreatment sample; processing the preprocessed sample by adopting an empirical mode decomposition method to obtain a plurality of intrinsic mode functions IMFs and residual errors; optimizing a whale algorithm; improving a BP neural network based on a whale optimization algorithm, searching for an optimal weight and a threshold, training by using intrinsic mode functions IMFs as model input, and adjusting parameter values in the training process; and constructing a combination model of whale optimization BP neural network based on empirical mode decomposition to obtain a passenger flow prediction value. The method can be used for carrying out stabilization processing on the time sequence data of the rail transit passenger flow, and improving the short-time prediction precision of the urban rail transit passenger flow by combining with an improved BP neural network.

Description

Urban rail transit passenger flow short-time prediction method based on improved BP neural network
Technical Field
The invention belongs to the field of urban rail transit short-time passenger flow prediction, and particularly relates to an urban rail transit short-time passenger flow prediction method based on an improved BP neural network.
Background
With the continuous development of urban rail transit, subways gradually become a travel mode of daily selection of people, so that the prediction of the passenger flow of a subway station in a certain period of time in the future is realized based on time series data of historical passenger flow, and on one hand, the capacity configuration of a wire network, the time scheme of train adjustment, the route guidance scheme of passengers and the like can be optimized for relevant departments; on the other hand, the reference of the travel modes can be provided for the traveler, so that the pressure between various travel modes can be balanced.
The development process of short-term passenger flow prediction can be roughly divided into three stages. The first stage is a conventional mathematical statistics-based model, such as a Historical average model (HA), least squares, ARIMA, logistic regression, kalman filter model, K-nearest neighbor model, and the like. The second stage is a model based on machine learning. With the development of machine learning, some machine learning models and hybrid prediction models are gradually applied to the field of short-term passenger flow prediction, for example, using decision trees, random forests, multi-layer perceptrons, Support Vector Machine (SVM) models, and the like. As a branch of machine learning, deep learning has been rapidly developed in recent years, and its good prediction performance has greatly promoted innovation in the traffic prediction field, for example, short-term traffic prediction at all rail transit stations in the whole network can be performed using one model with higher prediction accuracy, and the short-term traffic prediction also enters a third development stage, which is a development stage represented by a deep learning model. The cyclic neural network RNN, the convolutional neural network CNN, the graph convolution neural network GCN and the like at the stage are mined and applied to short-time passenger flow prediction, and a large number of deep learning frames are developed immediately.
Although studies on prediction of short-term traffic flow or traffic flow have been receiving wide attention in recent years, most of them fail to sufficiently grasp the characteristics of short-term traffic flow data such as chronology, non-stationarity, and non-linearity. Therefore, the invention designs an urban rail transit passenger flow short-time prediction method based on empirical mode decomposition and a neural network.
Disclosure of Invention
The purpose of the invention is as follows: in order to improve the short-time passenger flow prediction precision of the rail transit, the invention provides an urban rail transit short-time passenger flow prediction method based on an improved BP neural network, and the urban rail transit short-time passenger flow prediction method is used for carrying out stabilization processing on time series data of the rail transit passenger flow and improving the short-time passenger flow prediction precision of the rail transit.
The technical scheme is as follows: the invention provides an urban rail transit passenger flow short-time prediction method based on an improved BP neural network, which specifically comprises the following steps:
(1) summarizing station entering passenger flow volume of a single station in pre-acquired AFC card swiping data of rail transit according to time granularity within operation time as a preprocessing sample;
(2) processing the preprocessed sample by adopting an empirical mode decomposition method to obtain a plurality of intrinsic mode functions IMFs and residual errors;
(3) optimizing a whale algorithm;
(4) improving a BP neural network based on a whale optimization algorithm, searching for an optimal weight and a threshold, training by using intrinsic mode functions IMFs in the step (2) as model input, and adjusting parameter values in the training process;
(5) and constructing a combination model of whale optimization BP neural network based on empirical mode decomposition to obtain a passenger flow prediction value.
Further, the step (1) comprises the steps of:
(11) filtering the abnormal data;
(12) dividing the m-day passenger flow time sequence data according to time granularity, dividing the m-day passenger flow time sequence data according to Xmin time granularity in each operation period to obtain n time periods, then counting the passenger flow in each time period, and establishing an initial sample;
(13) the data for m days obtained from the treatment were processed according to the following ratio of 9: the scale of 1 is divided into a training set and a test set.
Further, the step (2) comprises the steps of:
(21)k(t)=(k 1 ,…,k t ,…,k T ) For the passenger flow sequence, T is the time sequence length initialization of the inbound passenger flow: let r be 0 =k (t) ,i=1;
(22) Obtaining an ith intrinsic mode function IMF:
(221) initialization: h is a total of 0 (t)=r i-1 (t),j=1;
(222) For a given original signal k (t), all maximum value points and minimum value points are searched, and three are adopted
Fitting the upper envelope e of the signal with a sub-spline interpolation function n (t) and the lower envelope e l (t);
(223) Calculate the average of the upper and lower envelopes:
Figure BDA0003668552660000021
(224) calculating the timing h j (t):
h j (t)=h j-1 (t)-m j-1 (t)
(225) Judgment of h j (t) whether or not a condition for becoming IMFn is satisfied; if h j (t) satisfies the condition, it is the ith IMF (IMF) of the original signal k (t) i (t)), performing (23); if the condition is not satisfied, the step (222) to (225) is repeated until j +1 is satisfied, and the process is stopped until the condition is satisfied; the Cauchy convergence criterion is adopted as a threshold value for stopping screening, and the defined standard deviation is as follows:
Figure BDA0003668552660000031
S D reference number ofThe value is 0.2-0.3, and when the calculation standard deviation of two continuous times is in the interval, the screening can be stopped;
(23) and (3) screening the ith intrinsic mode function IMF component from the original sequence to obtain a residual error r (t):
r(t)=r i-1 (t)-imf i (t)
(26) if the number of extreme points of the residual r (t) is still greater than or equal to 2, making i equal to i +1, continuing (22) and screening other IMFs; otherwise, ending;
(27) the original sequence k (t) is expressed as a plurality of intrinsic mode functions IMFn and residuals r (t), namely:
Figure BDA0003668552660000032
further, the step (3) comprises the steps of:
(31) defining the process of searching prey as the process of searching the optimal solution of a certain problem, the mathematical model is as follows:
D=|C·X J (t)-X(t)|
X(t+1)=X J (t)-A·D
in the formula, D is the updating step length when searching prey; a and C are coefficients; x J (t) is the optimal solution for the current location and is replaced at each iteration; x (t) is the current position;
(32) the random number is adopted for position updating, so that the capacity of a whale optimization algorithm is improved, the whale optimization algorithm is not easy to fall into a local optimal solution, and a mathematical model is as follows:
D 1 =|X rand (t)-X(t)|
X(t+1)=X rand (t)-A·D 1
in the formula, X rand Is a random number, i.e. a random position; d 1 Is the update step size when enclosing prey;
(33) prey on prey: shrinking and surrounding: in the iterative process, a in the formula a of 2-2T/T is 0 from 2, so that the process that whales shrink to surround preys is simulated;
spiral updating position: simulating a spiral predation mode of whales, and establishing a position process between the whales and the target, wherein a mathematical model is as follows:
D 2 =|X J (t)-X(t)|
X(t+1)=D 2 ·e bl ·cos(2πl)+X J (t)
in the formula, D 2 The step length is updated during predation; b is a constant, l is [ -1,1 [)]A random number in between;
assuming that the probability of whale updating the optimized position in the contraction enclosure mechanism or spiral tracking is 50% each, the mathematical model is as follows:
Figure BDA0003668552660000041
wherein p is a random number between 0 and 1.
Further, the step (4) comprises the steps of:
(41) initializing the weight alpha and the threshold beta of the BP neural network, and determining the network topology structure, wherein k 1 ,k 2 ,…,k n Denoted by is the input vector, { K } 1 ,K 2 ,…,K n Represents the output vector;
(42) converting the weight and the threshold into a position vector of whale, setting an initial population size N, a maximum evolution algebra Tmax, and selecting a mean square error as an optimized target function of the whale;
(43) setting the learning rate alpha to be 0.01, wherein the model has high convergence rate and is not easy to fall into local optimum;
(44) the activation function selects a tansig function and a purelin function, and the formula is as follows:
Figure BDA0003668552660000042
y=αx+β
wherein x is an input variable; e is a natural constant;
(45) calculating individual fitness, finding out the position of the current optimal individual, and marking as x best (t);
(46) Updating the individual location according to the value of A; when p is<0.5 and | A<1, according to the formula X (t +1) ═ X J (t) -a · D updating individual locations; when p is<0.5 and | A | ≧ 1, according to formula X (t +1) ═ X rand (t)-A·D 1 Updating the individual position; when p is more than or equal to 0.5, D is obtained according to the formula X (t +1) 2 ·e bl .cos(2πl)+X J (t) updating the individual location;
(47) and taking the target error precision and the maximum iteration number as termination criteria, and assigning the obtained optimal weight alpha and the threshold beta to the BP neural network.
Further, the step (5) includes the steps of:
(51) based on the data of swiping cards for m days continuously, the time sequence k (t) ═ k (k) of the passenger flow is calculated according to X min time granularity 1 ,…,k t ,…,k T ) Decomposing the IMFn by using the EMD method to obtain intrinsic modulus IMFn and residual r (t);
(52) normalizing the decomposed components by using mapminmax function, wherein the normalized value is generally [ -1,1 [ -1]To (c) to (d); assume that data k is k ═ { k } t Normalized to
Figure BDA0003668552660000051
The specific calculation formula is as follows:
Figure BDA0003668552660000052
in the formula, y ma3 And y min Artificially set upper and lower bounds, k min And k ma3 Is the maximum and minimum in the sample;
(53) applying the normalized data to a whale optimization BP network model for training and simulation;
(54) the predicted value K of each component IMFn And K r(t) And performing inverse normalization, and then reconstructing and superposing the inverse normalization to obtain a final predicted value K.
Has the advantages that: compared with the prior art, the invention has the beneficial effects that: the method comprises the steps of optimizing external and internal environments of a BP neural network respectively by using an empirical mode decomposition and a whale optimization algorithm, establishing a combined prediction model for predicting the arrival passenger flow at a subway station, realizing stabilization treatment on a non-stable and non-linear arrival passenger flow time sequence by using the empirical mode decomposition, searching for optimal model parameters of the BP neural network by using the whale optimization algorithm, and realizing optimization of internal and external structures; the method can improve the short-time passenger flow prediction precision of the rail transit, has important significance for making a reasonable scheduling optimization scheme for relevant departments, selecting a better travel mode for travelers, reducing traffic jam and the like, and provides a new method for the short-time passenger flow prediction of the urban rail transit.
Drawings
FIG. 1 is a flow chart of the present invention;
FIG. 2 is a timing diagram of the present invention for 15min traffic;
FIG. 3 is a diagram of EMD decomposition results of inbound passenger flows according to the present invention;
FIG. 4 is a topology structure diagram of the BP neural network of the present invention;
FIG. 5 is a comparison of predicted results for the present invention;
fig. 6 is a comparison graph of prediction error for the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings.
The invention provides an urban rail transit passenger flow short-time prediction method based on an improved BP neural network, which is characterized in that original passenger flow data are decomposed into a limited number of intrinsic mode functions IMFs with local characteristics and different frequencies and residual errors by empirical mode decomposition to obtain unstable and nonlinear characteristics of the data, the unstable and nonlinear characteristics are used as input of a prediction model, and a whale optimization algorithm is adopted to optimize the weight and threshold of the BP neural network to obtain a more stable prediction model. As shown in fig. 1, the method comprises the following steps:
step 1: and summarizing station entering passenger flow volume of a single station in the pre-acquired rail transit AFC card swiping data according to time granularity in operation time to be used as a preprocessing sample.
Processing the abnormal data: data meeting the following conditions will be filtered out: unreasonable entering and exiting: the station names of the station entering vehicles and the station names of the station exiting vehicles are the same; secondly, the time for entering and exiting is unreasonable, and the time for entering and exiting is outside the range of subway operation time; the inbound time is the same as the outbound time or the inbound time is after the outbound time; the theoretical shortest inbound or outbound time is too short or too long; unreasonable trip time: the total travel time of the passengers is too short and is less than the time in the train with the shortest path recorded by the train schedule between the ODs; the total time is too long and exceeds the maximum stay time of passengers on a single trip or the failure time of the intelligent ticket card.
Dividing the m-day passenger flow time sequence data according to time granularity, dividing the m-day passenger flow time sequence data according to Xmin time granularity in each operation period to obtain n time periods, and then counting the passenger flow in each time period to establish an initial sample; and dividing the data of m days obtained by processing into a training set and a test set according to a certain proportion. And summarizing the processed data according to the time granularity of 15min to obtain the inbound passenger flow time sequence, which is shown in figure 2.
Step 2: and processing the preprocessed sample by using an empirical mode decomposition method to obtain a plurality of intrinsic mode functions IMFs and residual errors.
And (3) processing the preprocessed samples obtained in the step (1) by adopting an empirical mode decomposition method to obtain 7 Intrinsic Mode Functions (IMFs) and residual errors, and taking the IMFs and the residual errors as model input.
The processed inbound passenger flow sequence k (t) ═ (k) is processed 1 ,…,k t ,…,k T ) Decomposition is carried out, wherein T is the time sequence length of the inbound passenger flow, k t For time t, the EMD process is as follows:
step 2.1: initialization: let r be 0 =k (t) ,i=1;
Step 2.2: obtaining an ith intrinsic mode function IMF:
1) initialization: h is 0 (t)=r i-1 (t),j=1;
2) For a given original signal k (t), all maximum value points and minimum value points are searched, and a cubic spline interpolation function is adopted to fit the signalUpper envelope e of n (t) and the lower envelope e l (t);
3) Calculate the average of the upper and lower envelopes:
Figure BDA0003668552660000071
4) calculating the timing h j (t):
h j (t)=h j-1 (t)-m j-1 (t)
5) Judgment h j (t) whether or not the condition for becoming the eigenmode function IMFn is satisfied. If h j (t) satisfies the condition, it is the ith IMF (IMF) of the original signal k (t) i (t)), performing step 2.3; if the condition is not satisfied, let j equal to j +1, repeat 2) to 5) of step 2.2), repeat until the condition is satisfied and stop. The Cauchy convergence criterion is adopted as a threshold value for stopping screening, and the defined standard deviation is as follows:
Figure BDA0003668552660000072
S D the reference value of (2) is 0.2-0.3, and when the calculated standard deviation of two consecutive times is in the interval, the screening can be stopped.
Step 2.3: screening the ith intrinsic mode function IMF component from the original sequence to obtain residual error r (t)
r(t)=r i-1 (t)-imf i (t)
Step 2.4: if the number of the extreme points of the residual error r (t) is still greater than or equal to 2, making i equal to i +1, and continuing to screen other intrinsic mode functions IMF in step 2.2; otherwise, ending.
Step 2.5: the complex original sequence k (t) is expressed as a plurality of intrinsic mode functions IMFn and residuals r (t), namely:
Figure BDA0003668552660000073
the EMD decomposition results obtained through the above steps are shown in fig. 3.
And step 3: optimizing the whale algorithm.
Whale optimization is an algorithm based on the hunting behavior of whale, and the algorithm simulates the three predation steps of the whale: search for prey, surround prey, prey (bubble net attack). The specific implementation process is as follows:
step 3.1: searching prey: defining the process of searching prey as the process of searching the optimal solution of a certain problem, the mathematical model is as follows:
D=|C·X J (t)-X(t)|
X(t+1)=X J (t)-A·D
in the formula: d is the updating step length when searching prey; a and C are coefficients; x J (t) is the optimal solution for the current location and is replaced at each iteration; x (t) is the current position. The calculation process for a and C is as follows:
A=2a·r-a
C=2r
a=2-2t/T
in the formula: r is a random number belonging to the range of 0 to 1; the value of a decreases linearly from 2 to 0; and T is the total iteration number.
Step 3.2: surrounding a prey: in the stage, random numbers are adopted for position updating, so that the capacity of a whale optimization algorithm is improved, the whale optimization algorithm is not easy to fall into a local optimal solution, and a mathematical model is as follows:
D 1 =|X rand (t)-X(t)|
X(t+1)=X rand (t)-A·D 1
in the formula: x rand Is a random number, i.e. a random position; d 1 Is the update step size when enclosing the prey.
Step 3.3: prey on prey preys
1) Shrinking and surrounding: an iterative process of speaking a in the formula a 2-2T/T from 2 to 0 simulates the process of whale shrinking around a prey.
2) Spiral updating position: simulating a spiral predation mode of whales, and establishing a position process between the whales and a target, wherein a mathematical model is as follows:
D 2 =|X J (t)-X(t)|
X(t+1)=D 2 ·e bl ·cos(2πl)+X J (t)
in the formula: d 2 The step length is updated during predation; b is a constant, l is [ -1,1 [)]A random number in between.
In order to shape this synchronous behavior, assuming that whales update their optimal positions in the shrink wrapping mechanism or spiral tracking, the probability of whales updating the optimal positions in the shrink wrapping mechanism or spiral tracking is 50%, the mathematical model is as follows:
Figure BDA0003668552660000081
in the formula: p is a random number between 0 and 1.
And 4, step 4: and (3) improving the BP neural network based on a whale optimization algorithm, searching for an optimal weight and a threshold, training by using the IMFs in the step (2) as model input, and adjusting parameter values in the training process. The specific process is as follows:
step 4.1: the weight value alpha and the threshold value beta of the BP neural network are initialized, and the network topology structure is determined as shown in figure 4, wherein k 1 ,k 2 ,…,k n Denoted by is the input vector, { K } 1 ,K 2 ,…,K n Denoted by is the output vector.
Step 4.2: and (4) converting the weight and the threshold in the step (4.1) into a position vector of the whale, setting an initial population size N, a maximum evolution algebra Tmax, and selecting a mean square error as an optimized target function of the whale.
Step 4.3: the learning rate α is set to 0.01, and at this time, the model convergence rate is fast and is not likely to fall into local optimum.
Step 4.4: the activation function selects a tansig function and a purelin function, and the formula is as follows:
Figure BDA0003668552660000091
y=αx+β
in the formula: x is an input variable; e is a natural constant.
Step 4.5: calculating individual fitness, finding out the position of the current optimal individual, and marking as x best (t)。
Step 4.6: the individual location is updated according to the value of a. When p is<0.5 and | A-<1, according to the formula X (t +1) ═ X J (t) -a · D updating individual locations; when p is<0.5 and | A | > 1, according to the formula X (t +1) ═ X rand (t)-A·D 1 Updating the individual positions; when p is more than or equal to 0.5, according to the formula X (t +1) ═ D 2 ·e bl ·cos(2πl)+X J (t) updating the individual location.
Step 4.7: and taking the target error precision and the maximum iteration number as termination criteria, and assigning the obtained optimal weight alpha and the threshold beta to the BP neural network.
And 5: and constructing a whale optimized BP neural network combined model (EMD-WOA-BP) based on empirical mode decomposition to obtain a passenger flow prediction value.
Based on the data of swiping cards for m days continuously, the time sequence k (t) ═ k (k) of the passenger flow is calculated according to X min time granularity 1 ,…,k t ,…,k T ) Decomposing the IMFn by using the EMD method to obtain an intrinsic modulus IMFn and a residual r (t); normalizing the decomposed components by using mapminmax function, wherein the normalized value is generally [ -1,1 [ -1]In the middle of; assume that data k is k ═ { k } t Normalized to
Figure BDA0003668552660000092
The specific calculation formula is as follows:
Figure BDA0003668552660000093
in the formula: y is max And y min Artificially set upper and lower bounds, k min And k max Are the maximum and minimum values in the sample. Applying the normalized data to a whale optimization BP network model for training and simulation; the predicted value K of each component IMFn And K r(t) And performing inverse normalization, and then reconstructing and superposing the inverse normalization to obtain a final predicted value K.
The passenger flow time sequence is calculated according to 15min time granularity on the basis of the card swiping data of 25 continuous days, the obtained prediction result is shown in figure 5, the prediction value of the combined model is closer to the actual value relative to a single model, and the prediction effect is better. The abscissa in the passenger flow prediction result graph represents the test sample number, the ordinate represents the passenger flow volume, and the prediction time period is 5:45-24:00 every day. The obtained prediction error comparison graph is shown in fig. 6, and when the passenger flow peak is faced, the error of the combined model is far smaller than that of the single model, so that the combined model has a better fitting effect. And in general, the error value of the combined model is smaller than that of the test sample number on the abscissa and the prediction error on the ordinate in the single model diagram.

Claims (7)

1. A method for predicting urban rail transit passenger flow in a short time based on an improved BP neural network is characterized by comprising the following steps:
(1) summarizing station entering passenger flow volume of a single station in pre-acquired AFC card swiping data of rail transit according to time granularity within operation time as a preprocessing sample;
(2) processing the preprocessed sample by adopting an empirical mode decomposition method to obtain a plurality of intrinsic mode functions IMFs and residual errors;
(3) optimizing a whale algorithm;
(4) improving a BP neural network based on a whale optimization algorithm, searching for an optimal weight and a threshold, training by using intrinsic mode functions IMFs in the step (2) as model input, and adjusting parameter values in the training process;
(5) and constructing a combination model of whale optimization BP neural network based on empirical mode decomposition to obtain a passenger flow prediction value.
2. The urban rail transit passenger flow short-time prediction method based on the improved BP neural network as claimed in claim 1, wherein the step (1) comprises the following steps:
(11) filtering the abnormal data;
(12) dividing the m-day passenger flow time sequence data according to time granularity, dividing the m-day passenger flow time sequence data according to Xmin time granularity in each operation period to obtain n time periods, then counting the passenger flow in each time period, and establishing an initial sample;
(13) the data for m days obtained from the treatment were processed according to the following ratio of 9: the ratio of 1 is divided into a training set and a test set.
3. The method for urban rail transit passenger flow short-term prediction based on the improved BP neural network as claimed in claim 1, wherein the step (2) comprises the following steps:
(21)k(t)=(k 1 ,…,k t ,…,k T ) For the passenger flow sequence, T is the time sequence length initialization of the inbound passenger flow: let r be 0 =k (t) ,i=1;
(22) Obtaining an ith intrinsic mode function IMF;
(23) and (3) screening the ith intrinsic mode function IMF component from the original sequence to obtain a residual error r (t):
r(t)=r i-1 (t)-imf i (t)
(24) if the number of the extreme points of the residual error r (t) is still more than or equal to 2, making i equal to i +1, continuing (22), and screening other intrinsic mode functions IMF; otherwise, ending;
(25) the original sequence k (t) is expressed as a plurality of intrinsic mode functions IMFn and residuals r (t), namely:
Figure FDA0003668552650000021
4. the urban rail transit passenger flow short-time prediction method based on the improved BP neural network as claimed in claim 1, wherein the step (3) comprises the following steps:
(31) the process of searching prey is defined as the process of searching the optimal solution of a certain problem, and the mathematical model is as follows:
D=|C·X J (t)-X(t)|
X(t+1)=X J (t)-A·D
in the formula, D is the updating step length when searching prey; a and C are coefficients; x J (t) is the optimal solution for the current location and is replaced at each iteration; x (t) is the current position;
(32) the random number is adopted for position updating, so that the whale optimization algorithm capacity is improved, the whale optimization algorithm is not easy to fall into a local optimal solution, and a mathematical model is as follows:
D 1 =|X rand (t)-X(t)|
X(t+1)=X rand (t)-A·D 1
in the formula, X rand Is a random number, i.e. a random position; d 1 Is the update step size when enclosing prey;
(33) prey on prey: shrinking and surrounding: in the iterative process, the value of a in the formula a-2T/T is linearly reduced from 2 to 0, so that the process that whales shrink to surround prey is simulated;
spiral updating position: simulating a spiral predation mode of whales, and establishing a position process between the whales and the target, wherein a mathematical model is as follows:
D 2 =|X J (t)-X(t)|
X(t+1)=D 2 ·e bl ·cos(2πl)+X J (t)
in the formula, D 2 The step length is updated during predation; b is a constant and l is [ -1,1]A random number in between;
the probability of updating the optimal position of whale in the contraction enclosure mechanism or spiral tracking is 50%, and the mathematical model is as follows:
Figure FDA0003668552650000022
wherein p is a random number between 0 and 1.
5. The method for predicting urban rail transit passenger flow in short time based on the improved BP neural network as claimed in claim 1, wherein the step (4) comprises the following steps:
(41) initializing weight alpha and threshold beta of BP neural network, and determining network topology structure, wherein k 1 ,k 2 ,…,k n Denotes an input vector, { K } 1 ,K 2 ,…,K n Denotes an output vector;
(42) converting the weight and the threshold into a position vector of whale, setting an initial population size N, a maximum evolution algebra Tmax, and selecting a mean square error as an optimized target function of the whale;
(43) setting the learning rate alpha to be 0.01, wherein the model has high convergence rate and is not easy to fall into local optimum;
(44) the activation function selects a tansig function and a purelin function, and the formula is as follows:
Figure FDA0003668552650000031
y=αx+β
wherein x is an input variable; e is a natural constant;
(45) calculating individual fitness, finding out the position of the current optimal individual, and marking as x best (t);
(46) Updating the individual location according to the value of A; when p is<0.5 and | A<1, according to the formula X (t +1) ═ X J (t) -a · D updating individual locations; when p is<0.5 and | A | ≧ 1, according to formula X (t +1) ═ X rand (t)-A·D 1 Updating the individual position; when p is more than or equal to 0.5, according to the formula X (t +1) ═ D 2 ·e bl ·cos(2πl)+X J (t) updating the individual location;
(47) and taking the target error precision and the maximum iteration number as termination criteria, and assigning the obtained optimal weight alpha and the threshold beta to the BP neural network.
6. The method for predicting urban rail transit passenger flow in short time based on the improved BP neural network as claimed in claim 1, wherein the step (5) comprises the following steps:
(51) taking the data of swiping cards for m days continuously as a base, and measuring the granularity according to X min timeCalculating a passenger flow time series k (t) ═ k 1 ,…,k t ,…,k T ) Decomposing the IMFn by using the EMD method to obtain an intrinsic modulus IMFn and a residual r (t);
(52) normalizing the decomposed components by using mapminmax function, wherein the normalized value is generally [ -1,1 [ -1]To (c) to (d); assume that data k ═ k t Normalized to
Figure FDA0003668552650000033
The specific calculation formula is as follows:
Figure FDA0003668552650000032
in the formula, y max And y min Artificially set upper and lower bounds, k min And k is max Is the maximum and minimum in the sample;
(53) applying the normalized data to a whale optimized BP network model for training and simulation;
(54) the predicted value K of each component I3Fn And K r(t) And performing inverse normalization, and then reconstructing and superposing the inverse normalization to obtain a final predicted value K.
7. The method for urban rail transit passenger flow short-term prediction based on the improved BP neural network as claimed in claim 3, wherein the step (22) comprises the following steps:
(221) initialization: h is 0 (t)=r i-1 (t),j=1;
(222) For a given original signal k (t), all maximum value points and minimum value points are searched, and a cubic spline interpolation function is adopted to fit an upper envelope line e of the signal n (t) and the lower envelope e l (t);
(223) Calculate the average of the upper and lower envelopes:
Figure FDA0003668552650000041
(224) calculating the time sequence h j (t):
h j (t)=h j-1 (t)-m j-1 (t)
(225) Judgment h j (t) whether or not a condition for becoming IMFn is satisfied; if h j (t) satisfies the condition, it is the ith IMF (IMF) of the original signal k (t) i (t)), performing (23); if the condition is not satisfied, making j equal to j +1, repeating the steps (222) to (225), and repeating until the condition is satisfied and stopping; the Cauchy convergence criterion is adopted as a threshold value for stopping screening, and the defined standard deviation is as follows:
Figure FDA0003668552650000042
S D the reference value of (2) is 0.2-0.3, and when the calculated standard deviation of two consecutive times is in the interval, the screening can be stopped.
CN202210597129.XA 2022-05-30 2022-05-30 Urban rail transit passenger flow short-time prediction method based on improved BP neural network Pending CN114925924A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210597129.XA CN114925924A (en) 2022-05-30 2022-05-30 Urban rail transit passenger flow short-time prediction method based on improved BP neural network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210597129.XA CN114925924A (en) 2022-05-30 2022-05-30 Urban rail transit passenger flow short-time prediction method based on improved BP neural network

Publications (1)

Publication Number Publication Date
CN114925924A true CN114925924A (en) 2022-08-19

Family

ID=82811872

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210597129.XA Pending CN114925924A (en) 2022-05-30 2022-05-30 Urban rail transit passenger flow short-time prediction method based on improved BP neural network

Country Status (1)

Country Link
CN (1) CN114925924A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116468324A (en) * 2023-04-25 2023-07-21 北京化工大学 Data-driven traffic hub arrival passenger flow volume decomposition-integration prediction method
CN116682265A (en) * 2023-08-04 2023-09-01 南京隼眼电子科技有限公司 Traffic flow prediction model construction method, traffic flow prediction model using method and electronic equipment
CN117787746A (en) * 2023-12-28 2024-03-29 辽宁科技大学 Building energy consumption prediction method based on ICEEMDAN-IDBO-BILSTM

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116468324A (en) * 2023-04-25 2023-07-21 北京化工大学 Data-driven traffic hub arrival passenger flow volume decomposition-integration prediction method
CN116468324B (en) * 2023-04-25 2024-01-05 北京化工大学 Data-driven traffic hub arrival passenger flow volume decomposition-integration prediction method
CN116682265A (en) * 2023-08-04 2023-09-01 南京隼眼电子科技有限公司 Traffic flow prediction model construction method, traffic flow prediction model using method and electronic equipment
CN117787746A (en) * 2023-12-28 2024-03-29 辽宁科技大学 Building energy consumption prediction method based on ICEEMDAN-IDBO-BILSTM
CN117787746B (en) * 2023-12-28 2024-05-28 辽宁科技大学 Building energy consumption prediction method based on ICEEMDAN-IDBO-BILSTM

Similar Documents

Publication Publication Date Title
CN114925924A (en) Urban rail transit passenger flow short-time prediction method based on improved BP neural network
CN108846517B (en) Integration method for predicating quantile probabilistic short-term power load
CN109002948B (en) CDA-BP-based microgrid short-term photovoltaic power generation power prediction method
Dong et al. Wind power prediction based on recurrent neural network with long short-term memory units
EP0240679B1 (en) Improving the training of markov models used in a speech recognition system
CN110969290A (en) Runoff probability prediction method and system based on deep learning
CN112149902B (en) Subway short-time arrival passenger flow prediction method based on passenger flow characteristic analysis
CN114626585B (en) Urban rail transit short-time passenger flow prediction method based on generation countermeasure network
CN106022549A (en) Short term load predication method based on neural network and thinking evolutionary search
Karagul et al. Using 2-Opt based evolution strategy for travelling salesman problem
CN115496257A (en) Short-term vehicle speed prediction based on space-time fusion
CN114970815A (en) Traffic flow prediction method and device based on improved PSO algorithm optimized LSTM
CN114822533B (en) Voice interaction method, model training method, electronic device and storage medium
CN116681152A (en) Short-term load prediction method based on SOM-BP neural network improved Prophet model
Lai et al. Bus arrival time prediction using wavelet neural network trained by improved particle swarm optimization
CN112036651A (en) Electricity price prediction method based on quantum immune optimization BP neural network algorithm
CN110322055A (en) A kind of method and system improving data risk model scoring stability
CN115662401B (en) Customer service call voice recognition method based on continuous learning
CN114463978A (en) Data monitoring method based on rail transit information processing terminal
CN115018156A (en) Short-term wind power prediction method
CN115409170A (en) Sample data generation and trip demand prediction model training and prediction method and device
CN108417204A (en) Information security processing method based on big data
CN112785022B (en) Method and system for excavating electric energy substitution potential
Wen Single-site passenger flow forecast based on ga-lstm
CN110580548A (en) Multi-step traffic speed prediction method based on class integration learning

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