mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-01 11:29:48 +08:00
enhance: [cherry-pick]disk index support binary_vector (#33575)
issue:https://github.com/milvus-io/milvus/issues/22837 related https://github.com/milvus-io/milvus/pull/33631 Signed-off-by: cqy123456 <qianya.cheng@zilliz.com>
This commit is contained in:
parent
f94a72252c
commit
443197bdfc
@ -197,6 +197,10 @@ IndexFactory::CreateVectorIndex(
|
||||
return std::make_unique<VectorDiskAnnIndex<bfloat16>>(
|
||||
index_type, metric_type, version, file_manager_context);
|
||||
}
|
||||
case DataType::VECTOR_BINARY: {
|
||||
return std::make_unique<VectorDiskAnnIndex<bin1>>(
|
||||
index_type, metric_type, version, file_manager_context);
|
||||
}
|
||||
default:
|
||||
throw SegcoreError(
|
||||
DataTypeInvalid,
|
||||
@ -311,6 +315,14 @@ IndexFactory::CreateVectorIndex(
|
||||
space,
|
||||
file_manager_context);
|
||||
}
|
||||
case DataType::VECTOR_BINARY: {
|
||||
return std::make_unique<VectorDiskAnnIndex<bin1>>(
|
||||
index_type,
|
||||
metric_type,
|
||||
version,
|
||||
space,
|
||||
file_manager_context);
|
||||
}
|
||||
default:
|
||||
throw SegcoreError(
|
||||
DataTypeInvalid,
|
||||
|
@ -513,5 +513,6 @@ VectorDiskAnnIndex<T>::update_load_json(const Config& config) {
|
||||
template class VectorDiskAnnIndex<float>;
|
||||
template class VectorDiskAnnIndex<float16>;
|
||||
template class VectorDiskAnnIndex<bfloat16>;
|
||||
template class VectorDiskAnnIndex<bin1>;
|
||||
|
||||
} // namespace milvus::index
|
||||
|
@ -837,6 +837,9 @@ template std::string
|
||||
DiskFileManagerImpl::CacheRawDataToDisk<bfloat16>(
|
||||
std::vector<std::string> remote_files);
|
||||
template std::string
|
||||
DiskFileManagerImpl::CacheRawDataToDisk<bin1>(
|
||||
std::vector<std::string> remote_files);
|
||||
template std::string
|
||||
DiskFileManagerImpl::CacheRawDataToDisk<float>(
|
||||
std::shared_ptr<milvus_storage::Space> space);
|
||||
template std::string
|
||||
@ -845,5 +848,8 @@ DiskFileManagerImpl::CacheRawDataToDisk<float16>(
|
||||
template std::string
|
||||
DiskFileManagerImpl::CacheRawDataToDisk<bfloat16>(
|
||||
std::shared_ptr<milvus_storage::Space> space);
|
||||
template std::string
|
||||
DiskFileManagerImpl::CacheRawDataToDisk<bin1>(
|
||||
std::shared_ptr<milvus_storage::Space> space);
|
||||
|
||||
} // namespace milvus::storage
|
||||
|
Loading…
Reference in New Issue
Block a user