Skip to content

Commit

Permalink
Updated the BWA_MEM memory requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
muffato committed Nov 29, 2023
1 parent 2f3c372 commit afadced
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions conf/base.config
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,9 @@ process {
// Runtime for 1 billion reads on 12 threads is a function of the logarithm of the genome size
// Runtime is considered proportional to the number of reads and inversely to number of threads
time = { check_max( 3.h * task.attempt * Math.ceil(positive_log(meta2.genome_size/100000, 10)) * Math.ceil(meta.read_count/1000000000) * 12 / log_increase_cpus(6, 6*task.attempt, meta.read_count/1000000000, 2), 'time' ) }
// Memory usage for 1 BWAMEM2 thread is 500 MB for every 1 Gbp.
// Memory usage of BWAMEM2 is about proportional to the number of threads but need to add about 6 GB to avoid MEMLIMIT.
// Base RAM usage is about 6 times the genome size. Each thread takes an additional 800 MB RAM
// Memory usage of SAMTOOLS_VIEW is negligible.
memory = { check_max( 6.GB + 500.MB * Math.ceil(meta2.genome_size / 1000000000) * log_increase_cpus(6, 6*task.attempt, meta.read_count/1000000000, 2), 'memory' ) }
memory = { check_max( 6.GB * Math.ceil(meta2.genome_size / 1000000000) + 800.MB * log_increase_cpus(6, 6*task.attempt, meta.read_count/1000000000, 2), 'memory' ) }
}

withName: MINIMAP2_ALIGN {
Expand Down

0 comments on commit afadced

Please sign in to comment.