# Classification of Architectural Heritage Images Using Deep Learning Techniques
## 3 Results
### Comparison of the Results  
Table 6 shows a summary of the results obtained in the different tests performed. Considering the reference size of 64 \(\times\) 64 pixels, the best result is achieved with a full training of the ResNet network with an accuracy value of 0.93. Some experiments with other sizes were also repeated for comparison (32 \(\times\) 32 and 128 \(\times\) 128 pixels according to each case). Thus, for the case of images of \(128\times 128\) pixels, an accuracy result of 0.9319 is obtained with the fine tuning of the Inception-ResNet-v2 network. This result is slightly higher than mentioned before, but achieved with larger images (using 64 \(\times\) 64 pixel images the accuracy value stays at 0.9103). It is also observed that the number of epochs necessary for the fine-tuning case is much lower than for the full training. The following graphs show graphically the evolution of the accuracy results achieved (in ordinates) over time. In the first case (Figure 8), the abscissa represents the time spent (though they are dimensionless units, they correspond approximately to minutes in the case of using high performance equipment with several GPUs working in parallel and hours in the case of using a single conventional CPU, e.g., Intel Core i5). It can be seen that fine tuning always achieves convergence in a shorter time than full training, as expected. Regarding the accuracy achieved, it is greater in the case of using residual networks compared to the others, although every day new networks appear that achieve small but significant improvements in the accuracies achieved. As mentioned, the best results have been obtained with the full training of a ResNet type network, so the results obtained with this residual network are reviewed in greater depth. Table 7 shows the confusion matrix of the network once convergence is reached. The values of the diagonal of the matrix represent the percentage of correct predictions for each class. The rows correspond to the actual values and the columns to the predicted values. That is, the value of row \(i\) and column \(j\) corresponds to the percentage of images of class \(i\) incorrectly identified as class \(j\). \begin{table}
\begin{tabular}{l l l l} \hline \hline
**Algorithm** & **Image Size** & **Accuracy** & **Epoch** \\ \hline AlexNet (Full Training) & 32 \(\times\) 32 & 0.823 & 1400 \\ AlexNet (Full Training) & 64 \(\times\) 64 & 0.857 & 1198 \\ ResNet (Full Training) & 32 \(\times\) 32 & 0.896 & 949 \\ ResNet (Full Training) & 64 \(\times\) 64 & 0.93 & 585 \\ Inception V3 (Fine Tuning) & 64 \(\times\) 64 & 0.8943 & 93 \\ Inception V3 (Fine Tuning) & 128 \(\times\) 128 & 0.9155 & 88 \\ Inception-ResNet-v2 (Fine Tuning) & 64 \(\times\) 64 & 0.9103 & 82 \\ Inception-ResNet-v2 (Fine Tuning) & 128 \(\times\) 128 & 0.9319 & 77 \\ \hline \hline \end{tabular}
\end{table} 
Table 6: Comparison of the accuracy results obtained in the different tests performed. \begin{table}
\begin{tabular}{c c c c c c c} \hline \hline \multirow{2}{*}{**Momentum**} & \multirow{2}{*}{\begin{tabular}{c} **Initial** \\ **Learning Rate** \\ \end{tabular} } & \multirow{2}{*}{**Decay**} & \multicolumn{2}{c}{**Number of**} & \multirow{2}{*}{\begin{tabular}{c} **Weight** \\ **Epochs Per Decay** \\ \end{tabular} } & \multirow{2}{*}{\
\begin{tabular}{c} **End Learning** \\ **Decay Rate** \\ \end{tabular} } & \multirow{2}{*}{
\begin{tabular}{c} **Batch** \\ **Size** \\ \end{tabular} } \\ \hline
0.9 & 0.01 & 0.94. & 2 & 0.00004 & 0.0001 & 32 \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Hyperparameters used in the fine tuning of Inception-Resnet-v2 network. In the second case (Figure 9), the abscissa represent the epochs of the corresponding experiment. Table 8 shows the recall, precision and specificity values obtained for each of the classes. Since the different classes are not of the same size, the F1 score and balanced accuracy values have also been calculated, which try to compensate the results obtained when unbalanced classes are used, so we will focus on them.