Versionen im Vergleich

Schlüssel

  • Diese Zeile wurde hinzugefügt.
  • Diese Zeile wurde entfernt.
  • Formatierung wurde geändert.
Kommentar: zurückgeholt von v. 3

...

If no specific requests regarding the number of tasks has been done, mpirun defaults to hyperthreading and starts cores*2 processes. If a number of tasks has been specified (with -N and/or either with -n or --tasks-per-node), an (Open)  mpirun  honors this via the flag -map-by. For example:

Codeblock
languagebash
titleHyperthreading active, 80/192 Processes per Node will be started
collapsetrue
#!/bin/bash
#SBATCH -N 4

module load gcc/9.32.0 openmpi/gcc.9/43.1.4

cpus_per_node=${SLURM_JOB_CPUS_PER_NODE%\(*}

mpirun -map-by ppr:$cpus_per_node:node5
mpirun ./yourexe


Codeblock
languagebash
titleHyperthreading disabled, 96 processes per node are started.
collapsetrue
#!/bin/bash
#SBATCH -N 4
#SBATCH --tasks-per-node 96

module load gcc/9.32.0 openmpi/gcc.9/43.1.4

tasks_per_node=${SLURM_TASKS_PER_NODE%\(*}

mpirun -map-by ppr:$tasks_per_node:node5
mpirun ./yourexe