Skip to content

Commit

Permalink
Fix reconstruct tests
Browse files Browse the repository at this point in the history
Cherry-picked-from: commit 1e87978
Fixes: microsoft#315
  • Loading branch information
PhilipBAdams authored and pabs3 committed Apr 1, 2023
1 parent 703eefb commit 3207093
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Test/src/ReconstructIndexSimilarityTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ void GenerateReconstructData(std::shared_ptr<VectorSet>& real_vecset, std::share
if (ptr == nullptr || !ptr->Initialize(CODEBOOK_FILE.c_str(), std::ios::binary | std::ios::in)) {
BOOST_ASSERT("Canot Open CODEBOOK_FILE to read!" == "Error");
}
quantizer->LoadIQuantizer(ptr);
quantizer = COMMON::IQuantizer::LoadIQuantizer(ptr);
BOOST_ASSERT(quantizer);

std::shared_ptr<Helper::ReaderOptions> options(new Helper::ReaderOptions(GetEnumValueType<R>(), m, VectorFileType::DEFAULT));
Expand Down Expand Up @@ -247,7 +247,7 @@ void GenerateReconstructData(std::shared_ptr<VectorSet>& real_vecset, std::share
if (!ptr->Initialize(CODEBOOK_FILE.c_str(), std::ios::binary | std::ios::in)) {
BOOST_ASSERT("Canot Open CODEBOOK_FILE to read!" == "Error");
}
quantizer->LoadIQuantizer(ptr);
quantizer = COMMON::IQuantizer::LoadIQuantizer(ptr);
BOOST_ASSERT(quantizer);

rec_vecset.reset(new BasicVectorSet(ByteArray::Alloc(sizeof(R) * n * m), GetEnumValueType<R>(), m, n));
Expand Down

0 comments on commit 3207093

Please sign in to comment.