Loading CHANGELOG.md +2 −0 Original line number Diff line number Diff line Loading @@ -12,6 +12,7 @@ Please mark all change in change log and use the ticket from JIRA. - \#340 - Test cases run failed on 0.6.0 - \#353 - Rename config.h.in to version.h.in - \#374 - sdk_simple return empty result - \#397 - sdk_simple return incorrect result ## Feature - \#12 - Pure CPU version for Milvus Loading @@ -29,6 +30,7 @@ Please mark all change in change log and use the ticket from JIRA. - \#310 - Add Q&A for 'protocol https not supported or disable in libcurl' issue - \#322 - Add option to enable / disable prometheus - \#358 - Add more information in build.sh and install.md - \#255 - Add ivfsq8 test report detailed version ## Task Loading core/src/index/CMakeLists.txt +3 −3 Original line number Diff line number Diff line Loading @@ -88,14 +88,14 @@ endif () include(ThirdPartyPackagesCore) if (CMAKE_BUILD_TYPE STREQUAL "Release") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -fPIC -DELPP_THREAD_SAFE -fopenmp") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -fPIC -DELPP_THREAD_SAFE -fopenmp -mavx -mf16c -msse4 -mpopcnt") if (KNOWHERE_GPU_VERSION) set(CUDA_NVCC_FLAGS "${CUDA_NVCC_FLAGS} -O3") endif () else () set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIC -DELPP_THREAD_SAFE -fopenmp") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -g -fPIC -DELPP_THREAD_SAFE -fopenmp -mavx -mf16c -msse4 -mpopcnt") if (KNOWHERE_GPU_VERSION) set(CUDA_NVCC_FLAGS "${CUDA_NVCC_FLAGS} -O0 -g") set(CUDA_NVCC_FLAGS "${CUDA_NVCC_FLAGS} -O3 -g") endif () endif () Loading core/src/index/knowhere/knowhere/common/Config.h +14 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,8 @@ #pragma once #include <memory> #include <sstream> #include "Log.h" namespace knowhere { Loading Loading @@ -50,6 +52,18 @@ struct Cfg { CheckValid() { return true; } void Dump() { KNOWHERE_LOG_DEBUG << DumpImpl().str(); } virtual std::stringstream DumpImpl() { std::stringstream ss; ss << "dim: " << d << ", metric: " << int(metric_type) << ", gpuid: " << gpu_id << ", k: " << k; return ss; } }; using Config = std::shared_ptr<Cfg>; Loading core/src/index/knowhere/knowhere/index/vector_index/helpers/IndexParameter.cpp +22 −0 Original line number Diff line number Diff line Loading @@ -34,4 +34,26 @@ GetMetricType(METRICTYPE& type) { KNOWHERE_THROW_MSG("Metric type is invalid"); } std::stringstream IVFCfg::DumpImpl() { auto ss = Cfg::DumpImpl(); ss << ", nlist: " << nlist << ", nprobe: " << nprobe; return ss; } std::stringstream IVFSQCfg::DumpImpl() { auto ss = IVFCfg::DumpImpl(); ss << ", nbits: " << nbits; return ss; } std::stringstream NSGCfg::DumpImpl() { auto ss = IVFCfg::DumpImpl(); ss << ", knng: " << knng << ", search_length: " << search_length << ", out_degree: " << out_degree << ", candidate: " << candidate_pool_size; return ss; } } // namespace knowhere core/src/index/knowhere/knowhere/index/vector_index/helpers/IndexParameter.h +9 −0 Original line number Diff line number Diff line Loading @@ -53,6 +53,9 @@ struct IVFCfg : public Cfg { IVFCfg() = default; std::stringstream DumpImpl() override; bool CheckValid() override { return true; Loading @@ -69,6 +72,9 @@ struct IVFSQCfg : public IVFCfg { : IVFCfg(dim, k, gpu_id, nlist, nprobe, type), nbits(nbits) { } std::stringstream DumpImpl() override; IVFSQCfg() = default; bool Loading Loading @@ -119,6 +125,9 @@ struct NSGCfg : public IVFCfg { NSGCfg() = default; std::stringstream DumpImpl() override; bool CheckValid() override { return true; Loading Loading
CHANGELOG.md +2 −0 Original line number Diff line number Diff line Loading @@ -12,6 +12,7 @@ Please mark all change in change log and use the ticket from JIRA. - \#340 - Test cases run failed on 0.6.0 - \#353 - Rename config.h.in to version.h.in - \#374 - sdk_simple return empty result - \#397 - sdk_simple return incorrect result ## Feature - \#12 - Pure CPU version for Milvus Loading @@ -29,6 +30,7 @@ Please mark all change in change log and use the ticket from JIRA. - \#310 - Add Q&A for 'protocol https not supported or disable in libcurl' issue - \#322 - Add option to enable / disable prometheus - \#358 - Add more information in build.sh and install.md - \#255 - Add ivfsq8 test report detailed version ## Task Loading
core/src/index/CMakeLists.txt +3 −3 Original line number Diff line number Diff line Loading @@ -88,14 +88,14 @@ endif () include(ThirdPartyPackagesCore) if (CMAKE_BUILD_TYPE STREQUAL "Release") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -fPIC -DELPP_THREAD_SAFE -fopenmp") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -fPIC -DELPP_THREAD_SAFE -fopenmp -mavx -mf16c -msse4 -mpopcnt") if (KNOWHERE_GPU_VERSION) set(CUDA_NVCC_FLAGS "${CUDA_NVCC_FLAGS} -O3") endif () else () set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g -fPIC -DELPP_THREAD_SAFE -fopenmp") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -g -fPIC -DELPP_THREAD_SAFE -fopenmp -mavx -mf16c -msse4 -mpopcnt") if (KNOWHERE_GPU_VERSION) set(CUDA_NVCC_FLAGS "${CUDA_NVCC_FLAGS} -O0 -g") set(CUDA_NVCC_FLAGS "${CUDA_NVCC_FLAGS} -O3 -g") endif () endif () Loading
core/src/index/knowhere/knowhere/common/Config.h +14 −0 Original line number Diff line number Diff line Loading @@ -18,6 +18,8 @@ #pragma once #include <memory> #include <sstream> #include "Log.h" namespace knowhere { Loading Loading @@ -50,6 +52,18 @@ struct Cfg { CheckValid() { return true; } void Dump() { KNOWHERE_LOG_DEBUG << DumpImpl().str(); } virtual std::stringstream DumpImpl() { std::stringstream ss; ss << "dim: " << d << ", metric: " << int(metric_type) << ", gpuid: " << gpu_id << ", k: " << k; return ss; } }; using Config = std::shared_ptr<Cfg>; Loading
core/src/index/knowhere/knowhere/index/vector_index/helpers/IndexParameter.cpp +22 −0 Original line number Diff line number Diff line Loading @@ -34,4 +34,26 @@ GetMetricType(METRICTYPE& type) { KNOWHERE_THROW_MSG("Metric type is invalid"); } std::stringstream IVFCfg::DumpImpl() { auto ss = Cfg::DumpImpl(); ss << ", nlist: " << nlist << ", nprobe: " << nprobe; return ss; } std::stringstream IVFSQCfg::DumpImpl() { auto ss = IVFCfg::DumpImpl(); ss << ", nbits: " << nbits; return ss; } std::stringstream NSGCfg::DumpImpl() { auto ss = IVFCfg::DumpImpl(); ss << ", knng: " << knng << ", search_length: " << search_length << ", out_degree: " << out_degree << ", candidate: " << candidate_pool_size; return ss; } } // namespace knowhere
core/src/index/knowhere/knowhere/index/vector_index/helpers/IndexParameter.h +9 −0 Original line number Diff line number Diff line Loading @@ -53,6 +53,9 @@ struct IVFCfg : public Cfg { IVFCfg() = default; std::stringstream DumpImpl() override; bool CheckValid() override { return true; Loading @@ -69,6 +72,9 @@ struct IVFSQCfg : public IVFCfg { : IVFCfg(dim, k, gpu_id, nlist, nprobe, type), nbits(nbits) { } std::stringstream DumpImpl() override; IVFSQCfg() = default; bool Loading Loading @@ -119,6 +125,9 @@ struct NSGCfg : public IVFCfg { NSGCfg() = default; std::stringstream DumpImpl() override; bool CheckValid() override { return true; Loading