data structures and software dependability

computer science department

brandenburg university of technology cottbus - senftenberg


latest update: October 30, 2019, at 11:24 AM

BTU Cottbus
(27) London; United Kingdom
(25) Cottbus; Germany
(3) Melbourne; Australia
(3) New York; United States
(3) Hamburg; Germany
(2) Parsippany; United States
(2) Warsaw; Poland
(2) Berlin; Germany
(2) Eisenhüttenstadt; Germany
(2) Willetton; Australia
(2) Shenzhen; China
(2) Oxford; United Kingdom
(2) Konstanz; Germany
(2) Cordoba; Argentina
(1) Chongqing; China
(1) San Jose; United States
(1) Wuppertal; Germany
(1) Amstelveen; Netherlands
(1) Medveja; Croatia
(1) Sibiu; Romania
(1) Essen; Germany
(1) Bogotá; Colombia
(1) Nasik; India
(1) Halberstadt; Germany
(1) Hagen; Germany
(1) Utrecht; Netherlands
(1) Montmorency; Australia
(1) Dresden; Germany
(1) Moers; Germany
(1) San Justo De La Vega; Spain
(1) Antibes; France
(1) Ban Kat; Thailand
(1) Cairo; Egypt


  • 2019-07-03 New release is ready: Spike 1.4.4.
  • 2019-05-29 New release is ready: Spike 1.4.3.
  • 2019-05-09 New release is ready: Spike 1.4.2.
  • 2019-04-27 New release is ready: Spike 1.4.1.
  • 2019-04-21 New release is ready: Spike 1.4.0.
  • 2018-10-08 First release for Linux & OSX is ready.
  • 2018-08-09 First news: we are here.



  • Linux (Intel only, 64bit)

** page is under update

  • Mac OS X (10.12+, Intel only, 64bit)

** page is under update

  • Windows (version 10 or greater)

** page is under update

* All platforms ** page is under update test-case

See Installation for what to do with the downloaded file.

General Description

Spike is a tool for efficient and reproducible simulation of stochastic/continuous/hybrid Petri nets, coloured or uncoloured ones. It is a command line tool with a set of commands and allows for executing a configuration script to run a simulation.


  • runs on: Linux, Mac, Windows
  • support of SBML models
  • conversion between different file formats:
    • ANDL to: PNML, ERODE
    • ERODE to: ANDL, PNML
  • support for simulation:
    • stochastic (Gillespie’s SSA, tau leaping, delta leaping, fau),
    • continuous (BDF, ADAMS, classic, Rosenbrock, Euler),
    • hybrid algorithms(HRSSA, accelerated HRSSA, static, accelerated static, dynamic)
  • pruning of clean siphons and constant places
  • unfolding of coloured Petri nets
  • human readable configuration script to configure model parameters and simulation options


Spike is distributed as single zip files which include a statically linked single executable and a set of examples.

Installation steps:

  1. unzip Spike's package to destination folder;
  2. optionally, rename the file spike-[version] to spike;
  3. check Spike's version by typing in the command line interface (CLI) the command:
      spike version

expected output:

      Spike: v[version number] 

Printing the list of available commands:

      spike help



expected output:

      usage: help -c=[command]

        exe       execute configuration file
        version   display Spike version
        help      display help
        save      save net to file
        prune     prune net
        eval      evaluate constants & places
        unfold    unfold coloured net
        load      load net from file

Manuals and Tutorials


Executing a sequence of commands

Spike has a list of commands, each with its own list of parameters, which can be executed. Commands are processed in a sequential way. This means that, when the model is not in memory, the load command must be at the beginning of the command chain. Let's consider the following use case: model pruning and saving the pruned model to a file:

  spike load -f=fileName prune -cs save -f=prunedFileName

First, Spike has to load the model from a file into the memory, next to prune any clean siphons, and finally to save the pruned model to the given file.

The following example present unfolding of coloured net presented as CANDL . The results fo unfolding is will be saved as uncoloured net (ANDL):

  spike load -f=colouredFileName.candl unfold save -f=uncolouredFileName.andl

Executing a configuration script

The following command will start the execution of a prepared simulation experiment by reading a configuration script.

  spike exe -f=path/to/file.scp

All logs are stored in the folder named logs.

To run the configuration script examples included in the distribution kit, Spike must be executed in the directory where the examples are located; e.g.:

  spike exe -f=conf-sim-andl.spc

All results and subfolders with logs will be stored under the current directory.

List of commands:

  • version - display Spike version
  • help
    • -c=[command] - display help for a given command
  • exe - execute configuration script
    • -f=[fileName] - loads a configuration script file from a given path
    • -p=[number=1] - max number of parallel simulations; when set to 0 - tries to set the parallel simulations to the number of available cpu cores; if not successful, set to default value 1 (sequential executing);this value is not equal to how many threads/processes will be use for additional processing/computation
    • -port=[number=7777] - port used in the interprocess communication; the default value is set to 7777
    • -process=[strategy=1] - process creation strategy: 1 - reuse, 2 - create new process
    • -v - validate (perform dry run)
  • load - load a model from a file (ANDL, CANDL, SBML, PNML, ERODE)
    • -f=[fileName] - load a file from a given path; for ERODE file only the semantic of reaction network is supported, the symbolic parameters and Hill kinetics are not supported;
    • -a - add scaling factors for mass/action kinetics
    • -net=[type=CPN] - load SBML as continuous or stochastic PN (CPN | SPN)
    • -r - load SBML with reversible reactions
    • -b - load SBML with boundary conditions
  • save - save the model to a file
    • -f=[fileName] - save a file to a given path (ANDL, CANDL, PNML, ERODE); saving as ERODE file only the semantic of reaction network is supported; exporting to PNML is only allowed for a net without the time
    • -erode [SMB | FE | BE] - while saving ERODE file extend it by a given reduction method
  • prune - pruning of clean siphons and constant places
    • -cs - prune clean siphons
    • -lcs=[fileName] - load clean siphons from the file and prune
    • -scs=[fileName] - save clean siphons to a file
    • -cp - prune constant places
    • -lcp=[fileName] - load constant places from the file and prune
    • -scp=[fileName] - save constant places to the file
  • unfold - unfold coloured PN
    • -e - evaluate value expressions (tokens, multiplicity)
    • -c=[constantName=value,...] - specifying new values for existing constants
  • eval - evaluation of constants and places (after evaluation all constants / placec values represented by equations will be replaced by numeric value of equations)
    • -p - evaluate places
    • -c - evaluate constants

Configuration script examples

To comply with the demand for reproducible simulation experiments, Spike is supported by a script language which allows for model and simulation configuration. The structure of the script is easily readable for a user and does not require any special tools for editing: a simple text editor is enough. Models included in examples are part of Spike's distribution package.

Example 1 Example configuration which shows how to set: initial markings, value of constants, scanning of model parameters.

Example 2 Example configuration of simulation option scanning.

Example 3 Example configuration of stochastic simulation for SBML model.

Related Papers

  • [CH19a]
    J Chodak and M Heiner:
    Spike – reproducible simulation experiments with configuration file branching;
    In Proc. CMSB 2019, Trento, Springer, LNCS/LNBI, volume 11773, pages 315-321, September 2019. [ doi ] [ BibTeX ]
  • [CH19b]
    J Chodak and M Heiner:
    SPIKE – as a Supporting Tool for a Model Parameters Optimization via Branched Simulations;
    In Proc. 23th German Workshop on Algorithms and Tools for Petri Nets (AWPN 2019), University of Hagen, pages 18-23, October 2019. [ url ] [ pdf ] [ BibTeX ]
  • [CH19b.sld]
    J Chodak and M Heiner:
    SPIKE – as a Supporting Tool for a Model Parameters Optimization via Branched Simulations;
    Talk, AWPN2019, University of Hagen, October 2019. [ pdf ] [ BibTeX ]
  • [CH18]
    J Chodak and M Heiner:
    Spike - a command line tool for continuous, stochastic & hybrid simulation of (coloured) Petri nets;
    In Proc. 21th German Workshop on Algorithms and Tools for Petri Nets (AWPN 2018), University of Augsburg, pages 1-6, October 2018. [ url ] [ pdf ] [ BibTeX ]
  • [CH18.sld]
    J Chodak and M Heiner:
    Spike - a command line tool for continuous, stochastic & hybrid simulation of (coloured) Petri nets;
    Talk, AWPN2018, University of Augsburg, October 2018. [ pdf ] [ BibTeX ]

Related Tools

  • modelling tools
  • reduction of systems of ordinary differential equations (ODEs)

Bug Reports

Submit your bug reports and any comments about Spike to jacek [period] chodak [snail] b-tu [period] de

… the end …

Any comments or questions are welcome. Please direct them to monika [period] heiner [snail] b-tu [period] de Privacy Policy