-
Notifications
You must be signed in to change notification settings - Fork 10
Simulation_Results
weilixu edited this page Jun 22, 2018
·
6 revisions
After a successful simulation, we then are facing to many different simulation results files: .err, .eso, .html and .rdd, etc.
How to quickly identify key results from so many files? That is the goal of Simulation Results class.
Result class is the gateway to connect with a model's information and simulation results. There are two methods to get a model's result class:
- Return from the simulation method
import BuildSimHubAPI as bsh_api
project_api_key = "7e140eec-b37f-4213-88b5f96c0065"
file_dir = "/Users/weilixu/Desktop/5ZoneAirCooled.epJSON"
wea_dir = "/Users/weilixu/Desktop/data/jsontest/in.epw"
# initialize the client
bsh = bsh_api.BuildSimHubAPIClient()
new_sj_run = bsh.new_simulation_job(project_api_key)
results = new_sj_run.run(file_dir, wea_dir, track=True)
if results:
print(str(results.net_site_eui()) + " " + results.last_parameter_unit)
"""Output
32.1 kBtu/ft2
"""- Retrieve a model results
import BuildSimHubAPI as bsh_api
project_api_key = "7e140eec-b37f-4213-8640-88b5f96c0065"
model_api_key = "96d21c84-d17f-41a2-1d09ca43736e"
# initialize the client
bsh = bsh_api.BuildSimHubAPIClient()
results = bsh.model_results(project_api_key, model_api_key)
if results:
print(str(results.net_site_eui()) + " " + results.last_parameter_unit)
"""Output
32.1 kBtu/ft2
"""This function opens local default browser to view the model's 3D geometry.
# if success the 3D viewer will be opened in the default web browser
results.bldg_geo()ddd
```python print(str(results.bldg_orientation()) # Output: 30 ```

