pytrnsys simulation framework
Project description
pytrnsys: The python TRNSYS tool kit
The pytrnsys package provides a complete framework to run and process, plot and report TRNSYS simulations. It is designed to give researchers a fast, fully automatized and easily reproducible way to execute and share TRNSYS simulations by the use of a single short configuration file. In addition, a large variety of commands is accessible to post-process simulation results in one shot.
Documentation
The documentation can be found on pytrnsys.readthedocs.io.
Installation
In the following all commands should be run from the pytrnsys
directory. The command should be run in a
"Windows Command Prompt" for Windows environment. The commands should be very similar should you wish to install on
Linux.
If you want to install pytrnsys as a python package, follow the "Binary installation / User installation". If you want to develop the code, you will need git. Then you should follow the "Installation from source / Developer installation".
Binary installation / User installation
Prerequisites
Required
Getting started
-
Open a command prompt (e.g. by hitting the Windows-key, then typing "cmd" into the search box and hitting enter). The following commands should be entered into the command prompt just opened.
-
Navigate to the directory which should contain the
pytrnsys
directory:cd [your-directory]
Replace
[your-directory]
(including the brackets []) with your directory of choice: if your directory is calledfoo
thenpytrnsys
will be installed tofoo\pytrnsys
. -
Create a virtual environment:
py -3.9 -m venv pytrnsys
-
Activate it:
pytrnsys\Scripts\activate
-
Install the
wheel
package:pip install wheel
-
Install
pytrnsys
and its requirements:pip install -r https://raw.githubusercontent.com/SPF-OST/pytrnsys/master/requirements/releases/v0.5a10/requirements.txt
You can now close the command prompt opened in the first step.
pytrnsys can now be used from a python editor of your choice within the virtual environment you created.
Installation from source / Developer installation
Prerequisites
Required
- Python 3.9
- A local clone of the following GIT repository:
https://github.com/SPF-OST/pytrnsys.git
Recommended
Getting started
All the following commands should be run from the pytrnsys
directory. The commands
specified are for a Windows environment. They are very similar for Linux.
- Create a virtual environment:
py -3.9 -m venv venv
- Activate it:
venv\Scripts\activate
- Install the requirements:
pip install wheel pip install -r requirements\dev\requirements.txt
And you're ready to go!
Beware that pytrnsys
can only be run from within the virtual environment you created in
step 1, i.e., whenever you open a new console window from which you want to run it you
first need to active the environment (step 2. above).
About
This code was not initially developed with the intention to be shared with others outside our institute SPF, but after realizing that it could help the community to have a better workflow with TRNSYS, we decided to share it.
Developers:
- Daniel Carbonell : Institut für Solartechnik SPF, Rapperswil, Switzerland.
- Jeremias Schmidli : Institut für Solartechnik SPF, Rapperswil, Switzerland.
- Maike Schubert: Institut für Solartechnik SPF, Rapperswil, Switzerland.
- Martin Neugebauer: Institut für Solartechnik SPF, Rapperswil, Switzerland.
- Mattia Battaglia : Institut für Solartechnik SPF, Rapperswil, Switzerland.
Acknowledgements
A first version of this package was created in 2013 and since then it has evolved considerably. We would like to thank the Swiss Federal Office Of Energy (SFOE) who supported many projects related to simulations of renewable energy systems where this code has been developed. We would also like to thank the European Union’s Horizon 2020 research and innovation programme for the funding received in TRI-HP under the Grant Agreement No. 81488. This project allowed to decicate efforts in sharing the code with the consortium and to make the code usable for the others.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for pytrnsys-0.5a10-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4bd1449e5c422c7bae0dc2cc3a78b634e336da85b9cbf678d51f3c6771a1aa2f |
|
MD5 | 3c36ad6a6c2d12ea116c5c865311e693 |
|
BLAKE2b-256 | 1c8a662e7b6af4757d811e0a1c7d6f63aceca4be7f645844b5654b71f96f7156 |