## 2 Related Deep Learning Algorithms
### Results of Experiments  
Our exhaustive analysis of different combinations of deep learning (DL) models and parameters has significantly contributed to understanding the application of reconstruction-based DL methods in anomaly detection. By exploring various configurations of autoencoders, Variational Autoencoders (VAEs), and Modified Loss Variational Autoencoders, we have provided valuable insights into the efficacy of these models in detecting network anomalies. As summarized in Table 2, the results reveal that the VAE model with a modified cost function consistently outperforms the other models. This highlights the importance of incorporating anomalous data in training despite not directly reconstructing it. An interesting observation from our experiments is that while the autoencoder showed acceptable performance even with large latent dimensions, it was more prone to overfitting, underscoring the need for careful model configuration. The paper's approach to evaluating the deep learning models for anomaly detection focuses on three key performance metrics: accuracy, specificity, and sensitivity [45]. Let us discuss the relevance and importance of each of these metrics in the context of anomaly detection:  
Accuracy:
* Measures the overall effectiveness of the model in classifying both normal and anomalous instances correctly. * It is a primary indicator of model performance, providing a high-level view of how well the model performs across all classifications. Specificity:
* Specificity measures the proportion of actual negatives (normal instances) that are correctly identified. * High specificity in network anomaly detection indicates the model's effectiveness in correctly identifying normal traffic, which is crucial to minimizing false alarms (false positives). Sensitivity (also known as recall):
* Sensitivity assesses the model's ability to correctly identify positives (anomalies). * This metric is crucial in anomaly detection, as it reflects the model's capacity to detect actual threats or anomalies in the network traffic. The choice of these metrics is particularly apt for anomaly detection in network traffic scenarios. In such applications, it is critical not only to identify anomalies accurately (high accuracy) but also to ensure that everyday activities are not misclassified as anomalies (high specificity) and that actual anomalies are not missed (high sensitivity). Accuracy provides a balanced view of overall model performance. At the same time, specificity and sensitivity offer insights into the model's ability to handle the nuances of anomaly detection--distinguishing between normal operations and potential threats. This combination of metrics offers a comprehensive evaluation of the model's performance, considering the critical aspects of anomaly detection where false positives and false negatives have significant implications. \begin{table}
\begin{tabular}{c c c c c c c c c c c} \hline \hline  & & & \multicolumn{3}{c}{**Autoencoder**} & \multicolumn{3}{c}{**Variational Autoencoder**} & \multicolumn{3}{c}{**Modified Loss**} \\  & & & & & & & & & & & \\ \hline
**Hidden\_dim** & **Latent\_dim** & **Accuracy** & **Specificity** & **Sensitivity** & **Accuracy** & **Specificity** & **Sensitivity** & **Accuracy** & **Specificity** & **Sensitivity** \\ \hline \multirow{8}{*}{64} & \multirow{2}{*}{8} & 0.98647 & 0.9866 & 0.98644 & 0.99452 & 0.99236 & 0.99506 & 0.99885 & 0.99876 & 0.99887 \\ \cline{3-10}  &  
The statistical analysis of the results from the autoencoder, Variational Autoencoder, and Modified Loss Variational Autoencoder across various hidden and latent dimensions yields the summary statistics shown in Table 3.  
These results demonstrate that the Modified Loss Variational Autoencoder consistently achieves higher performance across all metrics compared to the standard autoencoder and Variational Autoencoder, with very low variability in its results.