Package: pylammpsmpi
pylammpsmpi - Parallel Lammps Python interfaceWithpylammpsmpiyou can control ampi4pyparallel LAMMPS instance from a serial python process or a Jupyter
notebook. Internallypylammpsmpileverages thepympipoolcommunication interface to connect the serial python
process the user interacts with, with thempi4pyparallel LAMMPS instance. The advantage of separating thempi4pyparallel LAMMPS instance from the rest of the workflow is that the workflow can be written as serial python code, while
still benefiting from the parallel performance of LAMMPS. Still this comes at the cost of additional data transfer, as
the LAMMPS pointers cannot be transferred this way and the linked data has to be copied instead. So copying large
atomistic structures can decrease the performance of thepylammpsmpiinterface in comparison to writing your own fullympi4pyparallel LAMMPS workflows.InterfacesThepylammpsmpimodule implements three different interfaces for different use cases:pylammpsmpi.LammpsBase: The most basic interface is theLammpsBase, it implements the same commands like the
defaultlammps.lammpsinterface and returns the same datatypes. With this API compatibility to the standard
interface, this interface is commonly the easiest way to accelerate a serial LAMMPS based workflow by leveragingmpi4pyparallel LAMMPS instances.pylammpsmpi.LammpsConcurrent: Inspired by theconcurrent.futuresmodule in the standard python library thepylammpsmpi.LammpsConcurrentinterface implements the same API as thepylammpsmpi.LammpsBaseclass but rather than
holding the controlling process until thempi4pyparallel LAMMPS instance finishes the execution of a given set of
commands, thepylammpsmpi.LammpsConcurrentinterface returns aconcurrent.futures.Futureobject. This enables the
development of asynchronous / concurrent workflows.pylammpsmpi.LammpsLibrary: Finally, thepylammpsmpi.LammpsLibraryinterface adds a higher level interface on top
of the defaultlammps.lammpsinterface. This higher level interface provides direct access to the commands and
thermodynamic properties used in the LAMMPS input files. Especially for experienced LAMMPS users who are familiar with
the LAMMPS input files this interface simplifies switching from file based input to using the python interface.The choice of interface depends on the users background, experience and the simulation protocol the user wants to
implement. Still internally all three interfaces are based on thepylammpsmpi.LammpsConcurrentinterface, so they use
an additional thread to connect thempi4pyparallel LAMMPS instance to the serial python process or Jupyter notebook.DocumentationInstallationconda-based installationpypi-based installationInterfacesLammpsBaseLammpsConcurrentLammpsLibraryDevelopmentLicensepylammpsmpiis released under the BSD licensehttps://github.com/pyiron/pylammpsmpi/blob/main/LICENSE. It is a
spin-off of thepyironprojecthttps://github.com/pyiron/pyirontherefore if you usepylammpsmpifor calculation
which result in a scientific publication, please cite:@article{pyiron-paper,
  title = {pyiron: An integrated development environment for computational materials science},
  journal = {Computational Materials Science},
  volume = {163},
  pages = {24 - 36},
  year = {2019},
  issn = {0927-0256},
  doi = {https://doi.org/10.1016/j.commatsci.2018.07.043},
  url = {http://www.sciencedirect.com/science/article/pii/S0927025618304786},
  author = {Jan Janssen and Sudarsan Surendralal and Yury Lysogorskiy and Mira Todorova and Tilmann Hickel and Ralf Drautz and Jörg Neugebauer},
  keywords = {Modelling workflow, Integrated development environment, Complex simulation protocols},
}