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.

Release files for dsf-suite 7.2.3

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.3
File Size Uploaded
dsf_suite-7.2.3.tar.gz 184.8 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for dsf-suite 7.2.3
File
dsf_suite-7.2.3-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
dsf_suite-7.2.3-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.3-cp314-cp314-macosx_26_0_arm64.whl CPython 3.14 CPython 3.14 macOS 26.0+ ARM64 Details
dsf_suite-7.2.3-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
dsf_suite-7.2.3-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.3-cp313-cp313-macosx_26_0_arm64.whl CPython 3.13 CPython 3.13 macOS 26.0+ ARM64 Details
dsf_suite-7.2.3-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
dsf_suite-7.2.3-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.3-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.3.tar.gz

Download URL dsf_suite-7.2.3.tar.gz
Size 184.8 kB
Tags Source
SHA-256 checksum
How to use checksums
dc9a255e6e95b3162af3b125bde3916d72704645e4d67d9978c99786b13fa189
BLAKE2b-256 checksum
How to use checksums
0a8f440990eccbbe063dc9ee37fc0478fe963993c1f89f19770be6a4010011f3
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.3-cp314-cp314-win_amd64.whl

Download URL dsf_suite-7.2.3-cp314-cp314-win_amd64.whl
Size 1.6 MB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
fa116aa0535a973e5878180c895062f5d4101805d06dbc9a4a3508d9d51a0f4e
BLAKE2b-256 checksum
How to use checksums
e2d1c1d7e6f25e500f5e07a5ac2dca6b2e1ddd141a80d8c68b573943dd8c4545
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.3-cp314-cp314-manylinux_2_28_x86_64.whl

Download URL dsf_suite-7.2.3-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
7a31a43fef24bd960c3d44bbdd42641f72d21b578597dae061c7d274335a89cc
BLAKE2b-256 checksum
How to use checksums
fc778208122427a27e679bd3de0bae3ec67f47dd17e9a8b880049a4460555466
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.3-cp314-cp314-macosx_26_0_arm64.whl

Download URL dsf_suite-7.2.3-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
542f7b4805d6f551d085b3b944ce50672ec30e14419871122c53a1049cad9f69
BLAKE2b-256 checksum
How to use checksums
119d54b17cea7eb9d364fdabcbc4e88d4ef973d1dc20523436043527a2c20fbe
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.3-cp313-cp313-win_amd64.whl

Download URL dsf_suite-7.2.3-cp313-cp313-win_amd64.whl
Size 1.6 MB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
1493e210249083c04a6b2ee24403aef81f449ed2f7507b6edf2fa92c30f81f37
BLAKE2b-256 checksum
How to use checksums
6b489ecb0489d24e37160abe8db96b1c49a7df3fa800da279a77433b47b8ef43
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.3-cp313-cp313-manylinux_2_28_x86_64.whl

Download URL dsf_suite-7.2.3-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
6cdddc62b6c97c1c1148098e81957d72407f7f112c88e24728d9a784baec2c95
BLAKE2b-256 checksum
How to use checksums
ef0a162471bab61be482522cf5f909f2d1c239e8b4a914bd3a9c5a84c4555fdd
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.3-cp313-cp313-macosx_26_0_arm64.whl

Download URL dsf_suite-7.2.3-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
551240cfa792fc4735cfc6d0f8b9b1783cdaa1f9ae0a7d506dbd000efcafe100
BLAKE2b-256 checksum
How to use checksums
cf134f24202f3bbe03c3d6d79de1a6229648a467ded98e25d55d8682f82bf462
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.3-cp312-cp312-win_amd64.whl

Download URL dsf_suite-7.2.3-cp312-cp312-win_amd64.whl
Size 1.6 MB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
efda4a110e5b7c241b09b7049721c7142094cecf5e19c94d7a7da016bf77bc77
BLAKE2b-256 checksum
How to use checksums
5abfe8a517f014fca40e90a9a1ad39d39831bdb7c60eaf58a32d80a1a77737a8
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.3-cp312-cp312-manylinux_2_28_x86_64.whl

Download URL dsf_suite-7.2.3-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
33c60732155d2779aa0c7e1bfe74e4152c3a2a90c14f565a1ca0963eeaaa51a1
BLAKE2b-256 checksum
How to use checksums
a5ed076dd0d0994e51d8d7bedec017b72baddba2d186ad3ca20705d15df480ac
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.3-cp312-cp312-macosx_26_0_arm64.whl

Download URL dsf_suite-7.2.3-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
3652d085bf16e1ffd66887117e7080ba67ae65338c9a268c78fc4422b33fd997
BLAKE2b-256 checksum
How to use checksums
4f5ee8a4b50bcc5ac6cce2d8a5d52c2a2b3e0dec7e1398ed8f5a694a87917a7e
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.2.5

10 release files

7.2.4

10 release files

This release

7.2.3 This release

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