Having spent more hours than I care to imagine wading through EnergyPlus IDF files and writing custom Python scripts to do specific tasks, the work that has gone into writing Eppy is an absolute godsend. Little tweaks to IDF files that last week took half an hour to complete, today took five minutes. And that’s including looking how to use Eppy as I went along!

EnergyPlus IDF material objects

What is Eppy?

From the project’s tutorial page:

Eppy is a scripting language for EnergyPlus IDF files, and EnergyPlus output files. Eppy is written in the programming language Python. As a result it takes full advantage of the rich data structure and idioms that are available in python. You can programmatically navigate, search, and modify EnergyPlus idf files using eppy. The power of using a scripting language allows you to do the following:

  • Make a large number of changes in an idf file with a few lines of eppy code.
  • Use conditions and filters when making changes to an idf file
  • Make changes to multiple idf files.
  • Read data from the output files of a E+ simulation run.
  • Based to the results of a E+ simulation run, generate the input file for the next simulation run.
  • So what does this matter? Here are some of the things you can do with eppy:

  • Change construction for all north facing walls.
  • Change the glass type for all windows larger than 2 square meters.
  • Change the number of people in all the interior zones.
  • Change the lighting power in all south facing zones.
  • Change the efficiency and fan power of all rooftop units.
  • Find the energy use of all the models in a folder (or of models that were run after a certain date)
  • If a model is using more energy than expected, keep increasing the R-value of the roof until you get to the expected energy use.
  • That’s certainly got me excited. If it has you worked up too, then go check it out.

    Jamie Bull | mail@oco-carbon.com

    Related Posts

    IntroThis tutorial is intended as a walk-through for complete beginners to geomeppy. geomeppy is a python project built on top of eppy, and as the name implies, it adds much more geometry editing capabilities.At the end of the tutorial, you will have created and run an EnergyPlus model without once having to manually edit an […]

    Just a quick post to point out a couple of really useful tools.The first is a web-based tool for finding weather files for a location of interest. It’s similar to the Excel EPW finder tool we created a few years back, but much more modern looking. It is however missing a few of the useful […]

    Eppy is a really useful library which I’ve written about several times, since before I really had anything to offer in terms of contributing code. Over the past year or so though, I’ve started to contribute back some of the changes and additions I’ve made while using eppy on academic and commercial projects.This post is […]

    6 Comments on “Eppy – EnergyPlus scripting with Python”

    • Jaouad says:

      Hi, it’s seems to be very useful.
      However, I can’t install it.

      Does it work with python 2.7 or python 3?

      I have this problem when I try to install it

      from eppy import modeleditor
      Traceback :
      File “”,line 1, in
      File “C:\users\me\eppy-0.4.6\eppy\modeleditor.py”, line 44
      print round(abs(second-first), places)
      SyntaxError: invalid syntax

      Thanks for your answer

      • Jamie Bull says:

        Hi Jaouad. The library is written for Python 2.7 although they have plans for Python 3. Which are you using?

    • Javed Iqbal says:

      Hello Jamie,

      This is great!! I am very new to scripting but i understand the significance of basic scripting and due to this amount of time i can save. I really want to use Eppy scripting and take this to another level. I appreciate if you can list down the steps to run Python after installation to run basic script on IDF file.

      Thanks in advance,

      • Jamie Bull says:

        Hi Javed,

        Take a look at the documentation for Eppy. It gives a really thorough introduction to using Python as well as the capabilities of Eppy itself.


    • Javed Iqbal says:


      Which IDE is best to use for Python scripting for EnergyPlus??


      • Jamie Bull says:

        I use Eclipse with the PyDev plugin. I particularly like the Git integration for version tracking of models. It’s quite a steep learning curve though so you may find it to be more than you need. Are you using any IDE at the moment?

    Leave a Reply

    Your email address will not be published. Required fields are marked *