CN110533905B - Traffic flow prediction method, system and equipment - Google Patents

Traffic flow prediction method, system and equipment Download PDF

Info

Publication number
CN110533905B
CN110533905B CN201910595128.XA CN201910595128A CN110533905B CN 110533905 B CN110533905 B CN 110533905B CN 201910595128 A CN201910595128 A CN 201910595128A CN 110533905 B CN110533905 B CN 110533905B
Authority
CN
China
Prior art keywords
bird nest
traffic flow
updated
determining
fitness value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910595128.XA
Other languages
Chinese (zh)
Other versions
CN110533905A (en
Inventor
蔡延光
乐冰
蔡颢
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong University of Technology
Original Assignee
Guangdong University of Technology
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 Guangdong University of Technology filed Critical Guangdong University of Technology
Priority to CN201910595128.XA priority Critical patent/CN110533905B/en
Publication of CN110533905A publication Critical patent/CN110533905A/en
Application granted granted Critical
Publication of CN110533905B publication Critical patent/CN110533905B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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
    • G08G1/0129Traffic data processing for creating historical data or processing based on historical data
    • 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
    • G08G1/0133Traffic data processing for classifying traffic situation

Abstract

The application discloses a traffic flow prediction method, which comprises the following steps: determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm; preprocessing input highway traffic flow data to obtain a training sample; training a preset radial basis function neural network by using a training sample to obtain a traffic flow prediction model: and predicting the traffic flow by using the traffic flow prediction model. According to the technical scheme provided by the application, the initial parameters of the preset radial basis function neural network are determined through an improved cuckoo algorithm, and then the traffic flow is predicted by using the traffic flow prediction model, so that the obtained traffic flow prediction model has higher convergence speed and better prediction precision, and has a good effect in predicting the traffic flow of the expressway. The application also provides a traffic flow prediction system, equipment and a computer readable storage medium, which have the beneficial effects.

Description

Traffic flow prediction method, system and equipment
Technical Field
The present application relates to the field of traffic flow prediction, and in particular, to a method, system, device, and computer-readable storage medium for traffic flow prediction.
Background
In recent years, traffic problems are increasingly serious due to the fact that the traffic flow of expressway is more and more, road congestion is caused, and certain threat is brought to life and property safety of people, so that effective control of traffic flow is a problem which needs to be solved urgently in the current society. The Cuckoo Search algorithm (CS) has strong global optimization capability and can be well applied to a highway traffic flow prediction model, but with the popularization of CS algorithm application, experiments show that the CS algorithm cannot jump out of the current optimal solution due to the limitation of Search capability in the iterative process, so that the effective control of highway traffic flow becomes very difficult.
Therefore, how to accurately predict the traffic flow of the expressway is a technical problem which needs to be solved by the technical personnel in the field at present.
Disclosure of Invention
An object of the present application is to provide a method, system, apparatus, and computer-readable storage medium for traffic flow prediction for accurately predicting traffic flow of a highway.
In order to solve the above technical problem, the present application provides a method for predicting a traffic flow, including:
determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm;
preprocessing input highway traffic flow data to obtain a training sample;
training the preset radial basis function neural network by using the training sample to obtain a traffic flow prediction model:
and predicting the traffic flow by using the traffic flow prediction model.
Optionally, the determining an initial parameter of the preset radial basis function neural network by using an improved cuckoo algorithm includes:
encoding parameters of the radial basis function neural network;
initializing parameters of the improved cuckoo algorithm;
determining a fitness function of the improved cuckoo algorithm;
determining the fitness values of all bird nest positions according to the fitness function, and determining the optimal bird nest position according to each fitness value;
updating the position of the bird nest by adopting an improved monkey mountain climbing process strategy, and determining the fitness value of the updated position of the bird nest according to the fitness function;
judging whether the updated fitness value of the bird nest position is larger than the fitness value of the optimal bird nest position;
and if so, updating the optimal bird nest position to the updated bird nest position.
Optionally, after updating the optimal bird nest position to the updated bird nest position, the method further includes:
carrying out self-adaptive updating on the recognized probability;
generating a random number, and judging whether the random number is greater than the updated recognition probability;
if so, randomly changing the position of the bird nest, and determining the fitness value of the randomly changed position of the bird nest according to the fitness function;
judging whether the fitness value of the randomly changed bird nest position is greater than the fitness value of the optimal bird nest position;
and if the fitness value of the randomly changed bird nest position is greater than that of the optimal bird nest position, updating the optimal bird nest position to the randomly changed bird nest position.
Optionally, the updating the position of the bird nest by using the improved monkey mountain climbing process strategy includes:
according to the ith bird nest position xi=(xi1,xi2,…,xin) And formula
Figure BDA0002117408460000021
Determining a crawling process coefficient Deltax of the ith bird nesti(ii) a Wherein, Δ xi=(Δxi1,Δxi2,...,Δxin);
According to the climbing process coefficient DeltaxiBy the formula
Figure BDA0002117408460000022
Calculating a pseudo gradient vector f'ij(xi);
According to the pseudo gradient vector f'ij(xi) By the formula
Figure BDA0002117408460000023
Calculating updated bird nest position yi(ii) a Wherein, yi=(yi1,yi2,...,yin);
Judging the updated bird nest position yiWhether within a reasonable range and satisfying f (y)i)≥f(xi);
If yes, the ith bird nest position x is determinediUpdated to the updated bird nest position yi
If not, keeping the ith bird nest position xiThe change is not changed;
wherein a is a hill climbing step length, χ is a random number belonging to [0,1], and sign is a sign function.
The present application also provides a system for traffic flow prediction, the system comprising:
the determining module is used for determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm;
the preprocessing module is used for preprocessing input highway traffic flow data to obtain a training sample;
the training module is used for training the preset radial basis function neural network by using the training sample to obtain a traffic flow prediction model:
and the prediction module is used for predicting the traffic flow by utilizing the traffic flow prediction model.
Optionally, the determining module includes:
the encoding submodule is used for encoding the parameters of the radial basis function neural network;
the initialization submodule is used for initializing parameters of the improved cuckoo algorithm;
a first determining submodule for determining a fitness function of the improved cuckoo algorithm;
the second determining submodule is used for determining the fitness values of all the bird nest positions according to the fitness function and determining the optimal bird nest position according to each fitness value;
the first updating submodule is used for updating the position of the bird nest by adopting an improved monkey hill climbing process strategy and determining the fitness value of the updated position of the bird nest according to the fitness function;
the first judgment submodule is used for judging whether the fitness value of the updated bird nest position is larger than the fitness value of the optimal bird nest position or not;
and a third determining submodule, configured to update the optimal bird nest position to the updated bird nest position when the fitness value of the updated bird nest position is greater than the fitness value of the optimal bird nest position.
Optionally, the determining module further includes:
the second updating submodule is used for carrying out self-adaptive updating on the recognition probability;
a second judgment submodule, configured to generate a random number, and judge whether the random number is greater than the updated recognition probability;
a random change submodule, configured to randomly change the nest position when the random number is greater than the updated recognition probability, and determine a fitness value of the randomly changed nest position according to the fitness function;
the third judgment submodule is used for judging whether the fitness value of the randomly changed bird nest position is larger than the fitness value of the optimal bird nest position;
and the third updating submodule is used for updating the optimal bird nest position to the randomly changed bird nest position if the fitness value of the randomly changed bird nest position is greater than the fitness value of the optimal bird nest position.
Optionally, the first update sub-module includes:
a determination unit for determining the ith bird nest position xi=(xi1,xi2,…,xin) And formula
Figure BDA0002117408460000041
Determining a crawling process coefficient Deltax of the ith bird nesti(ii) a Wherein, Δ xi=(Δxi1,Δxi2,...,Δxin);
A first calculating unit for calculating the creep coefficient Δ xiBy the formula
Figure BDA0002117408460000042
Calculating a pseudo gradient vector f'ij(xi);
A second computing unit to derive from the pseudo gradient vector f'ij(xi) By the formula
yij=xij+a·sign(f′ij(xi) Calculate an updated bird's nest position yi(ii) a Wherein, yi=(yi1,yi2,...,yin);
A judging unit for judging the updated bird nest position yiWhether within a reasonable range and satisfying f (y)i)≥f(xi);
An updating unit for updating the updated bird nest position yiWithin the reasonable range and satisfies f (y)i)≥f(xi) Then, the ith bird nest position xiUpdated to the updated bird nest position yi
A holding unit for holding the updated bird nest position yiIs not within the reasonable range or does not satisfy f (y)i)≥f(xi) While maintaining said ith nest position xiThe change is not changed;
wherein a is a hill climbing step length, χ is a random number belonging to [0,1], and sign is a sign function.
The present application also provides a traffic flow prediction apparatus including:
a memory for storing a computer program;
a processor for implementing the steps of the method of traffic flow prediction as described in any one of the above when the computer program is executed.
The present application also provides a computer-readable storage medium having a computer program stored thereon, which, when being executed by a processor, carries out the steps of the method of traffic flow prediction according to any one of the preceding claims.
The application provides a traffic flow prediction method, which comprises the following steps: determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm; preprocessing input highway traffic flow data to obtain a training sample; training a preset radial basis function neural network by using a training sample to obtain a traffic flow prediction model: and predicting the traffic flow by using the traffic flow prediction model.
According to the technical scheme, the initial parameters of the preset radial basis function neural network are determined through an improved cuckoo algorithm, then the preset radial basis function neural network is trained by using training samples to obtain a traffic flow prediction model, and finally the traffic flow is predicted by using the traffic flow prediction model, so that the obtained traffic flow prediction model has higher convergence speed and better prediction precision, and has a good effect in predicting the expressway traffic flow. The application also provides a traffic flow prediction system, a traffic flow prediction device and a computer readable storage medium, which have the beneficial effects and are not repeated herein.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a traffic flow prediction method according to an embodiment of the present application;
FIG. 2 is a flow chart of an actual representation of S101 in a method of traffic flow prediction as provided in FIG. 1;
FIG. 3 is a flow chart of another practical representation of S101 in a method of traffic flow prediction as provided in FIG. 1;
fig. 4 is a block diagram of a traffic flow prediction system according to an embodiment of the present application;
FIG. 5 is a block diagram of another traffic flow prediction system provided in accordance with an embodiment of the present application;
fig. 6 is a block diagram of a traffic flow prediction apparatus according to an embodiment of the present application.
Detailed Description
The core of the application is to provide a method, a system, equipment and a computer readable storage medium for traffic flow prediction, which are used for accurately predicting the traffic flow of a highway.
To make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some but not all embodiments of the present application. All other embodiments obtained by a person of ordinary skill in the art without any inventive work based on the embodiments in the present application are within the scope of protection of the present application.
Referring to fig. 1, fig. 1 is a flowchart illustrating a traffic flow prediction method according to an embodiment of the present disclosure.
The method specifically comprises the following steps:
s101: determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm;
the cuckoo search algorithm is a novel meta-heuristic search algorithm, and the idea is mainly based on two strategies: nestling parasitism and levy flight mechanisms of cuckoos. An optimal nest is searched and obtained through a random walk mode to hatch own eggs, an efficient optimization searching mode can be achieved through the mode, the method has the main advantages of being few in parameters, simple to operate, easy to achieve, high in random searching path optimization and optimization searching capacity and the like, however, experiments show that in the iteration process of a CS algorithm, due to the limitation of the searching capacity, the current optimal solution cannot be skipped, and effective control of highway traffic flow becomes very difficult, so that the traffic flow prediction method is provided for solving the problems;
the Radial Basis Function (RBF) neural network is a feedforward type neural network with good performances such as unique optimal approximation (overcoming of the problem of local minimum), concise training, high learning convergence speed and the like, and has been proved at present that the RBF can approximate any continuous nonlinear network with any precision and is widely applied to the fields of Function approximation, voice recognition, mode recognition, image processing, automatic control, fault diagnosis and the like;
optionally, the preset radial basis function neural network mentioned herein may specifically be:
Figure BDA0002117408460000061
wherein x is1,x2,...,xnIs an input variable, n is the number of nodes in the input layer, ykj(k 1,2.. times, n, j 1,2.. times, m) is the output corresponding to the kth input sample, wij(i 1,2.. M, j 1,2.. M) is a weight from the hidden layer to the output layer; m is the dimension of the output vector; m is the number of hidden layer nodes. Phi (x)k,ci) (k 1,2., n, i 1,2.. M) represents a radial basis function (using a gaussian function), as in the formula:
Figure BDA0002117408460000062
wherein σiIs the standard deviation of the gaussian function; x is the number ofkIs the kth input sample; c. CiIs the center of the basis function; | xk-ciI is the Euclidean distance between the sample and the center;
inputting variable x into radial basis function neural network1,x2,...,xnDefining historical data of highway traffic flow in the previous N consecutive days; and defining the output variable y of the radial basis function neural network as the traffic flow data of the expressway in the N +1 th day to be measured.
S102: preprocessing input highway traffic flow data to obtain a training sample;
optionally, the preprocessing of the input highway traffic flow data mentioned herein to obtain a training sample may specifically be:
dividing historical highway traffic flow data into rainstorm weather and normal weather according to weather types, taking the historical highway traffic flow data in the rainstorm weather in the first N consecutive days as input, and taking the highway traffic flow data in the rainstorm weather of the (N + 1) th day as output until training samples of the first N days are completely trained;
according to the formula
Figure BDA0002117408460000071
Normalizing the input highway traffic flow data;
wherein x isikA highway traffic flow value, x, at the kth time point of the ith highway traffic flowmaxAnd xminThe maximum value and the minimum value of the highway traffic flow data are respectively xikIs implicitly emitted to [ x ]new min,xnew max]In the region of (1), wherein xnew maxAnd xnew minThe maximum and minimum values of the processed data are respectively.
S103: training a preset radial basis function neural network by using a training sample to obtain a traffic flow prediction model;
the significance of the traffic flow prediction model obtained by training the preset radial basis function neural network by using the training samples is that the traffic flow prediction model obtained by training is used for predicting the traffic flow prediction of the expressway, so that the prediction speed and accuracy are improved.
S104: and predicting the traffic flow by using the traffic flow prediction model.
Based on the technical scheme, the method for predicting the traffic flow determines initial parameters of the preset radial basis function neural network through an improved cuckoo algorithm, then trains the preset radial basis function neural network by using a training sample to obtain a traffic flow prediction model, and finally predicts the traffic flow by using the traffic flow prediction model, so that the obtained traffic flow prediction model has higher convergence speed and better prediction accuracy, and has good effect in predicting the traffic flow of the expressway.
With respect to step S101 of the previous embodiment, the determination of the initial parameters of the preset radial basis function neural network by the modified cuckoo algorithm is described below with reference to fig. 2.
Referring to fig. 2, fig. 2 is a flowchart illustrating an actual representation manner of S101 in the traffic flow prediction method shown in fig. 1.
The method specifically comprises the following steps:
s201: encoding parameters of the radial basis function neural network;
s202: initializing parameters of an improved cuckoo algorithm;
optionally, the parameters for initializing the improved cuckoo algorithm mentioned herein may specifically be:
initializing parameters of the improved cuckoo algorithm: nest number nest of other bird species, fitness function f (X), X ═ X1,x2…,xi)TWhere i is 1,2.,. nest, monkey hill climbing minimum step aminMaximum step size amaxThe maximum recognition probability Pmax and the minimum recognition probability Pmin of other kinds of birds, the allowable error epsilon and the maximum iteration time tmax of the algorithm.
S203: determining a fitness function of the improved cuckoo algorithm;
optionally, as mentioned herein, it may specifically be:
according to the formula
Figure BDA0002117408460000081
Calculating the fitness;
wherein the average value
Figure BDA0002117408460000082
Satisfy the formula
Figure BDA0002117408460000083
S204: determining the fitness values of all bird nest positions according to the fitness function, and determining the optimal bird nest position according to each fitness value;
s205: updating the position of the bird nest by adopting an improved monkey mountain climbing process strategy, and determining the fitness value of the updated position of the bird nest according to a fitness function;
optionally, as mentioned herein, the step of updating the position of the bird nest by using the improved monkey mountain climbing process strategy may specifically be:
according to the ith bird nest position xi=(xi1,xi2,…,xin) And formula
Figure BDA0002117408460000084
Determining the climbing process coefficient Deltax of the ith nesti(ii) a Wherein, Δ xi=(Δxi1,Δxi2,...,Δxin);
According to the climbing process coefficient DeltaxiBy the formula
Figure BDA0002117408460000085
Calculating a pseudo gradient vector f'ij(xi);
According to a pseudo gradient vector f'ij(xi) By the formula
Figure BDA0002117408460000091
Calculating the updated bird nest position yi(ii) a Wherein, yi=(yi1,yi2,...,yin);
Determining the updated bird nest position yiWhether within a reasonable range and satisfying f (y)i)≥f(xi);
If yes, the ith bird nest position xiUpdated to an updated bird nest position yi
If not, keeping the ith bird nest position xiThe change is not changed;
wherein a is the climbing step length, and χ is [0,1]]Random number of (2), a creep coefficient Δ xiIs the crawling process coefficient of the ith bird nest, f'ij(xi) For pseudo-gradient vectors, sig is a sign function, yiIs the updated position of the bird nest.
S206: judging whether the fitness value of the updated bird nest position is larger than the fitness value of the optimal bird nest position;
if yes, go to step S207;
optionally, when the fitness value of the updated bird nest position is smaller than or equal to the fitness value of the optimal bird nest position, the optimal bird nest position is kept unchanged.
S207: and updating the optimal bird nest position to the updated bird nest position.
With respect to the previous embodiment, after step S207 is executed, the steps shown in fig. 3 may also be executed, which will be described below with reference to fig. 3.
Referring to fig. 3, fig. 3 is a flowchart illustrating another practical expression of S101 in the traffic flow prediction method shown in fig. 1.
The method specifically comprises the following steps:
s301: carrying out self-adaptive updating on the recognized probability;
optionally, the adaptive update of the recognition probability mentioned here may specifically be:
according to the formula
Figure BDA0002117408460000092
Carrying out self-adaptive updating on the recognized probability;
wherein p isminTo minimize the probability of recognition, pmaxTo maximize the probability of recognition, pmin、pmaxAll are fixed values and are between 0 and 1;
when the best individual of the population is close to the global optimal solution, the self-adaptive recognition probability strategy can narrow the range of searching the population, retain the current better solution to the next generation and help the algorithm to obtain the optimal solution in a short time.
S302: generating a random number, and judging whether the random number is greater than the updated recognition probability;
if yes, go to step S303;
alternatively, when the generated random number is less than or equal to the updated recognition probability, the optimal bird nest position may be kept unchanged.
S303: randomly changing the position of the bird nest, and determining the fitness value of the randomly changed position of the bird nest according to the fitness function;
s304: judging whether the fitness value of the randomly changed bird nest position is greater than the fitness value of the optimal bird nest position;
if yes, go to step S305;
optionally, when the fitness value of the randomly changed bird nest position is smaller than or equal to the fitness value of the optimal bird nest position, the optimal bird nest position may be kept unchanged.
S305: and updating the optimal bird nest position to the randomly changed bird nest position.
Referring to fig. 4, fig. 4 is a structural diagram of a traffic flow prediction system according to an embodiment of the present application.
The system may include:
a determining module 100, configured to determine an initial parameter of a preset radial basis function neural network through an improved cuckoo algorithm;
the preprocessing module 200 is used for preprocessing input highway traffic flow data to obtain a training sample;
the training module 300 is configured to train a preset radial basis function neural network by using a training sample to obtain a traffic flow prediction model:
and the prediction module 400 is used for predicting the traffic flow by using the traffic flow prediction model.
Referring to fig. 5, fig. 5 is a structural diagram of another traffic flow prediction system according to an embodiment of the present application.
The determination module 100 may include:
the encoding submodule is used for encoding the parameters of the radial basis function neural network;
the initialization submodule is used for initializing parameters of the improved cuckoo algorithm;
the first determining submodule is used for determining a fitness function of the improved cuckoo algorithm;
the second determining submodule is used for determining the fitness values of all the bird nest positions according to the fitness function and determining the optimal bird nest position according to each fitness value;
the first updating submodule is used for updating the position of the bird nest by adopting an improved monkey hill climbing process strategy and determining the fitness value of the updated position of the bird nest according to a fitness function;
the first judgment submodule is used for judging whether the fitness value of the updated bird nest position is greater than the fitness value of the optimal bird nest position;
and the third determining submodule is used for updating the optimal bird nest position to the updated bird nest position when the fitness value of the updated bird nest position is greater than the fitness value of the optimal bird nest position.
Further, the determining module 100 may further include:
the second updating submodule is used for carrying out self-adaptive updating on the recognition probability;
the second judgment submodule is used for generating a random number and judging whether the random number is greater than the updated recognition probability;
the random change submodule is used for randomly changing the position of the bird nest when the random number is greater than the updated recognition probability and determining the fitness value of the randomly changed position of the bird nest according to the fitness function;
the third judgment submodule is used for judging whether the fitness value of the randomly changed bird nest position is larger than the fitness value of the optimal bird nest position;
and the third updating submodule is used for updating the optimal bird nest position to the randomly changed bird nest position if the fitness value of the randomly changed bird nest position is greater than that of the optimal bird nest position.
The first update sub-module may include:
a determination unit for determining the ith bird nest position xi=(xi1,xi2,…,xin) And formula
Figure RE-GDA0002212841980000111
Determining a creep coefficient Deltax of an ith bird nesti(ii) a Wherein, Δ xi=(Δxi1,Δxi2,...,Δxin);
A first calculation unit for calculating a creep coefficient Δ xiBy the formula
Figure BDA0002117408460000113
Calculating a pseudo gradient vector f'ij(xi);
A second computing unit to derive from the pseudo gradient vector f'ij(xi) By the formula
yij=xij+a·sign(f′ij(xi) Calculate an updated bird's nest position yi(ii) a Wherein, yi=(yi1,yi2,...,yin);
A judging unit for judging the updated bird nest position yiWhether within a reasonable range and satisfying f (y)i)≥f(xi);
An updating unit for updating the bird nest position yiWithin a reasonable range and satisfies f (y)i)≥f(xi) Then, the ith bird nest position xiUpdated to an updated bird nest position yi
A holding unit for holding the updated bird nest position yiIs not within a reasonable range or does not satisfy f (y)i)≥f(xi) While maintaining the ith bird nest position xiThe change is not changed;
wherein a is the climbing step length, and χ is [0,1]]Random number of (2), a creep coefficient Δ xiIs the crawling process coefficient of the ith bird nest, f'ij(xi) For pseudo-gradient vectors, sign is a sign function, yiIs the updated position of the bird nest.
Since the embodiment of the system part corresponds to the embodiment of the method part, the embodiment of the system part is described with reference to the embodiment of the method part, and is not repeated here.
Referring to fig. 6, fig. 6 is a structural diagram of a traffic flow prediction apparatus according to an embodiment of the present application.
The traffic flow prediction apparatus 600 may have relatively large differences due to different configurations or performances, and may include one or more processors (CPUs) 622 (e.g., one or more processors) and a memory 632, one or more storage media 630 (e.g., one or more mass storage devices) storing applications 642 or data 644. Memory 632 and storage medium 630 may be, among other things, transient or persistent storage. The program stored on the storage medium 630 may include one or more modules (not shown), each of which may include a series of instructions operating on a device. Still further, the central processor 622 may be configured to communicate with the storage medium 630 and execute a series of instruction operations in the storage medium 630 on the traffic flow prediction apparatus 600.
The traffic flow prediction apparatus 600 may also include one or more power supplies 626, one or more wired or wireless network interfaces 650, one or more input-output interfaces 658, and/or one or more operating systems 641, such as Windows Server, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.
The steps in the traffic flow prediction method described above with reference to fig. 1 to 3 are implemented by the traffic flow prediction apparatus based on the configuration shown in fig. 6.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the system, the apparatus and the module described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus, device and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, a division of modules is merely a division of logical functions, and an actual implementation may have another division, for example, a plurality of modules or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or modules, and may be in an electrical, mechanical or other form.
Modules described as separate parts may or may not be physically separate, and parts shown as modules may or may not be physical modules, may be located in one place, or may be distributed on a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present application may be integrated into one processing module, or each module may exist alone physically, or two or more modules are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode.
The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a function calling device, or a network device) to execute all or part of the steps of the method of the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, and an optical disk.
A method, system, device and computer readable storage medium for traffic flow prediction provided by the present application are described in detail above. The principles and embodiments of the present application are explained herein using specific examples, which are presented only to assist in understanding the method and its core concepts of the present application. It should be noted that, for those skilled in the art, it is possible to make several improvements and modifications to the present application without departing from the principle of the present application, and such improvements and modifications also fall within the scope of the claims of the present application.
It is further noted that, in the present specification, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.

Claims (6)

1. A method of traffic flow prediction, comprising:
determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm;
preprocessing input highway traffic flow data to obtain a training sample;
training the preset radial basis function neural network by using the training sample to obtain a traffic flow prediction model:
predicting the traffic flow by utilizing the traffic flow prediction model;
the determining of the initial parameters of the preset radial basis function neural network through the improved cuckoo algorithm includes:
encoding parameters of the radial basis function neural network;
initializing parameters of the improved cuckoo algorithm;
determining a fitness function of the improved cuckoo algorithm;
determining the fitness values of all bird nest positions according to the fitness function, and determining the optimal bird nest position according to each fitness value;
updating the position of the bird nest by adopting an improved monkey mountain climbing process strategy, and determining the fitness value of the updated position of the bird nest according to the fitness function;
judging whether the updated fitness value of the bird nest position is larger than the fitness value of the optimal bird nest position;
if so, updating the optimal bird nest position to the updated bird nest position;
adopt to improve monkey climbing process strategy to update bird's nest position includes:
according to the first
Figure DEST_PATH_IMAGE002
Position of bird nest
Figure DEST_PATH_IMAGE004
And formula
Figure DEST_PATH_IMAGE006
Determine the second
Figure 955670DEST_PATH_IMAGE002
Climbing process coefficient of bird nest
Figure DEST_PATH_IMAGE008
(ii) a Wherein the content of the first and second substances,
Figure DEST_PATH_IMAGE010
according to the climbing process coefficient
Figure 310295DEST_PATH_IMAGE008
By the formula
Figure DEST_PATH_IMAGE012
Computing pseudo gradient vectors
Figure DEST_PATH_IMAGE014
According to the pseudo gradient vector
Figure 152349DEST_PATH_IMAGE014
By the formula
Figure DEST_PATH_IMAGE016
Calculating the updated bird nest position
Figure DEST_PATH_IMAGE018
(ii) a Wherein the content of the first and second substances,
Figure DEST_PATH_IMAGE020
determining the updated bird nest position
Figure 875454DEST_PATH_IMAGE018
Whether within a reasonable range and satisfy
Figure DEST_PATH_IMAGE022
If yes, the first step is carried out
Figure 784767DEST_PATH_IMAGE002
Position of bird nest
Figure DEST_PATH_IMAGE024
Updated to updated bird nest positions
Figure 935125DEST_PATH_IMAGE018
If not, keeping the first step
Figure 671000DEST_PATH_IMAGE002
Position of bird nest
Figure 604321DEST_PATH_IMAGE024
The change is not changed;
wherein the content of the first and second substances,
Figure DEST_PATH_IMAGE026
in order to climb the step length of the mountain,
Figure DEST_PATH_IMAGE028
is given by
Figure DEST_PATH_IMAGE030
The random number of (a) is set,
Figure DEST_PATH_IMAGE032
is a symbolic function.
2. The method of claim 1, further comprising, after updating an optimal bird nest location to the updated bird nest location:
carrying out self-adaptive updating on the recognized probability;
generating a random number, and judging whether the random number is greater than the updated recognition probability;
if so, randomly changing the position of the bird nest, and determining the fitness value of the randomly changed position of the bird nest according to the fitness function;
judging whether the fitness value of the randomly changed bird nest position is greater than the fitness value of the optimal bird nest position;
and if the fitness value of the randomly changed bird nest position is greater than that of the optimal bird nest position, updating the optimal bird nest position to the randomly changed bird nest position.
3. A system for traffic flow prediction, comprising:
the determining module is used for determining initial parameters of a preset radial basis function neural network through an improved cuckoo algorithm;
the preprocessing module is used for preprocessing input highway traffic flow data to obtain a training sample;
the training module is used for training the preset radial basis function neural network by using the training sample to obtain a traffic flow prediction model:
the prediction module is used for predicting the traffic flow by utilizing the traffic flow prediction model;
the determining module comprises:
the encoding submodule is used for encoding the parameters of the radial basis function neural network;
the initialization submodule is used for initializing parameters of the improved cuckoo algorithm;
a first determining submodule for determining a fitness function of the improved cuckoo algorithm;
the second determining submodule is used for determining the fitness values of all the bird nest positions according to the fitness function and determining the optimal bird nest position according to each fitness value;
the first updating submodule is used for updating the position of the bird nest by adopting an improved monkey hill climbing process strategy and determining the fitness value of the updated position of the bird nest according to the fitness function;
the first judgment submodule is used for judging whether the fitness value of the updated bird nest position is larger than the fitness value of the optimal bird nest position or not;
a third determining submodule, configured to update the optimal bird nest position to the updated bird nest position when the fitness value of the updated bird nest position is greater than the fitness value of the optimal bird nest position;
the first update submodule includes:
a determination unit for determining based on
Figure 663413DEST_PATH_IMAGE002
Position of bird nest
Figure 811104DEST_PATH_IMAGE004
And formula
Figure 34275DEST_PATH_IMAGE006
Determine the second
Figure 505708DEST_PATH_IMAGE002
Climbing process coefficient of bird nest
Figure 622568DEST_PATH_IMAGE008
(ii) a Wherein the content of the first and second substances,
Figure 786833DEST_PATH_IMAGE010
a first calculating unit for calculating the crawling process coefficient
Figure 621934DEST_PATH_IMAGE008
By the formula
Figure 631478DEST_PATH_IMAGE012
Computing pseudo gradient vectors
Figure 9370DEST_PATH_IMAGE014
A second calculation unit for calculating a pseudo gradient vector based on the pseudo gradient vector
Figure 439477DEST_PATH_IMAGE014
By the formula
Figure 902819DEST_PATH_IMAGE016
Calculating updated bird nest positions
Figure 450475DEST_PATH_IMAGE018
(ii) a Wherein the content of the first and second substances,
Figure 807507DEST_PATH_IMAGE020
a judging unit for judging the updated bird nest positionDevice for placing
Figure 47995DEST_PATH_IMAGE018
Whether within a reasonable range and satisfy
Figure 123268DEST_PATH_IMAGE022
An updating unit for updating the position of the bird nest
Figure 740194DEST_PATH_IMAGE018
Within the reasonable range and satisfy
Figure 190548DEST_PATH_IMAGE022
When it is, the first step
Figure 867517DEST_PATH_IMAGE002
Position of bird nest
Figure 898927DEST_PATH_IMAGE024
Updated to the updated bird nest position
Figure 53964DEST_PATH_IMAGE018
A holding unit for holding the updated bird nest position
Figure 260955DEST_PATH_IMAGE018
Out of or not satisfying the stated reasonable range
Figure 967880DEST_PATH_IMAGE022
While maintaining the first
Figure 627531DEST_PATH_IMAGE002
Position of bird nest
Figure 586260DEST_PATH_IMAGE024
The change is not changed;
wherein the content of the first and second substances,
Figure 241232DEST_PATH_IMAGE026
in order to climb the step length of the mountain,
Figure 260004DEST_PATH_IMAGE028
is given by
Figure 141372DEST_PATH_IMAGE030
The random number of (a) is set,
Figure 529890DEST_PATH_IMAGE032
is a symbolic function.
4. The system of claim 3, wherein the determination module further comprises:
the second updating submodule is used for carrying out self-adaptive updating on the recognition probability;
a second judgment submodule, configured to generate a random number, and judge whether the random number is greater than the updated recognition probability;
a random change submodule, configured to randomly change the position of the bird nest when the random number is greater than the updated recognition probability, and determine a fitness value of the randomly changed position of the bird nest according to the fitness function;
the third judgment submodule is used for judging whether the fitness value of the randomly changed bird nest position is larger than the fitness value of the optimal bird nest position;
and the third updating submodule is used for updating the optimal bird nest position to the randomly changed bird nest position if the fitness value of the randomly changed bird nest position is greater than the fitness value of the optimal bird nest position.
5. A traffic flow prediction apparatus characterized by comprising:
a memory for storing a computer program;
a processor for implementing the steps of the method of traffic flow prediction according to any one of claims 1 to 2 when executing the computer program.
6. A computer-readable storage medium, characterized in that a computer program is stored thereon, which computer program, when being executed by a processor, carries out the steps of the method of traffic flow prediction according to any one of claims 1 to 2.
CN201910595128.XA 2019-07-03 2019-07-03 Traffic flow prediction method, system and equipment Active CN110533905B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910595128.XA CN110533905B (en) 2019-07-03 2019-07-03 Traffic flow prediction method, system and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910595128.XA CN110533905B (en) 2019-07-03 2019-07-03 Traffic flow prediction method, system and equipment

Publications (2)

Publication Number Publication Date
CN110533905A CN110533905A (en) 2019-12-03
CN110533905B true CN110533905B (en) 2022-02-15

Family

ID=68659645

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910595128.XA Active CN110533905B (en) 2019-07-03 2019-07-03 Traffic flow prediction method, system and equipment

Country Status (1)

Country Link
CN (1) CN110533905B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111932875A (en) * 2020-07-29 2020-11-13 太原理工大学 Intersection group key path identification method based on improved cuckoo search algorithm
CN112907953B (en) * 2021-01-27 2022-01-28 吉林大学 Bus travel time prediction method based on sparse GPS data

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104299033A (en) * 2014-09-24 2015-01-21 上海电力学院 Magnetic flux leakage defect reconstruction method based on cuckoo searching and particle filter hybrid algorithm
CN106127295A (en) * 2016-06-21 2016-11-16 湘潭大学 A kind of Optimal Design of Pressure Vessel method based on self adaptation cuckoo Yu fireworks hybrid algorithm
CN107018103A (en) * 2017-04-07 2017-08-04 淮南职业技术学院 A kind of small echo norm blind balance method based on the group's optimization of adaptive step monkey
CN107864507A (en) * 2017-11-22 2018-03-30 哈尔滨工程大学 Cognitive ratio power control method based on quantum monkey group hunting mechanism
CN109637121A (en) * 2018-06-05 2019-04-16 南京理工大学 A kind of road traffic congestion prediction technique in short-term based on CS-SVR algorithm
CN109671272A (en) * 2018-12-29 2019-04-23 广东工业大学 A kind of freeway traffic flow prediction technique

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104299033A (en) * 2014-09-24 2015-01-21 上海电力学院 Magnetic flux leakage defect reconstruction method based on cuckoo searching and particle filter hybrid algorithm
CN106127295A (en) * 2016-06-21 2016-11-16 湘潭大学 A kind of Optimal Design of Pressure Vessel method based on self adaptation cuckoo Yu fireworks hybrid algorithm
CN107018103A (en) * 2017-04-07 2017-08-04 淮南职业技术学院 A kind of small echo norm blind balance method based on the group's optimization of adaptive step monkey
CN107864507A (en) * 2017-11-22 2018-03-30 哈尔滨工程大学 Cognitive ratio power control method based on quantum monkey group hunting mechanism
CN109637121A (en) * 2018-06-05 2019-04-16 南京理工大学 A kind of road traffic congestion prediction technique in short-term based on CS-SVR algorithm
CN109671272A (en) * 2018-12-29 2019-04-23 广东工业大学 A kind of freeway traffic flow prediction technique

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
节假日高速公路短时交通流预测;乐冰 等;《东莞理工学院学报》;20190630;第26卷(第3期);第7-11页 *

Also Published As

Publication number Publication date
CN110533905A (en) 2019-12-03

Similar Documents

Publication Publication Date Title
US11119250B2 (en) Dynamic adaption of vessel trajectory using machine learning models
CN112099496B (en) Automatic driving training method, device, equipment and medium
CN106953862B (en) Sensing method and device for network security situation and sensing model training method and device
CN110533905B (en) Traffic flow prediction method, system and equipment
KR102410820B1 (en) Method and apparatus for recognizing based on neural network and for training the neural network
US20180107451A1 (en) Automatic scaling for fixed point implementation of deep neural networks
KR20190028531A (en) Training machine learning models for multiple machine learning tasks
BR112020026198A2 (en) systems and methods for determining the potential malicious event
CN108122048B (en) Transportation path scheduling method and system
CN116301048A (en) Unmanned plane path planning method, unmanned plane path planning system, electronic equipment and storage medium
CN114625150B (en) Rapid ant colony unmanned ship dynamic obstacle avoidance method based on danger coefficient and distance function
Tanaka et al. Automated structure discovery and parameter tuning of neural network language model based on evolution strategy
Ma et al. Jointly trained sequential labeling and classification by sparse attention neural networks
CN103279674A (en) Ship search-and-rescue method based on ant colony algorithm
CN114863226A (en) Network physical system intrusion detection method
KR20210039921A (en) Operation method of deep neural network system configured to optimize neural network model
CN111582919A (en) Flight passenger seat rate prediction method and system
CN110749325B (en) Flight path planning method and device
CN115310732B (en) Flight delay prediction method and system
CN115102779B (en) Prediction model training and access request decision method, device and medium
Xu et al. Traffic flow forecasting with spatial-temporal graph convolutional networks in edge-computing systems
CN113609761B (en) Calculation method, device, equipment and storage medium of model parameters
Zhang et al. Learning efficient sparse structures in speech recognition
He et al. Reinforcement learning in many-agent settings under partial observability
CN115071985A (en) Artificial intelligence driven emergency pilot assistance system and method

Legal Events

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