Skip to content

Commit

Permalink
Merge pull request #47 from OpenBioSim/feature_CUDA_docs
Browse files Browse the repository at this point in the history
Adds CUDA documentation to README
  • Loading branch information
mb2055 authored Jun 4, 2024
2 parents a1247ee + 50c1b20 commit 4891b9a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,14 @@ An example perturbable system for a methane to ethanol perturbation in solvent
can be found [here](https://sire.openbiosim.org/m/merged_molecule.s3.bz2).
This is a `bzip2` compressed file that will need to be extracted before use.

#### Running SOMD2 using one or more GPUs

In order to run using GPUs you will first need to set the relevant environment variable. For example, to run using 4 CUDA enabled GPUS set `CUDA_VISIBLE_DEVICES=0,1,2,3` (for openCL and HIP use `OPENCL_VISIBLE_DEVICES` and `HIP_VISIBLE_DEVICES` respectively).

By default SOMD2 will run using the CPU platform, however if the relevant environment variable has been set (as above) the new platform will be detected and set. In the case that this detection fails, or if there are multiple platforms available, the `--platform` option can be set (for example `--platform cuda`).

By default, SOMD2 will automatically manage the distribution of lambda windows across all listed devices. In order to restrict the number of devices used the `--max_gpus` option can be set, for example setting `max_gpus=2` while `CUDA_VISIBLE_DEVICES` are set as above would restrict SOMD2 to using only GPUs 0 and 1.

## Analysis

Simulation output will be written to the directory specified using the
Expand Down

0 comments on commit 4891b9a

Please sign in to comment.