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

Remove uint32 distance idx specializations #1235

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 12 additions & 16 deletions cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -307,15 +307,19 @@ if(RAFT_COMPILE_DIST_LIBRARY)
src/distance/neighbors/specializations/refine_h_uint64_t_uint8_t.cu
src/distance/cluster/kmeans_fit_float.cu
src/distance/cluster/kmeans_fit_double.cu
src/distance/distance/specializations/detail/canberra.cu
src/distance/distance/specializations/detail/chebyshev.cu
src/distance/distance/specializations/detail/correlation.cu
src/distance/distance/specializations/detail/cosine.cu
src/distance/distance/specializations/detail/cosine.cu
src/distance/distance/specializations/detail/hamming_unexpanded.cu
src/distance/distance/specializations/detail/hellinger_expanded.cu
src/distance/distance/specializations/detail/canberra_double_double_double_int.cu
src/distance/distance/specializations/detail/canberra_float_float_float_int.cu
src/distance/distance/specializations/detail/chebyshev_double_double_double_int.cu
src/distance/distance/specializations/detail/chebyshev_float_float_float_int.cu
src/distance/distance/specializations/detail/correlation_double_double_double_int.cu
src/distance/distance/specializations/detail/correlation_float_float_float_int.cu
src/distance/distance/specializations/detail/cosine_double_double_double_int.cu
src/distance/distance/specializations/detail/cosine_float_float_float_int.cu
src/distance/distance/specializations/detail/hamming_unexpanded_double_double_double_int.cu
src/distance/distance/specializations/detail/hamming_unexpanded_float_float_float_int.cu
src/distance/distance/specializations/detail/hellinger_expanded_float_float_float_int.cu
src/distance/distance/specializations/detail/hellinger_expanded_double_double_double_int.cu
src/distance/distance/specializations/detail/jensen_shannon_float_float_float_int.cu
src/distance/distance/specializations/detail/jensen_shannon_float_float_float_uint32.cu
src/distance/distance/specializations/detail/jensen_shannon_double_double_double_int.cu
src/distance/distance/specializations/detail/kernels/gram_matrix_base_double.cu
src/distance/distance/specializations/detail/kernels/gram_matrix_base_float.cu
Expand All @@ -327,28 +331,20 @@ if(RAFT_COMPILE_DIST_LIBRARY)
src/distance/distance/specializations/detail/kernels/tanh_kernel_double.cu
src/distance/distance/specializations/detail/kernels/tanh_kernel_float.cu
src/distance/distance/specializations/detail/kl_divergence_float_float_float_int.cu
src/distance/distance/specializations/detail/kl_divergence_float_float_float_uint32.cu
src/distance/distance/specializations/detail/kl_divergence_double_double_double_int.cu
src/distance/distance/specializations/detail/l1_float_float_float_int.cu
src/distance/distance/specializations/detail/l1_float_float_float_uint32.cu
src/distance/distance/specializations/detail/l1_double_double_double_int.cu
src/distance/distance/specializations/detail/l2_expanded_float_float_float_int.cu
src/distance/distance/specializations/detail/l2_expanded_float_float_float_uint32.cu
src/distance/distance/specializations/detail/l2_expanded_double_double_double_int.cu
src/distance/distance/specializations/detail/l2_sqrt_expanded_float_float_float_int.cu
src/distance/distance/specializations/detail/l2_sqrt_expanded_float_float_float_uint32.cu
src/distance/distance/specializations/detail/l2_sqrt_expanded_double_double_double_int.cu
src/distance/distance/specializations/detail/l2_sqrt_unexpanded_float_float_float_int.cu
src/distance/distance/specializations/detail/l2_sqrt_unexpanded_float_float_float_uint32.cu
src/distance/distance/specializations/detail/l2_sqrt_unexpanded_double_double_double_int.cu
src/distance/distance/specializations/detail/l2_unexpanded_double_double_double_int.cu
src/distance/distance/specializations/detail/l2_unexpanded_float_float_float_uint32.cu
src/distance/distance/specializations/detail/l2_unexpanded_float_float_float_int.cu
src/distance/distance/specializations/detail/lp_unexpanded_double_double_double_int.cu
src/distance/distance/specializations/detail/lp_unexpanded_float_float_float_uint32.cu
src/distance/distance/specializations/detail/lp_unexpanded_float_float_float_int.cu
src/distance/distance/specializations/detail/russel_rao_double_double_double_int.cu
src/distance/distance/specializations/detail/russel_rao_float_float_float_uint32.cu
src/distance/distance/specializations/detail/russel_rao_float_float_float_int.cu
src/distance/distance/specializations/fused_l2_nn_double_int.cu
src/distance/distance/specializations/fused_l2_nn_double_int64.cu
Expand Down
16 changes: 1 addition & 15 deletions cpp/include/raft/distance/specializations/detail/canberra.cuh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -48,20 +48,6 @@ extern template void distance<raft::distance::DistanceType::Canberra, double, do
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::Canberra, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
16 changes: 1 addition & 15 deletions cpp/include/raft/distance/specializations/detail/chebyshev.cuh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -47,20 +47,6 @@ extern template void distance<raft::distance::DistanceType::Linf, double, double
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::Linf, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,20 +49,6 @@ distance<raft::distance::DistanceType::CorrelationExpanded, double, double, doub
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::CorrelationExpanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
16 changes: 1 addition & 15 deletions cpp/include/raft/distance/specializations/detail/cosine.cuh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,20 +49,6 @@ distance<raft::distance::DistanceType::CosineExpanded, double, double, double, i
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::CosineExpanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,20 +49,6 @@ distance<raft::distance::DistanceType::HammingUnexpanded, double, double, double
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::HammingUnexpanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,20 +49,6 @@ distance<raft::distance::DistanceType::HellingerExpanded, double, double, double
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::HellingerExpanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -47,19 +47,6 @@ distance<raft::distance::DistanceType::JensenShannon, double, double, double, in
cudaStream_t stream,
bool isRowMajor,
double metric_arg);
extern template void
distance<raft::distance::DistanceType::JensenShannon, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -48,20 +48,6 @@ distance<raft::distance::DistanceType::KLDivergence, double, double, double, int
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::KLDivergence, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
15 changes: 1 addition & 14 deletions cpp/include/raft/distance/specializations/detail/l1.cuh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -47,19 +47,6 @@ extern template void distance<raft::distance::DistanceType::L1, double, double,
bool isRowMajor,
double metric_arg);

extern template void distance<raft::distance::DistanceType::L1, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -47,20 +47,6 @@ distance<raft::distance::DistanceType::L2Expanded, double, double, double, int>(
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::L2Expanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,20 +49,6 @@ distance<raft::distance::DistanceType::L2SqrtExpanded, double, double, double, i
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::L2SqrtExpanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2021-2022, NVIDIA CORPORATION.
* Copyright (c) 2021-2023, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -49,20 +49,6 @@ distance<raft::distance::DistanceType::L2SqrtUnexpanded, double, double, double,
bool isRowMajor,
double metric_arg);

extern template void
distance<raft::distance::DistanceType::L2SqrtUnexpanded, float, float, float, std::uint32_t>(
const float* x,
const float* y,
float* dist,
std::uint32_t m,
std::uint32_t n,
std::uint32_t k,
void* workspace,
size_t worksize,
cudaStream_t stream,
bool isRowMajor,
float metric_arg);

} // namespace detail
} // namespace distance
} // namespace raft
Loading