5

Python Library for EnergyPlus Runtime Language (ERL)

Hello, I am a complete NOOB on EnergyPlus (E+). I just started looking into it and have spent only 2 days learning the E+ with some tutorials mentioned in the documentation. My goal is to simulate a custom PID controller for the underfloor heating system on a residential building.

From the tutorials, I understand how I can create .IDF file and simulate them with the WeatherData using DOS commands. I also checked that I can use Eppy (Python Library, https://eppy.readthedocs.io) to create/edit/start simulation for E+.

I found (from the documentation) that I can create custom controllers using ERL. I am wondering if there is any Python Library for running ERL from Python itself? It can be either Python v3 or Python v2.

P.S - I haven't read the ERL documentation fully yet.

Tanay's avatar
181
Tanay
asked 2019-04-09 02:13:57 -0500
__AmirRoth__'s avatar
4.4k
__AmirRoth__
updated 2019-04-09 15:45:06 -0500
edit flag offensive 0 remove flag close merge delete

Comments

Hi Tanay, I am also in a similar condition like you were two years ago. I am a complete beginner in E+ and can comfortably work with Python. I am not sure if you did manage to get a workaround of ERL based on any Python Library. My objective is to customize a few thermal setpoint strategy and HVAC sizing for building simulation without using E+, solely using Python.

Let me know if you have some useful tips.

Best, Debayan

Debayan93's avatar Debayan93 (2021-09-09 09:39:05 -0500) edit

@Debayan93 The Python EMS API is now available, https://energyplus.readthedocs.io/en/..., version 0.2. I am using this currently to control zone thermostat setpoints during runtime. If you want to see some example code check out my GitHub project https://github.com/mechyai/RL-BCA. Though, it is still very much a work in progress and documentation is out of date, but it is working for me currently. Some tests scripts and my EmsPy files/class may be useful to you.

mechyai's avatar mechyai (2021-09-09 09:49:14 -0500) edit
add a comment see more comments

1 Answer

12

First, welcome to EnergyPlus. I'm glad you started with the tutorials, and your goal seems interesting and very much doable with EnergyPlus. You can definitely create IDFs and run them from the command line, or you can use a variety of tools to generate/modify the IDFs and run the files from a GUI.

As for a Python-based EMS, there isn't anything right now, but we (the core EnergyPlus development team) are currently developing a Python-EMS implementation in EnergyPlus. It will be completed in a future release, as it is still early in the design phase. I would suggest continuing with raw ERL if you are already getting comfortable with it, though I know some interfaces have also adopted at least minimal EMS functionality right into the interface.

Good luck

Edwin's avatar
1.4k
Edwin
answered 2019-04-09 12:35:27 -0500
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments