Application guide or cheat sheet for Python module of Ladybug tools

Hi,

I have started using GH_CPython component to refer python libraries installed in system.

Recently, I wished to develop few custom components that use Eppy library to avail additional EnergyPlus strings related to EnergyManagementSystem objects for co-simulation in Rhino-Grasshopper.

However, I am unable to extract the EnergyPlus details such as name of the surface, construction name assigned to surface and so on from existing HoneyBee components directly.

I have installed lbt-Grasshopper, ladubug-grasshopper and other libraries but couldn’t use those in GH_CPython as I am unaware of functions aligned to the library.

Can anyone help me to provide a wayforward in the application of these libraries?

@Naga ,

I am going to assume that you are NOT referring to the legacy plugins here since the legacy plugins are more like a set of scripts that talk to one another and there isn’t a set of core python packages for them. Here is the current dependency tree of the ladybug tools core Python libraries, which the latest [+] plugins are using:


Note that this tree is constantly changing and may become outdated in the next few months

All of the libraries in this tree are built to run on both CPython >= 3.6 and IronPython 2.7 (the only exceptions are the 2 “schema” libraries, which require CPython but installing them doesn’t break things in ironpython). These core libraries have no dependencies on the Rhino SDK or anything that would tie them to a specific operating system. You can see in the lower-left of the image that the easiest way to get all of these core library packages is with the following command:

pip install lbt-dragonfly[cli] -U

All of the Ladybug Tools Python packages with the word “Grasshopper” in them (including lbt-grasshopper) contain purely Grasshopper user objects and their source code. They have dependencies on the core libraries and the Rhino SDK as does the ladybug-rhino Python package that they all use. You can think of this as a somewhat-separate dependency tree built on top of the core libraries like so:

From your question, it sounds like everything you want is in the core libraries so I recommend playing around with those for now.

2 Likes

Thank you soo much @chris. My intention is to develop & inculcate EMS plugins using GhCPython to avoid jumping between EnergyPlus IDF editor and Ladybug tools.

1 Like