Skip to content

Commit c6e0dfc

Browse files
author
Qi Chen
committed
add more append threads
1 parent d29ce73 commit c6e0dfc

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

Test/inc/Test.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33

44
#pragma once
55

6+
#define BOOST_TEST_LOG_LEVEL test_suite
67
#include <iostream>
78
#include <boost/test/unit_test.hpp>

Test/src/SPFreshTest.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ std::shared_ptr<VectorIndex> BuildLargeIndex(const std::string &outDirectory, st
177177
Update=true
178178
SteadyState=true
179179
InsertThreadNum=1
180-
AppendThreadNum=1
180+
AppendThreadNum=4
181181
ReassignThreadNum=0
182182
DisableReassign=false
183183
ReassignK=64
@@ -333,8 +333,8 @@ void InsertVectors(SPANN::Index<ValueType> *p_index, int insertThreads, int step
333333
std::uint64_t *offsets = new std::uint64_t[2]{0, p_meta.Length()};
334334
std::shared_ptr<MetadataSet> meta(new MemMetadataSet(
335335
p_meta, ByteArray((std::uint8_t *)offsets, 2 * sizeof(std::uint64_t), true), 1));
336-
auto status = p_index->AddIndex(addset->GetVector((SizeType)index), 1, p_opts.m_dim, meta, true);
337-
BOOST_REQUIRE(status == ErrorCode::Success);
336+
BOOST_REQUIRE(p_index->AddIndex(addset->GetVector((SizeType)index), 1, p_opts.m_dim, meta, true) ==
337+
ErrorCode::Success);
338338
}
339339
else
340340
{

Test/src/TestDataGenerator.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ void TestDataGenerator<T>::GenerateBatchTruth(const std::string &filename, std::
145145
int maxthreads = std::thread::hardware_concurrency();
146146
for (int iter = 0; iter < batches + 1; iter++)
147147
{
148+
SPTAGLIB_LOG(Helper::LogLevel::LL_Info, "Generating groundtruth for batch %d\n", iter);
148149
std::vector<std::thread> mythreads;
149150
mythreads.reserve(maxthreads);
150151
std::atomic_size_t sent(0);

0 commit comments

Comments
 (0)