-
Notifications
You must be signed in to change notification settings - Fork 199
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
Great Lakes Cluster (UMich) #4869
Conversation
3a14f3c
to
bd7d7f7
Compare
Oh great, I can help with this as I have a working install on this cluster. |
Here's my profile file, which we can use as a start # please set your project account
export proj=#####
# remembers the location of this script
export MY_PROFILE=$(cd $(dirname $BASH_SOURCE) && pwd)"/"$(basename $BASH_SOURCE)
if [ -z ${proj-} ]; then echo "WARNING: The 'proj' variable is not yet set in your $MY_PROFILE file! Please edit its line 2 to continue!"; return; fi
# required dependencies
module load cmake
module load gcc
module load openmpi
module load phdf5
module load git
module load cuda
module load python/3.10.4
# compiler environment hints
export CC="$(which gcc)"
export CXX="$(which g++)"
export CUDACXX="$(which nvcc)"
export CUDAHOSTCXX="$(which g++)"
export FC="$(which gfortran)"
export SRC_DIR=${HOME}/src and here's my install script # Load required modules
source ~/warpx.profile
module load python/3.10.4
# uninstall old versions
rm -rf build
rm -r *.whl
# Build warpx
cmake -S . -B build \
-DWarpX_LIB=ON \
-DWarpX_APP=ON \
-DWarpX_MPI=ON \
-DWarpX_COMPUTE=CUDA \
-DWarpX_DIMS="1;2;RZ;3" \
-DWarpX_PYTHON=ON \
-DWarpX_PRECISION=DOUBLE \
-DWarpX_PARTICLE_PRECISION=SINGLE \
-DGPUS_PER_SOCKET=4 \
-DGPUS_PER_NODE=8
cmake --build build -j 8
cmake --build build --target pip_install -j 8 |
Thank you @archermarx, that is great! I am working to get this documented mainline with Brendan Stassel ✨ Awesome, there is a parallel HDF5 module |
bd7d7f7
to
5498e2b
Compare
Tools/machines/greatlakes-umich/greatlakes_v100_warpx.profile.example
Outdated
Show resolved
Hide resolved
Draft of the docs for testing :) |
Oh nice! I know Brendan |
Hey @archermarx! Thanks for sharing your profile and install script |
@ax3l following the doc you linked, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
c-blosc currently fails due to looking for c-blosc2
dir, then only using c-blosc
dir. Either work, but it needs to be consistent.
Oh yes, because this PR is not yet merged. You could do this in cd ~/src/warpx
git remote add ax3l https://github.com/ax3l/WarpX.git
git fetch --all
git checkout -b doc-greatlakes-umich ax3l/doc-greatlakes-umich |
I can add the remote git, but when I go to checkout the file it fails.
|
Sorry, I forgot to write also: git fetch --all and posted the wrong git URL. Editing now above msg. |
40b071b
to
b80a6e0
Compare
.. code-block:: bash | ||
|
||
bash $HOME/src/warpx/Tools/machines/greatlakes-umich/install_v100_dependencies.sh | ||
source ${HOME}/sw/greatlakes/v100/venvs/warpx-v100/bin/activate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Above the guide informs the user to always source $HOME/greatlakes_v100_warpx.profile
.
Is activate copied to the greatlakes_v100_warpx.profile or are we loading a different source here? If so, why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This extra line is only needed once, as we set up the dependencies, to continue in the same terminal.
The reason for that extra line in this step is that we already sourced the profile but only the line now adds the venv - so it was not yet activated.
Status: We are still working on the job script, to ensure the GPU visibility is correct set (one unique GPU per one MPI rank pinned on the closest CPU). @bstassel opened a ticket to support for this. @archermarx what job script template are you using for the V100 GPUs? Did you solve this already? |
@ax3l This job script appeared to work for me for running a 2-GPU job after some discussion with ARC-TS #!/bin/bash
#SBATCH --job-name=#####
#SBATCH --account=#####
#SBATCH --partition=gpu
#SBATCH --nodes=1
#SBATCH --ntasks=2
#SBATCH --cpus-per-gpu=1
#SBATCH --gpus-per-task=v100:1
#SBATCH --gpu-bind=single:1
#SBATCH --mem=32000m
#SBATCH --time=00:05:00
#SBATCH --output=output.log
#SBATCH --mail-type=END,FAIL
# Load required modules
module load gcc hdf5 openmpi/4.1.6-cuda cmake git cuda python/3.10.4
srun python PICMI_inputs_2d.py |
Oh,
could be what I missed. |
I will give this a try and report the result. EDIT: this resolved the error thrown by WarpX about MPI mapping |
For future reference, the complete documentation for SLURM is here: https://slurm.schedmd.com/srun.html#OPT_gres-flags There is an interesting combination between |
I want to make sure I comprehend the SBATCH commands used in greatlakes_v100.sbatch.
Do I have that right? |
I was comparing the output.txt file between the job that had No gpu-bind
`--gpu-bind=single:1'
|
Do you have Amex GPU aware mpi enabled?
…On Wed, Apr 24, 2024, 9:42 PM Brendan ***@***.***> wrote:
I was comparing the output.txt file between the job that had
--gpu-bind=single:1 and the one that didn't. It appears forcing 1 GPU to
1 MPI rank gives worse performance? Maybe this is only because the
simulation is so short, I don't see the benefits.
*No gpu-bind*
STEP 100 starts ...
--- INFO : re-sorting particles
--- INFO : Writing openPMD file diags/diag1000100
--- INFO : Writing openPMD file diags/openPMDfw000100
--- INFO : Writing openPMD file diags/openPMDbw000100
STEP 100 ends. TIME = 1.083064693e-14 DT = 1.083064693e-16
Evolve time = 2.07016534 s; This step = 0.346136823 s; Avg. per step = 0.0207016534 s
**** WARNINGS ******************************************************************
* GLOBAL warning list after [ THE END ]
*
* No recorded warnings.
********************************************************************************
Total Time : 4.078974041
TinyProfiler total time across processes [min...avg...max]: 4.08 ... 4.088 ... 4.096
`--gpu-bind=single:1'
STEP 100 starts ...
--- INFO : re-sorting particles
--- INFO : Writing openPMD file diags/diag1000100
--- INFO : Writing openPMD file diags/openPMDfw000100
--- INFO : Writing openPMD file diags/openPMDbw000100
STEP 100 ends. TIME = 1.083064693e-14 DT = 1.083064693e-16
Evolve time = 8.21666101 s; This step = 1.493229092 s; Avg. per step = 0.0821666101 s
**** WARNINGS ******************************************************************
* GLOBAL warning list after [ THE END ]
*
* No recorded warnings.
********************************************************************************
Total Time : 16.89200922
TinyProfiler total time across processes [min...avg...max]: 16.89 ... 16.9 ... 16.91
—
Reply to this email directly, view it on GitHub
<#4869 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AOP3QGT2YJ676ZXVQPEHNR3Y7BNPPAVCNFSM6AAAAABGMDSSQ6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANZWGE3TGOJTGI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Awesome progress! Starting to answer individual Qs from above.
The last part, not exactly. We can do inter-GPU communication with MPI direct.
All correct. This in particular just says: we want to MPI processes per 1 node. The reason for that is that we have 2 GPUs per node and want a 1:1 mapping. (We would do the same if it was only one Intel Xeon Gold per node, because they are multi-core CPUs anyway.)
That is totally ok. Solution: use less GPUs or solve a bigger problem :) General guidance for 16 GB V100 GPUs: try to have about 128^3 to 256^3 cells per GPU, as fits with your number of particles per cell. Looks like the GPU bindings work! 🎉 |
Yeah, I think so.
|
Document how to use the Great Lakes Cluster at the University of Michigan.
New module added on the system.
Ensure one MPI rank sees exactly one, unique GPU.
3997ba7
to
3b0fbd6
Compare
I'll give this a try tomorrow!
…On Wed, Apr 24, 2024, 11:27 PM Axel Huebl ***@***.***> wrote:
@ax3l <https://github.com/ax3l> requested your review on: #4869
<#4869> Great Lakes Cluster
(UMich).
—
Reply to this email directly, view it on GitHub
<#4869 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AOP3QGVWZB6USO6BQITXBD3Y7BZZXAVCNFSM6AAAAABGMDSSQ6VHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJSGYYDAOBTGM4DGMA>
.
You are receiving this because your review was requested.Message ID:
***@***.***>
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me!
@archermarx thanks a lot!! I will preliminarily merge this to Please report back here if this worked - otherwise we can do a follow-up PR. |
#SBATCH --cpus-per-task=20 | ||
#SBATCH --gpus-per-task=v100:1 | ||
#SBATCH --gpu-bind=single:1 | ||
#SBATCH -o WarpX.o%j |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Recommend expliciting putting
#SBATCH --mem=0
to signify this request is allocating all the memory on the node. This should happen dynamically, since --exclusive
is set but i think for users it is a good idea to put so they have some reference to what is implicitly happening with the job request
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait, --mem=0
means all? o.0
I think --exclusive
is a bit clearer for now / avoids duplication, unless it does not work to reserve all host memory.
* Great Lakes Cluster (UMich) Document how to use the Great Lakes Cluster at the University of Michigan. * Fix c-blosc2 typos * Parallel HDF5 for CUDA-aware MPI New module added on the system. * Fix GPU Visibility Ensure one MPI rank sees exactly one, unique GPU. * Add `#SBATCH --gpu-bind=single:1` * Add clean-up message.
Start documenting how to use the Great Lakes Cluster at University of Michigan.
User guide: https://arc.umich.edu/greatlakes/user-guide
Action Items