diff options
-rw-r--r-- | src/Witness_complex/include/gudhi/Landmark_choice_by_furthest_point.h | 7 | ||||
-rw-r--r-- | src/Witness_complex/include/gudhi/Landmark_choice_by_random_point.h | 4 |
2 files changed, 9 insertions, 2 deletions
diff --git a/src/Witness_complex/include/gudhi/Landmark_choice_by_furthest_point.h b/src/Witness_complex/include/gudhi/Landmark_choice_by_furthest_point.h index 2491b319..472cc0f7 100644 --- a/src/Witness_complex/include/gudhi/Landmark_choice_by_furthest_point.h +++ b/src/Witness_complex/include/gudhi/Landmark_choice_by_furthest_point.h @@ -39,6 +39,11 @@ namespace witness_complex { * current landmark set as the new landmark. * \details It chooses nbL landmarks from a random access range `points` and * writes {witness}*{closest landmarks} matrix in `knn`. + * + * The type KNearestNeighbors can be seen as + * Witness_range<Closest_landmark_range<Vertex_handle>>, where + * Witness_range and Closest_landmark_range are random access ranges + * */ template <typename KNearestNeighbours, @@ -82,7 +87,7 @@ namespace witness_complex { curr_max_w = i; } } - for (unsigned i = 0; i < points.size(); ++i) + for (unsigned i = 0; i < nb_points; ++i) std::sort(knn[i].begin(), knn[i].end(), [&wit_land_dist, i](int a, int b) { diff --git a/src/Witness_complex/include/gudhi/Landmark_choice_by_random_point.h b/src/Witness_complex/include/gudhi/Landmark_choice_by_random_point.h index 617c0258..7da74066 100644 --- a/src/Witness_complex/include/gudhi/Landmark_choice_by_random_point.h +++ b/src/Witness_complex/include/gudhi/Landmark_choice_by_random_point.h @@ -32,7 +32,9 @@ namespace Gudhi { namespace witness_complex { - /** \brief Landmark choice strategy by taking random vertices for landmarks. + /** + * \ingroup witness_complex + * \brief Landmark choice strategy by taking random vertices for landmarks. * \details It chooses nbL distinct landmarks from a random access range `points` * and outputs a matrix {witness}*{closest landmarks} in knn. * |