## 4 Results and Discussion
### U-Net with Pretrained Backbones for Segmentation  
During the segmentation phase, we performed four experiments, each consisting of comparable sub-experiments. In sub-experiments (1.1, 2.1, 3.1, and 4.1), we used images and masks from ORIGA and REFUGE, while in sub-experiments (1.2, 2.2, 3.2, and 4.2), we employed images and masks from ORIGA and RIM-ONE DL. To identify the best-performing backbone architecture for the U-Net model, we evaluated it using different datasets. ResNet34 was the primary architecture, but ResNet50, VGG19, DenseNet121, and EfficientNetB0 were also explored. In subsequent experiments, we utilized images and their masks sourced from ORIGA and REFUGE for Experiment 1.1, and ORIGA and RIM-ONE DL for Experiment 1.2. Images were resized to 128 \(\times\) 128 pixels and denoised with Gaussian and median filters. Masks were encoded to represent background, OD, and OC classes. Images and masks were split into training and test sets (80:20) and normalized by scaling pixel values from 0-255 to 0-1. All models were trained for the same number of epochs and batch size. ResNet34 outperformed other pretrained backbones, achieving the highest mIoU in Experiment 1.1, as indicated in Table 9, and Experiment 1.2, as shown in Table 10.  
Experiments 2.1 and 2.2 evaluated the effect of augmentation techniques on image segmentation using ResNet34 in the U-Net model based on similar datasets. Techniques included random rotations, brightness, contrast adjustments, and horizontal flips. Experiment 2.1 applied these to 832 images and explored the impact of increasing the dataset to 1248 images. Measured mIoU assesses technique effectiveness and the impact of removing brightness and contrast adjustments. Experiment 2.1 results are in Table 11. In Experiment 2.2, the same techniques augmented 1360 images, investigating the impact of increasing to 2040 images. Measured mIoU, exploring the effect of excluding random brightness and contrast adjustments, is presented in Table 12. This comprehensive approach allowed for us to determine which augmentation techniques provided the most improvement to the ResNet34-based image segmentation model. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline  & \multicolumn{4}{c}{**Experiment 1.2**} \\ \hline
**Dataset** & **Epoch** & **Batch Size** & **Model** & **Backbone** & **mIoU** \\ \hline  & & & & ResNet34 & 0.82803315 \\ ORIGA & & & & ResNet50 & 0.82745105 \\ and & 30 & 8 & U-Net & VGG19 & 0.2535684 \\ RIM-ONE DL & & & & EfficientNetb0 & 0.27394077 \\  & & & & DenseNet121 & 0.28304914 \\ \hline \hline \end{tabular}
\end{table} 
Table 10: The mIoU scores for the pretrained backbones in Experiment 1.2. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline  & \multicolumn{4}{c}{**Experiment 1.1**} \\ \hline
**Dataset** & **Epoch** & **Batch Size** & **Model** & **Backbone** & **mIoU** \\ \hline  & & & & ResNet34 & 0.8432825 \\ ORIGA & & & & ResNet50 & 0.8392462 \\ and & 30 & 8 & U-Net & VGG19 & 0.281714 \\ REFUGE-TS & & & & EfficientNetb0 & 0.5335277 \\  & & & DenseNet121 & 0.6566112 \\ \hline \hline \end{tabular}
\end{table} 
Table 9: The mIoU scores for the pretrained backbones in Experiment 1.1. Experiments 3.1 and 3.2 tested batch sizes (8, 16, 32, 64, and 128) for mIoU impact. Batch size 8 yielded the highest mIoU during training. However, when evaluating on the HRF dataset, a batch size of 16 performed better. Tables 13 and 14 display mIoU values for different batch sizes, underscoring the importance of proper selection. In Experiments 4.2 and 4.2, training utilized varied epochs: 30, 40, and 50 for Experiment 4.1, and extended to 60 for Experiment 4.2. Experiment 4.1 achieved the highest mIoU (0.953595) at 50 epochs, but a comparable mIoU (0.950539) was obtained at 40 epochs. Opting for improved visual results on the (HRF) dataset, the model trained with 40 epochs was selected. Table 15 presents mIoU values for different epoch counts, while Figure 6 illustrates the training and validation IOU and loss for this model.