# A Scene Graph Similarity-Based Remote Sensing Image Retrieval Algorithm
## 3 Remote Sensing Image Retrieval Algorithms Based on Scene Graph Similarity
### One-Shot Object Detection Algorithm for Remote Sensing Images Based on a Siamese Network
Then, higher-level feature maps underwent upsampling to facilitate fusion with adjacent feature maps. Finally, the fused feature maps were convolved with a 3 \(\times\) 3 kernel to yield the output feature map. This process integrated feature maps from different scales to effectively enhance the adaptability of the model to small objects and boost its feature extraction capability. Figure 4: Flowcharts of the residual and AC modules. Figure 5: The flowchart of the ACSE module. The network structure parameters are showed in the Table 1.  
(3) Generation of the network ARPN based on the candidate regions of the attention mechanism  
In object detection algorithms, the region proposal network (RPN) generates candidate regions (proposals) through predefined anchor points to perform localization tasks. A standard RPN network primarily classifies anchors into foreground and background categories without distinguishing specific anchor types, generating several anchors with categories different from those of the query image. This could adversely affect the precision of the localization task. To address this challenge, this research proposed an attention-based region  
\begin{table}
\begin{tabular}{c c c} \hline \hline
**Name** & **ResNet01** & **ACSENet** \\ \hline Conv1 & \(7\times 7,64,\text{S2}\) & \(7\times 7,64,\text{S2}\) \\  & \(3\times 3\), maxpool, S2 & \(3\times 3\), maxpool, S2 \\ Conv2\_x & \(\left[ \begin{array}{c}1\times 1 Conv,64\\ 3\times 3 Conv,64\\ 1\times 1 Conv,256\end{array} \right]\times 3\) & \(\left[\begin{array}{c}1\times 1 Conv,64\\ 3\times 3 Conv,64  
proposal network (ARPN) that incorporated an attention mechanism. This network refined the features extracted from the retrieval feature map to \"purify\" the generated proposals such that their categories aligned as closely as possible with those of the query image. The overall structure of the attention-mechanism-based ARPN is illustrated in Figure 7. Firstly, the feature map of the query image underwent global average pooling and depth-wise separable convolution operations to obtain the support feature S. The retrieval image feature map underwent depthwise separable convolution operations to obtain the query feature Q. Then, a cross-correlation [37] operation was performed between the two to generate an attention feature map. Finally, the obtained attention feature map was input into the RPN network to generate proposals. (4) Double-head detector  
In one-shot object detection algorithms, detectors process and transform the candidate regions (proposals) outputted by the RPN, calculate the similarity between the feature maps of the retrieval and query images, and thereby obtain the category prediction results. Traditional Siamese networks typically use Euclidean distances to calculate the similarity between two features. However, Euclidean distances only calculate the geometric distance between two features, considering the differences among feature vector dimensions, neglecting the correlations among feature vectors. To better handle the correlations among feature vectors, this research designed a dual-branch detector structure based on CNNs and fully connected networks to accomplish the classification task. Figure 8 presents the overall structure of the double-head detector, where the input is two feature maps of size \(7\times 7\times 512\) obtained after ROI pooling. Firstly, the two feature maps were concatenated to generate a \(7\times 7\times 1024\) feature map. Then, they were separately passed through the FC-head and Conv-head to generate the corresponding similarities, which were then averaged to obtain the final similarity. Figure 8: The flowchart of the double-head detector. Figure 7: The schematic diagram of the ARPN.