.. -*- encoding: utf-8 -*-

.. _installation:

==============
 Installation
==============

This document should help you to install the **GromacsWrapper**
package. Please raise and issue in the `Issue Tracker`_ if problems
occur or if you have suggestions on how to improve the package or
these instructions. Ask for help in the `discussions`_ forum.

.. _Issue Tracker: https://github.com/Becksteinlab/GromacsWrapper/issues
.. _discussions:
   https://github.com/Becksteinlab/GromacsWrapper/discussions


``pip`` installation
====================

The latest release can be directly installed with :program:`pip`::

  pip install GromacsWrapper

(This will automatically download and install the `latest version of
GromacsWrapper from PyPi`_.)

.. _`latest version of GromacsWrapper from PyPi`:
   https://pypi.org/project/GromacsWrapper/


``conda`` installation
======================

.. versionadded:: 0.8.1
.. versionchanged:: 0.8.3
   Package migrated from *bioconda* to *conda-forge*.

Install as a `conda-forge package`_ with the `conda`_ package manager from the
`conda-forge`_ channel ::

   conda install -c conda-forge gromacswrapper

The *conda-forge* channel should be explicitly specified if you are
not already using it by default.

.. Note::

   The *conda-forge* channel also contains `conda-forge packages for
   GROMACS`_ (earlier versions ≤ 2021.x are available as `GROMACS
   bioconda packages`_), which can be used for testing and system
   setup; for running in a high-performance environment you are
   advised to carefully benchmark and possibly compile a version of
   GROMACS_ that is tuned for the system.

.. _conda: https://docs.conda.io
.. _conda-forge: https://conda-forge.org/
.. _`conda-forge package`: https://anaconda.org/conda-forge/GromacsWrapper
.. _`conda-forge packages for GROMACS`: https://anaconda.org/conda-forge/gromacs/
.. _`GROMACS bioconda packages`: https://anaconda.org/bioconda/gromacs/
.. _GROMACS: http://www.gromacs.org/
   
   
Manual Download
===============

If your prefer to download manually, get the latest stable release
from https://github.com/Becksteinlab/GromacsWrapper/releases and
either ::

  pip install GromacsWrapper-0.9.0.tar.gz

or install from the unpacked source::

  tar -zxvf GromacsWrapper-0.9.0.tar.gz
  cd GromacsWrapper-0.9.0
  pip install .



Source code access
==================

The tar archive from https://github.com/Becksteinlab/GromacsWrapper/releases
contains a full source code distribution.

In order to follow code development you can also browse the code
**git** repository at https://github.com/Becksteinlab/GromacsWrapper
and checkout the *main* branch::

   git clone https://github.com/Becksteinlab/GromacsWrapper.git
   cd GromacsWrapper

Code contributions are welcome. We use `black`_ for uniform code
formatting so please install black_ and run it on your code.

.. _`black`: https://github.com/psf/black
   

Requirements
============

Python_ >= 3.9 and GROMACS_ (4.6.x, 2016, 2018, 2019, 2020, 2021,
2022, 2023, 2024) must be installed.

.. _Python: http://www.python.org


System requirements
-------------------

Tested with Python 3.9--3.12 on Linux and Mac OS X. Earlier Python
versions were only supported until release 0.8.5.


Required Python modules
-----------------------

The basic package makes use of numpy_ and numkit_ (which uses scipy_);
all dependencies are installed during a normal installation process.

.. _numpy: http://numpy.scipy.org
.. _numkit: https://github.com/Becksteinlab/numkit
.. _scipy: https://www.scipy.org/scipylib/index.html

