Python 2/3 package for calculating many-body dispersion energies.
Most functionality is implemented in the Fortran module in src/mbd.f90
.
There are two basic ways how to install pymbd.
Both ways require a Fortran compiler, Lapack, CFFI, and Numpy. Optional MPI support requires mpi4py installed from source. All these need to be installed before installing pymbd.
On Ubuntu:
apt-get install gfortran libblas-dev liblapack-dev [mpi-default-dev mpi-default-bin]
On macOS:
brew install gcc [mpich]
pip install cffi numpy [mpi4py]
pip install git+https://github.com/azag0/pymbd.git
If you have pytest installed, you can run tests with
pytest --pyargs pymbd -v --durations=3
This is the recommended way for developing or if installing via pip runs into problems.
git clone https://github.com/azag0/pymbd.git && cd pymbd
mkdir build && pushd build && cmake .. && make && popd
pip install -r requirements.txt
python setup.py build_ext -i
Tests can be run with
make -C build check
pytest -v --durations=3
Pymbd doesn't have any input files, it is called directly from Python scripts.
For examples, see the tests.