# Application of Deep Neural Networks in Recognition of Selected Types of Objects in Digital Images
## 2 Results of Research
### Research Methodology  
The research methodology in this work is based on a consistent approach to designing and conducting experiments to optimize neural network models and evaluate the effectiveness of various machine learning techniques. This section discusses in detail the methods of data collection, processing, and analysis that were used to obtain reliable and valuable research results. The approach considered both classical supervised learning methods and modern techniques such as self-supervised learning and transfer learning. The data used in the study included both input and output data. The input data were images from the Animals-10 collection, which contains images of ten different categories of animals: dog, cat, horse, spyder, butterfly, chicken, sheep, cow, squirrel, elephant [33]. This collection was divided into a more extensive training collection and a test collection, which also served a validation function. In the supervised learning and transfer learning approaches, the data were explicitly categorized at the model training stage. In self-supervised learning, on the other hand, all images were placed in a single folder, as this type of learning does not require categorization of the data. Only after initial training, the model was trained on a smaller, categorized dataset using transfer learning, and then tested on a test set, allowing validation of the results. The outputs consisted of various results, including the following:  
* Graphs depicting the results of the conducted experiments. Two graphs were created for each experiment: a basic one, which included information such as accuracy, validation accuracy, loss and validation loss, and an extended version, which additionally showed GPU and memory usage. * Saved models after training, which can be used in the future for prediction or further testing. * Log files from TensorBoard and TensorFlow Profiler, which included training metrics such as accuracy and loss, as well as data on operation performance and resource consumption such as GPU and memory. The sampling plan in this work addressed both the selection of appropriate data to train the models and the selection of hyperparameter values. In the case of imagingdata, it was crucial to ensure that the training and test sets were representative so that models could be validated effectively. With regard to hyperparameters, an analysis of the literature and popular approaches was conducted to determine appropriate values. The study tested different batch sizes (8, 16, 32), activation functions (ReLU, Leaky ReLU, ELU) and optimizers with different learning rate settings [34]. The self-supervised learning approach used the best architecture from previous experiments (GoogLeNet) and the optimal batch size for best results. Data collection in this project was conducted through scripts written in Python 3.13.5, which automated the process of training models and collecting results. For supervised learning, scripts were prepared for three architectures: LeNet5, AlexNet, and GoogLeNet. Each of these scripts allowed experimentation with different values of hyperparameters, which allowed a thorough analysis of the impact of these parameters on the effectiveness of the models. This study began by selecting the most popular approach, the ReLU activation function and the Adam optimizer with an initial learning rate of \(1\times 10^{-3}\). Then, after determining the best batch size, subsequent experiments with the activation function used this best size, and only the activation function itself was changed. In the optimizer studies, once the optimal batch size and activation function were determined, only the choice of optimizer was already manipulated. For self-supervised learning, two scripts were created: one to perform training using the SimSiam architecture, and another to train the model with frozen weights. For the transfer learning approach, a single script was used to train the YOLOv8 model.