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 pybind11. 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.

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.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dsf_suite-6.4.0.tar.gz (173.7 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

dsf_suite-6.4.0-cp314-cp314-win_amd64.whl (1.7 MB view details)

Uploaded CPython 3.14Windows x86-64

dsf_suite-6.4.0-cp314-cp314-manylinux_2_28_x86_64.whl (2.3 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ x86-64

dsf_suite-6.4.0-cp314-cp314-macosx_26_0_arm64.whl (1.6 MB view details)

Uploaded CPython 3.14macOS 26.0+ ARM64

dsf_suite-6.4.0-cp313-cp313-win_amd64.whl (1.7 MB view details)

Uploaded CPython 3.13Windows x86-64

dsf_suite-6.4.0-cp313-cp313-manylinux_2_28_x86_64.whl (2.3 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

dsf_suite-6.4.0-cp313-cp313-macosx_26_0_arm64.whl (1.6 MB view details)

Uploaded CPython 3.13macOS 26.0+ ARM64

dsf_suite-6.4.0-cp312-cp312-win_amd64.whl (1.7 MB view details)

Uploaded CPython 3.12Windows x86-64

dsf_suite-6.4.0-cp312-cp312-manylinux_2_28_x86_64.whl (2.3 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

dsf_suite-6.4.0-cp312-cp312-macosx_26_0_arm64.whl (1.6 MB view details)

Uploaded CPython 3.12macOS 26.0+ ARM64

File details

Details for the file dsf_suite-6.4.0.tar.gz.

File metadata

  • Download URL: dsf_suite-6.4.0.tar.gz
  • Upload date:
  • Size: 173.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for dsf_suite-6.4.0.tar.gz
Algorithm Hash digest
SHA256 2c6d147f802b2729b5e346a7f47afda057d9f0058a7584e665482be0a6045874
MD5 1483bd6e5c295d74043fbe862fbad249
BLAKE2b-256 4d852a189ee2a063153b50b45820e4229c8b812ceb7bbaabe0bab69680c3ef04

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: dsf_suite-6.4.0-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 1.7 MB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for dsf_suite-6.4.0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 788be1dd55de331f8586f1fff4861f017a656f4fba27d4fd9ee397b56c2f117e
MD5 b14ca380e9e70a1e30d541052805922a
BLAKE2b-256 85cd0de45f915a3de859e033b7f31b3253e85cd340c15e69759f5c00e79d6f3a

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp314-cp314-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dsf_suite-6.4.0-cp314-cp314-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b3406b233c50e3dbb11c1d0873612649ba3b21efe55d00f28442632e2ba105fd
MD5 5fa43c7ba6ea2b0c429501ddae23acc1
BLAKE2b-256 f000a6777930e331a95f8c8540ea8141c9fd7a82fc5182c275b256ac8e5695b4

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp314-cp314-macosx_26_0_arm64.whl.

File metadata

File hashes

Hashes for dsf_suite-6.4.0-cp314-cp314-macosx_26_0_arm64.whl
Algorithm Hash digest
SHA256 d323a1d1e2d0e30535dbf4b146201c13c008675eb9b1c7c10ffc4c631df22002
MD5 af3efa48d070b8c3b06ac348846cc8f3
BLAKE2b-256 090fb8c3e2d7ea68eed47e9f5460f10c67613a7eb3eceecab73bd1d2188ae853

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: dsf_suite-6.4.0-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 1.7 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for dsf_suite-6.4.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 754e0e9cc82c2e55b2f21e7d875915a41354a426c223e9dbac24449ae0a950d2
MD5 a069c32843ad47cc9f1c7040ce89fe7e
BLAKE2b-256 0edee3bcccb1749e31adc033407ff4eba5936f7b2651260b2d01d4ddc22590ac

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dsf_suite-6.4.0-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 6767ebd13441abd9d00841531740aeed7b58a198446ab3eb243d9db44fd4e04b
MD5 e43e010408cb02a89c8e965424dbdf8d
BLAKE2b-256 9e6db029324e4e7c0631267041e78c04397fe6f6c90dcfeb50dee793620cc568

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp313-cp313-macosx_26_0_arm64.whl.

File metadata

File hashes

Hashes for dsf_suite-6.4.0-cp313-cp313-macosx_26_0_arm64.whl
Algorithm Hash digest
SHA256 508b48111a867e3fa9a5a64e4cfff7608eaf41ce005975eb77839346fda4e564
MD5 bccc39ff63a5249fcac361dc19696de6
BLAKE2b-256 a5d3573434375586a1416848642be3a857668d12f6e281c68196432ba938e046

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: dsf_suite-6.4.0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 1.7 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for dsf_suite-6.4.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 f7ae6203d466ec73dd2b42e5b67e83b684c4ecb14500bcfc8a12e44f750949e2
MD5 0c64fca1e799187c374c98b23c5e19af
BLAKE2b-256 ba0f70f20dfe18b87ff0cf64184b7bc022755a1ce1a44c8eaabf31eaa5f91272

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dsf_suite-6.4.0-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 4cb29ce0f8fcb8e119b7f92b6f698be10507c7bb2165ba672e711b25b4fd5749
MD5 8f228628e2de39cf38b6e5f837fda9c6
BLAKE2b-256 a3fc7e09e7f92cc5153440877f6a72300464693ee8f86123b7838187c02b6030

See more details on using hashes here.

File details

Details for the file dsf_suite-6.4.0-cp312-cp312-macosx_26_0_arm64.whl.

File metadata

File hashes

Hashes for dsf_suite-6.4.0-cp312-cp312-macosx_26_0_arm64.whl
Algorithm Hash digest
SHA256 f54a5ff839bf684daad0e8585889c6808993c3f1289be0fd9427fdec488542d9
MD5 85f1f6e3e5f431f4b22b1e71103c1e76
BLAKE2b-256 c0b5fd41c20818f48c3e02df4fba13633f55361ad19b1185c5d13db9d41407d0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page