First time here? Check out the Help page!
1 | initial version |
Given that what you see when you run your test_pyems.py
is the result of energyplus --help
, I think your test_pyems.py
is calling api.runtime.run_energyplus
with incorrect arguments.
An example would be:
import sys
sys.path.insert(0, '/usr/local/EnergyPlus-9-4-0/')
from pyenergyplus.api import EnergyPlusAPI
api = EnergyPlusAPI()
state = api.state_manager.new_state()
# Register any callbacks
def callback_function(state_arguments):
pass
api.runtime.callback_begin_zone_timestep_after_init_heat_balance(state, callback_function)
api.runtime.run_energyplus(state,
[
'-w', '/usr/local/EnergyPlus-9-4-0/WeatherData/USA_CO_Golden-NREL.724666_TMY3.epw',
'-d', 'out',
'myfile.idf'
]
)
I have an example notebook on Github on jmarrec/OpenStudio_to_EnergyPlusAPI, and you can find a few on the E+ repo in tst/EnergyPlus/api
, for example tst/EnergyPlus/api/TestRuntime.py