in-toolset’s documentation

in-toolset is an editor and (basic) simulator for industry workflow nets (inets), a model of interorganisational workflows based on petrinets.

Currently, the tool supports editing and manually simulating these industry workflows, and exporting industry nets as PNML petri nets, but support for checking for bisimilarity using LTSmin and for automatically generating a subset of the language of triggering sequences of an inet in XES is planned, as is a model of “domains” for organisations and messages.

in-toolset has cross-platform support and has been verified to work on linux, MacOS, and windows. It should work on most systems with python3.6 or newer and pyqt5. The recommended way to install it is to run pip install in-toolset, this makes a command-line tool in-toolset available which starts the graphical editor.

The toolset was originally created by: Daniel Otten, Jakob Wuhrer, Julia Bolt, Ricardo Schaaf, and Yannik Marchand, on behalf of Pieter Kwantes of Leiden University.

It is provided here licensed under the GNU General Public License v3.0.

Indices and tables



This module allows for signalling with callbacks and interconnectable signals. To do this, the Signal and SignalListener classes are used. Furthermore, it provides the class Property which allows the creation of object properties with associated signals to signify changes.

class in_toolset.common.Property(signame, default=None)

A basic property system that can be used to add properties with getters, setters, and signals to a class..

class in_toolset.common.Signal

A Signal basically consists of a list of callbacks and associated params that will be called when emit() is called.

connect(func, *param)

Connect a callback, to be called when when emit() is called.

disconnect(func, *param)

Disconnect or remove a callback so that it will no longer be called when emit() is called.


Call all connected callbacks with args and their associated param

class in_toolset.common.SignalListener

The SignalListener class groups callbacks and the signals to which they were added to allow for easier deletion/disconnection.

connect(signal, callback)

Connect callback to signal and store it in this


Disconnect all callbacks stored in this


The config module allows for configuration of the behaviour of in-toolset, using a text file with key-value items as storage for the settings

class in_toolset.config.Config(filename)

Manages basic configuration of the graphical interface as a list of key-value pairs


Get the value of field


Load the key-value pairs from the file filename into self

set(field, value)

Set the value of field to value


Get the current value of the configuration field field



Start the graphical editor with a new, blank, industry net.


The in_toolset.model module contains code for modelling the behaviour of petri nets, industry nets and generic uncoloured petri nets.

It relies heavily on the signalling and property classes in in_toolset.common.


class in_toolset.model.base.Node

A special child class of Object. It introduces directional connections between Nodes, which allows for the creation of graphs and the like


Create an outgoing connection from self to target


Remove an outgoing connection from self to target if present

class in_toolset.model.base.Object

A basic object class, objects can be marked as deleted and have Signal-typed members to signify deletion or changes


Mark the object as deleted


Mark the object as active

class in_toolset.model.base.ObjectList

A list of objects of the Object class. When iterating over an ObjectList, deleted or inactive Objects are filtered out.


Add an object to the list


Remove an item from the list

class in_toolset.model.base.PetriNet

A representation of a petrinet, containing places and transitions, implemented as a child class of Object. Places and transitions are represented as objects of type Place and Transition , respectively


Merge other and self into a new PetriNet and return it. This allows for bisimulation using LTSmin


The Property deadlock shows whether the petrinet is currently in deadlock. A petrinet is in deadlock if there are no enabled transitions.


(Re)Set all places in self to the default initial marking. This default initial marking is defined such that all places without any incoming transitions will contain one token, and the others will be empty.


Trigger a random transition, if possible

class in_toolset.model.base.Place

A representation of a place as in petri nets, implemented as a child class of Node. Can contain a positive number of uncoloured tokens, and can be connected to incoming or outgoing transitions transitions.


Increase the number of tokens by 1


Set the number of tokens in self to tokens


Decrease the number of tokens by 1

class in_toolset.model.base.Transition

A representation of a transition as in petri nets, implemented as a child class of Node. Can be connected to an arbitrary number of places.


The Property enabled shows whether the transition is currently enabled.


Trigger self, updating the amount of tokens contained in all connected places

triggered = None

The Signal triggered emits when the transition is triggered


class in_toolset.model.pnml.PNMLWriter(net, graph)

Allows exporting a petrinet and a graph in PNML format


Write petrinet corresponding to and self.graph to file in PNML format


class in_toolset.model.project.ProjectReader

Loads a project file (in our own json-based file format) corresponding to an inet into the program.

class in_toolset.model.project.ProjectWriter

Writes a project to a project file (in our own json-based file format).


This library adds the ability to store data necessary for a visual representation of an industry net.

class in_toolset.model.ui.TransitionType

An enum for the different possible transition types


An input transition can receive messages from another enterprise if connected on the industry level


An internal transition “stays” within a single enterprise net and is not connected to other nets


An output transition can send messages to another enterprise if enabled and connected on the industry level

class in_toolset.model.ui.UIArrow(source, target)
class in_toolset.model.ui.UIChannelArrow(source, target, channel)
class in_toolset.model.ui.UIGraph
class in_toolset.model.ui.UIInternalArrow(source, target)
class in_toolset.model.ui.UILabel
class in_toolset.model.ui.UILooseArrow(node, transition)
class in_toolset.model.ui.UINode(obj)
class in_toolset.model.ui.UIObject
class in_toolset.model.ui.UIPetriNet
class in_toolset.model.ui.UITransition

User Interface


The main class, corresponding to one instance of the graphical toolkit. It manages windows and allows for basic managing of projects.


Create a new project or load an existing one


Start the graphical interface and the program itself


class in_toolset.ui.common.ArrowBase(scene)
class in_toolset.ui.common.ArrowItem(scene, arrow)
class in_toolset.ui.common.LabelBase(scene)
boundingRect(self) → QRectF
paint(self, QPainter, QStyleOptionGraphicsItem, widget: QWidget = None)
class in_toolset.ui.common.LabelItem(scene, label)
class in_toolset.ui.common.LooseArrowItem(scene, style, arrow)
paint(self, QPainter, QStyleOptionGraphicsItem, widget: QWidget = None)
class in_toolset.ui.common.NodeBase(scene, shape=None)
paint(self, QPainter, QStyleOptionGraphicsItem, widget: QWidget = None)
class in_toolset.ui.common.NodeItem(scene, shape, node)


class in_toolset.ui.enterprise.PlaceItem(scene, style, node)
paint(self, QPainter, QStyleOptionGraphicsItem, widget: QWidget = None)
class in_toolset.ui.enterprise.PlaceSettings(node)
class in_toolset.ui.enterprise.TemporaryArrow(scene, source)

A placeholder arrow to be displayed on the canvas during placement of a arrow (while it is being dragged), to show the orientation and place of the arrow currently being placed.

class in_toolset.ui.enterprise.TemporaryPlace(scene, style)

A placeholder place to be displayed on the canvas during placement of a place, to show the place of the place currently being placed.

class in_toolset.ui.enterprise.TemporaryTransition(scene, style)

A placeholder transition to be displayed on the canvas during placement of a transition, to show the place of the transition currently being placed.

class in_toolset.ui.enterprise.TransitionItem(scene, style, node)
class in_toolset.ui.enterprise.TransitionSettings(node)


class in_toolset.ui.industry.ChannelArrowItem(scene, style, arrow)
class in_toolset.ui.industry.ChannelArrowLabel(scene, arrow)
class in_toolset.ui.industry.EnterpriseItem(scene, style, obj)
class in_toolset.ui.industry.EnterpriseSettings(obj)
class in_toolset.ui.industry.LooseArrowSettings(obj)
class in_toolset.ui.industry.MessageAnimItem(scene, style, arrow, isTarget)
class in_toolset.ui.industry.TemporaryArrowItem(scene, source)

class, shortcut, checkable=False)


class in_toolset.ui.scene.GeneralSettings(net)
class in_toolset.ui.scene.SeparatorLine
class in_toolset.ui.scene.SettingsWidget


The menu bar that can be used to select the active tools for left and right mouse buttons


Make a group of tools availabe, so that their corresponding tool buttons may be visible in the toolbar.


Return the currently active tool for a specific group, if there is an active too in said group. Otherwise, return -1.


Empty the toolbar


Select and enable the tool with name name

class, group)
paintEvent(self, QPaintEvent)
class, tool)
paintEvent(self, QPaintEvent)


class in_toolset.ui.view.EditorItem(scene)
class in_toolset.ui.view.EditorScene
drawBackground(self, QPainter, QRectF)
keyPressEvent(self, QKeyEvent)
mouseDoubleClickEvent(self, QGraphicsSceneMouseEvent)
mouseMoveEvent(self, QGraphicsSceneMouseEvent)
mousePressEvent(self, QGraphicsSceneMouseEvent)
mouseReleaseEvent(self, QGraphicsSceneMouseEvent)
class in_toolset.ui.view.EditorShape(scene, shape=None)
boundingRect(self) → QRectF
paint(self, QPainter, QStyleOptionGraphicsItem, widget: QWidget = None)
shape(self) → QPainterPath
class in_toolset.ui.view.EditorView(scene)
keyPressEvent(self, QKeyEvent)
mouseMoveEvent(self, QMouseEvent)
mousePressEvent(self, QMouseEvent)
mouseReleaseEvent(self, QMouseEvent)
wheelEvent(self, QWheelEvent)


class in_toolset.ui.window.EnterpriseItem(node)
class in_toolset.ui.window.IndustryItem(industry)
class in_toolset.ui.window.MainWindow(style)
closeEvent(self, QCloseEvent)
keyPressEvent(self, QKeyEvent)
class in_toolset.ui.window.NetListWidget