370
V. L. Kondarattsev et al.
Similarity measure of descriptors. The input of the algorithm is a descriptive
representations of two models D 1 , D 2 , proximity threshold value ε ≥ 0. As a result,
the algorithm returns similarity measure μ(D 1 , D 2 ) between two descriptors.
Steps of the algorithm:
1. Let be a set of vectors from the second descriptive representation D 2 , that
have not yet participated in the comparison process. At the beginning, this set
coincides with the set of vectors that the second descriptor consists of =
d
21
, d
22
, . . . , d
2N
.
2. Also enter into consideration n that is the number of vectors for two descriptors
that are close to each other in the sense of the metric:
ρ
x
1
, x
2
=
4
i=1
x
1
i − x
2
i
, x
1
, x
2
∈ R
4
.
At the beginning of the algorithm n = 0.
3. Let ‘us find the number of vectors pairs from two descriptors that lie no further
apart than the threshold distance. To do this, we will iterate through all the vectors
d
1i in the first descriptor D 1 .
3.1 For each d
1i we will iterate over vectors from the set d
2 j
∈ .
3.2 Calculate the distance ρ
d
1i
, d
2 j
.
3.3 If this distance does not exceed the threshold value: ρ
< ε, then the vector
d
2 j
: = \
d
2 j
is excluded from further comparison, then we increase
the counter n = n + 1, otherwise, the set traversal continues.
4. Iterating over all vectors from D 1 , we can calculate the similarity measure as a
ratio:
μ =
n
N
.
Despite the fact that the algorithm was obtained empirically, in practice it shows
an acceptable quality of work.
24.5.3 Experiments
In our tests, we fix the number of vertex pairs on the icosphere equal to N = 640. This
number of points for emitting rays from the icosphere surface allows to achieve an
acceptable execution speed of the algorithm with the search quality already stabilized.
When conducting tests, it was experimentally checked that the ranked output of the
search stops changing with increasing of N . Examples of such tests for various N
values are shown in Fig. 24.8.
The implementation of the algorithm is written in Python 3 and Rust programming
languages and is released as an add-on for Blender 3D software.
V. L. Kondarattsev et al.
Similarity measure of descriptors. The input of the algorithm is a descriptive
representations of two models D 1 , D 2 , proximity threshold value ε ≥ 0. As a result,
the algorithm returns similarity measure μ(D 1 , D 2 ) between two descriptors.
Steps of the algorithm:
1. Let be a set of vectors from the second descriptive representation D 2 , that
have not yet participated in the comparison process. At the beginning, this set
coincides with the set of vectors that the second descriptor consists of =
d
21
, d
22
, . . . , d
2N
.
2. Also enter into consideration n that is the number of vectors for two descriptors
that are close to each other in the sense of the metric:
ρ
x
1
, x
2
=
4
i=1
x
1
i − x
2
i
, x
1
, x
2
∈ R
4
.
At the beginning of the algorithm n = 0.
3. Let ‘us find the number of vectors pairs from two descriptors that lie no further
apart than the threshold distance. To do this, we will iterate through all the vectors
d
1i in the first descriptor D 1 .
3.1 For each d
1i we will iterate over vectors from the set d
2 j
∈ .
3.2 Calculate the distance ρ
d
1i
, d
2 j
.
3.3 If this distance does not exceed the threshold value: ρ
< ε, then the vector
d
2 j
: = \
d
2 j
is excluded from further comparison, then we increase
the counter n = n + 1, otherwise, the set traversal continues.
4. Iterating over all vectors from D 1 , we can calculate the similarity measure as a
ratio:
μ =
n
N
.
Despite the fact that the algorithm was obtained empirically, in practice it shows
an acceptable quality of work.
24.5.3 Experiments
In our tests, we fix the number of vertex pairs on the icosphere equal to N = 640. This
number of points for emitting rays from the icosphere surface allows to achieve an
acceptable execution speed of the algorithm with the search quality already stabilized.
When conducting tests, it was experimentally checked that the ranked output of the
search stops changing with increasing of N . Examples of such tests for various N
values are shown in Fig. 24.8.
The implementation of the algorithm is written in Python 3 and Rust programming
languages and is released as an add-on for Blender 3D software.
