Abstract:
Medication errors, commonly contributed by human factors, have the potential to cause serious harm to human beings. Therefore, a deep learning-based approach is necessary to be developed to ensure patient safety. The investigation involves three core base models—ResNet50, InceptionV3, and MobileNet—assessing individual performances. A novel stacking ensemble method was proposed, and its efficacy is compared to the base models and related works. The research’s key findings reveal that the proposed stacking ensemble model outperforms all the other models with a 98.80% test accuracy. It also excels in precision, recall, and F1-score, with scores of 98.81%, 98.80%, and 98.80%, respectively. The study also indicates the time efficiency of the proposed stacking ensemble compared to other methods. Notably, MobileNet exhibits superiority in training and prediction time, emphasizing the trade-offs between accuracy and efficiency. Overall, this research sheds light on the overlooked potential of ensemble methods in pill image classification, contributing a robust solution to enhance our understanding of their effectiveness in healthcare and pharmaceutical applications.