# Application of Deep Neural Networks in Recognition of Selected Types of Objects in Digital Images
## 4 Summary  
The research conducted was aimed at optimizing neural network models and evaluating the effectiveness of various machine learning techniques in object detection tasks in images. The paper discusses in detail the results of experiments on the selection of hyperparameters, the comparison of different neural network architectures, and the comparison of the optimized architecture with the highest accuracy with other techniques such as self-supervised learning and transfer learning. Three main approaches were analyzed: supervised learning, self-supervised learning, and transfer learning, with different results in terms of object detection efficiency. The YOLOv8 model achieved the highest efficiency in the transfer learning approach, as confirmed by the results on classification accuracy and optimal use of computational resources. The results suggest that transfer learning, especially using pre-trained models, is a promising technique for tasks requiring fast training and high classification accuracy, especially in the context of small datasets. In the case of supervised learning, studies have shown that the technique, despite its effectiveness, is strongly dependent on the quality and quantity of labeled data. The GoogLeNet model used in this approach has achieved high accuracy in classifying objects in images, demonstrating its stability and effectiveness with large labeled datasets. However, the time-consuming nature of the data-labeling process is a significant limitation of this method. On the other hand, self-supervised learning (SSL), implemented using the SimSiam method, allowed a significant reduction in the dependence on labeled data, generating hidden labels from unstructured data. Despite the smaller number of labeled data, the method showed promising results, with the potential to further improve accuracy with increased training time. Figure 31: Normalized confusion matrix for the retrained YOLOv8 model by transfer learning method. Compared to classic SL, the model trained with SSL achieved lower but still competitive accuracy, indicating the method's great potential in the context of limited labeled data resources. The method achieved higher accuracy than the LeNet-5 model after 50 epochs on the full dataset, suggesting that the size of the images and the fact that LeNet-5 used black and white images have a more significant impact on the model's performance than the data labeling itself in these particular approaches. This indicates the importance of appropriate training data selection and complexity in terms of achieving better object detection results. Several significant difficulties were encountered during the project:  
* One of the biggest challenges was the limitation of computing resources. For very deep and complex architectures, such as GoogLeNet and GoogLe-Net in combination with SimSiam, memory started to run out at larger batch sizes, limiting the ability to test more resource-intensive hyperparameter values. * Training more complex models, such as GoogLeNet and GoogLeNet+ SimSiam, was also very time-consuming. The long training time affected the performance of the project and translated into significant power consumption. * Relatively low accuracy was obtained for the LeNet-5 model due to the architecture itself. LeNet-5 accepts small images that become pixelated during processing, leading to a significant loss of relevant information. * Another difficulty was synchronizing versions of different tools, libraries, environments, and programming language. Compatibility issues often caused delays and required additional work to make sure all the system components worked harmoniously. * Analyzing the results and selecting the best solution was also a challenge. Looking at the confusion matrix, different approaches did better with different classes of objects, making it difficult to clearly identify the best model. Final decisions were made based on the overall results, which may not have taken into account detailed differences in classification.