# Deep Learning for Predicting Traffic in V2X Networks
## 1 Introduction
Recently, it has become possible to use AI technology in 5G mobile networks to optimally design the physical layer, make complex decisions, manage the network, and optimize resources in such networks. Moreover, the developing big data technique provides an outstanding opportunity to learn the critical features of wireless networks and gain a more accurate and deeper understanding of the performance of 5G cellular networks [8; 9]. Nowadays, ML is successfully used in a variety of fields, as it can process massive amounts of data and discover dependencies that are difficult for humans to identify manually. Moreover, such an algorithm can determine the optimal solution to a given problem by statistically analyzing a large amount of data. For example, ML algorithms are used to predict accidents in heat supply systems. ML reduces the number of dangerous events (e.g., the failure of a rail on a railway track) by predicting rare, dangerous failures based on big data processing. In addition, they can be successfully used for delay-sensitive applications such as medical care, safety, and contingency responses such as remote intensive patient care. A significant event needs to be reported to a monitoring organization during a specific period to decide on suitable actions. In addition, the algorithms of ML are used to solve problems in antivirus scanning, hydrocarbon reservoir exploration, business, and so on [10; 11; 12]. The following are some of the main motivations behind this study:  
* Improve QoS demands and network monitoring for resource management and security. * Monitor network availability and activity for anomaly detection, including security and operational issues. * We proposed a DL-based LSTM method for the following reasons:
* It can predict future time series data more accurately than traditional time series models and stores historical series data over a long period. * It adjusts data faster and more efficiently than traditional time series models. * Better performance when processing larger datasets. * Another advantage over other approaches to time series forecasting is that it maximizes the accuracy of the learning method across training iterations. * The more data added to the model, the smarter and better it can estimate traffic volumes, which is important for real-time traffic forecasting. * Lack of awareness of the parameters of IoT communication. * Insufficient machine learning analysis prevents adequate prediction accuracy from being achieved. * The computational complexity of QoS measurement. * The main contributions to the proposed work are summarized as follows:
* The unidirectional long short-term memory (LSTM) with a DL for traffic prediction in the vehicle-to-everything (V2X) network was proposed. * The model DL was trained in different cases, based on the number of packets sent per second, with unidirectional LSTM in a V2X environment. The objective was to determine the best case that would offer us the best accuracy. * In terms of prediction accuracy, a comparison was made between the different cases depending on the packets transmitted per second: 4 packets/s, 6 packets/s, 8 packets/s, 10 packets/s, 12 packets/s, and 14 packets/s. * Prediction accuracy was determined using root-mean-square error (RMSE), mean absolute percentage error (MAPE), and processing time, using MSE as the loss function and a learning rate of 0.1. * Finally, the simulation findings demonstrate the following:
* The best prediction accuracy was found for the number of packets transmitted of 4 packets/s, which outperforms the competitors and shows outstanding performance. * On the other hand, the prediction accuracy when using 14 packets/s is lower than the other models. * The model with a prediction of 12 packets/s has the fastest processing time, but the models with a prediction of 14 packets/s have the slowest processing time compared to their competitors.