Skip to main content

Python Interface for Spatial Stochastic Biochemical Simulations

Project description

SpatialPy is a Python 3 package for simulation of spatial deterministic/stochastic reaction-diffusion-advection problems embedded in Lagrangian reference frame particle based fluid dynamics domain

This package is intended to replace the PyURDME software https://github.com/pyurdme/pyurdme and will feature both a NSM solver for RDME simulation on static domains and a sSSA-SDPD particle based fluid dynamics solver as described in the publication "A hybrid smoothed dissipative particle dynamics (SDPD) spatial stochastic simulation algorithm (sSSA) for advection–diffusion–reaction problems" by Drawert, Jacob, Li, Yi, Petzold https://www.sciencedirect.com/science/article/pii/S0021999118307101

PLEASE REGISTER AS A USER, so that we can prove SpatialPy has many users when we seek funding to support development. SpatialPy is part of the StochSS project.

PyPI - License PyPI - Python Version PyPI PyPI - Downloads

Table of contents

Installation

SpatialPy can be installed on your computer using different methods, as described below.

Using PyPI

On Linux, macOS, and Windows operating systems, you should be able to install SpatialPy with pip. Please review the official pip documentation for installation instructions and additional information.

Then, to install SpatialPy from the Python package repository, run the following command:

python3 -m pip install spatialpy --user --upgrade

Using the source code repository

As an alternative to getting it from PyPI, you can instruct pip to install SpatialPy directly from the GitHub repository:

python3 -m pip install https://github.com/StochSS/SpatialPy/archive/main.zip --user --upgrade

As a final alternative, you can first use git to clone a copy of the SpatialPy source tree from the GitHub repository to your local computer disk, and then install SpatialPy using that copy:

git clone https://github.com/StochSS/SpatialPy.git
cd SpatialPy
python3 -m pip install  .  --user --upgrade

Usage

SpatialPy provides simple object-oriented abstractions for defining a model of a biochemical system and simulating that model using efficient stochastic simulation algorithms. The basic steps to use SpatialPy are:

  1. Create a SpatialPy.Model containing molecular species, parameters, and reactions.
  2. Invoke the model's .run() method.

The run() method can be customized using keyword arguments to select different solvers, random seed, data return type and more. For more detailed examples on how to use SpatialPy, please see the Jupyter notebooks contained in the examples subdirectory.

Getting help

SpatialPy's online documentation provides more details about using the software. If you find any problem with SpatialPy or the documentation, please report it using the GitHub issue tracker for this repository. You can also contact Dr. Brian Drawert directly with questions and suggestions.

Contributing

We would be happy to receive your help and participation with enhancing SpatialPy! Please follow the guidelines described in CONTRIBUTING.md.

New developments happen primarily in the develop branch. New releases are put in the main branch.

Main Branch Develop Branch
Build Status Build Status

License

SpatialPy is licensed under the GNU General Public License version 3. Please see the file LICENSE for more information.

Authors and history

Acknowledgments

This work has been funded by National Institutes of Health (NIH) NIBIB Award No. 2R01EB014877-04A1.

SpatialPy uses numerous open-source packages, without which it would have been effectively impossible to develop this software with the resources we had. We want to acknowledge this debt. In alphabetical order, the packages are:

  • Jupyter – web application for creating documents containing code, visualizations and narrative text
  • MatplotLib – Python plotting library
  • Plotly – Graphing library for making interactive, publication-quality graphs
  • Numpy – the fundamental package for scientific computing with Python
  • Scipy – Python-based ecosystem of open-source software for mathematics, science, and engineering

Finally, we are grateful for institutional resources made available by the University of North Carolina at Asheville, the University of California at Santa Barbara, Uppsala University, and the California Institute of Technology.

           

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spatialpy-1.0.2.tar.gz (692.7 kB view details)

Uploaded Source

Built Distribution

spatialpy-1.0.2-py3-none-any.whl (756.8 kB view details)

Uploaded Python 3

File details

Details for the file spatialpy-1.0.2.tar.gz.

File metadata

  • Download URL: spatialpy-1.0.2.tar.gz
  • Upload date:
  • Size: 692.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.10

File hashes

Hashes for spatialpy-1.0.2.tar.gz
Algorithm Hash digest
SHA256 96ff84c091f295131b71977861c3979f1a184d8b06ff0c513049972917da8bd7
MD5 a8602094a412689a4cb5fc8569df9899
BLAKE2b-256 cddd8f65acd415281964722c516c745202a0427282c0000a929ca3385d7c018c

See more details on using hashes here.

File details

Details for the file spatialpy-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: spatialpy-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 756.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.10

File hashes

Hashes for spatialpy-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 8a8efc67b72ce94345f566a9581af43d183a06cd82781d2411509adb47bc84b1
MD5 80d0dd7cc0f13ec6d151b87efa08f1f4
BLAKE2b-256 99fa89a2bacd93b2cf00ea4ba17dc0cb7b113af9ebcb140c57fc9bb741960e95

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page