# Research on Building Target Detection Based on High-Resolution Optical Remote Sensing Imagery
## 2 Data and Methodology
### Methodology
#### 2.2.2 Diffusion-Based Saliency Model  
In order to improve the accuracy of building detection and reduce missed detection and misjudgment, the saliency model is used for building target detection. The specific flowchart is shown in Figure 4. First, the SLIC super-pixel segmentation method is used. This method uses the K-means algorithm to generate the super-p  
Figure 4: The flowchart of saliency model for building detection. and spatial distances of the images together define the distance metric function used for clustering. The results of super-pixel segmentation are shown in Figure 5.  
After generating the SLIC super-pixel model, a construction graph \(\mathbf{G}=(\mathbf{V},\mathbf{E})\) is obtained, where \(\mathbf{V}\) represents the node, \(\mathbf{E}\) represents the undirected edge connecting the nodes, and the saliency values of adjacent nodes are very similar with high probability. And any two boundary nodes of the construction graph are adjacent to each other, thus forming a closed-loop graph, which can effectively reduce the geodesic distance of similar super-pixels, and then optimize the ranking results of the manifold ranking algorithm. Assuming that \(N_{i}\) denotes the set of neighboring points of node \(v_{i}\), and all nodes around the image boundary are considered as neighboring points of each other. Calculate the distance between the nodes in the CIELab color space, that is, the difference between the mean values of the superpixels corresponding to the two nodes and normalize them to obtain the incidence matrix \(\mathbf{W}\) and use manifold ranking algorithm to achieve saliency propagation. The tightness of the super-pixel blocks is defined by the degree of similarity between super-pixel blocks and spatial location, and to describe the similarity between super-pixels more precisely, define \(\mathbf{A}=\left[a_{ij}\right]_{N\times N}\) as the color similarity metric between a pair of super-pixels \(v_{i}\) and \(v_{j}\), where \(a_{ij}=\exp\left(-\left\|c_{i}-c_{j}\right\|/\sigma^{2}\right)\), and use the manifold ranking algorithm to propagate the similarity between super-pixels to obtain \(\mathbf{H}^{T}=(\mathbf{D}-\alpha\mathbf{W})^{-1}\mathbf{A}\), where the computed result \(\mathbf{H}=\left[h_{ij}\right]_{N\times N}\) is the executed diffusion of the similarity metric matrix. The method for calculating the spatial variance of the super-pixel \(v_{i}\) is shown in Equation (8). \[\mathbf{sv}(i)=\frac{\sum_{j=1}^{N}h_{ij}\cdot n_{j}\cdot\left\|b_{j}-u_{i} \right\|}{\sum_{j=1}^{N}h_{ij}\cdot n_{j}}, \tag{8}\]  
where \(n_{j}\) is the number of pixels of super-pixel \(v_{j}\) and \(b_{j}=\left[b_{j}^{x},b_{j}^{y}\right]\) is the center of mass of super-pixel \(v_{j}\) and defines the spatial mean \(\mu_{i}=\left[u_{i}^{x},u_{i}^{y}\right]\) as Equation (9). \[ \begin{array}{l}\mu_{i}^{x}=\frac{\sum_{j=1}^{N}h_{ij}\cdot n_{j}\cdot b_{i} ^{y}}{\sum_{j=1}^{N}h_{ij}\cdot n_{j}}\\ \mu_{i}^{y}=\frac{\sum_{j=1}^{N}h_{ij}\cdot n_{j}\cdot b_{i}^{y}}{\sum_{j=1}^{ N}h_{ij}\cdot n_{j}}\end{array}  \tag{9}\]  
The saliency map calculated by the diffusion-based foreground compactness saliency [15] detection method is shown in Equation (10). \[S_{com}(i)=1-Norm(\mathbf{sv}(i)), \tag{10}\]  
Figure 5: The results of super-pixel segmentation. (**a**) Image I, (**b**) Image II. where \(Norm(. )\) is the function that normalizes the data to 0-1. Define the Lab color space distance \(\mathbf{Id}(i)\) of the super-pixel \(v_{i}\) and its neighboring super-pixels as Equation (11). \[\mathbf{Id}(i)=\frac{\sum_{j\in N_{i}}S_{com}(j)\cdot n_{j}}{\sum_{j\in N_{i}}n_ {j}}\cdot\max_{j\in N_{i}}\lVert c_{i}-c_{j}\rVert. \tag{11}\]  
The smaller the value of \(\mathbf{Id}(i)\), the higher the probability that the super-pixel \(v_{i}\) belongs to the background. The \(\mathbf{Id}\) value smaller than the \(\mathbf{Id}\) mean is set to 0.