Skip to content

A Python library to read and manipulate RSCAD draft files.

License

LGPL-3.0, GPL-3.0 licenses found

Licenses found

LGPL-3.0
COPYING.LESSER
GPL-3.0
COPYING
Notifications You must be signed in to change notification settings

KIT-IAI/PyAPI-RTS

Repository files navigation

PyAPI-RTS

A Python library to read and manipulate RSCAD draft files.

See examples/simple_example/simple_example.ipynb for a short preview of the API or take a look into our documentation.

Installation

To install this project, perform the following steps:

  1. Clone the project
  2. cd into the cloned directory
  3. pip install poetry
  4. poetry install

Generate classes from RSCAD components

Before the first use of the project, the classes for the components in the RSCAD master library need to be generated.

  1. Copy the files from the COMPONENTS directory into pyapi_rts/pyapi_rts/class_extractor/COMPONENTS.

  2. Run poetry run python ./pyapi_rts/class_extractor/main.py

Other options for the class generation:

  • -d: Set to delete the output folder before new classes are generated
  • -o: Set to include the OBSOLETE folder in the generation. Recommended if you use .dfx files converted from older versions
  • -p: Set path to COMPONENTS folder
  • -t: Set thread count used to parse the files. Default: 8

! The progress bar is not accurate due to optimizations applied during generation.

Run tests

poetry run pytest

Citing

M. Weber, J. Enzinger, H. K. Çakmak, U. Kühnapfel and V. Hagenmeyer, "PyAPI-RTS: A Python-API for RSCAD Modeling," 2023 Open Source Modelling and Simulation of Energy Systems (OSMSES), Aachen, Germany, 2023, pp. 1-7, doi: 10.1109/OSMSES58477.2023.10089671.

About

A Python library to read and manipulate RSCAD draft files.

Topics

Resources

License

LGPL-3.0, GPL-3.0 licenses found

Licenses found

LGPL-3.0
COPYING.LESSER
GPL-3.0
COPYING

Stars

Watchers

Forks

Languages