Skip to content

Commit

Permalink
fix(full): Add full steps
Browse files Browse the repository at this point in the history
  • Loading branch information
mikkelkp committed Nov 29, 2023
1 parent 6db940b commit dc378f9
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
19 changes: 19 additions & 0 deletions pollination/annual_daylight_enhanced/_post_process.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from pollination_dsl.dag import Inputs, GroupedDAG, task, Outputs
from pollination.honeybee_radiance_postprocess.post_process import AnnualDaylightMetrics
from pollination.honeybee_radiance_postprocess.post_process import GridSummaryMetrics
from pollination.honeybee_display.translate import ModelToVis


@dataclass
Expand Down Expand Up @@ -77,6 +78,24 @@ def grid_summary_metrics(
}
]

@task(template=ModelToVis, needs=[calculate_annual_metrics])
def create_vsf(
self, model=model,
grid_data=calculate_annual_metrics._outputs.annual_metrics,
active_grid_data='udi', output_format='vsf'
):
return [
{
'from': ModelToVis()._outputs.output_file,
'to': 'visualization.vsf'
}
]

visualization = Outputs.file(
source='visualization.vsf',
description='Annual daylight result visualization in VisualizationSet format.'
)

metrics = Outputs.folder(
source='metrics', description='metrics folder.'
)
Expand Down
14 changes: 14 additions & 0 deletions pollination/annual_daylight_enhanced/entry.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,13 +127,27 @@ def annual_metrics_postprocess(
{
'from': AnnualDaylightPostProcess()._outputs.grid_summary,
'to': 'grid_summary.csv'
},
{
'from': AnnualDaylightPostProcess()._outputs.visualization,
'to': 'visualization.vsf'
}
]

visualization = Outputs.file(
source='visualization.vsf',
description='Annual daylight result visualization in VisualizationSet format.'
)

metrics = Outputs.folder(
source='metrics', description='Annual metrics folder.'
)

results = Outputs.folder(
source='results', description='Folder with raw result files (.ill) that '
'contain illuminance matrices for each sensor at each timestep of the analysis.'
)

grid_summary = Outputs.file(
source='grid_summary.csv', description='Grid summary of metrics.',
alias=grid_metrics_results
Expand Down

0 comments on commit dc378f9

Please sign in to comment.