## 1 Introduction  
The main advantages of NFV is the flexibility in allocating processing and bandwidth resources [1; 2] and the possibility of running the Virtual Network Function Instances (VNFIs) where and when needed and appropriately dimensioning their memory, disk and processing resources. This increased flexibility allows to efficiently handle the traffic variations and it is achieved by applying some techniques: (i) The vertical scaling [3], whereby cloud resources are reconfigured, e.g., by changing the number of processing cores to the VNFIs as traffic changes; (ii) the VNFI migration [4], whereby the NFVI-PoP executing the VNFI is changed over time with the possibility of performing resource consolidation and consequently achieving cost saving. We have proposed the Asymmetric Traffic Prediction-based Allocation (ATPA) algorithm [5; 6; 7] in which the resources are allocated on the basis of a traffic prediction based on both resource allocation and QoS degradation costs. The allocation cost is the rent cost of the processing cores. The QoS penalty cost is a compensation cost for the user when cloud resources are under-allocated and QoS degradation (i.e., packet loss or delay increase) occurs. The prediction models used in [5] are based on both traditional (i.e., Seasonal AutoRegressive Integrated Moving Average) and Artificial Intelligence (AI)-based (i.e., Long Short Term Memory) models. In this paper we follow a different approach and we propose the Asymmetric Processing Resource Prediction-based Allocation (APRPA) algorithm. Based on the measurement of processing capacities required by the VNFIs in measurement periods, APRPA evaluates the processing capacities to be allocated to the VNFIs in time instants after the measurement times. Unlike all the solutions proposed in the literature, APRPA does not aim at predicting the needed processing capacities (it would be impossible to exactly do that because of the non-predictable components of traffic) but at over-allocating or under-allocating the cloud resources according to the values of the allocation and QoS penalty costs. The advantages of APRPA with respect to ATPA are the following:  
* its resource-based prediction allows for a more implementable and European Telecommunications Standards Institute (ETSI)-compliant solution; in particular we highlight which are the ETSI functional blocks that may be involved in the allocation and prediction procedure;
* APRPA is based on a convolutional and Long Short Term Memory (LSTM) neural network able to handle both spatial correlations of the processing capacities of the VNFIs located in each NFVI-PoP and the temporal correlation in a single VNFI; conversely ATPA performs a simple traffic prediction with a LSTM neural network able to handle temporal correlation only;
* APRPA allows for a more accurate prediction, consequence of multiple SFCs sharing a single VNFI that leads to the prediction of an aggregated requested processing capacity; conversely ATPA predicts the traffic of a single SFC. The main contributions of the manuscript are the following: (i) a resource allocation framework aiming at allocating the cloud resources so as to minimize a cost function depending on both the allocation and QoS degradation costs; (ii) a simulation study of the proposed allocation framework and its effectiveness evaluation with respect to the ATPA algorithm and the Symmetric Processing Resource Prediction-based Allocation (SPRPA)[8] benchmark algorithm in which the allocation is performed by applying a traditional approach in which the aim is to exactly predict the needed processing capacity and based on the minimization of the Root Mean Squared Error. The related work and the research contributions are illustrated in Section 2. The NFV architecture with Artificial Intelligence (AI)-based resource allocation is discussed in Section 3. We describe the cost-aware convolutional and LSTM-based resource allocation framework in Section 4. The main numerical results are shown in Section 5. We report the main conclusions in Section 6.