Hello,
I'm looking to run Copywriter on a few Whole Exome BAMs. The CopywriteR()
call runs to completion when I run it on just one BAM. When I try multiple BAMs though (say 3), the job errors out with PBS: job killed: vmem 87574020096 exceeded limit 68719476736
even when I give it 64G of RAM (the BAMs put together are 18+18+15 = 51G, so even reading them all into memory should not be a problem. Why am I facing this error?
All software runs in limited memory. The solution is to iterate through the file, as illustrated in eg. 'Strategy 4' of
?GenomicAlignments::readGAlignments
or implemented inGenomicFiles::reduceBy*()
functions.Thank you, Oscar. I upped the memory to 128G and things ran to completion. A few other BAMs with lower depth worked fine, so I think your solution makes sense.
Is there any way to up the number of reads Rsamtools can handle? Maybe a recompilation of samtools or Rsamtools?
As Martin Morgan suggested I should implement an iterative strategy to decrease memory usage. I will work on this as soon as possible to implement this in the next version of CopywriteR.