From 6e2f8d17baa86b28391027a6b031f98354bb88ac Mon Sep 17 00:00:00 2001 From: Ben Frederickson Date: Mon, 2 Dec 2024 16:19:40 -0800 Subject: [PATCH] build fixes --- cpp/src/distance/detail/kernels/gram_matrix.cu | 9 +++++++-- cpp/src/distance/detail/kernels/kernel_factory.cu | 3 +++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/cpp/src/distance/detail/kernels/gram_matrix.cu b/cpp/src/distance/detail/kernels/gram_matrix.cu index a142c7667..bba44658d 100644 --- a/cpp/src/distance/detail/kernels/gram_matrix.cu +++ b/cpp/src/distance/detail/kernels/gram_matrix.cu @@ -465,14 +465,19 @@ void GramMatrixBase::linear(raft::resources const& handle, if (is_col_major_nopad) { auto out_row_major = raft::make_device_matrix_view( out.data_handle(), out.extent(1), out.extent(0)); + + // TODO: use PW distance from cuvs raft::sparse::distance::pairwise_distance( - handle, x2, x1, out_row_major, cuvs::distance::DistanceType::InnerProduct, 0.0); + handle, x2, x1, out_row_major, raft::distance::DistanceType::InnerProduct, 0.0); } else { auto out_row_major = raft::make_device_matrix_view( out.data_handle(), out.extent(0), out.extent(1)); raft::sparse::distance::pairwise_distance( - handle, x1, x2, out_row_major, cuvs::distance::DistanceType::InnerProduct, 0.0); + handle, x1, x2, out_row_major, raft::distance::DistanceType::InnerProduct, 0.0); } } +template class GramMatrixBase; +template class GramMatrixBase; + }; // namespace cuvs::distance::kernels diff --git a/cpp/src/distance/detail/kernels/kernel_factory.cu b/cpp/src/distance/detail/kernels/kernel_factory.cu index dd2e0c556..25f9e9b84 100644 --- a/cpp/src/distance/detail/kernels/kernel_factory.cu +++ b/cpp/src/distance/detail/kernels/kernel_factory.cu @@ -55,4 +55,7 @@ template return res; } +template class KernelFactory; +template class KernelFactory; + }; // end namespace cuvs::distance::kernels