1
0
mirror of https://github.com/osmarks/meme-search-engine.git synced 2025-06-07 00:44:07 +00:00

CLI switch for L

This commit is contained in:
osmarks 2025-01-14 08:31:03 +00:00
parent 2cebce1b73
commit 5ab91aa17e

View File

@ -32,6 +32,8 @@ struct CLIArguments {
verbose: bool, verbose: bool,
#[argh(option, short='n', description="stop at n queries")] #[argh(option, short='n', description="stop at n queries")]
n: Option<usize>, n: Option<usize>,
#[argh(option, short='L', description="search list size")]
search_list_size: Option<usize>,
#[argh(switch, description="always use full-precision vectors (slow)")] #[argh(switch, description="always use full-precision vectors (slow)")]
disable_pq: bool disable_pq: bool
} }
@ -195,7 +197,7 @@ fn main() -> Result<()> {
let mut scratch = Scratch { let mut scratch = Scratch {
visited: HashSet::new(), visited: HashSet::new(),
neighbour_buffer: NeighbourBuffer::new(1000), neighbour_buffer: NeighbourBuffer::new(args.search_list_size.unwrap_or(1000)),
neighbour_pre_buffer: Vec::new(), neighbour_pre_buffer: Vec::new(),
visited_list: Vec::new() visited_list: Vec::new()
}; };