From a1c3cdd8be3edd24df08358bc5f73b07cbc21c53 Mon Sep 17 00:00:00 2001 From: tibvdm Date: Wed, 28 Aug 2024 10:54:43 +0200 Subject: [PATCH] division by 0 fix --- sa-index/src/sa_searcher.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sa-index/src/sa_searcher.rs b/sa-index/src/sa_searcher.rs index 7aafa86..aa7e52b 100644 --- a/sa-index/src/sa_searcher.rs +++ b/sa-index/src/sa_searcher.rs @@ -152,7 +152,7 @@ impl Searcher { // Create the Searcher object let mut searcher = Self { sa, kmer_cache, proteins, suffix_index_to_protein }; - let print_step_size = min(searcher.kmer_cache.base.pow(k as u32) / 100, searcher.kmer_cache.base); + let print_step_size = max(searcher.kmer_cache.base.pow(k as u32) / 100, searcher.kmer_cache.base); eprintln!("Starting cache fill"); let start_cache_fill_time = get_time_ms().unwrap();