honeybee-openstudio 2.38.6 → 2.38.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b77ef2ddbd689cf19abe8c48c85b61eb1fb3b010b4fc68813dc9331a5c906c8d
4
- data.tar.gz: f7d2cefe7765c6a59a580cec468c2f3271e1708b706414dab9d0d03153ef2769
3
+ metadata.gz: 149f0edae2e446e882a6fb962684366c187b6dcd2f703efabecf9d20fb623a29
4
+ data.tar.gz: 02aca6abeb6bfe134b30269cd044e1942e64e1e56ec0b010c329e9d3e7a46c55
5
5
  SHA512:
6
- metadata.gz: 94ece34b71cca0e294656b6e68f7099e500bc79c6a8c3d0a880990d2301a119fd6b9c18757d15122e7aa78998fe96913c330c21e677bfe388e2aa9cae35e06c5
7
- data.tar.gz: 9334ccee3a16ebf15fc3163c416916db9a50039c416c568fe2710dd9de7045e9e691f5445cabcdc4f42fceeda3c9b85939ec69509c501d6c0c27c13371c9a071
6
+ metadata.gz: 9fc393de3df070bd30390d747b2c8e8007f7c1cf75e0e8d7ac5a9133c16748384f8d0c7758b72b9c147b6765ec01fabb122099c706e89995516842fb083c4d16
7
+ data.tar.gz: d2cd89048f5d5d39e65b901570e38d686a6b69c3f6c02c94a64a82131b94bd556a5b535160bd87e16ba47e77f374181db9dccf73ff8b11e3a8f6b4359ae47436
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = 'honeybee-openstudio'
7
- spec.version = '2.38.6'
7
+ spec.version = '2.38.8'
8
8
  spec.authors = ['Tanushree Charan', 'Dan Macumber', 'Chris Mackey', 'Mostapha Sadeghipour Roudsari']
9
9
  spec.email = ['tanushree.charan@nrel.gov', 'chris@ladybug.tools']
10
10
 
@@ -112,8 +112,9 @@ module Honeybee
112
112
 
113
113
  # remove illegal characters in identifier
114
114
  def self.clean_name(str)
115
- ascii = str.encode(Encoding.find('ASCII'), **@@encoding_options)
116
- ascii = truncate(ascii, 97)
115
+ encode_str = str.encode(Encoding.find('ASCII'), **@@encoding_options)
116
+ encode_str = truncate(encode_str, 97)
117
+ encode_str.gsub(/[,;!]/, '_')
117
118
  end
118
119
 
119
120
  # remove illegal characters in identifier
@@ -170,7 +170,7 @@ module Honeybee
170
170
  return result
171
171
  end
172
172
 
173
- def to_openstudio_shade(openstudio_model, shading_surface_group)
173
+ def to_openstudio_shade(openstudio_model)
174
174
  # get the vertices from the aperture
175
175
  if @hash[:geometry][:vertices].nil?
176
176
  hb_verts = @hash[:geometry][:boundary]
@@ -217,9 +217,6 @@ module Honeybee
217
217
  end
218
218
  end
219
219
 
220
- # add the shade to the group
221
- os_shading_surface.setShadingSurfaceGroup(shading_surface_group)
222
-
223
220
  os_shading_surface
224
221
  end
225
222
 
@@ -163,7 +163,7 @@ module Honeybee
163
163
  return result
164
164
  end
165
165
 
166
- def to_openstudio_shade(openstudio_model, shading_surface_group)
166
+ def to_openstudio_shade(openstudio_model)
167
167
  # get the vertices from the door
168
168
  if @hash[:geometry][:vertices].nil?
169
169
  hb_verts = @hash[:geometry][:boundary]
@@ -212,9 +212,6 @@ module Honeybee
212
212
  end
213
213
  end
214
214
 
215
- # add the shade to the group
216
- os_shading_surface.setShadingSurfaceGroup(shading_surface_group)
217
-
218
215
  os_shading_surface
219
216
  end
220
217
 
@@ -248,25 +248,6 @@ module Honeybee
248
248
  end
249
249
  end
250
250
 
251
- # add the shade to the group
252
- os_shading_surface.setShadingSurfaceGroup(shading_surface_group)
253
-
254
- # convert the apertures to shade objects
255
- if @hash[:apertures]
256
- @hash[:apertures].each do |aperture|
257
- hb_aperture = Aperture.new(aperture)
258
- os_subsurface_aperture = hb_aperture.to_openstudio_shade(openstudio_model, shading_surface_group)
259
- end
260
- end
261
-
262
- # convert the apertures to shade objects
263
- if @hash[:doors]
264
- @hash[:doors].each do |door|
265
- hb_door = Door.new(door)
266
- os_subsurface_door = hb_door.to_openstudio_shade(openstudio_model, shading_surface_group)
267
- end
268
- end
269
-
270
251
  os_shading_surface
271
252
  end
272
253
 
@@ -649,7 +649,7 @@ module Honeybee
649
649
  end
650
650
  @hash[:orphaned_faces].each do |face|
651
651
  face_object = Face.new(face)
652
- openstudio_shade = face_object.to_openstudio_shade(@openstudio_model, shading_surface_group)
652
+ openstudio_shade = face_object.to_openstudio_shade(@openstudio_model)
653
653
  if $orphan_groups
654
654
  openstudio_shade.setShadingSurfaceGroup(shading_surface_group)
655
655
  end
@@ -663,9 +663,9 @@ module Honeybee
663
663
  shading_surface_group = OpenStudio::Model::ShadingSurfaceGroup.new(@openstudio_model)
664
664
  shading_surface_group.setShadingSurfaceType('Building')
665
665
  end
666
- @hash[:orphaned_apertures].each do |ap|
666
+ @hash[:orphaned_apertures].each do |ap|
667
667
  ap_object = Aperture.new(ap)
668
- openstudio_shade = ap_object.to_openstudio_shade(@openstudio_model, shading_surface_group)
668
+ openstudio_shade = ap_object.to_openstudio_shade(@openstudio_model)
669
669
  if $orphan_groups
670
670
  openstudio_shade.setShadingSurfaceGroup(shading_surface_group)
671
671
  end
@@ -679,9 +679,9 @@ module Honeybee
679
679
  shading_surface_group = OpenStudio::Model::ShadingSurfaceGroup.new(@openstudio_model)
680
680
  shading_surface_group.setShadingSurfaceType('Building')
681
681
  end
682
- @hash[:orphaned_doors].each do |dr|
682
+ @hash[:orphaned_doors].each do |dr|
683
683
  dr_object = Door.new(dr)
684
- openstudio_shade = dr_object.to_openstudio_shade(@openstudio_model, shading_surface_group)
684
+ openstudio_shade = dr_object.to_openstudio_shade(@openstudio_model)
685
685
  if $orphan_groups
686
686
  openstudio_shade.setShadingSurfaceGroup(shading_surface_group)
687
687
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: honeybee-openstudio
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.38.6
4
+ version: 2.38.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tanushree Charan
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: exe
13
13
  cert_chain: []
14
- date: 2024-03-12 00:00:00.000000000 Z
14
+ date: 2024-04-10 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: json_pure