Skip to content

Installation

Installation

There are two primary ways to install biolocsim, depending on your use case.

For Users: Install from PyPI

If you intend to use biolocsim as a library in your own projects, the easiest way is to install the latest stable release from PyPI.

# Create a new conda environment with Python 3.10
conda create -n biolocsim python=3.10 -y
conda activate biolocsim

# Install biolocsim
pip install biolocsim

For Developers: Install from Source

If you want to contribute to biolocsim, run the examples, or use the latest development version, you should install it from the source code.

  1. Clone the repository:

    git clone https://github.com/sylvanding/biolocsim.git
    cd biolocsim
    
  2. Create a development environment: We recommend using conda for environment management to ensure consistency.

    # Create a new conda environment with Python 3.10
    conda create -n biolocsim-dev python=3.10 -y
    conda activate biolocsim-dev
    
  3. Install dependencies using Poetry: This project uses Poetry to manage dependencies. First, install Poetry itself:

    pip install poetry
    

    Then, install the project and its dependencies with poetry.lock (recommended):

    poetry install
    

    or without poetry.lock, including tools for development, testing, and documentation (not recommended):

    poetry install -E doc -E dev -E test
    
  4. Verify the installation (optional): You can run the full test suite with tox to make sure everything is set up correctly.

    poetry run tox
    

    This will run tests and code style checks.