openstudio-model-articulation 0.8.0 → 0.10.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (61) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +9 -0
  3. data/Gemfile +12 -5
  4. data/Jenkinsfile +1 -1
  5. data/README.md +2 -0
  6. data/lib/measures/SimplifyGeometryToSlicedBar/measure.rb +32 -37
  7. data/lib/measures/SimplifyGeometryToSlicedBar/measure.xml +34 -80
  8. data/lib/measures/SimplifyGeometryToSlicedBar/resources/os_lib_cofee.rb +10 -9
  9. data/lib/measures/SpaceTypeAndConstructionSetWizard/measure.rb +10 -13
  10. data/lib/measures/SpaceTypeAndConstructionSetWizard/measure.xml +28 -28
  11. data/lib/measures/blended_space_type_from_floor_area_ratios/measure.rb +31 -14
  12. data/lib/measures/blended_space_type_from_floor_area_ratios/measure.xml +36 -36
  13. data/lib/measures/blended_space_type_from_model/measure.rb +12 -5
  14. data/lib/measures/blended_space_type_from_model/measure.xml +47 -47
  15. data/lib/measures/create_DOE_prototype_building/measure.rb +1 -1
  16. data/lib/measures/create_DOE_prototype_building/measure.xml +19 -875
  17. data/lib/measures/create_bar_from_building_type_ratios/README.md +2 -13
  18. data/lib/measures/create_bar_from_building_type_ratios/measure.rb +122 -30
  19. data/lib/measures/create_bar_from_building_type_ratios/measure.xml +108 -349
  20. data/lib/measures/create_bar_from_deer_building_type_ratios/README.md +21 -1
  21. data/lib/measures/create_bar_from_deer_building_type_ratios/measure.rb +120 -18
  22. data/lib/measures/create_bar_from_deer_building_type_ratios/measure.xml +94 -32
  23. data/lib/measures/create_bar_from_doe_building_type_ratios/measure.rb +127 -18
  24. data/lib/measures/create_bar_from_doe_building_type_ratios/measure.xml +48 -26
  25. data/lib/measures/create_bar_from_model/measure.rb +17 -18
  26. data/lib/measures/create_bar_from_model/measure.xml +41 -41
  27. data/lib/measures/create_bar_from_space_type_ratios/README.md +1 -1
  28. data/lib/measures/create_bar_from_space_type_ratios/measure.rb +94 -14
  29. data/lib/measures/create_bar_from_space_type_ratios/measure.xml +104 -63
  30. data/lib/measures/create_baseline_building/measure.xml +33 -33
  31. data/lib/measures/create_deer_prototype_building/measure.xml +15 -15
  32. data/lib/measures/create_parametric_schedules/measure.rb +17 -20
  33. data/lib/measures/create_parametric_schedules/measure.xml +15 -15
  34. data/lib/measures/create_typical_building_from_model/README.md +16 -16
  35. data/lib/measures/create_typical_building_from_model/measure.rb +84 -18
  36. data/lib/measures/create_typical_building_from_model/measure.xml +159 -211
  37. data/lib/measures/create_typical_deer_building_from_model/README.md +38 -5
  38. data/lib/measures/create_typical_deer_building_from_model/measure.rb +84 -12
  39. data/lib/measures/create_typical_deer_building_from_model/measure.xml +165 -65
  40. data/lib/measures/create_typical_doe_building_from_model/README.md +17 -4
  41. data/lib/measures/create_typical_doe_building_from_model/measure.rb +84 -12
  42. data/lib/measures/create_typical_doe_building_from_model/measure.xml +125 -65
  43. data/lib/measures/deer_space_type_and_construction_set_wizard/measure.rb +13 -16
  44. data/lib/measures/deer_space_type_and_construction_set_wizard/measure.xml +72 -29
  45. data/lib/measures/make_shading_surfaces_based_on_zone_multipliers/measure.rb +4 -4
  46. data/lib/measures/make_shading_surfaces_based_on_zone_multipliers/measure.xml +21 -21
  47. data/lib/measures/merge_spaces_from_external_file/measure.rb +4 -4
  48. data/lib/measures/merge_spaces_from_external_file/measure.xml +34 -34
  49. data/lib/measures/radiant_slab_with_doas/README.md +0 -8
  50. data/lib/measures/radiant_slab_with_doas/measure.rb +2 -11
  51. data/lib/measures/radiant_slab_with_doas/measure.xml +31 -40
  52. data/lib/measures/replace_geometry_by_story/measure.rb +6 -10
  53. data/lib/measures/replace_geometry_by_story/measure.xml +19 -19
  54. data/lib/measures/set_nist_infiltration_correlations/measure.rb +34 -25
  55. data/lib/measures/set_nist_infiltration_correlations/measure.xml +38 -38
  56. data/lib/openstudio/model_articulation/version.rb +1 -1
  57. data/openstudio-model-articulation.gemspec +11 -4
  58. metadata +69 -16
  59. data/lib/measures/SimplifyGeometryToSlicedBar/resources/os_lib_geometry.rb +0 -1174
  60. data/lib/measures/SimplifyGeometryToSlicedBar/resources/os_lib_helper_methods.rb +0 -367
  61. data/lib/measures/create_typical_building_from_model/resources/Model.hvac.rb +0 -608
@@ -1,10 +1,10 @@
1
1
  <?xml version="1.0"?>
2
2
  <measure>
3
- <schema_version>3.0</schema_version>
3
+ <schema_version>3.1</schema_version>
4
4
  <name>blended_space_type_from_floor_area_ratios</name>
5
5
  <uid>48ff1765-871b-4c9c-9996-a22757c534ad</uid>
6
- <version_id>d6db3f27-e95f-48c5-b34e-f8d2839f8592</version_id>
7
- <version_modified>20230602T160044Z</version_modified>
6
+ <version_id>8f0c2268-a0f3-40d1-9859-197e2c94934c</version_id>
7
+ <version_modified>2024-05-20T07:54:33Z</version_modified>
8
8
  <xml_checksum>05C5DFDC</xml_checksum>
9
9
  <class_name>BlendedSpaceTypeFromFloorAreaRatios</class_name>
10
10
  <display_name>Blended Space Type from Floor Area Ratios</display_name>
@@ -103,22 +103,16 @@
103
103
  </attributes>
104
104
  <files>
105
105
  <file>
106
- <filename>example_model.osm</filename>
107
- <filetype>osm</filetype>
108
- <usage_type>test</usage_type>
109
- <checksum>C4F35230</checksum>
110
- </file>
111
- <file>
112
- <filename>1002_SmallOffice_2010_2a.osm</filename>
113
- <filetype>osm</filetype>
114
- <usage_type>test</usage_type>
115
- <checksum>9919F79E</checksum>
106
+ <filename>LICENSE.md</filename>
107
+ <filetype>md</filetype>
108
+ <usage_type>license</usage_type>
109
+ <checksum>BFFB1AA6</checksum>
116
110
  </file>
117
111
  <file>
118
- <filename>1002_RetailStandalone2013.osm</filename>
119
- <filetype>osm</filetype>
120
- <usage_type>test</usage_type>
121
- <checksum>EF019CDF</checksum>
112
+ <filename>README.md</filename>
113
+ <filetype>md</filetype>
114
+ <usage_type>readme</usage_type>
115
+ <checksum>CF3B0BF8</checksum>
122
116
  </file>
123
117
  <file>
124
118
  <filename>README.md.erb</filename>
@@ -127,10 +121,15 @@
127
121
  <checksum>703C9964</checksum>
128
122
  </file>
129
123
  <file>
130
- <filename>README.md</filename>
131
- <filetype>md</filetype>
132
- <usage_type>readme</usage_type>
133
- <checksum>CF3B0BF8</checksum>
124
+ <version>
125
+ <software_program>OpenStudio</software_program>
126
+ <identifier>2.0.0</identifier>
127
+ <min_compatible>3.8.0</min_compatible>
128
+ </version>
129
+ <filename>measure.rb</filename>
130
+ <filetype>rb</filetype>
131
+ <usage_type>script</usage_type>
132
+ <checksum>91F44304</checksum>
134
133
  </file>
135
134
  <file>
136
135
  <filename>design_doc.txt</filename>
@@ -139,27 +138,28 @@
139
138
  <checksum>A9E3FEA1</checksum>
140
139
  </file>
141
140
  <file>
142
- <filename>LICENSE.md</filename>
143
- <filetype>md</filetype>
144
- <usage_type>license</usage_type>
145
- <checksum>BFFB1AA6</checksum>
141
+ <filename>1002_RetailStandalone2013.osm</filename>
142
+ <filetype>osm</filetype>
143
+ <usage_type>test</usage_type>
144
+ <checksum>EF019CDF</checksum>
146
145
  </file>
147
146
  <file>
148
- <filename>measure_test.rb</filename>
149
- <filetype>rb</filetype>
147
+ <filename>1002_SmallOffice_2010_2a.osm</filename>
148
+ <filetype>osm</filetype>
150
149
  <usage_type>test</usage_type>
151
- <checksum>9BB3DA9C</checksum>
150
+ <checksum>9919F79E</checksum>
152
151
  </file>
153
152
  <file>
154
- <version>
155
- <software_program>OpenStudio</software_program>
156
- <identifier>2.0.0</identifier>
157
- <min_compatible>2.8.0</min_compatible>
158
- </version>
159
- <filename>measure.rb</filename>
153
+ <filename>example_model.osm</filename>
154
+ <filetype>osm</filetype>
155
+ <usage_type>test</usage_type>
156
+ <checksum>C4F35230</checksum>
157
+ </file>
158
+ <file>
159
+ <filename>measure_test.rb</filename>
160
160
  <filetype>rb</filetype>
161
- <usage_type>script</usage_type>
162
- <checksum>F302D8E8</checksum>
161
+ <usage_type>test</usage_type>
162
+ <checksum>9BB3DA9C</checksum>
163
163
  </file>
164
164
  </files>
165
165
  </measure>
@@ -7,13 +7,10 @@
7
7
  # http://nrel.github.io/OpenStudio-user-documentation/reference/measure_writing_guide/
8
8
 
9
9
  # load OpenStudio measure libraries from openstudio-extension gem
10
- require 'openstudio-extension'
11
- require 'openstudio/extension/core/os_lib_model_simplification'
10
+ require 'openstudio-standards'
12
11
 
13
12
  # start the measure
14
13
  class BlendedSpaceTypeFromModel < OpenStudio::Measure::ModelMeasure
15
- # contains code to blend space types
16
- include OsLib_ModelSimplification
17
14
 
18
15
  # human readable name
19
16
  def name
@@ -162,8 +159,18 @@ class BlendedSpaceTypeFromModel < OpenStudio::Measure::ModelMeasure
162
159
  end
163
160
  runner.registerInitialCondition("The initial building uses #{initial_cond_space_type_hash.size} spaces types.")
164
161
 
162
+ # open channel to log messages
163
+ reset_log
164
+
165
+ # Turn debugging output on/off
166
+ debug = false
167
+
165
168
  # blend space types
166
- blend_space_type_collections(runner, model, space_type_hash)
169
+ OpenstudioStandards::CreateTypical.blend_space_type_collections(model, space_type_hash)
170
+
171
+ # gather log
172
+ log_messages_to_runner(runner, debug)
173
+ reset_log
167
174
 
168
175
  # report final condition of model
169
176
  # re-run same same code used for initial condition
@@ -1,10 +1,10 @@
1
1
  <?xml version="1.0"?>
2
2
  <measure>
3
- <schema_version>3.0</schema_version>
3
+ <schema_version>3.1</schema_version>
4
4
  <name>blended_space_type_from_model</name>
5
5
  <uid>667c2f1f-0927-4dbd-a7be-1087b5c15181</uid>
6
- <version_id>23be7ce9-31dd-42f6-a4a4-ba8f6265e6a7</version_id>
7
- <version_modified>20230602T160045Z</version_modified>
6
+ <version_id>233944a0-9765-434c-ad88-36dbd30148b0</version_id>
7
+ <version_modified>2024-07-11T21:47:24Z</version_modified>
8
8
  <xml_checksum>28AD5222</xml_checksum>
9
9
  <class_name>BlendedSpaceTypeFromModel</class_name>
10
10
  <display_name>Blended Space Type from Model</display_name>
@@ -73,10 +73,45 @@
73
73
  </attributes>
74
74
  <files>
75
75
  <file>
76
- <filename>example_model.osm</filename>
76
+ <filename>LICENSE.md</filename>
77
+ <filetype>md</filetype>
78
+ <usage_type>license</usage_type>
79
+ <checksum>BFFB1AA6</checksum>
80
+ </file>
81
+ <file>
82
+ <filename>README.md</filename>
83
+ <filetype>md</filetype>
84
+ <usage_type>readme</usage_type>
85
+ <checksum>F9666FA7</checksum>
86
+ </file>
87
+ <file>
88
+ <filename>README.md.erb</filename>
89
+ <filetype>erb</filetype>
90
+ <usage_type>readmeerb</usage_type>
91
+ <checksum>703C9964</checksum>
92
+ </file>
93
+ <file>
94
+ <filename>replace_occupied_spaces_with_blended_space_type_design_doc.txt</filename>
95
+ <filetype>txt</filetype>
96
+ <usage_type>doc</usage_type>
97
+ <checksum>C2673B6F</checksum>
98
+ </file>
99
+ <file>
100
+ <version>
101
+ <software_program>OpenStudio</software_program>
102
+ <identifier>2.0.0</identifier>
103
+ <min_compatible>3.8.0</min_compatible>
104
+ </version>
105
+ <filename>measure.rb</filename>
106
+ <filetype>rb</filetype>
107
+ <usage_type>script</usage_type>
108
+ <checksum>A4B86F7D</checksum>
109
+ </file>
110
+ <file>
111
+ <filename>0916_lrg_htl_1_12_0.osm</filename>
77
112
  <filetype>osm</filetype>
78
113
  <usage_type>test</usage_type>
79
- <checksum>C4F35230</checksum>
114
+ <checksum>98A4FB11</checksum>
80
115
  </file>
81
116
  <file>
82
117
  <filename>0922_md_off_1_12_0.osm</filename>
@@ -97,63 +132,28 @@
97
132
  <checksum>F1C3606F</checksum>
98
133
  </file>
99
134
  <file>
100
- <filename>large_hotel_restaurant_from_create_typical.osm</filename>
135
+ <filename>basement_infil_test.osm</filename>
101
136
  <filetype>osm</filetype>
102
137
  <usage_type>test</usage_type>
103
- <checksum>F24EB88F</checksum>
138
+ <checksum>2C87151A</checksum>
104
139
  </file>
105
140
  <file>
106
- <filename>0916_lrg_htl_1_12_0.osm</filename>
141
+ <filename>example_model.osm</filename>
107
142
  <filetype>osm</filetype>
108
143
  <usage_type>test</usage_type>
109
- <checksum>98A4FB11</checksum>
144
+ <checksum>C4F35230</checksum>
110
145
  </file>
111
146
  <file>
112
- <filename>basement_infil_test.osm</filename>
147
+ <filename>large_hotel_restaurant_from_create_typical.osm</filename>
113
148
  <filetype>osm</filetype>
114
149
  <usage_type>test</usage_type>
115
- <checksum>2C87151A</checksum>
116
- </file>
117
- <file>
118
- <filename>README.md</filename>
119
- <filetype>md</filetype>
120
- <usage_type>readme</usage_type>
121
- <checksum>F9666FA7</checksum>
122
- </file>
123
- <file>
124
- <filename>README.md.erb</filename>
125
- <filetype>erb</filetype>
126
- <usage_type>readmeerb</usage_type>
127
- <checksum>703C9964</checksum>
128
- </file>
129
- <file>
130
- <filename>replace_occupied_spaces_with_blended_space_type_design_doc.txt</filename>
131
- <filetype>txt</filetype>
132
- <usage_type>doc</usage_type>
133
- <checksum>C2673B6F</checksum>
134
- </file>
135
- <file>
136
- <filename>LICENSE.md</filename>
137
- <filetype>md</filetype>
138
- <usage_type>license</usage_type>
139
- <checksum>BFFB1AA6</checksum>
150
+ <checksum>F24EB88F</checksum>
140
151
  </file>
141
152
  <file>
142
153
  <filename>measure_test.rb</filename>
143
154
  <filetype>rb</filetype>
144
155
  <usage_type>test</usage_type>
145
- <checksum>75D48CAC</checksum>
146
- </file>
147
- <file>
148
- <version>
149
- <software_program>OpenStudio</software_program>
150
- <identifier>2.0.0</identifier>
151
- <min_compatible>2.8.0</min_compatible>
152
- </version>
153
- <filename>measure.rb</filename>
154
- <filetype>rb</filetype>
155
- <usage_type>script</usage_type>
156
- <checksum>4A8C4B2E</checksum>
156
+ <checksum>CDC63FFD</checksum>
157
157
  </file>
158
158
  </files>
159
159
  </measure>
@@ -103,7 +103,7 @@ class CreateDOEPrototypeBuilding < OpenStudio::Measure::ModelMeasure
103
103
  # Drop down selector for Canadian weather files.
104
104
  epw_files = OpenStudio::StringVector.new
105
105
  epw_files << 'Not Applicable'
106
- BTAP::Environment.get_canadian_weather_file_names.each { |file| epw_files << file }
106
+ #BTAP::Environment.get_canadian_weather_file_names.each { |file| epw_files << file }
107
107
  epw_file = OpenStudio::Measure::OSArgument.makeChoiceArgument('epw_file', epw_files, true)
108
108
  epw_file.setDisplayName('Climate File (NECB only)')
109
109
  epw_file.setDefaultValue('Not Applicable')