From 84bb14fad4fa194816316e524808a2dd735fba12 Mon Sep 17 00:00:00 2001 From: yangxuan Date: Tue, 12 Nov 2024 10:17:13 +0800 Subject: [PATCH] fix small bugs Signed-off-by: yangxuan --- vectordb_bench/backend/runner/read_write_runner.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/vectordb_bench/backend/runner/read_write_runner.py b/vectordb_bench/backend/runner/read_write_runner.py index 7ff47e48..bc32d56c 100644 --- a/vectordb_bench/backend/runner/read_write_runner.py +++ b/vectordb_bench/backend/runner/read_write_runner.py @@ -92,18 +92,18 @@ def run_search_by_sig(self, q): if batch >= target_batch: perc = int(stage * 100) log.info(f"Insert {perc}% done, total batch={total_batch}") - log.info(f"[{batch:6}/{total_batch:6}|] Serial search - {perc}% start") + log.info(f"[{batch:5}|{total_batch:5}|] Serial search - {perc}% start") recall, ndcg, p99 =self.serial_search_runner.run() - if idx < len(self.search_stage) - 1: + if idx < len(self.search_stage): stage_search_dur = (self.data_volume * (self.search_stage[idx + 1] - stage) // self.insert_rate) // len(self.concurrencies) if stage_search_dur < 30: log.warning(f"Search duration too short, please reduce concurrency count or insert rate, or increase dataset volume: dur={stage_search_dur}, concurrencies={len(self.concurrencies)}, insert_rate={self.insert_rate}") - log.info(f"[{batch:6}/{total_batch:6}|]Conc search - {perc}% start, dur for each conc={stage_search_dur}s") + log.info(f"[{batch:5}|{total_batch:5}|]Conc search - {perc}% start, dur for each conc={stage_search_dur}s") else: last_search_dur = self.data_volume * (1.0 - stage) // self.insert_rate stage_search_dur = last_search_dur + self.read_dur_after_write - log.info(f"[{batch:6}/{total_batch:6}|]Last conc search - {perc}% start, [read_until_write|read_after_write|total] =[{last_search_dur}s|{self.read_dur_after_write}]s|{stage_search_dur}s") + log.info(f"[{batch:5}/{total_batch:5}|]Last conc search - {perc}% start, [read_until_write|read_after_write|total] =[{last_search_dur}s|{self.read_dur_after_write}]s|{stage_search_dur}s") max_qps = self.run_by_dur(stage_search_dur) res.append((perc, max_qps, recall))