Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update example in docs/polaris /running-jobs.md to use 1 rank / GPU #218

Open
saforem2 opened this issue May 2, 2023 · 1 comment
Open

Comments

@saforem2
Copy link
Member

saforem2 commented May 2, 2023

Update the

Running Multiple MPI Applications on a node
from docs/polaris/running-jobs.md#L47

example to instead use 1 MPI rank / GPU. e.g.

#!/bin/bash --login
setupPolaris()  {
  if [[ $(hostname) == x* ]]; then
    # -- MPI / Comms Setup -----------------
    NHOSTS=$(wc -l < "${PBS_NODEFILE}")
    NGPU_PER_HOST=$(nvidia-smi -L | wc -l)
    NGPUS=$((${NHOSTS}*${NGPU_PER_HOST}))
    MPI_COMMAND=$(which mpiexec)
    MPI_DEFAULTS="\
      --envall \
      --verbose \
      --hostfile ${HOSTFILE}"
    MPI_ELASTIC="\
      -n ${NGPUS} \
      --ppn ${NGPU_PER_HOST}"
    MPI_EXEC="\
      ${MPI_COMMAND} \
      ${MPI_DEFAULTS} \
      ${MPI_ELASTIC}"
  else
    echo "Unexpected hostname: $(hostname)"
  fi
}

setupPolaris
"${MPI_EXEC}" $@
@felker
Copy link
Member

felker commented Sep 23, 2024

Is this still an issue @saforem2 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants