@@ -25,7 +25,6 @@ struct DynamicConfig {
2525 uint8_t k_ext = 60 ;
2626 float eps_ext = 0 .1f ;
2727 deglib::builder::OptimizationTarget lid = deglib::builder::OptimizationTarget::StreamingData;
28- uint32_t build_threads = std::thread::hardware_concurrency() / 2 ;
2928 uint32_t anns_k = 100 ;
3029 uint32_t anns_repeat = 1 ;
3130 uint32_t anns_threads = 1 ;
@@ -91,7 +90,6 @@ void print_help(const char* program_name) {
9190 log (" Options:\n " );
9291 log (" --force-rebuild Force rebuilding the graphs even if graph files already exist\n " );
9392 log (" --instruction <inst> Select distance instruction set (auto, avx512, avx2, scalar)\n " );
94- log (" --threads <count> Number of threads used for building the graph (default: hardware_concurrency / 2)\n " );
9593 log (" --help, -h Display this detailed help message\n\n " );
9694 log (" Data Path:\n " );
9795 log (" Data is loaded from / saved to DATA_PATH defined at build time (e.g. \" {}\" )\n " , DATA_PATH );
@@ -106,10 +104,9 @@ static deglib::cpu::InstructionSet parse_instruction_set(const std::string& str)
106104 return deglib::cpu::InstructionSet::Auto;
107105}
108106
109- void run_dynamic_benchmark (const DatasetName& ds_name, const std::filesystem::path& data_path, bool force_rebuild, deglib::cpu::InstructionSet instruction, uint32_t build_threads ) {
107+ void run_dynamic_benchmark (const DatasetName& ds_name, const std::filesystem::path& data_path, bool force_rebuild, deglib::cpu::InstructionSet instruction) {
110108 Dataset ds (ds_name, data_path);
111109 auto config = get_dataset_config (ds_name);
112- config.build_threads = build_threads;
113110
114111 log (" \n === Benchmarking Dynamic Data Streams for Dataset: {} ===\n " , ds.name ());
115112
@@ -149,7 +146,7 @@ void run_dynamic_benchmark(const DatasetName& ds_name, const std::filesystem::pa
149146 config.k_ext ,
150147 config.eps_ext ,
151148 0 , 0 , 0 ,
152- config. build_threads ,
149+ 1 ,
153150 true ,
154151 ds.info ().scale ,
155152 false ,
@@ -190,10 +187,9 @@ void run_dynamic_benchmark(const DatasetName& ds_name, const std::filesystem::pa
190187
191188int main (int argc, char * argv[]) {
192189 const auto data_path = std::filesystem::path (DATA_PATH );
193- DatasetName ds_name = DatasetName::SIFT1M ;
190+ DatasetName ds_name = DatasetName::AUDIO ;
194191 bool force_rebuild = false ;
195- deglib::cpu::InstructionSet instruction = deglib::cpu::InstructionSet::Auto;
196- uint32_t build_threads = std::thread::hardware_concurrency () / 2 ;
192+ deglib::cpu::InstructionSet instruction = deglib::cpu::InstructionSet::AVX2 ;
197193
198194 for (int i = 1 ; i < argc; ++i) {
199195 std::string arg = argv[i];
@@ -204,8 +200,6 @@ int main(int argc, char* argv[]) {
204200 force_rebuild = true ;
205201 } else if (arg == " --instruction" && i + 1 < argc) {
206202 instruction = parse_instruction_set (argv[++i]);
207- } else if (arg == " --threads" && i + 1 < argc) {
208- build_threads = (uint32_t )std::stoul (argv[++i]);
209203 } else {
210204 auto parsed = DatasetName::from_string (arg);
211205 if (parsed.is_valid ()) {
@@ -228,7 +222,7 @@ int main(int argc, char* argv[]) {
228222 }
229223
230224 for (const auto & current_ds : datasets_to_run) {
231- run_dynamic_benchmark (current_ds, data_path, force_rebuild, instruction, build_threads );
225+ run_dynamic_benchmark (current_ds, data_path, force_rebuild, instruction);
232226 }
233227
234228 log (" \n Dynamic Benchmark Finished Successfully.\n " );
0 commit comments