From 7bd12ae77e896c098678d0fffc9d054596c34978 Mon Sep 17 00:00:00 2001 From: jlnav Date: Wed, 27 Sep 2023 14:42:09 -0500 Subject: [PATCH 1/3] small adjustments to libE docs --- docs/polaris/workflows/libensemble.md | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/docs/polaris/workflows/libensemble.md b/docs/polaris/workflows/libensemble.md index c0624963c..c693fc674 100644 --- a/docs/polaris/workflows/libensemble.md +++ b/docs/polaris/workflows/libensemble.md @@ -22,7 +22,7 @@ See the docs for more details on using [python on Polaris](https://docs.alcf.anl . /path/to-venv/bin/activate ``` - Where /path/to-venv can be anywhere you have write access. + Where ``/path/to-venv`` can be anywhere you have write access. For future uses just load the conda module and run the activate line. You can also ensure you are using the latest version of libEnsemble: @@ -35,23 +35,18 @@ See the docs for more details on using [python on Polaris](https://docs.alcf.anl ## libEnsemble examples -For a very simple example of using libEnsemble see the [Simple Sine tutorial](https://libensemble.readthedocs.io/en/main/tutorials/local_sine_tutorial.html) +For a very simple example of using libEnsemble see the [Simple Introduction tutorial](https://libensemble.readthedocs.io/en/main/tutorials/local_sine_tutorial.html) For an example that runs a small ensemble using a C application (offloading work to the GPU), see -[the GPU app tutorial](https://libensemble.readthedocs.io/en/main/tutorials/forces_gpu_tutorial.html). The required files for the this tutorial can be found in [this directory](https://github.com/Libensemble/libensemble/tree/develop/libensemble/tests/scaling_tests/forces). Also, see the -[video demo](https://youtu.be/Ff0dYYLQzoU). - -Note that when initializing the MPIExecutor on Polaris (**run_libe_forces.py** in the example), you currently need to use the following options to pick up the correct MPI runner: - - exctr = MPIExecutor(custom_info={'mpi_runner':'mpich', 'runner_name':'mpiexec'}) +[the GPU app tutorial](https://libensemble.readthedocs.io/en/main/tutorials/forces_gpu_tutorial.html). The required files for the this tutorial can be found in [this directory](https://github.com/Libensemble/libensemble/tree/main/libensemble/tests/scaling_tests/forces). ## Job Submission -libEnsemble runs on the compute nodes on Polaris using either -``multi-processing`` or ``mpi4py``. The user can set the number of workers for +libEnsemble runs on the compute nodes on Polaris using either Python's +``multiprocessing`` module or ``mpi4py``. The user can set the number of workers for maximum concurrency. libEnsemble will detect the nodes available from the PBS environment and use these for running simulations. Polaris supports -running multiple concurrent simulations on each node if desired, +running multiple concurrent simulations on each node if desired. A simple example batch script for a libEnsemble use case that runs four workers on one node: From bdacdb92ff6dee8a6a7c1db88b8a78ef095fd1b0 Mon Sep 17 00:00:00 2001 From: jlnav Date: Mon, 2 Oct 2023 10:52:36 -0500 Subject: [PATCH 2/3] tiny edits based on suggestions --- docs/polaris/workflows/libensemble.md | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/docs/polaris/workflows/libensemble.md b/docs/polaris/workflows/libensemble.md index c693fc674..07b9faa93 100644 --- a/docs/polaris/workflows/libensemble.md +++ b/docs/polaris/workflows/libensemble.md @@ -1,6 +1,13 @@ # libEnsemble -libEnsemble is a Python toolkit for running dynamic ensembles of calculations. Users provide generator and simulator functions to express their ensembles, where the generator can steer the ensemble based on previous results. A library of example functions is available which can be modified as needed. These functions can submit external executables at any scale and in a portable way. System details are detected, and dynamic resource management is provided. libEnsemble can be used in a consistent manner on laptops, clusters, and supercomputers with minimal required dependencies. +libEnsemble is a Python toolkit for running dynamic ensembles of calculations. + +Users provide generator and simulator functions to express their ensembles, where the generator can steer the ensemble based on previous results. These functions can submit external executables at any scale and in a portable way. + +System details are detected, and dynamic resource management is provided. This includes automatically detecting, assigning, and reassigning +GPUs for ensemble members. + +libEnsemble can be used in a consistent manner on laptops, clusters, and supercomputers with minimal required dependencies. ## Getting libEnsemble on Polaris @@ -38,17 +45,20 @@ See the docs for more details on using [python on Polaris](https://docs.alcf.anl For a very simple example of using libEnsemble see the [Simple Introduction tutorial](https://libensemble.readthedocs.io/en/main/tutorials/local_sine_tutorial.html) For an example that runs a small ensemble using a C application (offloading work to the GPU), see -[the GPU app tutorial](https://libensemble.readthedocs.io/en/main/tutorials/forces_gpu_tutorial.html). The required files for the this tutorial can be found in [this directory](https://github.com/Libensemble/libensemble/tree/main/libensemble/tests/scaling_tests/forces). +[the GPU app tutorial](https://libensemble.readthedocs.io/en/main/tutorials/forces_gpu_tutorial.html). +The required files for this tutorial can be found +in [this directory](https://github.com/Libensemble/libensemble/tree/main/libensemble/tests/scaling_tests/forces). +A [video demo](https://youtu.be/Ff0dYYLQzoU) is also available. ## Job Submission libEnsemble runs on the compute nodes on Polaris using either Python's -``multiprocessing`` module or ``mpi4py``. The user can set the number of workers for +``multiprocessing`` or ``mpi4py``. The user can set the number of workers for maximum concurrency. libEnsemble will detect the nodes available from the PBS environment and use these for running simulations. Polaris supports running multiple concurrent simulations on each node if desired. -A simple example batch script for a libEnsemble use case that runs four workers on one node: +A simple example batch script for a libEnsemble use case that runs five workers on one node: ```shell #!/bin/bash -l @@ -60,7 +70,7 @@ A simple example batch script for a libEnsemble use case that runs four workers export MPICH_GPU_SUPPORT_ENABLED=1 cd $PBS_O_WORKDIR - python run_libe_forces.py --comms local --nworkers 4 + python run_libe_forces.py --comms local --nworkers 5 ``` The script can be run with: From 5623e3d2152efaa3decef73f18c66310e252b401 Mon Sep 17 00:00:00 2001 From: jlnav Date: Mon, 2 Oct 2023 11:05:04 -0500 Subject: [PATCH 3/3] tiny adjust, add early link --- docs/polaris/workflows/libensemble.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/polaris/workflows/libensemble.md b/docs/polaris/workflows/libensemble.md index 07b9faa93..58ad34bc9 100644 --- a/docs/polaris/workflows/libensemble.md +++ b/docs/polaris/workflows/libensemble.md @@ -1,8 +1,8 @@ # libEnsemble -libEnsemble is a Python toolkit for running dynamic ensembles of calculations. +[libEnsemble](https://libensemble.readthedocs.io/en/main/) is a Python toolkit for running dynamic ensembles of calculations. -Users provide generator and simulator functions to express their ensembles, where the generator can steer the ensemble based on previous results. These functions can submit external executables at any scale and in a portable way. +Users provide generator and simulator functions to express their ensembles, where the generator can steer the ensemble based on previous results. These functions can portably submit external executables at any scale. System details are detected, and dynamic resource management is provided. This includes automatically detecting, assigning, and reassigning GPUs for ensemble members.