Common mistakes to avoid
Execution environment
Do not use
module purge. It removes too much and will break Slurm and other cluster functionality. Usemodule resetto remove all loaded modules and rebase to the default set for the current context.Avoid using a
/projectsdirectory as your working directory./projectsis for bulk storage of shared data./scratchandTMPDIRare for staging and running jobs. The separation helps prevent accidental deletion, data corruption, and provides better performance.
Misaligned resource selection
Do not request
--mem=2GBon Tinkercliffsnormal_qor--mem=8GBon Owlnormal_q. Some node memory is reserved for the OS and Slurm, so the proportionate share of memory available per core is slightly less than these amounts. Without setting any value for--mem, you will already get the correct proportionate share of memory (e.g., 1944MB on TC).
Scaling
Profile the workload with a representative example as a benchmark before scaling.
Right-size the resource request (cpus, memory, gpus, nodes).
Maximize the utilization and parallelism inside a single job before scaling to job arrays.