1 parent 8f8eedb commit 8afdc29Copy full SHA for 8afdc29
1 file changed
cpp/include/raft/random/detail/permute.cuh
@@ -13,6 +13,7 @@
13
#include <cooperative_groups.h>
14
#include <cuda/iterator>
15
#include <cuda/std/random>
16
+#include <thrust/random.h>
17
18
namespace raft {
19
namespace random {
@@ -211,8 +212,11 @@ void permute(IntType* perms,
211
212
uint64_t key)
213
{
214
if (N <= 0 || (perms == nullptr && out == nullptr)) { return; }
-
215
- cuda::shuffle_iterator shuffled_indices{cuda::random_bijection{N, cuda::std::minstd_rand{key}}};
+ thrust::random::ranlux48 rng(key);
216
+ cuda::shuffle_iterator shuffled_indices
217
+ {
218
+ cuda::random_bijection { N, rng }
219
+ }
220
221
if (out == nullptr) {
222
constexpr int ITEMS_PER_THREAD = 8;
0 commit comments