For the complete documentation index, see llms.txt. This page is also available as Markdown.

Modules

Environment modules provide pre-installed software (frameworks, tools, and container-backed environments) without requiring you to build or pull images yourself. They are a lightweight alternative to containers when you do not need full environment isolation or a custom software stack.

Two module systems are available:

  • Lmod — the primary module system. Use it to load and switch between pre-installed frameworks and tools.

  • SHPC (Singularity HPC) — extends Lmod with container-backed modules. SIF images are installed into a shared module tree so that module load transparently runs commands inside the container.

Modules are available on both login and compute pods. Load them in your batch script before calling srun so the environment is propagated to all tasks.


Lmod

Lmod is the module system on this cluster. Common commands:

module avail                  # list all available modules
module avail torch            # search by name
module load torch/2.7         # load a module
module list                   # show loaded modules
module unload torch/2.7       # unload a module
module purge                  # unload everything

Example: batch job using a module

#!/bin/bash
#SBATCH --job-name=torch-module
#SBATCH --nodes=2
#SBATCH --ntasks-per-node=1
#SBATCH --gpus-per-node=8
#SBATCH --cpus-per-task=48
#SBATCH --time=02:00:00

module load torch/2.7

srun python -m torch.distributed.run \
  --nproc_per_node 8 \
  --nnodes $SLURM_NNODES \
  train.py

SHPC (Singularity HPC)

SHPC installs container images as Lmod modules onto a shared volume, so module load transparently runs commands inside the container. Installed modules are available to all users.

By default, shpc installs modules under /mnt/shpc. This is intended to be a global admin-managed registry. Users are expected to configure their own shpc installation target:

Configure private module tree:

Admins can omit this step to install packags globally. The following install commands will target /mnt/shpc, and will be availabe to all users.

Install a module from the curated registry:

Install an arbitrary OCI image:

Note: running module-installed apps only works on privileged pods (worker-pods and VM-based login pods). If you encounter the error ERROR : Failed to create mount namespace: mount namespace requires privileges, check Apptainer installation, try running the same command with srun.

Global modules and container images are stored on the shared modulestore volume (/mnt/modulestore), so an install on a login pod is immediately available on compute pods without any additional steps. Users are encouraged to install their modules in their /home/$USER directory.

Last updated