dragonfly-doe2 0.12.12__py3-none-any.whl → 0.12.13__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.
@@ -215,6 +215,9 @@ class ModelDoe2Properties(object):
215
215
  is not addressed, the courtyards will simply be removed as part of the
216
216
  process of exporting to an INP file.
217
217
 
218
+ This method will also perform checks for whether the story floor plate
219
+ polygon exceeds the DOE-2 limit of 120 vertices.
220
+
218
221
  Args:
219
222
  tolerance: The tolerance to be used when joining the Room2D floor
220
223
  plates together into a Story floor plate. If None, the Model
@@ -236,8 +239,10 @@ class ModelDoe2Properties(object):
236
239
  for story in bldg.unique_stories:
237
240
  floor_geos = [room.floor_geometry for room in story.room_2ds]
238
241
  joined_geos = _grouped_floor_boundary(floor_geos, tolerance)
239
- c_count = 0
242
+ c_count, vert_len = 0, None
240
243
  for geo in joined_geos:
244
+ if len(geo.boundary) > 120:
245
+ vert_len = len(geo.boundary)
241
246
  if geo.has_holes:
242
247
  for hole in geo.holes:
243
248
  try:
@@ -266,10 +271,26 @@ class ModelDoe2Properties(object):
266
271
  'message': msg
267
272
  }
268
273
  story_msgs.append(msg)
274
+ if vert_len is not None:
275
+ msg = 'Story "{}" has a floor plate with {} vertices, which is more ' \
276
+ 'than the maximum 120 vertices supported by DOE-2.'.format(
277
+ story.display_name, vert_len)
278
+ if detailed:
279
+ msg = {
280
+ 'type': 'ValidationError',
281
+ 'code': '030101',
282
+ 'error_type': 'Room Exceeds Maximum Vertex Count',
283
+ 'extension_type': 'DOE2',
284
+ 'element_type': 'Room2D',
285
+ 'element_id': [r.identifier for r in story.room_2ds],
286
+ 'element_name': [r.display_name for r in story.room_2ds],
287
+ 'message': msg
288
+ }
289
+ story_msgs.append(msg)
269
290
  if detailed:
270
291
  return story_msgs
271
292
  if story_msgs != []:
272
- msg = 'The following Stories have courtyards in their floor plates' \
293
+ msg = 'The following Stories have issues with their floor plates' \
273
294
  ':\n{}'.format('\n'.join(story_msgs))
274
295
  if raise_exception:
275
296
  raise ValueError(msg)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dragonfly-doe2
3
- Version: 0.12.12
3
+ Version: 0.12.13
4
4
  Summary: Dragonfly extension for the DOE-2 energy simulation engine.
5
5
  Home-page: https://github.com/ladybug-tools/dragonfly-doe2
6
6
  Author: Ladybug Tools
@@ -5,11 +5,11 @@ dragonfly_doe2/writer.py,sha256=m7dlAUrVFwHWpKISWLEzNkDkd9g6XtnO4KJSFnw1IPY,7271
5
5
  dragonfly_doe2/cli/__init__.py,sha256=OwTHSsOOEoJjbw5CqPig8Yo7jk1f6m53OFnhuZgPthE,391
6
6
  dragonfly_doe2/cli/translate.py,sha256=Brx8p-9tUzrbdNFj_B398EmVQdFIENC-w2qROhkaWx8,9486
7
7
  dragonfly_doe2/properties/__init__.py,sha256=0JiyMYGeRlPLcxh1PSr6eJzDGgfrbMivcO9dS1h7wEU,33
8
- dragonfly_doe2/properties/model.py,sha256=Ho9xSkbhBIoHxJSNnmuTxvMD-I3FiVEzDuTx5hs3D5M,14467
8
+ dragonfly_doe2/properties/model.py,sha256=UX-evX7peTpPOWMtgKcAzxaBtf6qlzyAhCWBgnWYpXM,15627
9
9
  dragonfly_doe2/properties/room2d.py,sha256=ghKKhcX2TSgPUAdcQk-PPHo_5AilSmTiLElxb8--dkE,12773
10
- dragonfly_doe2-0.12.12.dist-info/licenses/LICENSE,sha256=hIahDEOTzuHCU5J2nd07LWwkLW7Hko4UFO__ffsvB-8,34523
11
- dragonfly_doe2-0.12.12.dist-info/METADATA,sha256=GXhBtvMHl52lHqvBLsvH-2uneYDhL4fiwuVHXcItycE,3103
12
- dragonfly_doe2-0.12.12.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
13
- dragonfly_doe2-0.12.12.dist-info/entry_points.txt,sha256=oBzZOsc8Bs40iHKtuyWGrz_nfLZu1-6cHrBej05ZqrY,59
14
- dragonfly_doe2-0.12.12.dist-info/top_level.txt,sha256=6CLCvUyl1H2vrbXmeA0ND_znFz4a2oOclc7NMBZxR6c,15
15
- dragonfly_doe2-0.12.12.dist-info/RECORD,,
10
+ dragonfly_doe2-0.12.13.dist-info/licenses/LICENSE,sha256=hIahDEOTzuHCU5J2nd07LWwkLW7Hko4UFO__ffsvB-8,34523
11
+ dragonfly_doe2-0.12.13.dist-info/METADATA,sha256=0SGg5D0I9TT_bwOoTpMYgg2YrzA_ngQuoZtGKEJENgk,3103
12
+ dragonfly_doe2-0.12.13.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
13
+ dragonfly_doe2-0.12.13.dist-info/entry_points.txt,sha256=oBzZOsc8Bs40iHKtuyWGrz_nfLZu1-6cHrBej05ZqrY,59
14
+ dragonfly_doe2-0.12.13.dist-info/top_level.txt,sha256=6CLCvUyl1H2vrbXmeA0ND_znFz4a2oOclc7NMBZxR6c,15
15
+ dragonfly_doe2-0.12.13.dist-info/RECORD,,