A set of helper classes, functions and demos, for interacting with the EnergyPlus Python API
Project description
EnergyPlus API Helper Scripts
This project is a small library of helper functionality and, more importantly, demo scripts, for interacting with the EnergyPlus API.
The EnergyPlus Python API is not on PyPi (as of now), it simply comes with the EnergyPlus installation.
This library makes that process a bit easier, and also offers a set of demos in the energyplus_api_helpers/demos
folder.
A super minimal example using the helper class here:
from pathlib import Path
from energyplus_api_helpers.import_helper import EPlusAPIHelper
helper = EPlusAPIHelper(Path('/path/to/EnergyPlus-22-2-0'))
api = helper.get_api_instance()
state = api.state_manager.new_state()
return_value = api.runtime.run_energyplus(state, ['-D', helper.path_to_test_file('5ZoneAirCooled.idf')])
In this example, the helper class is constructed simply by pointing it to a valid EnergyPlus install path (or build/Products directory for developers).
The helper class is then used to get an EnergyPlus API instance, which is in turn used to create a new EnergyPlus "state".
Finally, EnergyPlus is executed with some basic command line arguments passed into the run_energyplus
function of the main EnergyPlus API.
Code Quality
Code is checked for style using GitHub Actions.
Releases
When a release is tagged, a GitHub Action workflow will create a Python wheel and upload it to the PyPi server.
To install into an existing Python environment, execute pip install energyplus_api_helpers
Project details
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 energyplus_api_helpers-0.4.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | f5ee3c47b12d268f3fe55827abab691eadf1e4ec0000d3dd1ae2a1a0ea16f1aa |
|
MD5 | 9854d2712f57e5850985beb7f27a49de |
|
BLAKE2b-256 | 3f74cf1ecad471601a01c0dc996f7edd174fcf4340fe6da3066c3435ab669d3a |
Hashes for energyplus_api_helpers-0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 60c24c2e68ca0e513ca01770cc8671279458c6dda46cd18b919b16466b943642 |
|
MD5 | b9e302f474aedc658531bc51de52b88e |
|
BLAKE2b-256 | 2546ca6f8a377d0f80c66c3354489d59b1ee0360d1d887d50de0d2b6362c9f53 |