# Detection of Marine Oil Spill from PlanetScope Images Using CNN and Transformer Models
## 4 Results
Moreover, the Transformer models offered superior edge detail representation, with a more precise delineation of oil spill boundaries compared to DeepLabV3+, which produced coarser edges and missed finer details. This improvement is due to the shifted window-based attention mechanism, which captures both local and global features and adapts to various sizes of irregular objects. Table 5 presents the results of a comparative analysis of the performance of different model sizes. DeepLabV3+ was trained with ResNet50 as the backbone network, while Swin-UPerNet and Mask2 Former were trained in both small and large versions. The difference in performance between the various model sizes was negligible. \begin{table}
\begin{tabular}{c c c c c c c c c c} \hline \hline  & & **moU** & \
\begin{tabular}{c} **IoU** \\ **(Oil)** \\ \end{tabular} &
\begin{tabular}{c} **IoU** \\ **(Not Oil)** \\ \end{tabular} & **Accuracy** & **Precision** & **Recall** & **F1\_Score** & **Kappa** \\ \hline \multirow{3}{*}{Fold 3} & DL & 0.794 & 0.713 & 0.876 & 0.905 & 0.899 & 0.871 & 0.883 & 0.766 \\ \cline{2-10}  & Swin & 0.874 & 0.827 & 0.920 & 0.942 & 0.934 & 0.930 & 0.932 & 0.864 \\ \cline{2-10}  & M2F & 0.811 & 0.743 & 0.879 & 0.910 & 0.891 & 0.897 & 0.894 & 0.788 \\ \hline \multirow{3}{*}{Fold 4} & DL & 0.720 & 0.568 & 0.872 & 0.890 & 0.814 & 0.846 & 0.828 & 0.657 \\ \cline{2-10}  & Swin & 0.811 & 0.699 & 0.922 & 0.934 & 0.893 & 0.889 & 0.891 & 0.782 \\ \cline{2-10}  & M2F & 0.789 & 0.666 & 0.912 & 0.925 & 0.875 & 0.878 & 0.876 & 0.753 \\ \hline \multirow{3}{*}{Fold 5} & DL & 0.732 & 0.582 & 0.882 & 0.899 & 0.829 & 0.845 & 0.837 & 0.673 \\ \cline{2-10}  & Swin & 0.850 & 0.763 & 0.937 & 0.948 & 0.912 & 0.921 & 0.916 & 0.833 \\ \cline{2-10}  & M2F & 0.845 & 0.754 & 0.937 & 0.947 & 0.910 & 0.918 & 0.913 & 0.827 \\ \hline \multirow{3}{*}{Avg.} & DL & 0.740 & 0.608 & 0.873 & 0.894 & 0.847 & 0.842 & 0.843 & 0.687 \\ \cline{2-10}  & Swin & 0.840 & 0.758 & 0.923 & 0.938 & 0.910 & 0.912 & 0.911 & 0.821 \\ \cline{2-10}  & M2F & 0.804 & 0.704 & 0.904 & 0.922 & 0.888 & 0.888 & 0.887 & 0.775 \\ \hline \hline \end{tabular}
\end{table} 
Table 4: _Cont._Figure 5: Randomly selected examples from fold 1, including PlanetScope RGB images, segmentation labels, and predictions from DeepLabV3+ (DL), Swin-UPerNet (Swin), and Mask2 Former (M2F). \begin{table}
\begin{tabular}{c c c c c c c c c c} \hline \hline  & **mIoU** & \begin{tabular}{c} **IoU** \\ **(Oil)** \\ \end{tabular} & \
\begin{tabular}{c} **IoU** \\ **(Not Oil)** \\ \end{tabular} &
\begin{tabular}{c} **Accuracy** \\ \end{tabular} & **Precision** & **Recall** & **F1\_Score** & **Kappa** \\ \hline \multirow{3}{*}{DL} & r50 & 0.726 & 0.587 & 0.864 & 0.886 & 0.863 & 0.813 & 0.833 & 0.668 \\ \cline{2-9}  & r101 & 0.733 & 0.602 & 0.864 & 0.887 & 0.857 & 0.825 & 0.839 & 0.679 \\ \hline \multirow{3}{*}{Swin} & SwinS & 0.840 & 0.763 & 0.918 & 0.935 & 0.913 & 0.910 & 0.911 & 0.823 \\ \cline{2-9}  & SwinB & 0.836 & 0.756 & 0.916 & 0.933 & 0.912 & 0.906 & 0.909 & 0.817 \\ \cline{2-9}  & SwinL & 0.841 & 0.763 & 0.918 & 0.935 & 0.914 & 0.909 & 0.912 & 0.823 \\ \hline \multirow{3}{*}{M2F} & SwinS & 0.786 & 0.680 & 0.893 & 0.913 & 0.891 & 0.864 & 0.876 & 0.753 \\ \cline{2-9}  & SwinB & 0.775 & 0.663 & 0.887 & 0.908 & 0.886 & 0.855 & 0.869 & 0.738 \\ \cline{2-9}  & SwinL & 0.774 & 0.661 & 0.887 & 0.907 & 0.886 & 0.853 & 0.868 & 0.736 \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Performance comparison for model versions between DeepLabV3+ (DL), Swin-UPerNet (Swin), and Mask2 Former (M2F). Figure 6: Randomly selected examples from fold 2, including PlanetScope RGB images, segmentation labels, and predictions from DeepLabV3+ (DL), Swin-UPerNet (Swin), and Mask2 Former (M2F). Figure 7: Randomly selected examples from fold 3, including PlanetScope RGB images, segmentation labels, and predictions from DeepLabV3+ (DL), Swin-UPerNet (Swin), and Mask2 Former (M2F).