Closed Xentrics closed 1 year ago
Thanks for the useful suggestion!
Apologies! I just realized a problem with that approach. To my big surprise, the jobs parameter is completely ignored when the cores parameter is specified at the same time (instead, there are as many jobs as cores) ...
I just read in the documentation for jobs that 'For local execution this is an alias for –cores.' So we cannot have both options in local mode, because cores overwrites jobs and vice versa.
So it should only be
echo "snakemake all -j $njobs -k"|bash; break;;
Ahh thanks for the clarification, I am now remembering the issues with implementing local job submission 🥲 To be honest I never really use local mode since I run my analyses on the cluster, but it does seem like there is interest in the userbase for this type of execution.
Currently, the submitLocal() function in metaGEM.sh executes Snakemake with -j 1, effectively ignoring parallelization. I suggest to change this line (358 in version 1.0.2) from
echo "snakemake all -j 1 -k"|bash; break;;
to
echo "snakemake all -j $njobs -c $ncores -k"|bash; break;;
To make full use of Snakemake.