Skip to main content

DynamicalSystemFramework

Latest Release PyPI version DOI

Standard TBB SPDLOG CSV JSON SQLite codecov

The aim of this project is to rework the original Traffic Flow Dynamics Model. This rework consists of a full code rewriting, in order to implement more features (like intersections) and get advantage from the latest C++ updates.

Table of Contents

Installation

The library is available on PyPI:

pip install dsf-suite

To check the installation you can simply run

import dsf

print(dsf.__version__)

Installation (from source)

Requirements

The project requires C++20 or greater, cmake, tbb simdjson, spdlog, csv-parser and SQLiteCpp. To install requirements on Ubuntu:

sudo apt install cmake libtbb-dev

To install requirements on macOS:

brew install cmake tbb

Installation (C++)

The library can be installed using CMake. To build and install the project in the default folder run:

cmake -B build -DCMAKE_BUILD_TYPE=Release && cmake --build build -j$(nproc)
sudo cmake --install build

Otherwise, it is possible to customize the installation path:

cmake -B build -DCMAKE_INSTALL_PREFIX=/path/to/install

then building and installing it (eventually in sudo mode) with:

cmake --build build
cmake --install build

Installation (Python)

If you want to use the library from Python, you can build the Python bindings using nanobind. Make sure you have tbb installed:

sudo apt install libtbb-dev

Then, the installation is automatic via uv:

uv build

or you can just use the classic pip:

pip install .

After installation, you should be able to import the module in Python:

import dsf

print(dsf.__version__)

If you encounter issues, ensure that the installation path is in your PYTHONPATH environment variable.

Examples

Examples in this repository are (slowly) being deprecated. You can build them by adding the cmake flag -DDSF_EXAMPLES=ON and you will find the exectuables under the examples folder. You can also find some Python examples.

New examples are being updated on dsf-examples.

GUI

If you need a visualization tool there is one available on dsf-gui. It is still in alpha stage but is already useful for some purposes.

For Developers

This project as a pre-commit configuration. To use it properly, please install:

pip install pre-commit
pre-commit install

Testing

This project uses Doctest for testing.

If the project is compiled in Debug or Coverage mode, tests are always built. Otherwise, you can add the -DDSF_TESTS=ON flag to enable test build.

cmake -B build -DDSF_TESTS=ON
cmake --build build -j$(nproc)

To run the tests use the command:

ctest --test-dir build -j$(nproc) --output-on-failure

Benchmarking

Some functionalities of the library have been benchmarked in order to assess their efficiency.
The benchmarks are performed using Google Benchmarks.

To build the benchmarks add the flag -DDSF_BENCHMARKS=ON :

cmake -B build -DDSF_BENCHMARKS=ON
cmake --build build -j$(nproc)

To run all the benchmarks together use the command:

cd benchmark
for f in ./*.out ; do ./$f ; done

Citing

@software{berselli_2026_18745492,
  author       = {Berselli, Gregorio},
  title        = {DynamicalSystemFramework},
  month        = mar,
  year         = 2026,
  publisher    = {Zenodo},
  doi          = {10.5281/zenodo.18745492},
  url          = {https://doi.org/10.5281/zenodo.18745492},
}

Bibliography

  • Mungai, Veronica (2024) Studio dell'ottimizzazione di una rete semaforica. University of Bologna, Bachelor's Degree in Physics [L-DM270]. Link to Thesis.
  • Berselli, Gregorio (2024) Advanced queuing traffic model for accurate congestion forecasting and management. University of Bologna, Master's Degree in Physics [LM-DM270]. Link to Thesis.
  • Berselli, Gregorio (2022) Modelli di traffico per la formazione della congestione su una rete stradale. University of Bologna, Bachelor's Degree in Physics [L-DM270]. Link to Thesis.

Metadata

Release files for dsf-suite 7.2.6

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

Source distribution (sdist)

Source distribution for dsf-suite 7.2.6
File Size Uploaded
dsf_suite-7.2.6.tar.gz 186.8 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for dsf-suite 7.2.6
File
dsf_suite-7.2.6-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
dsf_suite-7.2.6-cp314-cp314-manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.28+ x86-64 Details
dsf_suite-7.2.6-cp314-cp314-macosx_26_0_arm64.whl CPython 3.14 CPython 3.14 macOS 26.0+ ARM64 Details
dsf_suite-7.2.6-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
dsf_suite-7.2.6-cp313-cp313-manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ x86-64 Details
dsf_suite-7.2.6-cp313-cp313-macosx_26_0_arm64.whl CPython 3.13 CPython 3.13 macOS 26.0+ ARM64 Details
dsf_suite-7.2.6-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
dsf_suite-7.2.6-cp312-cp312-manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.28+ x86-64 Details
dsf_suite-7.2.6-cp312-cp312-macosx_26_0_arm64.whl CPython 3.12 CPython 3.12 macOS 26.0+ ARM64 Details

Total release size: 16.4 MB

Release files / dsf_suite-7.2.6.tar.gz

Download URL dsf_suite-7.2.6.tar.gz
Size 186.8 kB
Tags Source
SHA-256 checksum
How to use checksums
c1f6507eb8c125a2d6ebb7154f3a20e50174e1dd3750c042c641839d8a15f59a
BLAKE2b-256 checksum
How to use checksums
ffa2493811aeddd97baf204b78d2a0af9ab8e51196ae1e14097705d4c6f39244
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp314-cp314-win_amd64.whl

Download URL dsf_suite-7.2.6-cp314-cp314-win_amd64.whl
Size 1.6 MB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
02f9071b9c92aa92746af385bb684fd71676192a13150ce1e40c89c62aeaac5b
BLAKE2b-256 checksum
How to use checksums
9337f2d4c226782cb41115ed645e9fad4e422bcab44aa0761c8df4b73f92ce2d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp314-cp314-manylinux_2_28_x86_64.whl

Download URL dsf_suite-7.2.6-cp314-cp314-manylinux_2_28_x86_64.whl
Size 2.2 MB
Tags CPython 3.14 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
8cae8fa76d3b9a960f2714fcabadda0b956a73115272c83b5391f92a1ba4e08b
BLAKE2b-256 checksum
How to use checksums
5bc7de851e0811aa523d8e8b121c85db9837cef207202c5b47ce04f4dc3fdf95
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp314-cp314-macosx_26_0_arm64.whl

Download URL dsf_suite-7.2.6-cp314-cp314-macosx_26_0_arm64.whl
Size 1.6 MB
Tags CPython 3.14 macOS 26.0+ ARM64
SHA-256 checksum
How to use checksums
299ec70dc6667ad32e783f0b7e5cbb95d56c82da3fd11a322b1ff9ea0a75bda3
BLAKE2b-256 checksum
How to use checksums
8da9f3cfe5c36853791982e7b8cb0a6ab3c5537da11d853d91ec33cda8206a94
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp313-cp313-win_amd64.whl

Download URL dsf_suite-7.2.6-cp313-cp313-win_amd64.whl
Size 1.6 MB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
282af2df3e475b06cee916fec7cbe3740f9bfb5878b5f7bddea4929adbb1081c
BLAKE2b-256 checksum
How to use checksums
cecac7ec23be53110b5203f5c5199a6dbb0dddf31f72fe2213741947137637f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp313-cp313-manylinux_2_28_x86_64.whl

Download URL dsf_suite-7.2.6-cp313-cp313-manylinux_2_28_x86_64.whl
Size 2.2 MB
Tags CPython 3.13 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
acd3cd59b46b2fe8ca9053078a28be00b29917acc0319b886053f9a8e1b378fd
BLAKE2b-256 checksum
How to use checksums
52412e076a408a6aa59c2e977146469b24319c5196618f2fedd4cf2f03bc71d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp313-cp313-macosx_26_0_arm64.whl

Download URL dsf_suite-7.2.6-cp313-cp313-macosx_26_0_arm64.whl
Size 1.6 MB
Tags CPython 3.13 macOS 26.0+ ARM64
SHA-256 checksum
How to use checksums
eee6ed812180c0905011c04b13cac7e20780c9298c1944b61ef28aba18b51194
BLAKE2b-256 checksum
How to use checksums
6a6caa15b2a7701d6354cf8575c0eb7b9cce0509a397cc0c18fd1e0b2fb53055
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp312-cp312-win_amd64.whl

Download URL dsf_suite-7.2.6-cp312-cp312-win_amd64.whl
Size 1.6 MB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
d47f6e51d745719436bea47e65e87197b736b0e12c1688f4754ba79ab08981a2
BLAKE2b-256 checksum
How to use checksums
a9610d3842009466401257773cbd5aff379af8e6d334394ad8638c6b6e0aa23f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp312-cp312-manylinux_2_28_x86_64.whl

Download URL dsf_suite-7.2.6-cp312-cp312-manylinux_2_28_x86_64.whl
Size 2.2 MB
Tags CPython 3.12 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
b612ba6852beb2ab64c66c54947fb85a4343f07ad7fa0b151a9f5eeb724764bc
BLAKE2b-256 checksum
How to use checksums
d64daf3386d0d7e07fd51116530562f05e6314b1011599afb94a776eb4f000e1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / dsf_suite-7.2.6-cp312-cp312-macosx_26_0_arm64.whl

Download URL dsf_suite-7.2.6-cp312-cp312-macosx_26_0_arm64.whl
Size 1.6 MB
Tags CPython 3.12 macOS 26.0+ ARM64
SHA-256 checksum
How to use checksums
eadd37e330acb4f2c831eaec851232bfa449ca3f0b120fed52cb838fe7889c88
BLAKE2b-256 checksum
How to use checksums
35ee38a0d29de9a0d101919bf2838c783372213f0317f45f5e94cad9f24d37d7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release history Release notifications | RSS feed

7.3.2

10 release files

7.3.1

10 release files

7.3.0

10 release files

7.2.9

10 release files

7.2.8

10 release files

7.2.7

10 release files

This release

7.2.6 This release

10 release files

7.2.5

10 release files

7.2.4

10 release files

7.2.3

10 release files

7.2.2

10 release files

7.2.1

10 release files

7.2.0

10 release files

7.1.0

10 release files

7.0.4

10 release files

7.0.3

10 release files

7.0.2

10 release files

7.0.1

10 release files

6.7.0

10 release files

6.6.3

10 release files

6.6.2

10 release files

6.6.1

10 release files

6.6.0

10 release files

6.5.7

10 release files

6.5.6

10 release files

6.5.5

10 release files

6.5.4

10 release files

6.3.2

10 release files

6.3.1

10 release files

6.2.5

10 release files

6.2.4

10 release files

6.2.3

10 release files

6.2.2

10 release files

6.2.1

10 release files

6.2.0

10 release files

6.0.9

10 release files

6.0.8

13 release files

6.0.7

13 release files

6.0.5

9 release files

6.0.4

9 release files

6.0.3

9 release files

6.0.2

9 release files

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