Skip to content

Commit

Permalink
Parametrize K for comparisons
Browse files Browse the repository at this point in the history
  • Loading branch information
JacksonCampolattaro committed Jul 16, 2020
1 parent 9fd3504 commit 8ef4840
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions Octree/test/Octree/test_octree_nearest_neighbour.cpp
Expand Up @@ -94,12 +94,10 @@ void naive_vs_octree(std::size_t dataset_size) {
assert(octree_elapsed_time < naive_elapsed_time);
}

void kdtree_vs_octree(std::size_t dataset_size) {
void kdtree_vs_octree(std::size_t dataset_size, std::size_t K) {

std::cout << "[ " << dataset_size << " points ]" << std::endl;

int K = 16;

// Create a dataset
Point_set points;
CGAL::Random_points_in_cube_3<Point> generator;
Expand Down Expand Up @@ -156,10 +154,10 @@ int main(void) {
naive_vs_octree(10000);
naive_vs_octree(100000);

kdtree_vs_octree(100);
kdtree_vs_octree(1000);
kdtree_vs_octree(10000);
kdtree_vs_octree(100000);
kdtree_vs_octree(100, 16);
kdtree_vs_octree(1000, 16);
kdtree_vs_octree(10000, 16);
kdtree_vs_octree(100000, 16);

return EXIT_SUCCESS;
}

0 comments on commit 8ef4840

Please sign in to comment.