Skip to main content

PyLEMS

Build Check LEMS examples Documentation Status PyPI

A LEMS simulator written in Python which can be used to run NeuroML2 models (see here).

For more about PyLEMS see:

Michael Vella, Robert C. Cannon, Sharon Crook, Andrew P. Davison, Gautham Ganapathy, Hugh P. C. Robinson, R. Angus Silver and Padraig Gleeson, libNeuroML and PyLEMS: using Python to combine procedural and declarative modeling approaches in computational neuroscience Frontiers in Neuroinformatics 2014, doi: 10.3389/fninf.2014.00038

PLEASE CITE THE PAPER ABOVE IF YOU USE PYLEMS!

For more details on LEMS see:

Robert C. Cannon, Padraig Gleeson, Sharon Crook, Gautham Ganapathy, Boris Marin, Eugenio Piasini and R. Angus Silver, LEMS: A language for expressing complex biological models in concise and hierarchical form and its use in underpinning NeuroML 2, Frontiers in Neuroinformatics 2014, doi: 10.3389/fninf.2014.00079

Installation

A stable version of PyLEMS is available on PyPI using pip:

pip install pylems

Alternatively, you can obtain the latest version with

git clone https://github.com/LEMS/pylems.git
cd pylems
git checkout development   # optional
pip install .

Usage as a LEMS model simulator

pylems [options] LEMS_file

Options

  • -I/-include path - Adds a directory to the model file include search path

Examples

NeuroML examples (from https://github.com/NeuroML/NeuroML2/tree/development/NeuroML2CoreTypes)

  • Example 0 -- Working
  • Example 1 -- Working
  • Example 2 -- Working
  • Example 3 -- Working
  • Example 4 -- Not working (Unsupported in PyLEMS: KSChannel)
  • Example 5 -- Working
  • Example 6 -- Working
  • Example 7 -- Working
  • Example 8 -- Working
  • Example 9 -- Working
  • Example 10 -- Working
  • Example 11 -- Working
  • Example 12 -- Not working (Unsupported in PyLEMS: Property)
  • Example 13 -- Working
  • Example 14 -- Not working (Unsupported in PyLEMS: Property)
  • Example 15 -- Working
  • Example 16 -- Working (apart from spikeArray)
  • Example 17 -- Working
  • Example 18 -- Working

LEMS examples (in directory examples)

  • example1.xml -- Working
  • example2.xml -- Working
  • example3.xml -- Working
  • example4.xml -- Not working (Unsupported in PyLEMS: KSChannel)
  • example5.xml -- Not working (Unsupported in PyLEMS: KSChannel)
  • example6.xml -- Working

TODO: Rest of examples require an update to the <Simulation> element, i.e. use <Simulation...> not <SimulationSet...>, to work in PyLEMS

LEMS elements that do not work

  • KSChannel
  • Property
  • XPath based parameters - PathParameter
  • Assertions

Tasks TODO

  • Implement flattening
  • Decouple events from runnables
  • Improve dimension-checking on expressions.

This code is distributed under the terms of the GNU Lesser General Public License.

Metadata

Release files for PyLEMS 0.6.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for PyLEMS 0.6.9
File Size Uploaded
pylems-0.6.9.tar.gz 72.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for PyLEMS 0.6.9
File Interpreter ABI Platform
pylems-0.6.9-py3-none-any.whl Python 3 none any Details

Total release size: 140.0 kB

Release files / pylems-0.6.9.tar.gz

Download URL pylems-0.6.9.tar.gz
Size 72.4 kB
Tags Source
SHA-256 checksum
How to use checksums
01b47e60ec1fc4896e9cf69c15160012148202547a9cf6759a93828abdcd738a
BLAKE2b-256 checksum
How to use checksums
b40bb5d0800c3ae8aecf4ac0ab415537643e8a1fff138f6a282409f23e4906cd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.25

Release files / pylems-0.6.9-py3-none-any.whl

Download URL pylems-0.6.9-py3-none-any.whl
Size 67.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2c4346da61f1e312c7eeb6d3f98922854b6674391648aaf4c9c5c8d0e3977beb
BLAKE2b-256 checksum
How to use checksums
f7c524fa6d73081f592b7008806c3e20ad6633ae12c8e2d56bc78f14a19d68c2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.25

Release history Release notifications | RSS feed

This release

0.6.9 This release

2 release files

0.6.8

2 release files

0.6.7

2 release files

0.6.4

2 release files

0.6.2

2 release files

0.6.1

1 release file

0.6.0

2 release files

0.5.9

2 release files

0.5.8

2 release files

0.5.5

2 release files

0.5.4

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

1 release file

0.4.9.1

1 release file

0.4.9

1 release file

0.4.8

1 release file

0.4.5

1 release file

0.4.4

1 release file

0.3.7

1 release file

0.3.5

1 release file

0.3.4

1 release file

0.3.3

1 release file

0.3.2.1

1 release file

0.3.2

1 release file

0.3.01

0.3.0

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page