# Application of Deep Neural Networks in Recognition of Selected Types of Objects in Digital Images
## 3 Discussion of Results
Surprisingly, the cat class is recognized by the model with very low accuracy (0.29) and misclassified with higher probability as a dog, which may suggest that the characteristics the model considers key to this category are not sufficiently differentiated. This may be because the model with the GoogLeNet architecture, learned using a self-supervised learning approach, may have difficulty distinguishing between classes with less pronounced visual differences. The model, while using a sophisticated self-supervised learning approach, does not always handle more complex classes well, which may suggest the need for further tuning of hyperparameters or adapting the architecture to the specific requirements of the task. Comparing the GoogLeNet model to the SSL SimSiam model, which is also based on the GoogLeNet architecture, it can be seen that GoogLeNet in the standard supervised approach achieves better classification results. However, it is worth noting that the GoogLeNet model trained with the SimSiam self-supervised approach could give much better results if the training process lasted 100 to 200 epochs. Unfortunately, this approach is very time-consuming--already, 50 epochs of training took about 10 h. In addition, in order to maintain fairness and reliability of the results, the models were trained for the same number of epochs to fairly compare their performance. However, if the training time had been extended for the SSL approach using the SimSiam method, there is a high probability that it would have achieved even better performance, approaching and perhaps even surpassing the standard GoogLeNet results. The advantage of the self-supervised approach is that it does not require tagged data, which is a huge advantage, especially in the context of limited resources. Given that the model trained with the SSL approach achieved such good results even though we did not have labeled data, this is a very promising achievement that shows the potential of this approach in situations where access to labeled data is limited. Figure 29: Normalized confusion matrix for the GoogLeNet model. _Results from the transfer learning approach_  
Transfer learning, using the YOLOv8 model, was applied to evaluate the effectiveness of adapting knowledge from pre-trained models to new tasks. Experimental results indicate that the method is effective, especially in the context of small datasets. Graphs showing changes in loss and accuracy metrics during training with frozen weights show a systematic decrease in loss values and an increase in accuracy, suggesting the effectiveness of this technique. The approach, despite initial fluctuations in validation loss, showed improvements in the model's ability to generalize on new data, making transfer learning with YOLOv8 a particularly promising technique in the context of tasks requiring high-precision classification. Figure 31 shows the normalized confusion matrix for the retrained YOLOv8 model by transfer learning. The matrix indicates high classification accuracy for most classes, which is particularly noticeable for categories such as butterfly, chicken, and horse, where the accuracy is 100%, 99%, and 98%, respectively. Despite minor matching errors for some classes, the transfer learning model with YOLOv8 generally achieves very high accuracy, which is particularly noteworthy given its ability to transfer previously learned representations to new classification tasks. This approach has a significant advantage in terms of speed of training and effective use of existing models. Training a model using the transfer learning method for a period of 50 epochs took less than one hour, making this approach the fastest among those tested. Summarizing and comparing the results of this model with the best results from previous approaches--optimized GoogLeNet from the classical supervised learning approach and GoogLeNet trained with the SSL SimSiam method--it can be seen that each model has its own unique advantages.