# Profit-Efficient Elastic Allocation of Cloud Resources Using Two-Stage Adaptive Workload Prediction
## 6 Performance Evaluation
### Prediction Performance Evaluation
To demonstrate the superior performance of ATSMNN-LSTM over other models, we employ the Diebold-Mariano (DM) test statistics [45] to compare the statistical significance of prediction errors across different models, as illustrated in Figure 21. The corresponding \(p\)-value for ATSMNN-LSTM is provided in Table 2.  
Figure 19: Comparison of the absolute error (AE). Figure 20: Cumulative distribution percentage error for different models. ET, error threshold; PBET, error threshold percentage. The Diebold-Mariano (DM) test statistic matrix quantifies pairwise predictive accuracy differences between models, where each off-diagonal element represents the DM statistic for a row-versus-column model comparison. Positive values indicate superior performance of the column model, while negative values favor the row model. Larger absolute values reflect stronger statistical significance. A \(p\)-value \(<\) 0.05 suggests a statistically significant difference in prediction errors. As shown in Figure 21, the test results for ATSMN-LSTM compared to other models are consistently negative (first row: \(-4.918\), \(-15.41\), \(-5.947\), \(-60.67\), \(-4.444\), \(-6.93\), \(-7.063\), \(-6.315\)), indicating that this model outperforms others in prediction accuracy. Combined with the statistical significance (\(p\)-value \(<\) 0.05) shown in Table 2, these results demonstrate that ATSMN-LSTM achieves statistically significant improvements in prediction accuracy over all comparative models. Additionally, to present the effectiveness of the proposed \(k\)-means method with the first-order gradient feature, we randomly selected two groups of the classification NN output data under the first-order gradient feature and original data, respectively. The results are compared in Figures 22 and 23. The two upper figures demonstrate that the NN with the first-order gradient feature classified the data into suitable categories (i.e., uphill and downhill categories). Moreover, this proves that the k-means algorithm with the first-order gradient feature is effective in automatically building a training data set for the NN, thus avoiding the costs associated with manual labeling of the training data. \begin{table}
\begin{tabular}{c c c} \hline \hline
**Comparison Model** & \(p\)**-Value** & **Result** \\ \hline ATSMNN & \(8.764\times 10^{-7}\) & \(<\)0.05 \\ ARIMA & \(<\)2.2204 \(\times\)\(10^{-16}\) & \(<\)0.05 \\ LR & \(2.723\times 10^{-9}\) & \(<\)0.05 \\ SVR & \(<\)2.2204 \(\times\)\(10^{-16}\) & \(<\)0.05 \\ LSTM & \(8.845\times 10^{-6}\) & \(<\)0.05 \\ Transformer & \(4.204\times 10^{-12}\) & \(<\)0.05 \\ LSTM–Transformer & \(2.864\times 10^{-14}\) & \(<\)0.05 \\ NN & \(2.703\times 10^{-10}\) & \(<\)0.05 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: The \(p\)-value of ATSMN-LSTM model. Figure 21: Heatmap of the Diebold–Mariano (DM) test statistics. **Robustness Analysis:**  
The ATSMNN-LSTM model partitions the data into uphill and downhill trends, isolating more consistent patterns and reducing the impact of anomalies, particularly those deviating from the overall trend, on model performance. The specialized LSTM models, each trained on specific trend patterns, effectively mitigate the impact of outliers by constraining anomalous fluctuations within their respective trend categories, thereby reducing the interference of extreme values on prediction performance. Moreover, the LSTM architecture employed in the ATSMNN-LSTM model offers inherent resilience to outliers through its gating mechanisms. Specifically, the forget gate adaptively modulates the weights of anomalous values, while the memory cell maintains the intrinsic trend characteristics, ensuring prediction stability even in the presence of transient load fluctuations. Thus, the ATSMNN-LSTM model exhibits enhanced robustness.