Translations:GNU Parallel/37/en: Difference between revisions
Jump to navigation
Jump to search
(Importing a new version from external source) |
(Importing a new version from external source) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
For example, when a long list of [[OpenMP]] tasks are executed as a single job submitted with <tt>--nodes=N</tt>, <tt>--ntasks-per-node=5</tt> and <tt>--cpus-per-task=8</tt>, the following command will take into account all processes to be started on all reserved nodes and the number of OpenMP threads per process: | For example, when a long list of [[OpenMP]] tasks are executed as a single job submitted with <tt>--nodes=N</tt>, <tt>--ntasks-per-node=5</tt> and <tt>--cpus-per-task=8</tt>, the following command will take into account all processes to be started on all reserved nodes and the number of OpenMP threads per process: | ||
{{Command | {{Command | ||
|parallel --jobs $SLURM_NTASKS_PER_NODE --sshloginfile ./node_list_${SLURM_JOB_ID} --workdir $PWD OMP_NUM_THREADS{{=}}$SLURM_CPUS_PER_TASK ./my_program | |parallel --jobs $SLURM_NTASKS_PER_NODE --sshloginfile ./node_list_${SLURM_JOB_ID} --workdir $PWD --env OMP_NUM_THREADS{{=}}$SLURM_CPUS_PER_TASK --sshdelay 30 ./my_program | ||
}} | }} | ||
In this case, up to <tt>5*N</tt> OpenMP processes are running simultaneously with a CPU usage of up to 800% each. | In this case, up to <tt>5*N</tt> OpenMP processes are running simultaneously with a CPU usage of up to 800% each. |
Latest revision as of 15:27, 20 May 2022
For example, when a long list of OpenMP tasks are executed as a single job submitted with --nodes=N, --ntasks-per-node=5 and --cpus-per-task=8, the following command will take into account all processes to be started on all reserved nodes and the number of OpenMP threads per process:
[name@server ~]$ parallel --jobs $SLURM_NTASKS_PER_NODE --sshloginfile ./node_list_${SLURM_JOB_ID} --workdir $PWD --env OMP_NUM_THREADS=$SLURM_CPUS_PER_TASK --sshdelay 30 ./my_program
In this case, up to 5*N OpenMP processes are running simultaneously with a CPU usage of up to 800% each.