From e15a112d4f5f7f4fcf148ef5af15e8ed98ba89ba Mon Sep 17 00:00:00 2001 From: Bradley Dice Date: Fri, 31 Jan 2025 17:39:49 -0600 Subject: [PATCH] Fix docs builds (#2562) This PR fixes two errors in docs builds: 1. a function with `void` return type had a `@return` parameter, which causes an error. The error was `error: found documented return type for raft::random::device::warp_random_sample that does not return anything` 2. a function with return type `std::vector` was being misinterpreted as the beginning of an HTML tag ``. This resulted in `error: end of comment block while expecting command `. --- cpp/include/raft/random/device/sample.cuh | 6 ++++-- cpp/include/raft/util/itertools.hpp | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/cpp/include/raft/random/device/sample.cuh b/cpp/include/raft/random/device/sample.cuh index d0e5200185..67b98f12fe 100644 --- a/cpp/include/raft/random/device/sample.cuh +++ b/cpp/include/raft/random/device/sample.cuh @@ -27,12 +27,14 @@ namespace raft::random::device { /** * @brief warp-level random sampling of an index. + * * It selects an index with the given discrete probability - * distribution(represented by weights of each index) + * distribution(represented by weights of each index). + * Only thread 0 will contain the valid reduced result. + * * @param rng random number generator, must have next_u32() function * @param weight weight of the rank/index. * @param idx index to be used as rank - * @return only the thread0 will contain valid reduced result */ template DI void warp_random_sample(rng_t& rng, T& weight, i_t& idx) diff --git a/cpp/include/raft/util/itertools.hpp b/cpp/include/raft/util/itertools.hpp index 493ac9befe..a31d9f79df 100644 --- a/cpp/include/raft/util/itertools.hpp +++ b/cpp/include/raft/util/itertools.hpp @@ -36,7 +36,7 @@ namespace raft::util::itertools { * fields of the structure (if the structure has more fields, some might be initialized * with their default value). * @param lists One or more initializer lists. - * @return std::vector A vector of structures containing the cartesian product. + * @return `std::vector` A vector of structures containing the cartesian product. */ template std::vector product(std::initializer_list... lists)