Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Single-threaded process requires 1 thread on any node: --ntasks=1 --cpus=per-task=1
  2. Multi-threaded process requires 16 threads on any node: --ntasks=1 --cpus-per-task=16
  3. Multi-threaded process requires 16 threads on a node with exclusivity (use only if undoubtedly needed): --ntasks=1 --cpus-per-task=16 --exclusive
  4. 16 concurrent but isolated tasks, each task with 1 thread (no multithreading): --ntasks=16 --nodes=1
  5. 16 concurrent but isolated tasks, each task with 2 threads (multithreading only within each single task): --ntasks=16 --nodes=1 --cpus-per-task=2


The scenarios indicate the following options have the following implications

  • cpus-per-task: Amount of threads for each task. Supports multithreading and intratask communication.
  • ntasks: Amount of isolated threads. Can not communicate with any other task, including tasks in the same job submission.
  • nodes: Amount of nodes in which to split tasks between. Should only be > 1 if utilizing MPI.


Warning

Unless using MPI or , slurm "job steps", or isolated concurrently running tasks: ntasks should remain = 1 and --nodes should either not be used or be = 1. The "--cpus-per-task" option should be used for thread allocations. For resource allocations with MPI, see: MPI with Slurm.

...