SpiecsEngine
 
Loading...
Searching...
No Matches

◆ SetUp()

void SpicesTest::kd_tree_test::SetUp ( )
inlineoverrideprotected

Testing class initialize function.

ThreadPool for build KDTree.

Insert points into the kd_tree.

Definition at line 27 of file KDTree_test.h.

27 {
28
30
34 std::vector<scl::kd_tree<2>::item> points;
35 points.push_back({ 3.0, 6.0 });
36 points.push_back({ 2.0, 2.0 });
37 points.push_back({ 4.0, 7.0 });
38 points.push_back({ 1.0, 3.0 });
39 points.push_back({ 2.0, 4.0 });
40 points.push_back({ 5.0, 4.0 });
41 points.push_back({ 7.0, 2.0 });
42
46 m_KDTree.insert(points);
47 }
#define SPICESTEST_PROFILE_FUNCTION()
scl::kd_tree< 2 > m_KDTree
Create a KDTree with 2 dimensions.
Definition KDTree_test.h:57
void insert(const std::vector< item > &points)
Insert a point into the kd_tree. Start at the root, comparing the new point’s first dimension with th...
Definition KDTree.h:602