Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing code that explicitly compares equality of rmm memory resources #2047

Merged
merged 14 commits into from
Dec 9, 2023
Prev Previous commit
Next Next commit
More fixes
  • Loading branch information
cjnolet committed Dec 7, 2023
commit 9a446a6c949c00f1fc6b4867fa1b2b3df6aa77ba
2 changes: 0 additions & 2 deletions cpp/include/raft/matrix/detail/select_radix.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -843,9 +843,7 @@ void radix_topk(const T* in,
}
const IdxT buf_len = calc_buf_len<T>(len);

size_t req_aux = max_chunk_size * (sizeof(Counter<T, IdxT>) + num_buckets * sizeof(IdxT));
size_t req_buf = max_chunk_size * buf_len * 2 * (sizeof(T) + sizeof(IdxT));
size_t mem_req = req_aux + req_buf + 256 * 6; // might need extra memory for alignment

rmm::device_uvector<Counter<T, IdxT>> counters(max_chunk_size, stream, mr);
rmm::device_uvector<IdxT> histograms(max_chunk_size * num_buckets, stream, mr);
Expand Down
2 changes: 1 addition & 1 deletion cpp/include/raft/neighbors/detail/ivf_pq_build.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -1835,7 +1835,7 @@ auto build(raft::resources const& handle,
handle, kmeans_params, trainset_const_view, centers_view, utils::mapping<float>{});

// Trainset labels are needed for training PQ codebooks
rmm::device_uvector<uint32_t> labels(n_rows_train, stream, big_memory_resource);
rmm::device_uvector<uint32_t> labels(n_rows_train, stream, device_memory);
auto centers_const_view = raft::make_device_matrix_view<const float, IdxT>(
cluster_centers, index.n_lists(), index.dim());
auto labels_view = raft::make_device_vector_view<uint32_t, IdxT>(labels.data(), n_rows_train);
Expand Down
Loading