TorchANI is a PyTorch implementation of ANI(Accurate NeurAl networK engINe for Molecular Energies), created and maintained by the Roitberg group. TorchANI contains classes like AEVComputer, ANIModel, and EnergyShifter that can be pipelined to compute molecular energies from the 3D coordinates of molecules. It also include tools to: deal with ANI datasets(e.g. ANI-1, ANI-1x, ANI-1ccx, ANI-2x) at torchani.data
, import various file formats of NeuroChem at torchani.neurochem, and more at torchani.utils.
Before running the NGC TorchANI container please ensure your system meets the following requirements.
The following examples demonstrate using the NGC TorchANI container to computing vibrational frequencies using analytical Hessian. TorchANI is able to use ASE interface to perform structure optimization and vibration analysis, but the Hessian in ASE's vibration analysis is computed numerically, which is slower and less accurate. Therefore, TorchANI provides an interface to compute the Hessian matrix and do vibration analysis analytically, thanks to the super power of torch.autograd
.
The environment variable BENCHMARK_DIR
will be used throughout the example to refer to the directory containing the python script. . Ensure you're running the correct container version by replacing YYYY.MM
with the appropriate container tag.
wget https://raw.githubusercontent.com/aiqm/torchani/master/examples/vibration_analysis.py
export BENCHDIR=$PWD
cd ${BENCHMARK_DIR}
wget https://gitlab.com/NVHPC/ngc-examples/-/raw/master/torchani/single-node/run_torchani.py
chmod +x run_torchani.py
cd ${BENCHMARK_DIR}
docker run --rm --gpus all --ipc=host -v ${PWD}:/host_pwd -w /host_pwd nvcr.io/hpc/torchani:YYYY.MM ./run_torchani.py
Docker versions below 1.40 must enable GPU support with --runtime nvidia
.
docker run --rm --runtime nvidia --ipc=host -v ${PWD}:/host_pwd -w /host_pwd nvcr.io/hpc/torchani:YYYY.MM ./run_torchani.py
cd ${BENCHMARK_DIR}
singularity run --nv -B${PWD}:/host_pwd --pwd /host_pwd docker://nvcr.io/hpc/torchani:YYYY.MM ./run_torchani.py
There is currently an issue in Singularity versions below v3.5 causing the LD_LIBRARY_PATH
to be incorrectly set within the container environment. As a workaround The LD_LIBRARY_PATH
must be unset before invoking Singularity:
LD_LIBRARY_PATH="" singularity run --nv -B${PWD}:/host_pwd --pwd /host_pwd docker://nvcr.io/hpc/torchani:YYYY.MM ./run_torchani.py
By pulling and using the container, you accept the terms and conditions of the TorchANI License