Skip to content

Commit

Permalink
Merge branch 'NOAA-EMC:develop' into feature/monitor_jobs_separate
Browse files Browse the repository at this point in the history
  • Loading branch information
KateFriedman-NOAA authored Oct 26, 2023
2 parents b9cbc13 + 8556541 commit 446494f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Status
======

* State of develop (HEAD) branch: GFSv17+ development
* State of operations (dev/gfs.v16 branch): GFS v16.3.9 `tag: [gfs.v16.3.9] <https://github.com/NOAA-EMC/global-workflow/releases/tag/gfs.v16.3.9>`_
* State of operations (dev/gfs.v16 branch): GFS v16.3.10 `tag: [gfs.v16.3.10] <https://github.com/NOAA-EMC/global-workflow/releases/tag/gfs.v16.3.10>`_

=============
Code managers
Expand Down
7 changes: 5 additions & 2 deletions ush/run_mpmd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ source "${HOMEgfs}/ush/preamble.sh"

cmdfile=${1:?"run_mpmd requires an input file containing commands to execute in MPMD mode"}

# Determine the number of MPMD processes from incoming ${cmdfile}
nprocs=$(wc -l < "${cmdfile}")

# Local MPMD file containing instructions to run in CFP
mpmd_cmdfile="${DATA:-}/mpmd_cmdfile"
if [[ -s "${mpmd_cmdfile}" ]]; then rm -f "${mpmd_cmdfile}"; fi
Expand All @@ -19,7 +22,6 @@ if [[ "${launcher:-}" =~ ^srun.* ]]; then # srun-based system e.g. Hera, Orion
((nm=nm+1))
done < "${cmdfile}"

nprocs=$(wc -l < "${mpmd_cmdfile}")
set +e
# shellcheck disable=SC2086
${launcher:-} ${mpmd_opt:-} -n ${nprocs} "${mpmd_cmdfile}"
Expand All @@ -42,7 +44,8 @@ elif [[ "${launcher:-}" =~ ^mpiexec.* ]]; then # mpiexec
done < "${cmdfile}"

chmod 755 "${mpmd_cmdfile}"
${launcher:-} "${mpmd_cmdfile}"
# shellcheck disable=SC2086
${launcher:-} -np ${nprocs} ${mpmd_opt:-} "${mpmd_cmdfile}"
rc=$?
if (( rc == 0 )); then
out_files=$(find . -name 'mpmd.*.out')
Expand Down

0 comments on commit 446494f

Please sign in to comment.