RasmussenLab / phamb

Downstream processing of VAMB binning for Viral Elucidation
MIT License
44 stars 8 forks source link

How can I control the total number of threads used by phamb? #31

Closed ilnamkang closed 2 years ago

ilnamkang commented 2 years ago

Hi,

Thank you for a great tool!

How can I control the total number of threads used by phamb?

I'm trying running phamb on my local Ubuntu server with a total of 80 cores, and I'd like to make phamb use not more than 60 cores.

When I set "threads_ppn" value to 3 in config.yaml, and set "-j" value to 20 in snakemake command, it seems that nearly all 80 cores are used during DeepVirFinder step.

Are there any ways to limit the total number of threads used by phamb?

Thanks.

joacjo commented 2 years ago

Hi ilnamkang

Thanks for your interest in the tool.

I hardcoded the number of threads in the Snakemake workflow to only use 1 core for a DeepVirFinder run (Everyone can of course modify the Snakemake flow as they want to get around this). So when you run execute the Snakemake workflow and only allow 20 parallel executions (-j 20), I do not understand how it's possible for the workflow to take up all cores.

Since it's several days ago you posted the Issue, I wonder if you solved this yet yourself?

Best, Joachim