honeybee-radiance-postprocess 0.4.484__py2.py3-none-any.whl → 0.4.486__py2.py3-none-any.whl

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.
@@ -1,28 +1,14 @@
1
1
  """Functions for IES LM post-processing."""
2
2
  from typing import Tuple, Union
3
- from pathlib import Path
4
3
  from collections import defaultdict
5
- import json
6
4
  import itertools
7
5
  import numpy as np
8
6
 
9
- from ladybug.analysisperiod import AnalysisPeriod
10
- from ladybug.datatype.generic import GenericType
11
- from ladybug.color import Colorset
12
- from ladybug.datacollection import HourlyContinuousCollection
13
- from ladybug.datatype.fraction import Fraction
14
- from ladybug.datatype.time import Time
15
- from ladybug.legend import LegendParameters
16
- from ladybug.header import Header
17
- from honeybee.model import Model
18
- from honeybee.units import conversion_factor_to_meters
19
- from honeybee_radiance.writer import _filter_by_pattern
20
7
  from honeybee_radiance.postprocess.annual import filter_schedule_by_hours
21
8
 
22
- from ..metrics import da_array2d, ase_array2d
23
9
  from ..annual import schedule_to_hoys, occupancy_schedule_8_to_6
24
10
  from ..results.annual_daylight import AnnualDaylight
25
- from ..util import filter_array, recursive_dict_merge
11
+ from ..util import filter_array
26
12
  from ..dynamic import DynamicSchedule, ApertureGroupSchedule
27
13
  from .lm_schedule import shd_trans_schedule_descending, states_schedule_descending
28
14
 
@@ -123,8 +109,16 @@ def dynamic_schedule_direct_illuminance(
123
109
  shd_trans_dict = {}
124
110
 
125
111
  for grid_info in grids_info:
112
+ grid_states_schedule = defaultdict(list)
113
+
126
114
  grid_count = grid_info['count']
127
- light_paths = [lp[0] for lp in grid_info['light_path']]
115
+ light_paths = []
116
+ for lp in grid_info['light_path']:
117
+ for _lp in lp:
118
+ if _lp == '__static_apertures__' and len(lp) > 1:
119
+ pass
120
+ else:
121
+ light_paths.append(_lp)
128
122
 
129
123
  shade_transmittances, shd_trans_dict = (
130
124
  shade_transmittance_per_light_path(
@@ -186,11 +180,16 @@ def dynamic_schedule_direct_illuminance(
186
180
  max_indices = array_combinations_filter.argmax(axis=0)
187
181
  # select the combination for each hour
188
182
  combinations = [combinations[idx] for idx in max_indices]
183
+
189
184
  # merge the combinations of dicts
190
185
  for combination in combinations:
191
186
  for light_path, value in combination.items():
192
187
  if light_path != '__static_apertures__':
193
- states_schedule[light_path].append(value)
188
+ grid_states_schedule[light_path].append(value)
189
+
190
+ for key, value in grid_states_schedule.items():
191
+ if key not in states_schedule:
192
+ states_schedule[key] = value
194
193
 
195
194
  occupancy_hoys = schedule_to_hoys(schedule, results.sun_up_hours)
196
195
 
@@ -340,7 +340,13 @@ def leed_states_schedule(
340
340
 
341
341
  for grid_info in grids_info:
342
342
  grid_count = grid_info['count']
343
- light_paths = [lp[0] for lp in grid_info['light_path']]
343
+ light_paths = []
344
+ for lp in grid_info['light_path']:
345
+ for _lp in lp:
346
+ if _lp == '__static_apertures__' and len(lp) > 1:
347
+ pass
348
+ else:
349
+ light_paths.append(_lp)
344
350
 
345
351
  shade_transmittances, shd_trans_dict = (
346
352
  shade_transmittance_per_light_path(
@@ -525,7 +531,13 @@ def leed_option_one(
525
531
  pass_ase_grids = []
526
532
  ase_hr_pct = []
527
533
  for (grid_info, grid_area) in zip(grids_info, grid_areas):
528
- light_paths = [lp[0] for lp in grid_info['light_path']]
534
+ light_paths = []
535
+ for lp in grid_info['light_path']:
536
+ for _lp in lp:
537
+ if _lp == '__static_apertures__' and len(lp) > 1:
538
+ pass
539
+ else:
540
+ light_paths.append(_lp)
529
541
  arrays = []
530
542
  # combine direct array for all light paths
531
543
  for light_path in light_paths:
@@ -558,7 +570,13 @@ def leed_option_one(
558
570
  pass_sda_blinds_up_grids = []
559
571
  pass_sda_blinds_down_grids = []
560
572
  for grid_info in grids_info:
561
- light_paths = [lp[0] for lp in grid_info['light_path']]
573
+ light_paths = []
574
+ for lp in grid_info['light_path']:
575
+ for _lp in lp:
576
+ if _lp == '__static_apertures__' and len(lp) > 1:
577
+ pass
578
+ else:
579
+ light_paths.append(_lp)
562
580
  base_zero_array = np.apply_along_axis(filter_array, 1, np.zeros(
563
581
  (grid_info['count'], len(results.sun_up_hours))), occ_mask)
564
582
  arrays = [base_zero_array.copy()]
@@ -1188,7 +1188,13 @@ class Results(_ResultsFolder):
1188
1188
  Returns:
1189
1189
  dict: A filtered states dictionary.
1190
1190
  """
1191
- light_paths = [elem for lp in grid_info['light_path'] for elem in lp]
1191
+ light_paths = []
1192
+ for lp in grid_info['light_path']:
1193
+ for _lp in lp:
1194
+ if _lp == '__static_apertures__' and len(lp) > 1:
1195
+ pass
1196
+ else:
1197
+ light_paths.append(_lp)
1192
1198
  if states:
1193
1199
  states = states.filter_by_identifiers(light_paths)
1194
1200
  else:
@@ -1351,7 +1357,13 @@ class Results(_ResultsFolder):
1351
1357
  break
1352
1358
  else:
1353
1359
  raise Exception(f'Grid info with full_id "{grid_info}" not found.')
1354
- light_paths = [elem for lp in grid_info['light_path'] for elem in lp]
1360
+ light_paths = []
1361
+ for lp in grid_info['light_path']:
1362
+ for _lp in lp:
1363
+ if _lp == '__static_apertures__' and len(lp) > 1:
1364
+ pass
1365
+ else:
1366
+ light_paths.append(_lp)
1355
1367
 
1356
1368
  return light_paths
1357
1369
 
@@ -1,9 +1,7 @@
1
1
  """Functions for WELL post-processing."""
2
2
  from typing import Tuple, Union
3
3
  from pathlib import Path
4
- from collections import defaultdict
5
4
  import json
6
- import itertools
7
5
  import numpy as np
8
6
 
9
7
  from ladybug.analysisperiod import AnalysisPeriod
@@ -239,7 +237,13 @@ def well_annual_daylight(
239
237
  l01_pass_sda_blinds_up_grids = []
240
238
  l01_pass_sda_blinds_down_grids = []
241
239
  for grid_info in grids_info:
242
- light_paths = [lp[0] for lp in grid_info['light_path']]
240
+ light_paths = []
241
+ for lp in grid_info['light_path']:
242
+ for _lp in lp:
243
+ if _lp == '__static_apertures__' and len(lp) > 1:
244
+ pass
245
+ else:
246
+ light_paths.append(_lp)
243
247
  base_zero_array = np.apply_along_axis(filter_array, 1, np.zeros(
244
248
  (grid_info['count'], len(results.sun_up_hours))), occ_mask)
245
249
  arrays_blinds_up = [base_zero_array.copy()]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: honeybee-radiance-postprocess
3
- Version: 0.4.484
3
+ Version: 0.4.486
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
@@ -14,7 +14,7 @@ Classifier: Operating System :: OS Independent
14
14
  Description-Content-Type: text/markdown
15
15
  License-File: LICENSE
16
16
  Requires-Dist: honeybee-radiance==1.66.138
17
- Requires-Dist: numpy>=1.21.6
17
+ Requires-Dist: numpy<2.0.0
18
18
 
19
19
  [![Build Status](https://github.com/ladybug-tools/honeybee-radiance-postprocess/actions/workflows/ci.yaml/badge.svg)](https://github.com/ladybug-tools/honeybee-radiance-postprocess/actions)
20
20
  [![Coverage Status](https://coveralls.io/repos/github/ladybug-tools/honeybee-radiance-postprocess/badge.svg?branch=master)](https://coveralls.io/github/ladybug-tools/honeybee-radiance-postprocess)
@@ -31,20 +31,20 @@ honeybee_radiance_postprocess/cli/util.py,sha256=Be9cGmYhcV2W37ma6SgQPCWCpWLLLlr
31
31
  honeybee_radiance_postprocess/cli/viewfactor.py,sha256=kU36YRzLya5PReYREjTfw3zOcWKHYZjVlVclyuR7Cqk,5245
32
32
  honeybee_radiance_postprocess/cli/well.py,sha256=A4i5scnWWOOwZFfC9vg8bUV2lOOJfbOb-HP8zCZy_ic,1888
33
33
  honeybee_radiance_postprocess/ies/__init__.py,sha256=kQXElEqFnLGNnrMSpA51XDHoqBup849FHeAqWASIy6w,45
34
- honeybee_radiance_postprocess/ies/lm.py,sha256=kHvwd2uT8Y-c2TjpvQzjLrWzwgayWjpzpbwS2S6cEvo,9570
34
+ honeybee_radiance_postprocess/ies/lm.py,sha256=20o_W2b9PPAQBoENUSO1qyOAxE5sLsrshtxdprEmRE8,9350
35
35
  honeybee_radiance_postprocess/ies/lm_schedule.py,sha256=ci58GXq2PntJ4yNUdI_x4UCRmq6KrLes-u7GeboX058,9954
36
36
  honeybee_radiance_postprocess/leed/__init__.py,sha256=kQXElEqFnLGNnrMSpA51XDHoqBup849FHeAqWASIy6w,45
37
- honeybee_radiance_postprocess/leed/leed.py,sha256=pZyVmHEL_T3MG5Mu7CQh9Y0Ku2wOJsv6UpNAn5J15uU,33457
37
+ honeybee_radiance_postprocess/leed/leed.py,sha256=od7ooRncPypk1eeCvVKx4IPaCMCDJEtE1FlcbsQJlcs,34021
38
38
  honeybee_radiance_postprocess/leed/leed_schedule.py,sha256=s3by1sv1DtOlCawvaMvnIDvEo5D8ATEJvWQ_rEeJIHg,9956
39
39
  honeybee_radiance_postprocess/results/__init__.py,sha256=1agBQbfT4Tf8KqSZzlfKYX8MeZryY4jJ1KB4HWqaDDk,182
40
40
  honeybee_radiance_postprocess/results/annual_daylight.py,sha256=11d4J1iIuITKuoWyWa-2_2WdrHYBULC0YP-mWBWi4JQ,34724
41
41
  honeybee_radiance_postprocess/results/annual_irradiance.py,sha256=5zwrr4MNeHUebbSRpSBbscPOZUs2AHmYCQfIIbdYImY,8298
42
- honeybee_radiance_postprocess/results/results.py,sha256=ABb_S8kDPruhGkDsfREXMg6K0p8FRhAZ3QIRUZCQPAI,54888
42
+ honeybee_radiance_postprocess/results/results.py,sha256=8wpxu6HBnrJXRoTkI7ucNuzhVmNKw1Z2zPP6wzk7ULQ,55236
43
43
  honeybee_radiance_postprocess/well/__init__.py,sha256=kQXElEqFnLGNnrMSpA51XDHoqBup849FHeAqWASIy6w,45
44
- honeybee_radiance_postprocess/well/well.py,sha256=Troym2sdGMYyzW2MGuflCFr737eUWrDP6Pc-zju7LiA,21071
45
- honeybee_radiance_postprocess-0.4.484.dist-info/LICENSE,sha256=hIahDEOTzuHCU5J2nd07LWwkLW7Hko4UFO__ffsvB-8,34523
46
- honeybee_radiance_postprocess-0.4.484.dist-info/METADATA,sha256=Ew6MNbdO93prTciQT1fG4oyRZDBpsO-wJLSJrDsX1DA,2240
47
- honeybee_radiance_postprocess-0.4.484.dist-info/WHEEL,sha256=AHX6tWk3qWuce7vKLrj7lnulVHEdWoltgauo8bgCXgU,109
48
- honeybee_radiance_postprocess-0.4.484.dist-info/entry_points.txt,sha256=gFtVPx6UItXt27GfEZZO00eOZChJJEL6JwGSAB_O3rs,96
49
- honeybee_radiance_postprocess-0.4.484.dist-info/top_level.txt,sha256=4-sFbzy7ewP2EDqJV3jeFlAFx7SuxtoBBELWaKAnLdA,30
50
- honeybee_radiance_postprocess-0.4.484.dist-info/RECORD,,
44
+ honeybee_radiance_postprocess/well/well.py,sha256=94NHsv_iYAyjWPZ40RzVqORl4D3IjVAUcKTiq3bEt_M,21206
45
+ honeybee_radiance_postprocess-0.4.486.dist-info/LICENSE,sha256=hIahDEOTzuHCU5J2nd07LWwkLW7Hko4UFO__ffsvB-8,34523
46
+ honeybee_radiance_postprocess-0.4.486.dist-info/METADATA,sha256=SQ4bD8GuGAXNufIMUKvTrcEJBfd3UNunO2Nnqq9kIv0,2238
47
+ honeybee_radiance_postprocess-0.4.486.dist-info/WHEEL,sha256=AHX6tWk3qWuce7vKLrj7lnulVHEdWoltgauo8bgCXgU,109
48
+ honeybee_radiance_postprocess-0.4.486.dist-info/entry_points.txt,sha256=gFtVPx6UItXt27GfEZZO00eOZChJJEL6JwGSAB_O3rs,96
49
+ honeybee_radiance_postprocess-0.4.486.dist-info/top_level.txt,sha256=4-sFbzy7ewP2EDqJV3jeFlAFx7SuxtoBBELWaKAnLdA,30
50
+ honeybee_radiance_postprocess-0.4.486.dist-info/RECORD,,