1#ifndef KNNCOLLE_HNSW_UTILS_HPP
2#define KNNCOLLE_HNSW_UTILS_HPP
4#include "hnswlib/hnswalg.h"
16template<
typename Input_>
17using I = std::remove_cv_t<std::remove_reference_t<Input_> >;
37template<
class HnswData_>
39 static std::function<void(
const std::filesystem::path&)> fun;
62template<
typename HnswData_>
64 static std::function<void(
const std::filesystem::path&,
const hnswlib::SpaceInterface<HnswData_>*)> fun;
87template<
typename Distance_>
89 static std::function<void(
const std::filesystem::path&,
const std::function<Distance_(Distance_)>&)> fun;
113template<
typename HnswData_>
115 static std::function<hnswlib::SpaceInterface<HnswData_>*(
const std::filesystem::path&, std::size_t)> fun;
137template<
typename Distance_>
139 static std::function<std::function<Distance_(Distance_)>(
const std::filesystem::path&)> fun;
knncolle bindings for HNSW search.
Definition distances.hpp:13
std::function< void(const std::filesystem::path &)> & custom_save_for_hnsw_data()
Definition utils.hpp:38
std::function< void(const std::filesystem::path &, const hnswlib::SpaceInterface< HnswData_ > *)> & custom_save_for_hnsw_distance()
Definition utils.hpp:63
std::function< void(const std::filesystem::path &, const std::function< Distance_(Distance_)> &)> & custom_save_for_hnsw_normalize()
Definition utils.hpp:88
std::function< std::function< Distance_(Distance_)>(const std::filesystem::path &)> & custom_load_for_hnsw_normalize()
Definition utils.hpp:138
std::function< hnswlib::SpaceInterface< HnswData_ > *(const std::filesystem::path &, std::size_t)> & custom_load_for_hnsw_distance()
Definition utils.hpp:114