## 4 Experimental Results and Analysis
### Results and Discussion  
For implementing the different DL-based IDS methodologies in this study, we selected the Batch size as \(2^{7}\), Learning rate as 0.01, Optimizer as _Adam_, and used _binary crossentropy_ as the Loss function. _ReLU_ and _sigmoid_ are the used activation functions in this study for the DL approaches. Table 4 summarizes the results in a percentage of the performance evaluation metrics considered in this study. The proposed DNN-based methodology is compared with the four different supervised DL algorithms such as 1-dimensional Convolutional Neural Network (CNN-1D), Recurrent Neural Network (RNN), and its different variants as Gated Recurrent Unit (GRU) and Long Short-Term Memory (LSTM). The results confirm the superiority of the proposed DNN-based IDS solution for an IoT network comparing other DL methodologies using the evaluation metrics. It is also observed that the CNN-1D model is the second-best model, while the LSTM is the worst among others in terms of the considered evaluation metrics. The evaluation metrics scores are also depicted in Figures 5 and 6. From Figure 5, DNN achieved the highest detection accuracy of 99.010% compared to the other DL algorithms, while LSTM showed the most minimal performance with an accuracy score of 96.41%. The DNN model also correctly predicted the anomalies with 99.304% correctness. The DNN-based proposed methodology also showed a high F1 score than other DL models to show the model's accuracy on an IoT-Botnet 2020 dataset. In addition, the DNN model exhibited a high score of 96.08% of correctly predicting Benign flows compared to the other considered DL methodologies. Figure 6 plots the performance of the different DL-based NIDS methodologies in terms of FAR and FNR. As discussed earlier, the main problem exhibited by the current NIDS is the high FAR. To this end, it is observed that the proposed method exhibited a very low FAR and FNR compared to methodologies. The proposed scheme achieved a FAR of 3.9% while achieving a very high detection accuracy at the same time. The LSTM model is observed to achieve a high FAR of 11.9%, showing its inefficiency to learn enough patterns to classify the network flows correctly. Figure 7 exhibits the percentage improvement of the DNN-based NIDS comparing other DL-based solutions. It is observed that DNN exhibited an improvement of 0.57-2.6% in terms of the model's accuracy while at the same time reducing the FAR by 0.23-7.98% to show its effectiveness. It is also observed that DNN showed a slight improvement in terms of evaluation metrics from CNN-1D. Similarly, DNN performed quite well comparing the LSTM model exhibiting its superiority comparing the typical supervised DL algorithms. \begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline
**DL** & \multirow{2}{*}{**Accuracy**} & \multirow{2}{*}{**Precision**} & \multirow{2}{*}{**Recall**} & \multirow{2}{*}{**F1 Score**} & \multirow{2}{*}{**FAR**} & \multirow{2}{*}{**TNR**} & \multirow{2}{*}{**FNR**} \\
**Algorithms** & & & & & & & \\ \hline
**RNN** & 98.435 & 98.579 & 97.170 & 97.850 & 5.303 & 94.697 & 0.357 \\
**CNN-1D** & 98.882 & 99.113 & 97.857 & 98.466 & 4.146 & 95.854 & 0.140 \\
**GRU** & 98.394 & 98.491 & 97.143 & 97.795 & 5.303 & 94.697 & 0.411 \\
**LSTM** & 96.410 & 96.594 & 93.597 & 94.980 & 11.902 & 88.098 & 0.904 \\
**DNN** & 99.010 & 99.304 & 98.020 & 98.642 & 3.915 & 96.085 & 0.044 \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Performance Evaluation metrics score [%]. Figure 5: Performance Evaluation Metrics for different DL-based IDS methodologies. Table 5 details the analysis of the individual labels (Benign and Anomaly) in terms of percentage precision, recall, and F1-score. We observed that all of the methodologies exhibited a very high percentage of detection rate for the anomaly flows, with DNN showing the best score of 99.95%. On the other hand, it is observed that the detection rate to detect the benign traffic is slightly decreased by 3.87-10.99%, with DNN still performing better than other algorithms with a score of 96.085%.