# Application of Deep Learning to Construct Breast Cancer Diagnosis Model
## 3 ResNet101-Optimize: Adaptive Moment Estimation (ADAM)
\begin{table}
\begin{tabular}{c c c c c} \hline \hline \multirow{2}{*}{**Fixed-Weight Layer**} & **Classification Accuracy 1** & **Classification Accuracy 2** & **Classification Accuracy 3** & **Average Accuracy** \\ \hline Before fixing mixed10 & & & & \\ (1-281) & 85.51\% & 86.96\% & 84.06\% & 85.51\% \\ Before fixing mixed9 & & & & \\ (1-250) & 88.41\% & 86.96\% & 86.96\% & 87.44\% \\ Before fixing mixed8 & & & & \\ (1-230) & 89.86\% & 91.30\% & 89.86\% & **90.71\%** \\ Before fixing mixed7 & & & & \\ (1-198) & 82.61\% & 84.06\% & 81.16\% & 82.61\% \\ \hline \hline \end{tabular} Bold text indicates highest accuracy rate.  
\end{table} 
Table 10: Fixed classification accuracy of different layers (ADAM). \begin{table}
\begin{tabular}{c c c c} \hline \hline \multirow{2}{*}{**Fixed-Weight Layer**} & **Classification Accuracy 1** & **Classification Accuracy 2** & **Classification Accuracy 3** & **Average Accuracy** \\ \hline Before fixing module 5c (1-333) & 79.71\% & 81.16\% & 78.26\% & 79.71\% \\ Before fixing module 5b (1-323) & 82.61\% & 84.06\% & 81.16\% & **82.61\%** \\ Before fixing module 5a (1-311) & 81.16\% & 78.26\% & 79.71\% & 79.71\% \\ \hline \hline \end{tabular} Bold text indicates highest accuracy rate.  
\end{table} 
Table 8: Accuracy rate of each classification with fixed number of layers (SGDM). \begin{table}
\begin{tabular}{c c c} \hline \hline \multirow{2}{*}{**Prediction Category**} & \multicolumn{2}{c}{**Genuine Category**} \\ \cline{2-4}  & **B or N** & **M** \\ \hline B or N & 25 & 5 \\ M & 5 & 34 \\ \hline \hline \end{tabular}  
* Inception v3–Optimizer: Adaptive Moment Estimation (ADAM)  
\end{table} 
Table 9: ResNet101 classification results. From Table 10, it can be observed that the classification accuracy of Inception v3 increases as the deeper layers are allowed to conduct higher-level feature extraction on the images. For this reason, the number of layers with fixed weights were reduced to test whether reducing the number of layers with fixed weights could increase the classification accuracy again (i.e., fixed weights from layer one to layer 198). From Table 10 the results showed that the classification accuracies obtained through three intervals of training and testing were 82.61%, 84.06%, and 81.16%, with an average accuracy of 82.61%; in other words, higher classification accuracy was obtained when the weights of Inception v3 were fixed from layer one to layer 230. 6. Inception v3-Optimizer: Stochastic Gradient Descent with Momentum (SGDM)  
From the experimental results, it can be observed that when using SGDM as an optimizer, the average classification accuracy of 83.09% was obtained after fixing the weight of each layer before the merge point mixed10. The average classification accuracy of 81.64% was obtained after fixing the weights of each layer before mixed9; 83.58% was obtained after fixing the weights of each layer before mixed8 (Table 11). As shown in Table 11, the highest classification accuracy is still obtained when using the SGDM optimizer with fixed weights from the first layer to the 230 th layer, but in contrast with when using the ADAM optimizer. The second-highest classification accuracy was obtained using SGDM optimizer with fixed weights from the first layer to the 281 st layer instead of the fixed weights from the first layer to the 250 th layer. It was also observed that the overall performance of Inception v3 using ADAM optimizer was better than the performance using SGDM. Since the best classification accuracy was obtained using Inception v3 with ADAM optimizer and transfer learning with fixed weights from the first layer to the 230 th layer, the test data set was integrated into this completed model and 91.3% classification accuracy was obtained. Twenty-eight (28) of the cases (benign or normal cases) were correctly classified, and two cases were incorrectly classified as malignant, 35 of the malignant cases were correctly classified, and four were incorrectly classified as benign or normal (Table 12).