# Self-Organizing Traffic Flow Prediction with an Optimized Deep Belief Network for Internet of Vehicles

^{1}

^{2}

^{3}

^{*}

## Abstract

**:**

## 1. Introduction

- We define a dynamic traffic pattern matrix to assess traffic volume data;
- We propose a 3-layer DBN composed of two RBMs to determine the salient features from time series traffic volume data for constructing a traffic flow prediction model on VANET-cellular systems.
- We utilize FFA algorithm to optimize and select the sizes of the learning rates in neural networks and;
- We perform simulations and explain how to use historical traffic data for traffic volume prediction.

## 2. Assessing Traffic Pattern Matrix

## 3. DBN for Time Series Forecasting

## 4. Optimization of the DBN Prediction Model

#### Optimization by Firefly Algorithm (FFA)

Algorithm 1. Firefly Algorithm |

Objective function $f\left(x\right)$, ${X}_{i}={\left({x}_{1},{x}_{1},\dots ,{x}_{1}\right)}^{T}$ Decide the population size of fireflies P and set the iteration number of I. Initialize a population ${X}_{i}\left(i=1,2,3,\dots ,n\right)$ of $fireflies$ Outline γ as light absorption coefficient While ($t<MaximumGeneration)$ For $i=1:nallnfireflies$ For $j=1:iallnfirefiles$ Light intensity ${I}_{i}$ at ${X}_{i}$ is determined by $f\left({X}_{i}\right)$ Evaluate per firefly via the (MSE) among the predicted value $\widehat{x}$(t) and original data $x$(t). If (${I}_{j}>{I}_{i})$ Move firefly $i$ towards $j$ in all $d$ dimensions End if Attraction differs with distance $r$ via $exp\left[-{\gamma}^{r}\right]$ Assess new solutions and update light intensity End for $j$ End for $i$ Rank the fireflies and discover the current best Find the best firefly with best attraction from its history End while |

## 5. Forecasting Results

## 6. Conclusions

## Author Contributions

## Funding

## Conflicts of Interest

## References

- Soleymani, S.A.; Abdullah, A.H.; Zareei, M.; Anisi, M.H.; Vargas-Rosales, C.; Khan, M.K.; Goudarzi, S. A secure trust model based on fuzzy logic in vehicular ad hoc networks with fog computing. IEEE Access
**2017**, 5, 15619–15629. [Google Scholar] [CrossRef] - Soleymani, S.A.; Abdullah, A.H.; Anisi, M.H.; Altameem, A.; Hasan, W.H.; Goudarzi, S.; Mandala, S.; Razak, Z.B.; Noor, N.M. BRAIN-F: Beacon rate adaption based on fuzzy logic in vehicular ad hoc network. Int. J. Fuzzy Syst.
**2017**, 19, 301–315. [Google Scholar] [CrossRef] - Ghafoor, K.Z.; Bakar, K.A.; Lloret, J.; Khokhar, R.H.; Lee, K.C. Intelligent beaconless geographical forwarding for urban vehicular environments. Wirel. Netw.
**2013**, 19, 345–362. [Google Scholar] [CrossRef] - Ghafoor, K.Z.; Mohammed, M.A.; Lloret, J.; Bakar, K.A.; Zainuddin, Z.M. Routing protocols in vehicular ad hoc networks: Survey and research challenges. Netw. Protocols Algorithms
**2013**, 5, 39–83. [Google Scholar] [CrossRef] - Abdulhai, B.; Porwal, H.; Recker, W. Short-term traffic flow prediction using neuro-genetic algorithms. J. Intell. Transp. Syst.
**2002**, 7, 3–41. [Google Scholar] [CrossRef] - Vlahogianni, E.I.; Karlaftis, M.G.; Golias, J.C. Optimized and meta-optimized neural networks for short-term traffic flow prediction: A genetic approach. Transp. Res. Part C Emerg. Technol.
**2005**, 13, 211–234. [Google Scholar] [CrossRef] - Williams, B.M. Multivariate vehicular traffic flow prediction: Evaluation of ARIMAX modeling. Transp. Res. Rec.
**2001**, 1776, 194–200. [Google Scholar] [CrossRef] - Williams, B.M.; Hoel, L.A. Modeling and forecasting vehicular traffic flow as a seasonal ARIMA process: Theoretical basis and empirical results. J. Transp. Eng.
**2003**, 129, 664–672. [Google Scholar] [CrossRef] - Sun, S.; Zhang, C.; Yu, G. A Bayesian network approach to traffic flow forecasting. IEEE Trans. Intell. Transp. Syst.
**2006**, 7, 124–131. [Google Scholar] [CrossRef] - Dougherty, M.S.; Cobbett, M.R. Short-term inter-urban traffic forecasts using neural networks. Int. J. Forecast.
**1997**, 13, 21–31. [Google Scholar] [CrossRef] - Ledoux, C. An urban traffic flow model integrating neural networks. Transp. Res. Part C Emerg. Technol.
**1997**, 5, 287–300. [Google Scholar] [CrossRef] - Shmueli, D. Applications of neural networks in transportation planning. Prog. Plan.
**1998**, 50, 141–204. [Google Scholar] [CrossRef] - Dia, H. An object-oriented neural network approach to short-term traffic forecasting. Eur. J. Oper. Res.
**2001**, 131, 253–261. [Google Scholar] [CrossRef][Green Version] - Yin, H.B.; Wong, S.C.; Xu, J.M.; Wong, C.K. Urban traffic flow prediction using a fuzzy-neural approach. Transp. Res. Part C Emerg. Technol.
**2002**, 10, 85–98. [Google Scholar] [CrossRef] - Lan, L.W.; Huang, Y.C. A rolling-trained fuzzy neural network approach for freeway incident detection. Transportmetrica
**2006**, 2, 11–29. [Google Scholar] [CrossRef] - El Faouzi, N.-E. Nonparametric traffic flow prediction using kernel estimator. In Proceedings of the 13th International Symposium on Transportation and Traffic Theory, Lyon, France, 24–26 July 1996; pp. 41–54. [Google Scholar]
- Smith, B.L.; Williams, B.M.; Oswald, R.K. Comparison of parametric and nonparametric models for traffic flow forecasting. Transp. Res. Part C Emerg. Technol.
**2002**, 10, 303–321. [Google Scholar] [CrossRef] - Huisken, G. Soft-computing techniques applied to short-term traffic flow forecasting. Syst. Anal. Model. Simul.
**2003**, 43, 165–173. [Google Scholar] [CrossRef] - Qu, L.; Li, L.; Zhang, Y.; Hu, J. PPCA based missing data imputation for traffic flow volume: A systematical approach. IEEE Trans. Intell. Transp. Syst.
**2009**, 10, 512–522. [Google Scholar] - Chen, C.; Wang, Y.; Li, L.; Hu, J.; Zhang, Z. The retrieval of intra-day trend and its influence on traffic prediction. Transp. Res. Part C Emerg. Technol.
**2012**, 22, 103–118. [Google Scholar] [CrossRef] - Smith, B.; Scherer, W.; Conklin, J. Exploring imputation techniques for missing data in transportation management systems. Transp. Res. Rec.
**2003**, 1836, 132–142. [Google Scholar] [CrossRef] - Kalhor, S.; Anisi, M.; Haghighat, A.T. A new position-based routing protocol for reducing the number of exchanged route request messages in Mobile Ad-hoc Networks. In Proceedings of the IEEE Second International Conference on Systems and Networks Communications (ICSNC 2007), Cap Esterel, France, 25–31 August 2017; p. 13. [Google Scholar]
- Sun, S.; Huang, R.; Gao, Y. Network-scale traffic modeling and forecasting with graphical lasso and neural networks. J. Transp. Eng.
**2012**, 138, 1358–1367. [Google Scholar] [CrossRef] - RAND. Moving Los Angeles: Short-Term Transportation Policy Options for Improving Transportation; RAND Corporation: Santa Monica, CA, USA, 2008. [Google Scholar]
- Traffic Choices Study: Summary Report; Federal Highway Administration: Seattle, WA, USA, 2008.
- Mamuneas, T.P.; Nadri, M.I. Contribution of Highway Capital to Industry and National Productivity Growth; Transportation Research Board: Washington, DC, USA, 1996. [Google Scholar]
- Ackley, D.H.; Hinton, G.E.; Sejnowski, T.J. A learning algorithm for Boltzmann machines. Cogn. Sci.
**1985**, 9, 147–169. [Google Scholar] [CrossRef] - Hinton, G.E.; Sejnowski, T.J. Learning and relearning in Boltzmann machines. In Paralle l Distributed Processing: Explorations in the Microstructure of Cognition; Rumel Hart, D.E., McClell, J.L., Eds.; MIT Press: Cambridge, MA, USA, 1986; Volume 1. [Google Scholar]
- Hinton, G.E.; Osindero, S.; The, Y.W. A faster learning algorithm for deep belief nets. Neural Comput.
**2006**, 1, 1527–1544. [Google Scholar] [CrossRef] [PubMed] - van Lint, J.W.C.; Hoogendoorn, S.P.; van Zuylen, H.J. Accurate freeway travel time prediction with state-space neural networks under missing data. Transp. Res. Part C Emerg. Technol.
**2005**, 13, 347–369. [Google Scholar] [CrossRef] - Sun, S.; Zhang, C.; Yu, G.; Lu, N.; Xiao, F. Bayesian network methods for traffic flow forecasting with incomplete data. In European Conference on Machine Learning; Springer: Berlin/Heidelberg, Germany, 2004; pp. 419–428. [Google Scholar]
- Lawerence, M.J.; Edmundson, R.H.; O’Connor, M.J. The accuracy of combining judgmental and statistical forecasts. Manag. Sci.
**1986**, 32, 1521–1532. [Google Scholar] [CrossRef] - Gao, Y.; Er, M.J. NARMAX time series model prediction: Feedforward and recurrent fuzzy neural network approaches. Fuzzy Sets Syst.
**2005**, 150, 331–350. [Google Scholar] [CrossRef] - Zheng, W.; Lee, D.; Shi, Q. Short-term freeway traffic flow prediction: Bayesian combined neural network approach. J. Transp. Eng.
**2006**, 132, 114–121. [Google Scholar] [CrossRef] - Sun, L.; Wu, Y.; Xu, J.; Xu, Y. An RSU-assisted localization method in non-GPS highway traffic with dead reckoning and V2R communications. In Proceedings of the IEEE 2012 2nd International Conference on Consumer Electronics, Communications and Networks (CECNet), Yichang, China, 21–23 April 2012; pp. 149–152. [Google Scholar]
- Box, G.E.; Jenkins, G.M.; Reinsel, G.C.; Ljung, G.M. Time Series Analysis: Forecasting and Control; John Wiley & Sons: New York, NY, USA, 2015. [Google Scholar]
- PTV Group. Available online: http://vision-traffic.ptvgroup.com/en-us/products/ptv-visum/ (accessed on 17 February 2018).
- LeCun, Y.; Bengio, Y.; Hinton, G. Deep learning. Nature
**2015**, 521, 436. [Google Scholar] [CrossRef] [PubMed] - Hinton, G.E.; Salakhutdinov, R.R. Reducing the dimensionality of data with neural networks. Science
**2006**, 313, 504–507. [Google Scholar] [CrossRef] [PubMed] - Rumelhart, D.E.; Hinton, G.E.; Williams, R.J. Learning representation by back-propagating errors. Nature
**1986**, 323, 533–536. [Google Scholar] [CrossRef] - Zhang, G.P. Time series forecasting using a hybrid ARIMA and neural network model. Neurocomputing
**2003**, 50, 159–175. [Google Scholar] [CrossRef] - Gardner, E.; McKenzie, E. Seasonal exponential smoothing with damped trends. Manag. Sci.
**1989**, 35, 372–376. [Google Scholar] [CrossRef] - Łukasik, S.; Żak, S. Firefly algorithm for continuous constrained optimization tasks. In Computational Collective Intelligence Semantic Web, Social Networks and Multiagent Systems; Springer: Berlin/Heidelberg, Germany, 2009; pp. 97–106. [Google Scholar]
- Yang, X.S. Nature-Inspired Metaheuristic Algorithms; Luniver Press: Beckington, UK, 2010. [Google Scholar]
- Box, G.E.P.; Jenkins, G. Time Series Analysis, Forecasting and Control; Cambridge University Press: Cambridge, UK, 1976. [Google Scholar]
- Goudarzi, S.; Hassan, W.H.; Anisi, M.H.; Soleymani, S.A.; Shabanzadeh, P. A Novel Model on Curve Fitting and Particle Swarm Optimization for Vertical Handover in Heterogeneous Wireless Networks. Math. Probl. Eng.
**2015**. [Google Scholar] [CrossRef] - Reuven, Y.R. Simulation and the Monte Carlo Method; John Wiley & Sons, Inc.: Hoboken, NJ, USA, 1981; 304p. [Google Scholar]
- Tok, D.S.; Shi, Y.; Tian, Y.; Yu, D.L. Factorized f-step radial basis function model for model predictive control. Neurocomputing
**2017**, 239, 102–112. [Google Scholar] - Lucon, P.A.; Donovan, R.P. An artificial neural network approach to multiphase continua constitutive modeling. Compos. Part B Eng.
**2007**, 38, 817–823. [Google Scholar] [CrossRef] - Gavirangaswamy, V.B.; Gupta, G.; Gupta, A.; Agrawal, R. Assessment of ARIMA-based prediction techniques for road-traffic volume. In Proceedings of the Fifth International Conference on Management of Emergent Digital EcoSystems, Luxembourg, 28–31 October 2013; pp. 246–251. [Google Scholar]
- Chai-Ead, N.; Aungkulanon, P.; Luangpaiboon, P. Bees and firefly algorithms for noisy non-linear optimisation problems. In Proceedings of the International Multi Conference of Engineering and Computer Scientists, Hong Kong, China, 16–18 March 2011; Volume 2. [Google Scholar]

**Figure 2.**Case study traffic network with five highways links. The numbers 1 to 5 illustrate 5 highways links.

Criteria | Data | Value |
---|---|---|

Highway free flow template | Raw data | Data on 5 mn-spaced intervals |

speed | 120 km/h | 10 km/5 mn interval |

Average link length | 2 km | 5 links traversed/5 mn interval |

Highway Congested template | Raw data | Data on 5 mn-spaced intervals |

Average speed | 72 km/h | 6 km/5 mn interval |

Average link length | 2 km | 3 links traversed/5 mn interval |

Description | Model Elements/Parameters | Quantity |
---|---|---|

Population of PSO | P | 10 |

The number of RBM | RBM1,RBM2 | 2 |

The number of input layer | N ($1\le N\le 20$) | Given by FFA |

Absorption coefficient | $\gamma $ | 0.1 |

Velocity coefficient | ${c}_{1},{c}_{2}$ | 1.0 |

The number of hidden layer | M ($1\le M\le 20$) | Given by FFA |

The number of output | - | 1 |

Interval of input data | $\tau $ | 1 |

Learning rate of RBM | $\epsilon \left(Step2\right)$ | Given by FFA |

Learning rate of BP | - | Given by FFA |

Population of FFA | P | 10 |

Iteration times of BP | L | 100 < L < 5000 |

Biases of units | ${b}_{i},{b}_{j}$ | 0.0 |

Convergence parameter of BP | $\alpha $ | 0.05 |

Convergence parameter of RBM | $\beta $ | 0.0005 |

Convergence period of RBM | k | 50 |

Structure and Evaluation | MLP-FFA | ARIMA | ARIMA-PSO | DRBM-FFA |
---|---|---|---|---|

Learning rates | 0.85 | 0.64 | 0.73 | 0.98 |

Iterations | 336 | 350 | 298 | 200 |

Learning MSE | 109.21 | 122.4 | 108.9 | 98.70 |

Short-term prediction MSE | 234.38 | 280.50 | 126.11 | 109.38 |

Predictor | Time Interval | r | RMSE | MAPE |
---|---|---|---|---|

MLP-FFA | t | 3.2 | 6.8 | 12.07% |

t + 1 | 3.5 | 7.2 | 13.95% | |

t + 2 | 3.6 | 7.8 | 14.89% | |

t + 3 | 3.9 | 7.9 | 15.32% | |

ARIMA | t | 4.4 | 9.1 | 13.56% |

t + 1 | 4.6 | 9.7 | 15.37% | |

t + 2 | 6.8 | 14.2 | 18.93% | |

t + 3 | 8.5 | 15.7 | 23.24% | |

ARIMA-PSO | t | 3.3 | 6.8 | 9.39% |

t + 1 | 3.4 | 6.9 | 9.89% | |

t + 2 | 3.7 | 7.2 | 10.48% | |

t + 3 | 3.9 | 7.8 | 11.57% | |

DRBM-FFA | t | 2.9 | 6.1 | 8.75% |

t + 1 | 3.1 | 6.4 | 9.63% | |

t + 2 | 3.4 | 6.9 | 10.31% | |

t + 3 | 3.5 | 7.1 | 11.12% |

Model | D | ${\mathit{T}}_{0}$ | ${\mathit{T}}_{1}$ | ${\widehat{\mathit{T}}}_{2}$ | $\frac{\left({\widehat{\mathit{T}}}_{2}-{\mathit{T}}_{1}\right)}{{\mathit{T}}_{0}}$ |
---|---|---|---|---|---|

MLP-FFA | 10 | 0.490 | 0.465 | 2.809 | 4.780 |

50 | 0.491 | 0.643 | 2.911 | 4.610 | |

100 | 0.493 | 0.720 | 3.108 | 4.800 | |

ARIMA | 10 | 0.389 | 0.509 | 3.142 | 6.722 |

50 | 0.378 | 0.734 | 3.708 | 7.855 | |

100 | 0.398 | 0.821 | 3.698 | 7.212 | |

ARIMA-PSO | 10 | 0.470 | 0.489 | 2.809 | 4.852 |

50 | 0.489 | 0.631 | 2.902 | 4.637 | |

100 | 0.489 | 0.715 | 3.212 | 5.090 | |

DRBM-FFA | 10 | 0.411 | 0.233 | 0.703 | 1.145 |

50 | 0.412 | 0.474 | 1.336 | 2.046 | |

100 | 0.412 | 0.732 | 1.994 | 2.857 |

© 2018 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Goudarzi, S.; Kama, M.N.; Anisi, M.H.; Soleymani, S.A.; Doctor, F.
Self-Organizing Traffic Flow Prediction with an Optimized Deep Belief Network for Internet of Vehicles. *Sensors* **2018**, *18*, 3459.
https://doi.org/10.3390/s18103459

**AMA Style**

Goudarzi S, Kama MN, Anisi MH, Soleymani SA, Doctor F.
Self-Organizing Traffic Flow Prediction with an Optimized Deep Belief Network for Internet of Vehicles. *Sensors*. 2018; 18(10):3459.
https://doi.org/10.3390/s18103459

**Chicago/Turabian Style**

Goudarzi, Shidrokh, Mohd Nazri Kama, Mohammad Hossein Anisi, Seyed Ahmad Soleymani, and Faiyaz Doctor.
2018. "Self-Organizing Traffic Flow Prediction with an Optimized Deep Belief Network for Internet of Vehicles" *Sensors* 18, no. 10: 3459.
https://doi.org/10.3390/s18103459