## 5 Discussion  
The proposed scheme offers several advantages and demonstrates unique contributions to the field of breast cancer diagnosis. By employing a dual-dataset approach, this study evaluates the impact of dataset size and image resolution on model performance, providing valuable insights into the influence of data characteristics. The integration of particle swarm optimization (PSO) into the dense layer of the custom-built CNN model represents a novel methodological advancement, significantly enhancing classification accuracy and computational efficiency. In this study, model performances were evaluated using two datasets. The first dataset contains 157,572 images with \(50\times 50\times 3\) dimensions, while the second dataset contains 1116 images with 224 \(\times\) 224 \(\times\) 3 dimensions. Training was performed on both datasets, and the results were compared. The results obtained in experimental study 1, utilizing a dataset of 157,572 images with dimensions of \(50\times 50\times 3\), demonstrate that all employed deep learning models achieved superior accuracy. When the performance metrics of the model were analyzed, it was observed that the custom-built CNN model had the highest accuracy, precision, recall, and F1 score value among all of the other models. This model yielded 93.80% accuracy for the experimental study 1. The analysis of the results from experimental study 2, which utilized a dataset of 1116 images with dimensions of 224 \(\times\) 224 \(\times\) 3, reveals that all models achieved high accuracy rates, similar to the rates obtained in experimental study 1. Among the evaluated models, the MobileNet model obtained an accuracy rate of 95.54% for the experimental study 2. Moreover, the use of a smaller dataset in this study influenced the precision, recall, and F1 score values of the models. The results of experimental study 1 exhibited consistent accuracy, precision, recall, and F1 score values across all models; however, experimental study 2, which employed a smaller dataset, showed a decrease in precision, recall, and F1 scores for all models except the MobileNet model. Despite achieving high accuracy and precision with limited data, these models exhibited low recall values. Consequently, it was observed that the dataset size plays an important role in the evaluation of model performance. Models trained with \(50\times 50\times 3\) dimensions generally exhibited higher accuracy rates, with more balanced and elevated precision, recall, and F1 scores compared to the results of experimental study 2. It was observed that models trained with larger-sized images (224 \(\times\) 224 \(\times\) 3) generally achieved higher precision and demonstrated better overall performance. However, other metrics such as recall, and F1 score, were lower, likely due to the smaller dataset size. In addition, the analysis of the false-negative and false-positive classifications by the CNN model using heatmap histogram graphs revealed that activation values were low in some images, while others showed a wider range. This indicates that the model failed to exhibit sufficient activation in certain cancerous regions and focused on irrelevant areas in other samples. Similarly, the analysis of the heatmap histogram graphs for images in  
Figure 12: (**a**) Accuracy and (**b**) loss function graph of DenseNet201 model within the scope of experimental study 2.  
which the model made false positive classifications revealed a wide range of activation values. This indicates that the model generated high activation values in some regions, which led to their incorrect classification as cancerous. It is concluded that these issues may arise because the images in the dataset are patched from 162 whole-mount slide images. This is because the limited size of the patch images significantly affected the model's ability to grasp a wider context and distinguish healthy tissues accurately. Figure 13 shows the images classified as false negatives (FN) and their corresponding Grad-CAM heatmap histogram plots.