Skip to content

Commit 8f10c26

Browse files
[8.0] initialize dataSize ion abstractInitParams in tiered factory NewIndex from hnsw file (#582)
initialize dataSize ion abstractInitParams in tiered factory NewIndex from hnsw file (#578) (cherry picked from commit 63badf2) Co-authored-by: meiravgri <[email protected]>
1 parent 36c62d4 commit 8f10c26

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/VecSim/index_factories/tiered_factory.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,12 @@ VecSimIndex *NewIndex(const TieredIndexParams *params, HNSWIndex<DataType, DistT
3535
.blockSize = hnsw_index->getBlockSize()};
3636

3737
std::shared_ptr<VecSimAllocator> flat_allocator = VecSimAllocator::newVecsimAllocator();
38+
size_t dataSize = VecSimParams_GetDataSize(bf_params.type, bf_params.dim, bf_params.metric);
39+
3840
AbstractIndexInitParams abstractInitParams = {.allocator = flat_allocator,
3941
.dim = bf_params.dim,
4042
.vecType = bf_params.type,
43+
.dataSize = dataSize,
4144
.metric = bf_params.metric,
4245
.blockSize = bf_params.blockSize,
4346
.multi = bf_params.multi,

0 commit comments

Comments
 (0)