## 4 Model Implementation and Evaluation
### Model Complexity  
Table 12 shows the initial parameters for the models EfficientNet-B0, ResNet101V2, InceptionV3, and InceptionResNetV2. It includes their truncated parameters, the number of Floating-Point Operations per Second (FLOPs), training duration, and inference duration. The EfficientNet-B0 model started with approximately 5.3 million parameters before truncation. After truncation, this number decreased to 4.39 million. These parameters were set to a frozen state, meaning they were not re-trained and were used only for feature extraction. Similarly, ResNet101V2 and InceptionV3 also saw significant reductions in their parameter counts. ResNet101V2 decreased from 44.6 million to 43.16 million, while  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Model** & **Accuracy (\%)** & **Recall (\%)** & **Precision (\%)** & **F1-Score (\%)** \\ \hline EfficientNet-B0 & 97.770 & 91.071 & 91.107 & 91.061 \\ ResNet101V2 & 97.375 & 89.506 & 89.623 & 89.471 \\ InceptionV3 & 98 & 92.004 & 92.071 & 92 \\ InceptionResNetV2 & 98.062 & 92.284 & 92.290 & 92.242 \\ \hline \hline \end{tabular}
\end{table}
Table 11: The results of multi-classification for the Kvasir v2 dataset utilizing the ILRC.  
Figure 12: The confusion matrices for the four CNN models after implementing under-sampling and data augmentation on the Kvasir-Capsule dataset.  
InceptionV3 dropped from 23.8 million to 22.34 million. InceptionResNetV2 experienced a notable decrease as well, falling from 55.8 million to 54.74 million. Overall, truncation was crucial because it reduced the complexity of the models and streamlined their architecture, which may help lower the risk of overfitting.  
FLOPs refer to the total number of arithmetic operations involving floating-point numbers (like addition and multiplication) that a system can execute in one second. In greater detail, multiply-add operations are considered two separate FLOPs because, in numerous contemporary models, convolutions do not include a bias term. Therefore, it is logical to classify multiplication and addition as distinct FLOPs.  
FLOPs provide an estimate of the computational complexity of the four DL models. Generally, a higher FLOP count suggests a more intricate model, which can result in improved performance but also demands greater computational resources. A model that has fewer FLOPs yet delivers comparable performance to a model with a higher FLOP count is often seen as more efficient. Knowing a model's FLOPs assists in choosing suitable hardware, such as GPUs or TPUs, that can manage the computational workload. Models with high FLOP counts necessitate more powerful hardware for effective operation. In real-time applications, the number of FLOPs directly influences inference speed. Fewer FLOPs can lead to quicker inference times, which is essential for time-sensitive tasks like autonomous driving or real-time video processing. The FLOPs for EfficientNet-B0, ResNet101V2, InceptionV3, and InceptionResNetV2 were 1,856,573,707; 32,808,287,188; 14,373,641,268; and 33,009,236,916, respectively.  
Inference time is an important metric for assessing the complexity of DL models, particularly when implementing them in practical applications. It indicates the duration required for a model to analyze an input and generate an output during the inference phase, which occurs when the model is utilized for making predictions after its training has been completed. The inference times for EfficientNet-B0, ResNet101V2, InceptionV3, and InceptionResNetV2 are 66.094 s per step, 100.143 s per step, 59.084 s per step, 122.175 s per step, and 76.108 s per step, respectively.