honeybee-radiance-postprocess 0.4.209__tar.gz → 0.4.210__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/PKG-INFO +1 -1
  2. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/grid.py +23 -3
  3. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess.egg-info/PKG-INFO +1 -1
  4. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/CODE_OF_CONDUCT.md +0 -0
  5. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/CONTRIBUTING.md +0 -0
  6. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/LICENSE +0 -0
  7. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/MANIFEST.in +0 -0
  8. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/README.md +0 -0
  9. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/dev-requirements.txt +0 -0
  10. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/__init__.py +0 -0
  11. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/__main__.py +0 -0
  12. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/annual.py +0 -0
  13. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/annualdaylight.py +0 -0
  14. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/__init__.py +0 -0
  15. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/leed.py +0 -0
  16. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/mtxop.py +0 -0
  17. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/postprocess.py +0 -0
  18. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/schedule.py +0 -0
  19. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/translate.py +0 -0
  20. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/two_phase.py +0 -0
  21. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/cli/util.py +0 -0
  22. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/dynamic.py +0 -0
  23. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/electriclight.py +0 -0
  24. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/en17037.py +0 -0
  25. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/leed.py +0 -0
  26. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/metrics.py +0 -0
  27. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/reader.py +0 -0
  28. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/results.py +0 -0
  29. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/type_hints.py +0 -0
  30. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess/util.py +0 -0
  31. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess.egg-info/SOURCES.txt +0 -0
  32. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess.egg-info/dependency_links.txt +0 -0
  33. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess.egg-info/entry_points.txt +0 -0
  34. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess.egg-info/requires.txt +0 -0
  35. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/honeybee_radiance_postprocess.egg-info/top_level.txt +0 -0
  36. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/requirements.txt +0 -0
  37. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/setup.cfg +0 -0
  38. {honeybee-radiance-postprocess-0.4.209 → honeybee-radiance-postprocess-0.4.210}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: honeybee-radiance-postprocess
3
- Version: 0.4.209
3
+ Version: 0.4.210
4
4
  Summary: Postprocessing of Radiance results and matrices
5
5
  Home-page: https://github.com/ladybug-tools/honeybee-radiance-postprocess
6
6
  Author: Ladybug Tools
@@ -7,6 +7,7 @@ import numpy as np
7
7
  from pathlib import Path
8
8
 
9
9
  from honeybee_radiance_postprocess.reader import binary_to_array
10
+ from ..annualdaylight import _annual_daylight_vis_metadata
10
11
 
11
12
  _logger = logging.getLogger(__name__)
12
13
 
@@ -66,7 +67,13 @@ def merge_grid_folder(input_folder, output_folder, extension, dist_info):
66
67
  '. Alternatively, the command will look for a _redist_info.json file inside the '
67
68
  'folder.', type=click.Path(file_okay=True, dir_okay=False, resolve_path=True)
68
69
  )
69
- def merge_metrics_folder(input_folder, output_folder, dist_info):
70
+ @click.option(
71
+ '--grids-info', '-gi',
72
+ help='An optional input for grid information that will be copied to each '
73
+ 'metric folder. This file is usually called grids_info.json.',
74
+ type=click.Path(file_okay=True, dir_okay=False, resolve_path=True)
75
+ )
76
+ def merge_metrics_folder(input_folder, output_folder, dist_info, grids_info):
70
77
  """Restructure annual daylight metrics in a distributed folder.
71
78
 
72
79
  Since this command redistributes metrics it is expected that the input
@@ -81,6 +88,9 @@ def merge_metrics_folder(input_folder, output_folder, dist_info):
81
88
  # handle optional case for Functions input
82
89
  if dist_info and not Path(dist_info).is_file():
83
90
  dist_info = None
91
+ if grids_info:
92
+ with open(grids_info) as gi:
93
+ grids_info = json.load(gi)
84
94
  extension_mapper = {
85
95
  'da': 'da',
86
96
  'cda': 'cda',
@@ -88,12 +98,22 @@ def merge_metrics_folder(input_folder, output_folder, dist_info):
88
98
  'udi_lower': 'udi',
89
99
  'udi_upper': 'udi'
90
100
  }
101
+ metric_info_dict = _annual_daylight_vis_metadata()
91
102
  input_folder = Path(input_folder)
92
- for metric in ['da', 'cda', 'udi', 'udi_lower', 'udi_upper']:
93
- extension = extension_mapper[metric]
103
+ output_folder = Path(output_folder)
104
+ for metric, extension in extension_mapper.items():
94
105
  metric_folder = input_folder.joinpath(metric)
106
+ metric_out = output_folder.joinpath(metric)
95
107
  restore_original_distribution_metrics(
96
108
  metric_folder, output_folder, metric, extension, dist_info)
109
+
110
+ if grids_info:
111
+ info_file = metric_out.joinpath('grids_info.json')
112
+ info_file.write_text(json.dumps(grids_info))
113
+
114
+ vis_data = metric_info_dict[metric]
115
+ vis_metadata_file = metric_out.joinpath('vis_metadata.json')
116
+ vis_metadata_file.write_text(json.dumps(vis_data, indent=4))
97
117
  except Exception:
98
118
  _logger.exception('Failed to restructure data from folder.')
99
119
  sys.exit(1)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: honeybee-radiance-postprocess
3
- Version: 0.4.209
3
+ Version: 0.4.210
4
4
  Summary: Postprocessing of Radiance results and matrices
5
5
  Home-page: https://github.com/ladybug-tools/honeybee-radiance-postprocess
6
6
  Author: Ladybug Tools