diff --git a/python/raft-ann-bench/src/raft-ann-bench/run/__main__.py b/python/raft-ann-bench/src/raft-ann-bench/run/__main__.py index 9476220d0d..2ab26ee0aa 100644 --- a/python/raft-ann-bench/src/raft-ann-bench/run/__main__.py +++ b/python/raft-ann-bench/src/raft-ann-bench/run/__main__.py @@ -116,9 +116,6 @@ def run_build_and_search( ] if force: cmd = cmd + ["--overwrite"] - - if search_threads: - cmd = cmd + ["--threads=%s" % search_threads] cmd = cmd + [temp_conf_filepath] subprocess.run(cmd, check=True) @@ -140,6 +137,10 @@ def run_build_and_search( ] if force: cmd = cmd + ["--overwrite"] + + if search_threads: + cmd = cmd + ["--threads=%s" % search_threads] + cmd = cmd + [temp_conf_filepath] subprocess.run(cmd, check=True)