Skip to content

Commit e15a112

Browse files
authored
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<S>` was being misinterpreted as the beginning of an HTML tag `<S>`. This resulted in `error: end of comment block while expecting command </s>`.
1 parent 19b8103 commit e15a112

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

cpp/include/raft/random/device/sample.cuh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,14 @@ namespace raft::random::device {
2727

2828
/**
2929
* @brief warp-level random sampling of an index.
30+
*
3031
* It selects an index with the given discrete probability
31-
* distribution(represented by weights of each index)
32+
* distribution(represented by weights of each index).
33+
* Only thread 0 will contain the valid reduced result.
34+
*
3235
* @param rng random number generator, must have next_u32() function
3336
* @param weight weight of the rank/index.
3437
* @param idx index to be used as rank
35-
* @return only the thread0 will contain valid reduced result
3638
*/
3739
template <typename T, typename rng_t, typename i_t = int>
3840
DI void warp_random_sample(rng_t& rng, T& weight, i_t& idx)

cpp/include/raft/util/itertools.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ namespace raft::util::itertools {
3636
* fields of the structure (if the structure has more fields, some might be initialized
3737
* with their default value).
3838
* @param lists One or more initializer lists.
39-
* @return std::vector<S> A vector of structures containing the cartesian product.
39+
* @return `std::vector<S>` A vector of structures containing the cartesian product.
4040
*/
4141
template <typename S, typename... Args>
4242
std::vector<S> product(std::initializer_list<Args>... lists)

0 commit comments

Comments
 (0)