Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
5

Python Library for EnergyPlus Runtime Language (ERL)

asked 2019-04-09 02:13:57 -0600

Tanay's avatar

updated 2019-04-09 15:45:06 -0600

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.

edit retag flag offensive 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 -0600 )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 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
12

answered 2019-04-09 12:35:27 -0600

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

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Training Workshops

Careers

Question Tools

1 follower

Stats

Asked: 2019-04-09 02:13:57 -0600

Seen: 847 times

Last updated: Apr 09 '19