do-dpc

Framework software package for the Data-Driven Predictive Control (DPC) algorithm with visual examples.

https://github.com/do-dpc/do-dpc

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (18.1%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

Framework software package for the Data-Driven Predictive Control (DPC) algorithm with visual examples.

Basic Info
  • Host: GitHub
  • Owner: do-dpc
  • License: lgpl-3.0
  • Language: Python
  • Default Branch: main
  • Homepage:
  • Size: 2.97 MB
Statistics
  • Stars: 2
  • Watchers: 0
  • Forks: 2
  • Open Issues: 2
  • Releases: 0
Created 11 months ago · Last pushed 7 months ago
Metadata Files
Readme License Citation

README.md

Do DPC

Pipeline Status Documentation Status PyPI

The purpose of this code is to provide a Framework for Data-Driven Predictive Control (DPC) with illustrative examples.

Please visit the extensive documentation, kindly hosted on readthedocs.

Citing do-dpc

Please follow the instructions if you want to use do-dpc for published work.

Getting Started

This library utilizes the Mosek Solver. While it is possible to use any solver compatible with CVXPY, it is recommended to use Mosek for optimal performance. Please follow the installation instructions on the Mosek website to set it up.

To ensure a clean and isolated development environment, it is recommended to use Python's virtual environment (venv).

Linux / macOS

sh python3.12 -m venv venv source venv/bin/activate pip install -r requirements.txt

Windows

sh py -m venv venv .\venv\Scripts\activate pip install -r requirements.txt

Additional Tools: SWIG

The library boxd2 requires SWIG, the Simplified Wrapper and Interface Generator.
SWIG is a tool that connects programs written in C or C++ with high-level languages such as Python. It is necessary for building Python bindings to C/C++ code, which is how boxd2 exposes its functionality to Python.

Installing SWIG

Windows

  • Via Chocolatey (recommended): sh choco install swig
  • Manual download:
    Download the installer from swig.org/download.html and follow the installation instructions.

macOS

  • Via Homebrew: sh brew install swig

Linux (Debian/Ubuntu)

  • Via apt: sh sudo apt-get update sudo apt-get install swig

  • For other distributions, use the appropriate package manager (dnf, yum, pacman, etc.).

Example Usage

Once your environment is set up and dependencies installed, you can use boxd2 in your Python code:

```python import boxd2

Example: create a box and compute its area

box = boxd2.Box(2, 3) print("Area:", box.area()) ```


Note:
If you encounter build errors related to SWIG when installing or using boxd2, ensure that SWIG is correctly installed and available in your system's PATH.

Building the documentation

Navigate to the docs Folder:

shell cd docs

Create and activate a virtual environment:

sh python3.12 -m venv venv source venv/bin/activate pip install -r requirements.txt

Generate the documentation:

shell make html

Once the HTML files are created, you can serve them locally:

shell python -m http.server --directory build/html 8000

Open your browser and visit:

http://localhost:8000

Folder structure

The code contains the following files and folders:

do-dpc/ ├── do_dpc/ # Core Python source code for the DPC library │ ├── control_utils/ # Utilities for control systems (PID, noise generators, etc.) │ ├── dpc/ # Core DPC algorithms and implementations │ │ ├── dpc.py # Main DPC implementation │ │ ├── dpc_structs.py # Data structures for DPC │ ├── utils/ # General utility modules (logging, path management, etc.) ├── docs/ # Documentation files (Sphinx) │ ├── build/ # Build artifacts for generated documentation │ ├── source/ # Source files for documentation │ │ ├── _static/ # Static assets (images, CSS, etc.) │ │ ├── _templates/ # Templates for documentation structure │ │ ├── dpc_methods/ # Documentation for different DPC methods │ │ ├── getting_started/ # Guides and introductory documentation │ │ ├── conf.py # Sphinx configuration file │ │ ├── index.rst # Main entry point for documentation │ ├── .readthedocs.yaml # Configuration for Read the Docs │ ├── Makefile # Makefile for building the documentation │ ├── make.bat # Windows batch script for building documentation ├── tests/ # Test suite for the DPC library │ ├── fixtures/ # Pytest fixtures for setting up test cases │ ├── system_tests/ # System-level integration tests │ ├── unit_tests/ # Unit tests for individual modules ├── .gitlab-ci.yml # CI/CD pipeline configuration for GitLab ├── .pylintrc # Linter configuration for Python code ├── CITATION.cff # Citation file for academic references ├── confest.py # Pytest configuration file ├── LICENSE.txt # Licensing information ├── README.md ├── requirements.txt └── setup.py # Setup script for packaging and installation

Owner

  • Name: do-dpc
  • Login: do-dpc
  • Kind: organization

Citation (CITATION.cff)

# This CITATION.cff file was generated with cffinit.
# Visit https://bit.ly/cffinit to generate yours today!

# TODO

GitHub Events

Total
  • Create event: 6
  • Issues event: 1
  • Release event: 1
  • Watch event: 5
  • Delete event: 4
  • Issue comment event: 6
  • Push event: 22
  • Pull request review comment event: 3
  • Pull request review event: 6
  • Pull request event: 11
  • Fork event: 2
Last Year
  • Create event: 6
  • Issues event: 1
  • Release event: 1
  • Watch event: 5
  • Delete event: 4
  • Issue comment event: 6
  • Push event: 22
  • Pull request review comment event: 3
  • Pull request review event: 6
  • Pull request event: 11
  • Fork event: 2

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 12 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 1
  • Total maintainers: 1
pypi.org: do-dpc

Framework software package for the Data-Driven Predictive Control (DPC) algorithm with visual examples.

  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 12 Last month
Rankings
Dependent packages count: 9.2%
Forks count: 31.5%
Average: 31.7%
Stargazers count: 34.1%
Dependent repos count: 51.9%
Maintainers (1)
Last synced: 6 months ago