{"id":13477490,"url":"https://github.com/NVIDIA/ngc-container-environment-modules","last_synced_at":"2025-03-27T05:31:55.066Z","repository":{"id":46016471,"uuid":"264042658","full_name":"NVIDIA/ngc-container-environment-modules","owner":"NVIDIA","description":"Environment modules for NGC containers","archived":false,"fork":false,"pushed_at":"2021-11-19T22:40:31.000Z","size":109,"stargazers_count":29,"open_issues_count":5,"forks_count":7,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-10-29T18:10:27.112Z","etag":null,"topics":["lmod","ngc","singularity"],"latest_commit_sha":null,"homepage":null,"language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/NVIDIA.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-05-14T22:51:07.000Z","updated_at":"2024-10-19T05:16:37.000Z","dependencies_parsed_at":"2022-09-02T18:43:02.320Z","dependency_job_id":null,"html_url":"https://github.com/NVIDIA/ngc-container-environment-modules","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NVIDIA%2Fngc-container-environment-modules","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NVIDIA%2Fngc-container-environment-modules/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NVIDIA%2Fngc-container-environment-modules/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NVIDIA%2Fngc-container-environment-modules/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/NVIDIA","download_url":"https://codeload.github.com/NVIDIA/ngc-container-environment-modules/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":222201230,"owners_count":16948029,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["lmod","ngc","singularity"],"created_at":"2024-07-31T16:01:43.529Z","updated_at":"2024-10-30T10:31:00.761Z","avatar_url":"https://github.com/NVIDIA.png","language":"Lua","readme":"# NGC Container Environment Modules\n\nNGC container environment modules are lightweight wrappers that make\nit possible to transparently use [NGC\ncontainers](https://ngc.nvidia.com) as environment modules.\n\n- Use familiar environment module commands, ensuring a minimal\n  learning curve or change to existing workflows\n\n- Leverage all the benefits of containers, including portability and\n  reproducibility\n\n- Take advantage of the optimized HPC and Deep Learning containers\n  from NGC\n\n## Synopsis\n\n```\n$ git clone https://github.com/NVIDIA/ngc-container-environment-modules\n$ module use $(pwd)/ngc-container-environment-modules\n$ module load gromacs\n$ gmx\n```\n\nThe `gmx` command on the host is transparently mapped into the GROMACS\ncontainer. If the container image is not already present, then the\nimage will be pulled and cached on first use.  Since Singularity\nautomatically mounts `$HOME`, `/tmp`, and the current working\ndirectory into the container, the container environment modules provide\nnearly transparent access to NGC containers.\n\nNote: Add the path to the NGC container environment modules to\n`MODULEPATH` to skip the `module use` step.\n\n## Prerequisites\n\n- [Lmod](https://lmod.readthedocs.io/en/latest/)\n- [Singularity](https://sylabs.io/guides/latest/user-guide/) 3.4.1 or later\n\n## Modification\n\nThe NGC container environment modules are a reference. It is expected\nthat they will need some modification for the local environment.\n\nSome of the expected changes are:\n\n1. The name of the Singularity module. The container environment\n   modules try to load the `Singularity` module (note the capital\n   'S'). Set the `NGC_SINGULARITY_MODULE` environment variable if the\n   local Singularity module is named differently (set it to `none` if\n   no Singularity module is required).\n\n2. Module conflicts. The container environment modules set module\n   conflicts based on the commands mapped into the container. Sites\n   may want to modify the list of conflicting modules to prevent\n   conflicts between containers or other environment modules.\n\n3. Container image cache. The container environment modules can either\n   pull NGC container images as needed or use a library of\n   pre-downloaded container images. Sites may wish to modify the\n   modules to only support one of these modes. Sites may also want to\n   hard-code the path to the library of pre-downloaded container\n   images rather than using the `NGC_IMAGE_DIR` environment variable.\n\n4. Mount additional directories into the containers. Sites may have\n   filesystems that should be visible to all user processes, such as a\n   `/scratch` filesystem or a set of shared datasets. In this case,\n   set `SINGULARITY_BINDPATH`, either globally, or in the container\n   environment modules.\n\n## Examples\n\n### Basic\n\nDownload a [GROMACS benchmark](http://ftp.gromacs.org/pub/benchmarks/)\nto run this example.\n\n```\n$ module load gromacs/2020.2\n$ gmx mdrun -ntmpi 1 -ntomp 40 -v -pin on -nb gpu --pme gpu --resetstep 12000 -nsteps 20000 -nstlist 400 -noconfout -s topol.tpr\n```\n\n### Interactive\n\n```\n$ module load pytorch/20.02-py3\n$ python3\n\u003e\u003e\u003e import torch\n\u003e\u003e\u003e x = torch.randn(2,3)\n```\n\n### Jupyter notebooks\n\n```\n$ module load rapidsai\n$ jupyter notebook --ip 0.0.0.0 --no-browser --notebook-dir /rapids/notebooks\n```\n\n### Multi-node MPI\n\nDownload the LAMMPS [Lennard Jones\nfluid](https://lammps.sandia.gov/inputs/in.lj.txt) dataset to run this\nexample.\n\n```\n$ module load lammps/15Jun2020\n$ mpirun -n 2 lmp -in in.lj.txt -var x 8 -var y 8 -var z 8 -k on g 2 -sf kk -pk kokkos cuda/aware on neigh full comm device binsize 2.8\n```\n","funding_links":[],"categories":["Lua"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FNVIDIA%2Fngc-container-environment-modules","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FNVIDIA%2Fngc-container-environment-modules","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FNVIDIA%2Fngc-container-environment-modules/lists"}