A simple DES modeling and simulation environment based on simpy, camunda modeler, and tkinter / pixi.js;
Camunda-Modeler-based creation of SimPy discrete event simulation models
Wouldn't it be cool to combine the block-based process modeling experience of commercial discrete event simulation packages with the amenities of proper IDE-based source-code editing? (Think Arena / Anylogic / ExtendSim / Plant Simulation / ... but with simple integration of third-party libraries, industry-standard interfaces, unit- and integration testing, dockerization, serverless execution in the cloud of your choice... and even actually working auto-completion! :D)
And all that not only for free, but using the worlds most popular language for data analytics and machine learning?
Created BPMN process diagrams are parsed and converted to Python-code, combining visual oversight of model structure with code-based definition of model behavior. Immediately executable, including a token-based process animation, allowing for space-discrete entity movements, and ready to be wrapped as a gym-environment to let a machine-learning algorithm find a control strategy.
Further information and sample projects:
- https://fladdimir.github.io/post/ (English)
- https://casymda.github.io/page/Webpage/Startpage.html (German)
pip install casymda
- connectable blocks for processing of entities
- graphical model description via camunda modeler
- process visualization browser-based or via tkinter
- space-discrete tilemap-movements of entities
- Gym-interface implementation for connection of reinforcment learning algorithms
- gradually typed (checkout pyright for vscode)
- automated model generation from process event-logs via PM4Py
Basic features are illustrated as part of the example models (which also serve as integration tests):
- seize and release a resource via graphical modeling
- entity movement along a shortest path defined by a csv-tilemap (built on networkx: https://networkx.github.io/)
This project trusts Black for formatting, Sonarqube for static code analysis, and pytest for unit & integration testing. Developed and tested on Linux (Ubuntu 18.04), Python 3.7.5. Tests can be carried out inside a docker-container, optionally including an installation from pypi to verify a successful upload.
sonarqube server (public docker image):
docker-compose up sonarqube
sonar-scanner (public docker image):
docker-compose up analysis
(run a docker-based unit-test first for coverage-reporting)
(remember to share your drive via Docker-Desktop settings if necessary, to be re-applied after each password change)
pytest --cov-report term --cov=src/casymda/ tests/
For Docker-based tests see docker-compose.yml
docker-compose run unit-test docker-compose run examples-test docker-compose run examples-test-pypi
Virtual environment setup
python3 -m venv venv
pip install -e .
Publish to pypi
python setup.py sdist twine upload dist/*
feedback / ideas / discussion / cheering / complaints welcome
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size casymda-0.2.21.tar.gz (37.3 kB)||File type Source||Python version None||Upload date||Hashes View|