# KCFS-YOLOv5: A High-Precision Detection Method for Object Detection in Aerial Remote Sensing Images
## 5 Simulation Results
### Effects of Coordinate Attention Module  
To compare the results of different attention modules, we added several advanced attention modules in the YOLOv5 algorithm for contrast experiments. Among them, SE [35] is a classical channel attention module, and it is the basis for other attention models. The CBAM is a fusion attention model that integrates channel attention and spatial attention, which has excellent performance on different datasets. NAM [47] is a lightweight fusion attention module based on the CBAM module. The ECA is an improved attention mechanism based on SE module. We added these attention modules and the Coordinate attention module to the back of the backbone network and sent the processed feature map to the same feature fusion layer. We conducted simulation experiments on the RSOD dataset which has abundant object categories, and the results are shown in the following Table 2:  
From Table 2, we can see that after embedding coordinate attention module into YOLOv5 algorithm, the improved algorithm achieves the best detection effect on the RSOD dataset. Where, _Map P_, and _R_e reach 94.17%, 95.27% and 91.41%, respectively. The precision of the algorithm framework can be improved obviously without dramatically increasing the computation and the _Lantency_. Therefore, we finally decided to embed the coordinate attention module in the YOLOv5.  
To further explore the effect of coordinate attention module on task of object detection, we used the YOLOv5 algorithm embedded with the coordinate attention module for object detection on three different datasets, and evaluated the detection results. The results are shown in Table 3.  
\begin{table}
\begin{tabular}{c c c c c c c c c c c c} \hline \hline \multirow{2}{*}{**Algorithm**} & \multicolumn{3}{c}{**NWPU WHR-10**} & \multicolumn{3}{c}{**RSOD**} & \multicolumn{3}{c}{**UCAS-AOD-CAR**} \\  & _Map (\%)_ & _P\({}_{r}\) (\%)_ & _R\({}_{e}\) (\%)_ & _FPS_ & _Map (\%)_ & _P\({}_{r}\) (\%)_ & _R\({}_{e}\) (\%)_ & _FPS_ & _Map (\%)_ & _P\({}_{r}\) (\%)_ & _R\({}_{e}\) (\%)_ & _FPS_ \\ \hline YOLOv5 & 91.08 & 91.08 & 86.26 & 54.3 & 90.67 & 90.59 & 89.56 & 56.5 & 86.48 & 85.30 & 83.36 & 60.6 \\ YOLOv5+K-means++ & 91.71 & 95.86 & 87.82 & 52.1 & 93.97 & 95.27 & 91.41 & 54.3 & 88.17 & 91.04 & 83.68 & 55.9 \\ \hline \hline \end{tabular}
\end{table}
Table 1: Comparison of the detection performance of the improved algorithm embedded with K-means++ algorithm and the conventional algorithm.  
\begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Algorithm** & _Map (\%)_ & _P\({}_{r}\) (\%)_ & _R\({}_{e}\) (\%)_ & _P (M)_ & _Lantency (ms)_ & _FPS_ \\ \hline YOLOv5 & 90.67 & 90.59 & 89.56 & 7.072 & 17.7 & 56.5 \\ YOLOv5+SE & 91.56 & 91.64 & 87.65 & 7.200 & 18.3 & 54.6 \\ YOLOv5+CBAM & 93.76 & 95.25 & 91.80 & 7.302 & 19.5 & 51.3 \\ YOLOv5+NAM & 92.14 & 92.98 & 89.54 & 7.237 & 20.3 & 49.3 \\ YOLOv5+ECA & 93.07 & 94.01 & 90.33 & 7.222 & 18.7 & 53.5 \\ YOLOv5+CA & 94.17 & 95.27 & 91.41 & 7.253 & 19.6 & 51.0 \\ \hline \hline \end{tabular}
\end{table}
Table 2: The effects of different attention mechanism module on RSOD dataset.  
It can be seen from Table 3, the YOLOv5 algorithm embedded with Coordinate Attention module has achieved improved detection accuracy on three different datasets. Meanwhile, the detection speed of the improved algorithm is not significantly reduced. Therefore, we finally decided to use the Coordinate Attention module in the improved YOLOv5 algorithm.