提交 4b8a72f9 编写于 作者: F fishpenguin

NSG build failed using GPU-edition if set gpu_enable false

上级 018abff2
...@@ -33,6 +33,7 @@ Please mark all change in change log and use the ticket from JIRA. ...@@ -33,6 +33,7 @@ Please mark all change in change log and use the ticket from JIRA.
- \#533 - NSG build failed with MetricType Inner Product - \#533 - NSG build failed with MetricType Inner Product
- \#543 - client raise exception in shards when search results is empty - \#543 - client raise exception in shards when search results is empty
- \#545 - Avoid dead circle of build index thread when error occurs - \#545 - Avoid dead circle of build index thread when error occurs
- \#547 - NSG build failed using GPU-edition if set gpu_enable false
- \#552 - Server down during building index_type: IVF_PQ using GPU-edition - \#552 - Server down during building index_type: IVF_PQ using GPU-edition
- \#561 - Milvus server should report exception/error message or terminate on mysql metadata backend error - \#561 - Milvus server should report exception/error message or terminate on mysql metadata backend error
- \#599 - Build index log is incorrect - \#599 - Build index log is incorrect
......
...@@ -117,7 +117,13 @@ NSG::Train(const DatasetPtr& dataset, const Config& config) { ...@@ -117,7 +117,13 @@ NSG::Train(const DatasetPtr& dataset, const Config& config) {
// TODO(linxj): dev IndexFactory, support more IndexType // TODO(linxj): dev IndexFactory, support more IndexType
#ifdef MILVUS_GPU_VERSION #ifdef MILVUS_GPU_VERSION
auto temp_resource = FaissGpuResourceMgr::GetInstance().GetRes(build_cfg->gpu_id);
#if temp_resource == nullptr
auto preprocess_index = std::make_shared<IVF>();
#else
auto preprocess_index = std::make_shared<GPUIVF>(build_cfg->gpu_id); auto preprocess_index = std::make_shared<GPUIVF>(build_cfg->gpu_id);
#endif
#else #else
auto preprocess_index = std::make_shared<IVF>(); auto preprocess_index = std::make_shared<IVF>();
#endif #endif
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册