# Geometric Similarity Measurement Method for Micro Scene Generalization
## 2 Methodology
### Direction Similarity
#### 2.2.2 Micro Scenes' Direction Similarity  
The direction Voronoi diagram model uses the 8-direction system to calculate the percentage of the Voronoi edge in each main direction to obtain the direction relationship, and it cannot be directly applied to the calculation of direction similarity [46]. For example, for the case shown in Figure 10, Table 1 provides the calculation result of the direction relationship. The result is semi-qualitative, and the percentages in each direction cannot be directly applied to similarity calculations.  
Figure 9: Procedures for computing direction relationships between two object groups: (**a**) the object groups; (**b**) triangulation of the object groups; (**c**) proximal sections of the object groups; and (**d**) direction Voronoi diagram.  
As such, we constructed a direction similarity measurement method that combines a direction Voronoi diagram and Hausdorff distance. This method quantifies the overall distribution characteristics of the direction Voronoi diagram, and calculates the directional similarity through the Hausdorff distance.  
Firstly, the equipartition spacing of lines and polygons is determined using Equation (11), and the direction Voronoi diagram is constructed (Figure 11).  
\[d=\text{Int}\Big{[}\varepsilon*\frac{MapScale(A)}{1000}*\frac{1}{10}\Big{]} \tag{11}\]  
where Int[] is a function that returns the integer part, and _MapScale_ (\(A\)) is the scale denominator of data \(A\). _MapScale_ (\(A\))/1000 indicates the actual length of the graph corresponding to 1 mm, 1/10 represents the proportion that can be recognized by human eyes at a distance of 1 mm on the drawing, and \(\varepsilon\) represents the distance tolerance coefficient.  
Subsequently, the ratio of the area of the triangle in each direction to the total area is calculated so that it can be used as the \(X\) coordinate. The ratio of the length of each line segment to the total length is used as the \(Y\) coordinate. The size of the direction angle is used as the offset value of the \(Z\) axis. Thereby, a three-dimensional feature point set describing the direction relationship is obtained (Figure 12).  
\begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline
**Object** & **N** & **E** & **SE** & **S** & **SW** & **W** & **NW** \\
**Group** & **(\%)** & **NE (\%)** & **(\%)** & **(\%)** & **(\%)** & **(\%)** & **(\%)** & **(\%)** \\ \hline (a) & 40.67 & 15.11 & 5.44 & & & 2.52 & 12.82 & 23.44 \\ (b) & 42.87 & 13.33 & & & & 3.99 & 20.22 & 19.59 \\ (c) & 41.14 & 16.27 & 5.24 & & & 4.72 & 16.17 & 16.46 \\ \hline \hline \end{tabular}
\end{table}
Table 1: Computation results of the direction relationship.  
Figure 11: Construction of direction Voronoi diagram: (**a**–**c**) the directional Voronoi diagrams constructed using the three scales of micro scenes.  
Figure 10: Object group generalization: (**a**) original data, (**b**) the first generalization, and (**c**) the second generalization.  
Then, the directional similarity between the micro scenes is calculated by the Hausdorff distance of the feature point set. The calculation formula is as follows:  
\[\text{Sim}_{\text{direction}}=1-\left|\frac{H_{M,S_{1}}(S_{1},S_{2})-H_{M,S_{2}}(S _{1},S_{2})}{\text{max}\big{(}H_{M,S_{1}}(S_{1},S_{2}),H_{M,S_{2}}(S_{1},S_{2}) \big{)}}\right| \tag{12}\]  
where \(H_{M,S_{1}}(S_{1},S_{2})\) and \(H_{M,S_{2}}(S_{1},S_{2})\) are the median Hausdorff distance, and \(\text{Sim}_{\text{direction}}\) is the direction similarity between \(S_{1}\) and \(S_{2}\).