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

pyenergyplus.api define weather

asked 2024-01-21 13:47:31 -0600

oprislan's avatar

updated 2024-01-22 16:25:03 -0600

Hello,

I'm really lost and need your help. I installed pyenergyplus.api / NBNL V 23.2 and try to run a simple idf file as a test. The run throws an error eplusout.err, that I didn't specify a weather.epw file. I tried chatGPT, but it refers to a IDF and Weather class in energyplus.api which aren't ther in the 23.2 version ...

  1. can you guide me to a detailed API description for version 23.2?
  2. can you provide a running example?

Thank you

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2024-01-22 01:43:04 -0600

hermmanhender's avatar

Hi! Can you share the Python script to see the problem?

You need to add two entries in the api.runtime.run_energyplus, the first one is an state that you need to create as:

state = api.state_manager.new_state()

And the second one is a list with five elements. Two of them are always the same ('d' and 'w') and the other three are the paths into your output directory, epw file and IDF/epjson file:

run_energyplus( state, ‘-d’, ‘/path/to/output/directory’, ‘-w’, ‘/path/to/weather.epw’, ‘/path/to/input.idf’ ] )

I hope that this help you!

edit flag offensive delete link more

Comments

It doesn't take a list of 5 elements. it takes state, and a list of command line args: https://energyplus.readthedocs.io/en/...

run_energyplus(state, ["-r", "-x", "-d", "ouput_dir/", "-w", "in.epw", "in.idf"])

See energyplus --help in a terminal to see what arguments you want to pass

Julien Marrec's avatar Julien Marrec  ( 2024-01-22 02:36:51 -0600 )edit

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: 2024-01-21 13:47:31 -0600

Seen: 91 times

Last updated: Jan 22