broadinstitute / pilon

Pilon is an automated genome assembly improvement and variant detection tool
GNU General Public License v2.0
338 stars 60 forks source link

Hard-coded memory #92

Open CristianRiccio opened 5 years ago

CristianRiccio commented 5 years ago

Hi,

Thanks for this software. I've used it to polish my assemblies. However, I had to manually change the memory limit in the python wrapper: "Wrapper script for Java Conda packages that ensures that the java runtime is invoked with the right options. Adapted from the bash script (http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in/246128#246128)."

This means I could not run it in a conda environment created by snakemake but instead had to create a conda environment, change your script, and then invoke snakemake without specifying a conda environment for the rule.

Would it be possible to put the memory as a parameter instead?

Cheers.

dcopetti commented 4 years ago

Hi @CristianRiccio , I was able to specify the memory requirement by looking for the pilon.jar file (with locate) and calling it directly with java: java -Xmx360G -jar /home/copettid/anaconda3/share/pilon-1.23-2/pilon-1.23.jar --genome file.fa --alignment.bam --output out.fa --diploid --threads 20 --changes

Dario