openstudio-standards 0.8.5 → 0.8.7

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 (174) hide show
  1. checksums.yaml +4 -4
  2. data/data/standards/test_performance_expected_dd_results.csv +90 -90
  3. data/lib/openstudio-standards/btap/activity.rb +858 -61
  4. data/lib/openstudio-standards/btap/attributes.rb +297 -103
  5. data/lib/openstudio-standards/btap/bridging.rb +1335 -593
  6. data/lib/openstudio-standards/btap/btap.rb +60 -181
  7. data/lib/openstudio-standards/btap/carbon/btap_carbon.rb +199 -142
  8. data/lib/openstudio-standards/btap/common/constructions.json +1275 -0
  9. data/lib/openstudio-standards/btap/common/costs.csv +1969 -0
  10. data/lib/openstudio-standards/btap/common/costs_local_factors.csv +2315 -0
  11. data/lib/openstudio-standards/btap/common/materials_glazing.csv +61 -0
  12. data/lib/openstudio-standards/btap/{common_resources → common}/materials_hvac.csv +1685 -1685
  13. data/lib/openstudio-standards/btap/{common_resources → common}/materials_lighting.csv +266 -266
  14. data/lib/openstudio-standards/btap/common/materials_opaque.csv +214 -0
  15. data/lib/openstudio-standards/btap/common/necb_building_types.csv +35 -0
  16. data/lib/openstudio-standards/btap/common/necb_space_types.csv +110 -0
  17. data/lib/openstudio-standards/btap/common/thermal_bridging.csv +73 -0
  18. data/lib/openstudio-standards/btap/costing/btap_costing.rb +346 -429
  19. data/lib/openstudio-standards/btap/costing/database.rb +104 -0
  20. data/lib/openstudio-standards/btap/costing/daylighting_sensor_control_costing.rb +356 -344
  21. data/lib/openstudio-standards/btap/costing/dcv_costing.rb +282 -296
  22. data/lib/openstudio-standards/btap/costing/envelope_costing.rb +179 -192
  23. data/lib/openstudio-standards/btap/costing/heating_cooling_costing.rb +2477 -2316
  24. data/lib/openstudio-standards/btap/costing/led_lighting_costing.rb +127 -142
  25. data/lib/openstudio-standards/btap/costing/lighting_costing.rb +216 -198
  26. data/lib/openstudio-standards/btap/costing/nv_costing.rb +522 -523
  27. data/lib/openstudio-standards/btap/costing/pv_ground_costing.rb +649 -649
  28. data/lib/openstudio-standards/btap/costing/shw_costing.rb +626 -625
  29. data/lib/openstudio-standards/btap/costing/thermal_bridging_costing.rb +72 -0
  30. data/lib/openstudio-standards/btap/costing/ventilation_costing.rb +2363 -2361
  31. data/lib/openstudio-standards/btap/deprecated.rb +1033 -0
  32. data/lib/openstudio-standards/btap/envelope.rb +313 -572
  33. data/lib/openstudio-standards/btap/fileio.rb +152 -1070
  34. data/lib/openstudio-standards/btap/geometry.rb +486 -766
  35. data/lib/openstudio-standards/btap/linear_regression.rb +130 -0
  36. data/lib/openstudio-standards/btap/paths.rb +46 -0
  37. data/lib/openstudio-standards/btap/qaqc/analysis.rb +163 -0
  38. data/lib/openstudio-standards/btap/qaqc/data.rb +2293 -0
  39. data/lib/openstudio-standards/btap/qaqc/datapoint.rb +641 -0
  40. data/lib/openstudio-standards/btap/schedules.rb +11 -611
  41. data/lib/openstudio-standards/btap/structure.rb +574 -189
  42. data/lib/openstudio-standards/constructions/materials/information.rb +1 -1
  43. data/lib/openstudio-standards/create_typical/create_typical.rb +1 -1
  44. data/lib/openstudio-standards/exterior_lighting/create.rb +135 -85
  45. data/lib/openstudio-standards/exterior_lighting/data/typical_exterior_lighting.json +20 -0
  46. data/lib/openstudio-standards/exterior_lighting/information.rb +23 -2
  47. data/lib/openstudio-standards/geometry/create.rb +7 -3
  48. data/lib/openstudio-standards/prototypes/ashrae_90_1/ashrae_90_1_2016/ashrae_90_1_2016.Model.rb +3 -2
  49. data/lib/openstudio-standards/prototypes/ashrae_90_1/ashrae_90_1_2019/ashrae_90_1_2019.Model.rb +3 -2
  50. data/lib/openstudio-standards/prototypes/common/data/thermostat_schedule_lookup.json +84 -84
  51. data/lib/openstudio-standards/prototypes/common/objects/Prototype.hvac_systems.rb +4 -4
  52. data/lib/openstudio-standards/refrigeration/create_walkin.rb +45 -5
  53. data/lib/openstudio-standards/refrigeration/data/refrigerated_walkins.csv +75 -75
  54. data/lib/openstudio-standards/schedules/parametric.rb +6 -0
  55. data/lib/openstudio-standards/service_water_heating/create_typical.rb +10 -3
  56. data/lib/openstudio-standards/service_water_heating/create_water_heating_loop.rb +30 -14
  57. data/lib/openstudio-standards/service_water_heating/information.rb +4 -1
  58. data/lib/openstudio-standards/sql_file/unmet_hours.rb +2 -1
  59. data/lib/openstudio-standards/standards/Standards.CoilCoolingDXSingleSpeed.rb +3 -1
  60. data/lib/openstudio-standards/standards/Standards.CoilHeatingDXSingleSpeed.rb +3 -1
  61. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2004/data/ashrae_90_1_2004.boilers.json +12 -0
  62. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2004/data/ashrae_90_1_2004.construction_properties.json +18432 -3072
  63. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2007/data/ashrae_90_1_2007.boilers.json +26 -0
  64. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2007/data/ashrae_90_1_2007.construction_properties.json +8532 -1422
  65. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2010/data/ashrae_90_1_2010.boilers.json +26 -0
  66. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2010/data/ashrae_90_1_2010.construction_properties.json +8532 -1422
  67. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2013/data/ashrae_90_1_2013.boilers.json +16 -0
  68. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2013/data/ashrae_90_1_2013.computer_room_acs.json +30 -30
  69. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2013/data/ashrae_90_1_2013.construction_properties.json +7560 -1260
  70. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2016/ashrae_90_1_2016.PumpVariableSpeed.rb +1 -2
  71. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2016/data/ashrae_90_1_2016.boilers.json +16 -0
  72. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2016/data/ashrae_90_1_2016.construction_properties.json +7560 -1260
  73. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2019/ashrae_90_1_2019.AirLoopHVAC.rb +3 -3
  74. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2019/ashrae_90_1_2019.PumpVariableSpeed.rb +1 -2
  75. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2019/data/ashrae_90_1_2019.boilers.json +22 -0
  76. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2019/data/ashrae_90_1_2019.construction_properties.json +7236 -1206
  77. data/lib/openstudio-standards/standards/ashrae_90_1/ashrae_90_1_2019/data/ashrae_90_1_2019.furnaces.json +223 -19
  78. data/lib/openstudio-standards/standards/ashrae_90_1/data/ashrae_90_1.schedules.json +37 -1
  79. data/lib/openstudio-standards/standards/ashrae_90_1_prm/ashrae_90_1_prm_2019/data/ashrae_90_1_prm_2019.boilers.json +3 -0
  80. data/lib/openstudio-standards/standards/ashrae_90_1_prm/ashrae_90_1_prm_2019/data/ashrae_90_1_prm_2019.construction_properties.json +6900 -1150
  81. data/lib/openstudio-standards/standards/cbes/data/cbes.schedules.json +1 -1
  82. data/lib/openstudio-standards/standards/deer/data/deer.schedules.json +1 -1
  83. data/lib/openstudio-standards/standards/necb/BTAP1980TO2010/data/surface_thermal_transmittance.json +76 -40
  84. data/lib/openstudio-standards/standards/necb/BTAPPRE1980/data/surface_thermal_transmittance.json +76 -40
  85. data/lib/openstudio-standards/standards/necb/ECMS/hvac_systems.rb +6 -4
  86. data/lib/openstudio-standards/standards/necb/NECB2011/NECB2011_QAQC.json +2988 -0
  87. data/lib/openstudio-standards/standards/necb/NECB2011/autozone.rb +25 -3
  88. data/lib/openstudio-standards/standards/necb/NECB2011/building_envelope.rb +672 -534
  89. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/Hospital.osm +1791 -1792
  90. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/LEEPMultiTower.osm +7 -1
  91. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/LEEPTownHouse.osm +7 -1
  92. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/LargeHotel.osm +5 -6
  93. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/LargeOffice.osm +8 -9
  94. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/NorthernEducation.osm +10 -4
  95. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/NorthernHealthCare.osm +14 -15
  96. data/lib/openstudio-standards/standards/necb/NECB2011/data/geometry/Outpatient.osm +7 -1
  97. data/lib/openstudio-standards/standards/necb/NECB2011/data/surface_thermal_transmittance.json +76 -40
  98. data/lib/openstudio-standards/standards/necb/NECB2011/hvac_systems.rb +14 -6
  99. data/lib/openstudio-standards/standards/necb/NECB2011/necb_2011.rb +542 -130
  100. data/lib/openstudio-standards/standards/necb/NECB2011/qaqc/necb_qaqc.rb +30 -63
  101. data/lib/openstudio-standards/standards/necb/NECB2011/service_water_heating.rb +7 -2
  102. data/lib/openstudio-standards/standards/necb/NECB2015/data/surface_thermal_transmittance.json +90 -0
  103. data/lib/openstudio-standards/standards/necb/NECB2015/necb_2015.rb +8 -6
  104. data/lib/openstudio-standards/standards/necb/NECB2017/data/surface_thermal_transmittance.json +76 -40
  105. data/lib/openstudio-standards/standards/necb/NECB2017/necb_2017.rb +2 -1
  106. data/lib/openstudio-standards/standards/necb/NECB2020/building_envelope.rb +0 -117
  107. data/lib/openstudio-standards/standards/necb/NECB2020/data/surface_thermal_transmittance.json +76 -45
  108. data/lib/openstudio-standards/standards/necb/NECB2020/necb_2020.rb +218 -0
  109. data/lib/openstudio-standards/standards/necb/common/construction_defaults.osm +12 -7
  110. data/lib/openstudio-standards/standards/standard.rb +1 -1
  111. data/lib/openstudio-standards/version.rb +1 -1
  112. data/lib/openstudio-standards.rb +9 -4
  113. metadata +59 -66
  114. data/data/inventory/thermal_bridging.csv +0 -90
  115. data/data/standards/OpenStudio_Standards-ashrae_90_1-ALL-comstock(space_types).xlsx +0 -0
  116. data/data/standards/openstudio_standards_duplicates_log.csv +0 -7962
  117. data/lib/openstudio-standards/btap/NECB_building_types.csv +0 -35
  118. data/lib/openstudio-standards/btap/NECB_space_types.csv +0 -109
  119. data/lib/openstudio-standards/btap/WeatherData1.json +0 -2110
  120. data/lib/openstudio-standards/btap/WeatherData1.xlsx +0 -0
  121. data/lib/openstudio-standards/btap/btap_result.rb +0 -1144
  122. data/lib/openstudio-standards/btap/btap_test_helper.rb +0 -86
  123. data/lib/openstudio-standards/btap/common_paths.rb +0 -81
  124. data/lib/openstudio-standards/btap/common_resources/ConstructionProperties.csv +0 -52
  125. data/lib/openstudio-standards/btap/common_resources/Constructions.csv +0 -37
  126. data/lib/openstudio-standards/btap/common_resources/construction_sets.csv +0 -1270
  127. data/lib/openstudio-standards/btap/common_resources/constructions_glazing.csv +0 -121
  128. data/lib/openstudio-standards/btap/common_resources/constructions_opaque.csv +0 -2256
  129. data/lib/openstudio-standards/btap/common_resources/costs.csv +0 -1897
  130. data/lib/openstudio-standards/btap/common_resources/costs_local_factors.csv +0 -2315
  131. data/lib/openstudio-standards/btap/common_resources/materials_glazing.csv +0 -35
  132. data/lib/openstudio-standards/btap/common_resources/materials_opaque.csv +0 -164
  133. data/lib/openstudio-standards/btap/costing/btap_measure_helper.rb +0 -359
  134. data/lib/openstudio-standards/btap/costing/btap_workflow.rb +0 -117
  135. data/lib/openstudio-standards/btap/costing/copy_test_results_files_to_expected_results.rb +0 -11
  136. data/lib/openstudio-standards/btap/costing/cost_building_from_file.rb +0 -136
  137. data/lib/openstudio-standards/btap/costing/costing_database_wrapper.rb +0 -173
  138. data/lib/openstudio-standards/btap/costing/dummy.epw +0 -8768
  139. data/lib/openstudio-standards/btap/costing/dummy.osm +0 -5320
  140. data/lib/openstudio-standards/btap/costing/neb_end_use_prices.csv +0 -42
  141. data/lib/openstudio-standards/btap/costing/necb_2011_spacetype_info.csv +0 -225
  142. data/lib/openstudio-standards/btap/costing/necb_reference_runs.csv +0 -28705
  143. data/lib/openstudio-standards/btap/costing/parallel_tests.rb +0 -92
  144. data/lib/openstudio-standards/btap/costing/test_list.txt +0 -15
  145. data/lib/openstudio-standards/btap/costing/test_run_all_test_locally.rb +0 -27
  146. data/lib/openstudio-standards/btap/costing/test_run_costing_tests.rb +0 -80
  147. data/lib/openstudio-standards/btap/necb_2011_spacetype_info.csv +0 -225
  148. data/lib/openstudio-standards/btap/utilities/Add_template_field_to_json.rb +0 -22
  149. data/lib/openstudio-standards/btap/utilities/convert_surfaces_to_adiabatic_necb_8426.rb +0 -204
  150. data/lib/openstudio-standards/btap/utilities/generate_space_types.rb +0 -8
  151. data/lib/openstudio-standards/btap/utilities/necb_to_epw_map.rb +0 -50
  152. data/lib/openstudio-standards/btap/utilities/os_sim_extract.rb +0 -48
  153. data/lib/openstudio-standards/btap/utilities/rename_surfaces.rb +0 -24
  154. data/lib/openstudio-standards/btap/utilities/round_surf_coords.rb +0 -32
  155. data/lib/openstudio-standards/btap/utilities/sched_create.rb +0 -145
  156. data/lib/openstudio-standards/btap/utilities/set_mult_to_adiabatic.rb +0 -53
  157. data/lib/openstudio-standards/btap/utilities/space_type.rb +0 -78
  158. data/lib/openstudio-standards/btap/utilities/weatherData1_xlsx_to_json.rb +0 -56
  159. data/lib/openstudio-standards/btap/vintagizer.rb +0 -161
  160. data/lib/openstudio-standards/btap/visualization.rb +0 -72
  161. data/lib/openstudio-standards/standards/necb/NECB2011/data/necb_2011_spacetype_info.csv +0 -225
  162. data/lib/openstudio-standards/standards/necb/common/btap_analysis.rb +0 -79
  163. data/lib/openstudio-standards/standards/necb/common/btap_data.rb +0 -2656
  164. data/lib/openstudio-standards/standards/necb/common/btap_datapoint.rb +0 -653
  165. data/lib/openstudio-standards/standards/necb/common/necb_reference_runs.csv +0 -28705
  166. data/lib/openstudio-standards/standards/necb/common/utility_pricing_2025-02-20.csv +0 -92
  167. /data/lib/openstudio-standards/btap/{common_resources → common}/carbon_frame.csv +0 -0
  168. /data/lib/openstudio-standards/btap/{common_resources → common}/carbon_glazing.csv +0 -0
  169. /data/lib/openstudio-standards/btap/{common_resources → common}/carbon_opaque.csv +0 -0
  170. /data/lib/openstudio-standards/btap/{common_resources → common}/hvac_vent_ahu.csv +0 -0
  171. /data/lib/openstudio-standards/btap/{common_resources → common}/lighting.csv +0 -0
  172. /data/lib/openstudio-standards/btap/{common_resources → common}/lighting_sets.csv +0 -0
  173. /data/lib/openstudio-standards/btap/{common_resources → common}/locations.csv +0 -0
  174. /data/lib/openstudio-standards/btap/{costing → common}/mech_sizing.json +0 -0
@@ -1,56 +0,0 @@
1
- # converts the WeatherData1.xlsx spreadsheet into a ruby hash using the rubyXL gem
2
-
3
- require 'csv'
4
- require 'json'
5
- require 'rubyXL'
6
-
7
- begin
8
- csv_file = "#{File.dirname(__FILE__)}/../btap/csvFile1.csv"
9
-
10
- input_file = "#{File.dirname(__FILE__)}/../btap/WeatherData1.xlsx"
11
-
12
- CSV.open(csv_file, 'wb') do |csv|
13
- workbook = RubyXL::Parser.parse input_file
14
- worksheet = workbook[0]
15
-
16
- worksheet.each_with_index do |row, row_idx|
17
- row_data = []
18
- (0...row.size).each do |col_idx|
19
- begin
20
- cell = row[col_idx]
21
- val = cell.value
22
- row_data << val
23
- rescue NoMethodError
24
- row_data << ''
25
- end
26
- end
27
- csv << row_data
28
- end
29
- end
30
- rescue StandardError
31
- end
32
-
33
- data_json_hash = CSV.open(csv_file, headers: true).map(&:to_h).to_json
34
-
35
- File.write("#{File.dirname(__FILE__)}/../btap/csvToJsonUpdate.json", data_json_hash)
36
-
37
- data_hash = JSON.parse(File.read("#{File.dirname(__FILE__)}/../btap/csvToJsonUpdate.json"))
38
-
39
- data_hash.each do |info|
40
- info['hdd18'] = info['hdd18'].to_i
41
- info['hdd15'] = info['hdd15'].to_i
42
- info['cdd18'] = info['cdd18'].to_i
43
- info['latitude'] = info['latitude'].to_f
44
- info['longitude'] = info['longitude'].to_f
45
- info['elevation'] = info['elevation'].to_i
46
- info['deltadb'] = info['deltadb'].to_f
47
- info['mau_type'] = true
48
- end
49
-
50
- pretty_output = JSON.pretty_generate(data_hash)
51
-
52
- File.delete("#{File.dirname(__FILE__)}/../btap/csvToJsonUpdate.json")
53
-
54
- File.delete("#{File.dirname(__FILE__)}/../btap/csvFile1.csv")
55
-
56
- File.write("#{File.dirname(__FILE__)}/../btap/WeatherData1.json", pretty_output)
@@ -1,161 +0,0 @@
1
- # *********************************************************************
2
- # * Copyright (c) 2008-2015, Natural Resources Canada
3
- # * All rights reserved.
4
- # *
5
- # * This library is free software; you can redistribute it and/or
6
- # * modify it under the terms of the GNU Lesser General Public
7
- # * License as published by the Free Software Foundation; either
8
- # * version 2.1 of the License, or (at your option) any later version.
9
- # *
10
- # * This library is distributed in the hope that it will be useful,
11
- # * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- # * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- # * Lesser General Public License for more details.
14
- # *
15
- # * You should have received a copy of the GNU Lesser General Public
16
- # * License along with this library; if not, write to the Free Software
17
- # * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18
- # **********************************************************************/
19
-
20
- # To change this template, choose Tools | Templates
21
- # and open the template in the editor.
22
-
23
- class Vintagizer
24
-
25
- #This method loads Vintage database information.
26
- #@author phylroy.lopez@nrcan.gc.ca
27
- #@param model [OpenStudio::Model::Model] A model object
28
- #@param file [String]
29
- #@param selectionHash [???]
30
- def initialize(model,file,selectionHash)
31
- #Load Vintage database information.
32
- end
33
-
34
- #This method will (????).
35
- #@author phylroy.lopez@nrcan.gc.ca
36
- #@param construction_file [String]
37
- #@param construction_set_name [String]
38
- #@param vintage [String]
39
- #@param building_type [String]
40
- #@param climate_zone [String]
41
- #@return [String] climate_zone
42
- def envelope(construction_file,construction_set_name,vintage,building_type,climate_zone)
43
-
44
- #Load Construction Lib set. "C:/OSRuby/Resources/DND/Trenton/TrentonConstructionsLibrary.osm"
45
- construction_lib = BTAP::FileIO::load_osm(construction_file)
46
- #Create temp model library.
47
- library = BTAP::FileIO::load_osm("C:/OSRuby/Resources/DOEArchetypes/blank.osm", "blank")
48
- #get construction set by type and vintage.. I/O expensive so doing it here.
49
- vintage_construction_set = construction_lib.getDefaultConstructionSetByName("#{ construction_type[0] }#{ vintage }").get
50
-
51
- #Construct name for new construction set.
52
- construction_id = "#{construction_type[0]}-#{vintage}-#{wall_retrofit[0]}-#{roof_retrofit[0]}-#{glazing_retrofit[0]}"
53
-
54
- new_construction_set =vintage_construction_set.clone(library).to_DefaultConstructionSet.get
55
-
56
- new_construction_set =vintage_construction_set.clone(library).to_DefaultConstructionSet.get
57
- #Set conductances to needed values in construction set if possible.
58
- BTAP::Resources::Envelope::ConstructionSets::customize_default_surface_construction_set_rsi!(
59
- library,
60
- construction_id,
61
- new_construction_set,
62
- 1.0 / ext_wall_ecm_info[0],
63
- 1.0 / ext_roof_ecm_info[0],
64
- 1.0 / ext_roof_ecm_info[0],
65
- 1.0 / ground_cond[0],
66
- 1.0 / ground_cond[0],
67
- 1.0 / ground_cond[0],
68
- glazing_ecm_info[0],
69
- glazing_ecm_info[1],
70
- glazing_ecm_info[2],
71
- glazing_ecm_info[0],
72
- glazing_ecm_info[1],
73
- glazing_ecm_info[2]
74
- )
75
-
76
- #Define costs
77
- BTAP::Resources::Envelope::ConstructionSets::customize_default_surface_construction_set_costs(new_construction_set,
78
- ext_wall_ecm_info[1],
79
- ext_roof_ecm_info[1],
80
- ext_roof_ecm_info[1],
81
- ground_cond[1],
82
- ground_cond[1],
83
- ground_cond[1],
84
- glazing_ecm_info[3],
85
- glazing_ecm_info[3],
86
- 0.0, #doors
87
- 0.0, #glass doors
88
- 0.0, #overhead doors
89
- 0.0, #skylight
90
- 0.0, #tubular_daylight_dome_cost =
91
- 0.0 #tubular_daylight_diffuser_cost
92
- )
93
-
94
- #Remove all existing constructions from model.
95
- BTAP::Resources::Envelope::remove_all_envelope_information( constructions_model )
96
- #Save to model.
97
- new_construction_set.setName(construction_id)
98
- constructions_model.building.get.setDefaultConstructionSet( new_construction_set.clone( constructions_model ).to_DefaultConstructionSet.get )
99
-
100
- #Give adiabatic surfaces a construction. Does not matter what. This is a bug in OpenStudio that leave these surfaces unassigned by the default construction set.
101
- all_adiabatic_surfaces = BTAP::Geometry::Surfaces::filter_by_boundary_condition(constructions_model.getSurfaces, "Adiabatic")
102
- wall_construction = constructions_model.building.get.defaultConstructionSet.get.defaultInteriorSurfaceConstructions.get.wallConstruction.get
103
- all_adiabatic_surfaces.each { |surface| surface.setConstruction(wall_construction) }
104
- end
105
-
106
- #This method will set infiltration magnitude.
107
- #@author phylroy.lopez@nrcan.gc.ca
108
- def infiltration()
109
- BTAP::Resources::SpaceLoads::ScaleLoads::set_inflitration_magnitude( constructions_model,
110
- 0.0, #setDesignFlowRate,
111
- 0.0, #setFlowperSpaceFloorArea,
112
- 0.0, #setFlowperExteriorSurfaceArea,
113
- 0.0 #setAirChangesperHour
114
- )
115
- end
116
-
117
- #This method will get and set the coiling coil fan Speed COP
118
- #@author phylroy.lopez@nrcan.gc.ca
119
- def fan_eff()
120
- #DX Coil COP ECMs
121
- unless 'default' == cop_info[1]
122
- constructions_model.getCoilCoolingDXSingleSpeeds.sort.each do |cooling_coil|
123
- cooling_coil.setRatedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ))
124
- end
125
- constructions_model.getCoilCoolingDXTwoSpeeds.sort.each do |cooling_coil|
126
- cooling_coil.setRatedHighSpeedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ) )
127
- cooling_coil.setRatedLowSpeedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ))
128
- end
129
- end
130
- end
131
-
132
- #This method will get and set the coiling coil pump Speed COP
133
- #@author phylroy.lopez@nrcan.gc.ca
134
- def pump_eff()
135
- #DX Coil COP ECMs
136
- unless 'default' == cop_info[1]
137
- constructions_model.getCoilCoolingDXSingleSpeeds.sort.each do |cooling_coil|
138
- cooling_coil.setRatedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ))
139
- end
140
- constructions_model.getCoilCoolingDXTwoSpeeds.sort.each do |cooling_coil|
141
- cooling_coil.setRatedHighSpeedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ) )
142
- cooling_coil.setRatedLowSpeedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ))
143
- end
144
- end
145
- end
146
-
147
- #This method will set the coiling coil COP
148
- #@author phylroy.lopez@nrcan.gc.ca
149
- def cop()
150
- #DX Coil COP ECMs
151
- unless 'default' == cop_info[1]
152
- constructions_model.getCoilCoolingDXSingleSpeeds.sort.each do |cooling_coil|
153
- cooling_coil.setRatedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ) )
154
- end
155
- constructions_model.getCoilCoolingDXTwoSpeeds.sort.each do |cooling_coil|
156
- cooling_coil.setRatedHighSpeedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ) )
157
- cooling_coil.setRatedLowSpeedCOP( OpenStudio::OptionalDouble.new( cop_info[1][0] ) )
158
- end
159
- end
160
- end
161
- end
@@ -1,72 +0,0 @@
1
- # *********************************************************************
2
- # * Copyright (c) 2008-2015, Natural Resources Canada
3
- # * All rights reserved.
4
- # *
5
- # * This library is free software; you can redistribute it and/or
6
- # * modify it under the terms of the GNU Lesser General Public
7
- # * License as published by the Free Software Foundation; either
8
- # * version 2.1 of the License, or (at your option) any later version.
9
- # *
10
- # * This library is distributed in the hope that it will be useful,
11
- # * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- # * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- # * Lesser General Public License for more details.
14
- # *
15
- # * You should have received a copy of the GNU Lesser General Public
16
- # * License along with this library; if not, write to the Free Software
17
- # * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18
- # **********************************************************************/
19
-
20
- require 'csv'
21
-
22
- module BTAP
23
-
24
- module Visualization
25
- class GraphEmbedder
26
- @destination_file
27
- @html_file
28
- Embedded_Definition_Start = "var EMBEDDED_ARRAY = "
29
- Embedded_Function_Call = "processEmbeddedArray(EMBEDDED_ARRAY);\n"
30
-
31
- #This method sets the global parameters for the GraphicEmbedder destination file and html file.
32
- #@author phylroy.lopez@nrcan.gc.ca
33
- #@param dest_file [String] sets the global parameters for the GraphicEmbedder destination file
34
- #@param html_file [String] sets the global parameters for the GraphicEmbedder html file
35
- def initialize(dest_file,html_file)
36
- @destination_file = dest_file
37
- @html_file = html_file
38
- end
39
-
40
- #This method will create embedding.
41
- #@author phylroy.lopez@nrcan.gc.ca
42
- #@param csv_file [String] path to csv file
43
- def create_embedding(csv_file)
44
- newfile = File.open(@destination_file, 'w')
45
- File.open(@html_file,'r').each do |line|
46
- if line.include? "!!Ruby Anchor!!"
47
- newfile.write(Embedded_Definition_Start + GraphEmbedder.get_array_as_string(csv_file) + ";\n")
48
- newfile.write(Embedded_Function_Call)
49
- else
50
- newfile.write(line)
51
- end
52
- end
53
- newfile.close
54
- end
55
-
56
- #This method will return an array as a string.
57
- #@author phylroy.lopez@nrcan.gc.ca
58
- #@param csv_file [String] path to csv file
59
- #@return [string_array<String>]
60
- def self.get_array_as_string(csv_file)
61
- csv = CSV.open(csv_file,'r')
62
- string_array = csv.to_a.inspect
63
- string_array = string_array.sub(/nil/,"\"\"")
64
- return string_array
65
- end
66
-
67
- end
68
-
69
- g = GraphEmbedder.new("C:\\OSRuby\\visualization\\graph\\embedded.html","C:\\OSRuby\\visualization\\graph\\pc-graph.html")
70
- g.create_embedding("C:\\OSRuby\\visualization\\graph\\datatest.csv")
71
- end
72
- end
@@ -1,225 +0,0 @@
1
- template,building_type,space_type,lighting_per_area_w_per_m2,occupancy_per_area_people_per_m2,occupancy_schedule,electric_equipment_per_area_w_per_m2,service_water_heating_peak_flow_per_area_gal_per_h_ft2
2
- NECB 2011,Space Function,- undefined -,0,0,,0,0
3
- NECB 2011,Space Function,Atrium - H < 13m,0,0.099996771,NECB-C-Occupancy,2.499976774,0
4
- NECB 2011,Space Function,Atrium - H > 13m,0,0.099996771,NECB-C-Occupancy,2.499976774,0
5
- NECB 2011,Space Function,Audience - auditorium,8.499921034,0.199993542,NECB-C-Occupancy,2.499976774,0.002839298
6
- NECB 2011,Space Function,Audience - motion picture,12.29988573,0.199993542,NECB-C-Occupancy,2.499976774,0.002839298
7
- NECB 2011,Space Function,Audience - performance arts,26.1997566,0.133364907,NECB-C-Occupancy,2.499976774,0.001893375
8
- NECB 2011,Space Function,Automotive - repair,7.19993311,0.050052205,NECB-E-Occupancy,4.999953548,0.002138732
9
- NECB 2011,Space Function,Bank - banking and offices,14.89986158,0.040041764,NECB-A-Occupancy,4.999953548,0.001142515
10
- NECB 2011,Space Function,Classroom/lecture/training,13.29987644,0.133364907,NECB-D-Occupancy,4.999953548,0.004120874
11
- NECB 2011,Space Function,Conf./meet./multi-purpose,13.19987737,0.199993542,NECB-C-Occupancy,0.999990712,0.004286783
12
- NECB 2011,Space Function,Convention centre - audience,8.799918246,0.199993542,NECB-C-Occupancy,2.499976774,0.002839298
13
- NECB 2011,Space Function,Convention centre - exhibit,15.59985507,0.199993542,NECB-C-Occupancy,2.499976774,0.002839298
14
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-A,8.399921959,0.010010441,NECB-A-Occupancy,0,0
15
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-B,8.399921959,0.010010441,NECB-B-Occupancy,0,0
16
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-C,8.399921959,0.010010441,NECB-C-Occupancy,0,0
17
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-D,8.399921959,0.010010441,NECB-D-Occupancy,0,0
18
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-E,8.399921959,0.010010441,NECB-E-Occupancy,0,0
19
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-F,8.399921959,0.010010441,NECB-F-Occupancy,0,0
20
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-G,8.399921959,0.010010441,NECB-G-Occupancy,0,0
21
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-H,8.399921959,0.010010441,NECB-H-Occupancy,0,0
22
- NECB 2011,Space Function,Corr. < 2.4m wide-sch-I,8.399921959,0.010010441,NECB-I-Occupancy,0,0
23
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-A,7.099934035,0.010010441,NECB-A-Occupancy,0,0
24
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-B,7.099934035,0.010010441,NECB-B-Occupancy,0,0
25
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-C,7.099934035,0.010010441,NECB-C-Occupancy,0,0
26
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-D,7.099934035,0.010010441,NECB-D-Occupancy,0,0
27
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-E,7.099934035,0.010010441,NECB-E-Occupancy,0,0
28
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-F,7.099934035,0.010010441,NECB-F-Occupancy,0,0
29
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-G,7.099934035,0.010010441,NECB-G-Occupancy,0,0
30
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-H,7.099934035,0.010010441,NECB-H-Occupancy,0,0
31
- NECB 2011,Space Function,Corr. >= 2.4m wide-sch-I,7.099934035,0.010010441,NECB-I-Occupancy,0,0
32
- NECB 2011,Space Function,Courthouse - cell,14.69986343,0.040041764,NECB-H-Occupancy,2.499976774,0.006180727
33
- NECB 2011,Space Function,Courthouse - chambers,12.59988294,0.050052205,NECB-A-Occupancy,7.499930322,0.002138732
34
- NECB 2011,Space Function,Courthouse - courtroom,18.49982813,0.199993542,NECB-A-Occupancy,2.499976774,0.002839298
35
- NECB 2011,Space Function,Dining - bar lounge/leisure,14.09986901,0.099996771,NECB-B-Occupancy,0.999990712,0.004272865
36
- NECB 2011,Space Function,Dining - family space,9.599910809,0.099996771,NECB-B-Occupancy,0.999990712,0.005692514
37
- NECB 2011,Space Function,Dining - other,6.999934972,0.099996771,NECB-B-Occupancy,0.999990712,0.005692514
38
- NECB 2011,Space Function,Dormitory - living quarters,4.099961911,0.040041764,NECB-G-Occupancy,2.499976774,0.009507954
39
- NECB 2011,Space Function,Dress./fitt. - performance arts,4.299960049,0.033368137,NECB-C-Occupancy,2.499976774,0.000631634
40
- NECB 2011,Space Function,Dwelling Unit(s),4.999953548,0.016684068,NECB-G-Occupancy,4.999953548,0.003961647
41
- NECB 2011,Space Function,Electrical/Mechanical-sch-A,13.29987644,0.004951401,NECB-A-Occupancy,0.999990712,0
42
- NECB 2011,Space Function,Electrical/Mechanical-sch-B,13.29987644,0.004951401,NECB-B-Occupancy,0.999990712,0
43
- NECB 2011,Space Function,Electrical/Mechanical-sch-C,13.29987644,0.004951401,NECB-C-Occupancy,0.999990712,0
44
- NECB 2011,Space Function,Electrical/Mechanical-sch-D,13.29987644,0.004951401,NECB-D-Occupancy,0.999990712,0
45
- NECB 2011,Space Function,Electrical/Mechanical-sch-E,13.29987644,0.004951401,NECB-E-Occupancy,0.999990712,0
46
- NECB 2011,Space Function,Electrical/Mechanical-sch-F,13.29987644,0.004951401,NECB-F-Occupancy,0.999990712,0
47
- NECB 2011,Space Function,Electrical/Mechanical-sch-G,13.29987644,0.004951401,NECB-G-Occupancy,0.999990712,0
48
- NECB 2011,Space Function,Electrical/Mechanical-sch-H,13.29987644,0.004951401,NECB-H-Occupancy,0.999990712,0
49
- NECB 2011,Space Function,Electrical/Mechanical-sch-I,13.29987644,0.004951401,NECB-I-Occupancy,0.999990712,0
50
- NECB 2011,Space Function,Fire station - engine room,5.99994426,0.040041764,NECB-H-Occupancy,2.499976774,0.006180727
51
- NECB 2011,Space Function,Fire station - quarters,3.399968411,0.040041764,NECB-G-Occupancy,2.499976774,0.009507954
52
- NECB 2011,Space Function,Food preparation,10.6999006,0.050052205,NECB-B-Occupancy,9.999907096,0.002849321
53
- NECB 2011,Space Function,Food preparation - vented,10.6999006,0.050052205,NECB-B-Occupancy,9.999907096,0.002849321
54
- NECB 2011,Space Function,Gym - audience,4.599957261,0.199993542,NECB-B-Occupancy,0,0.002839298
55
- NECB 2011,Space Function,Gym - fitness,9.799908958,0.199993542,NECB-B-Occupancy,0.999990712,0.00854573
56
- NECB 2011,Space Function,Gym - play,12.89988016,0.199993542,NECB-B-Occupancy,1.499986062,0.00854573
57
- NECB 2011,Space Function,Hospital - emergency,24.29977425,0.050052205,NECB-H-Occupancy,9.999907096,0.004277465
58
- NECB 2011,Space Function,Hospital - exam,17.89983371,0.050052205,NECB-C-Occupancy,9.999907096,0.002138732
59
- NECB 2011,Space Function,Hospital - laundry/washing,7.999925683,0.050052205,NECB-C-Occupancy,19.99981419,0.001428144
60
- NECB 2011,Space Function,Hospital - lounge/recreation,11.49989316,0.099996771,NECB-B-Occupancy,0.999990712,0.002853216
61
- NECB 2011,Space Function,Hospital - medical supply,13.69987272,0.050052205,NECB-H-Occupancy,0.999990712,0
62
- NECB 2011,Space Function,Hospital - nursery,9.499911746,0.050052205,NECB-H-Occupancy,9.999907096,0.002138732
63
- NECB 2011,Space Function,Hospital - nurses' station,9.399912671,0.050052205,NECB-H-Occupancy,2.499976774,0.001072849
64
- NECB 2011,Space Function,Hospital - operating room,20.2998114,0.050052205,NECB-H-Occupancy,9.999907096,0.007133752
65
- NECB 2011,Space Function,Hospital - patient room,6.699937759,0.050052205,NECB-H-Occupancy,9.999907096,0.002138732
66
- NECB 2011,Space Function,Hospital - pharmacy,12.29988573,0.050052205,NECB-C-Occupancy,2.499976774,0.001072849
67
- NECB 2011,Space Function,Hospital - physical therapy,9.799908958,0.050052205,NECB-C-Occupancy,9.999907096,0.001072849
68
- NECB 2011,Space Function,Hospital - radiology/imaging,14.19986808,0.050052205,NECB-H-Occupancy,9.999907096,0.002138732
69
- NECB 2011,Space Function,Hospital - recovery,12.39988481,0.050052205,NECB-H-Occupancy,9.999907096,0.004277465
70
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-A,11.69989131,0.010010441,NECB-A-Occupancy,0,0
71
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-B,11.69989131,0.010010441,NECB-B-Occupancy,0,0
72
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-C,11.69989131,0.010010441,NECB-C-Occupancy,0,0
73
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-D,11.69989131,0.010010441,NECB-D-Occupancy,0,0
74
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-E,11.69989131,0.010010441,NECB-E-Occupancy,0,0
75
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-F,11.69989131,0.010010441,NECB-F-Occupancy,0,0
76
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-G,11.69989131,0.010010441,NECB-G-Occupancy,0,0
77
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-H,11.69989131,0.010010441,NECB-H-Occupancy,0,0
78
- NECB 2011,Space Function,Hospital corr. < 2.4m-sch-I,11.69989131,0.010010441,NECB-I-Occupancy,0,0
79
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-A,9.599910809,0.010010441,NECB-A-Occupancy,0,0
80
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-B,9.599910809,0.010010441,NECB-B-Occupancy,0,0
81
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-C,9.599910809,0.010010441,NECB-C-Occupancy,0,0
82
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-D,9.599910809,0.010010441,NECB-D-Occupancy,0,0
83
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-E,9.599910809,0.010010441,NECB-E-Occupancy,0,0
84
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-F,9.599910809,0.010010441,NECB-F-Occupancy,0,0
85
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-G,9.599910809,0.010010441,NECB-G-Occupancy,0,0
86
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-H,9.599910809,0.010010441,NECB-H-Occupancy,0,0
87
- NECB 2011,Space Function,Hospital corr. >= 2.4m-sch-I,9.599910809,0.010010441,NECB-I-Occupancy,0,0
88
- NECB 2011,Space Function,Hotel/Motel - dining,8.799918246,0.099996771,NECB-B-Occupancy,0.999990712,0.005455906
89
- NECB 2011,Space Function,Hotel/Motel - lobby,11.39989409,0.099996771,NECB-H-Occupancy,2.499976774,0.001419649
90
- NECB 2011,Space Function,Hotel/Motel - rooms,11.89988945,0.040041764,NECB-F-Occupancy,2.499976774,0.01140843
91
- NECB 2011,Space Function,Hway lodging - dining,9.499911746,0.099996771,NECB-B-Occupancy,0.999990712,0.005455906
92
- NECB 2011,Space Function,Hway lodging - rooms,8.099924747,0.040041764,NECB-F-Occupancy,2.499976774,0.01140843
93
- NECB 2011,Space Function,Lab - classrooms,17.19984021,0.050052205,NECB-D-Occupancy,9.999907096,0.004277465
94
- NECB 2011,Space Function,Lab - research,23.59978075,0.050052205,NECB-A-Occupancy,9.999907096,0.004277465
95
- NECB 2011,Space Function,Library - cataloging,7.799927535,0.050052205,NECB-C-Occupancy,2.499976774,0.002138732
96
- NECB 2011,Space Function,Library - reading,9.999907096,0.050052205,NECB-C-Occupancy,0.999990712,0.002138732
97
- NECB 2011,Space Function,Library - stacks,22.89978725,0.050052205,NECB-C-Occupancy,0,0.002138732
98
- NECB 2011,Space Function,Lobby - elevator,6.899935897,0.099996771,NECB-C-Occupancy,0.999990712,0
99
- NECB 2011,Space Function,Lobby - motion picture,5.599947973,0.099996771,NECB-C-Occupancy,0.999990712,0
100
- NECB 2011,Space Function,Lobby - other,9.699909884,0.099996771,NECB-C-Occupancy,0.999990712,0
101
- NECB 2011,Space Function,Lobby - performance arts,21.49980027,0.099996771,NECB-C-Occupancy,0.999990712,0
102
- NECB 2011,Space Function,Locker room,9.799908958,0.099996771,NECB-*-Occupancy,2.499976774,0
103
- NECB 2011,Space Function,Locker room-sch-A,9.799908958,0.099996771,NECB-A-Occupancy,2.499976774,0
104
- NECB 2011,Space Function,Locker room-sch-B,9.799908958,0.099996771,NECB-B-Occupancy,2.499976774,0
105
- NECB 2011,Space Function,Locker room-sch-C,9.799908958,0.099996771,NECB-C-Occupancy,2.499976774,0
106
- NECB 2011,Space Function,Locker room-sch-D,9.799908958,0.099996771,NECB-D-Occupancy,2.499976774,0
107
- NECB 2011,Space Function,Locker room-sch-E,9.799908958,0.099996771,NECB-E-Occupancy,2.499976774,0
108
- NECB 2011,Space Function,Locker room-sch-F,9.799908958,0.099996771,NECB-F-Occupancy,2.499976774,0
109
- NECB 2011,Space Function,Locker room-sch-G,9.799908958,0.099996771,NECB-G-Occupancy,2.499976774,0
110
- NECB 2011,Space Function,Locker room-sch-H,9.799908958,0.099996771,NECB-H-Occupancy,2.499976774,0
111
- NECB 2011,Space Function,Locker room-sch-I,9.799908958,0.099996771,NECB-I-Occupancy,2.499976774,0
112
- NECB 2011,Space Function,Lounge/recreation,9.399912671,0.099996771,NECB-B-Occupancy,0.999990712,0.002853216
113
- NECB 2011,Space Function,Mfg - 7.5 <= bay H <= 15m,13.19987737,0.033368137,NECB-A-Occupancy,9.999907096,0.001425822
114
- NECB 2011,Space Function,Mfg - bay H < 7.5m,12.79988108,0.033368137,NECB-A-Occupancy,9.999907096,0.001425822
115
- NECB 2011,Space Function,Mfg - bay H > 15m,11.29989502,0.033368137,NECB-A-Occupancy,9.999907096,0.001425822
116
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-A,5.499948899,0.010010441,NECB-A-Occupancy,0,0
117
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-B,5.499948899,0.010010441,NECB-B-Occupancy,0,0
118
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-C,5.499948899,0.010010441,NECB-C-Occupancy,0,0
119
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-D,5.499948899,0.010010441,NECB-D-Occupancy,0,0
120
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-E,5.499948899,0.010010441,NECB-E-Occupancy,0,0
121
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-F,5.499948899,0.010010441,NECB-F-Occupancy,0,0
122
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-G,5.499948899,0.010010441,NECB-G-Occupancy,0,0
123
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-H,5.499948899,0.010010441,NECB-H-Occupancy,0,0
124
- NECB 2011,Space Function,Mfg - corr. < 2.4m-sch-I,5.499948899,0.010010441,NECB-I-Occupancy,0,0
125
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-A,4.399959123,0.010010441,NECB-A-Occupancy,0,0
126
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-B,4.399959123,0.010010441,NECB-B-Occupancy,0,0
127
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-C,4.399959123,0.010010441,NECB-C-Occupancy,0,0
128
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-D,4.399959123,0.010010441,NECB-D-Occupancy,0,0
129
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-E,4.399959123,0.010010441,NECB-E-Occupancy,0,0
130
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-F,4.399959123,0.010010441,NECB-F-Occupancy,0,0
131
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-G,4.399959123,0.010010441,NECB-G-Occupancy,0,0
132
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-H,4.399959123,0.010010441,NECB-H-Occupancy,0,0
133
- NECB 2011,Space Function,Mfg - corr. >= 2.4m-sch-I,4.399959123,0.010010441,NECB-I-Occupancy,0,0
134
- NECB 2011,Space Function,Mfg - detailed,13.89987087,0.033368137,NECB-A-Occupancy,0,0.001425822
135
- NECB 2011,Space Function,Mfg - equipment,13.29987644,0.033368137,NECB-A-Occupancy,9.999907096,0.001425822
136
- NECB 2011,Space Function,Museum - exhibition,11.29989502,0.199993542,NECB-C-Occupancy,2.499976774,0.005706432
137
- NECB 2011,Space Function,Museum - restoration,10.99989781,0.050052205,NECB-A-Occupancy,4.999953548,0.001191281
138
- NECB 2011,Space Function,Office - enclosed,11.89988945,0.050052205,NECB-A-Occupancy,7.499930322,0.002138732
139
- NECB 2011,Space Function,Office - open plan,10.99989781,0.050052205,NECB-A-Occupancy,7.499930322,0.002138732
140
- NECB 2011,Space Function,Parking garage space,1.999981424,0.000968752,NECB-H-Occupancy,0,0
141
- NECB 2011,Space Function,Penitentiary - audience,4.599957261,0.199993542,NECB-C-Occupancy,2.499976774,0.002839298
142
- NECB 2011,Space Function,Penitentiary - classroom,14.39986622,0.133364907,NECB-D-Occupancy,4.999953548,0.004120874
143
- NECB 2011,Space Function,Penitentiary - dining,11.49989316,0.099996771,NECB-B-Occupancy,0.999990712,0.005692514
144
- NECB 2011,Space Function,Post office sorting,10.09990617,0.050052205,NECB-A-Occupancy,7.499930322,0.002138732
145
- NECB 2011,Space Function,Religious - audience,18.19983092,0.199993542,NECB-I-Occupancy,0.999990712,0.001419649
146
- NECB 2011,Space Function,Religious - fellowship hall,6.899935897,0.199993542,NECB-C-Occupancy,0.999990712,0.004286783
147
- NECB 2011,Space Function,Religious - pulpit/choir,18.19983092,0.199993542,NECB-I-Occupancy,0.999990712,0.001419649
148
- NECB 2011,Space Function,Retail - dressing/fitting,9.399912671,0.033368137,NECB-C-Occupancy,2.499976774,0.000631634
149
- NECB 2011,Space Function,Retail - mall concourse,11.79989037,0.050052205,NECB-C-Occupancy,0.999990712,0.000710589
150
- NECB 2011,Space Function,Retail - sales,18.09983184,0.033368137,NECB-C-Occupancy,2.499976774,0.000631634
151
- NECB 2011,Space Function,Sales area,18.09983184,0.033368137,NECB-C-Occupancy,2.499976774,0.000631634
152
- NECB 2011,Space Function,Sports arena - audience,4.599957261,0.199993542,NECB-B-Occupancy,0,0.002839298
153
- NECB 2011,Space Function,Sports arena - court c1,32.399699,0.199993542,NECB-B-Occupancy,1.499986062,0.00854573
154
- NECB 2011,Space Function,Sports arena - court c2,20.69980769,0.199993542,NECB-B-Occupancy,1.499986062,0.00854573
155
- NECB 2011,Space Function,Sports arena - court c3,12.89988016,0.199993542,NECB-B-Occupancy,1.499986062,0.00854573
156
- NECB 2011,Space Function,Sports arena - court c4,7.799927535,0.199993542,NECB-B-Occupancy,1.499986062,0.00854573
157
- NECB 2011,Space Function,Sports arena - ring,28.79973244,0.199993542,NECB-B-Occupancy,1.499986062,0.00854573
158
- NECB 2011,Space Function,Stairway-sch-A,7.399931248,0.004951401,NECB-A-Occupancy,0,0
159
- NECB 2011,Space Function,Stairway-sch-B,7.399931248,0.004951401,NECB-B-Occupancy,0,0
160
- NECB 2011,Space Function,Stairway-sch-C,7.399931248,0.004951401,NECB-C-Occupancy,0,0
161
- NECB 2011,Space Function,Stairway-sch-D,7.399931248,0.004951401,NECB-D-Occupancy,0,0
162
- NECB 2011,Space Function,Stairway-sch-E,7.399931248,0.004951401,NECB-E-Occupancy,0,0
163
- NECB 2011,Space Function,Stairway-sch-F,7.399931248,0.004951401,NECB-F-Occupancy,0,0
164
- NECB 2011,Space Function,Stairway-sch-G,7.399931248,0.004951401,NECB-G-Occupancy,0,0
165
- NECB 2011,Space Function,Stairway-sch-H,7.399931248,0.004951401,NECB-H-Occupancy,0,0
166
- NECB 2011,Space Function,Stairway-sch-I,7.399931248,0.004951401,NECB-I-Occupancy,0,0
167
- NECB 2011,Space Function,Storage area,6.799936823,0.010010441,NECB-E-Occupancy,0.999990712,0.00142675
168
- NECB 2011,Space Function,Storage area - refrigerated,6.799936823,0.010010441,NECB-E-Occupancy,0.999990712,0.00142675
169
- NECB 2011,Space Function,Transp. baggage,8.199923821,0.050052205,NECB-H-Occupancy,2.499976774,0.001546575
170
- NECB 2011,Space Function,Transp. concourse,3.899963773,0.050052205,NECB-H-Occupancy,0,0.003089824
171
- NECB 2011,Space Function,Transp. counter,11.59989223,0.099996771,NECB-H-Occupancy,2.499976774,0.003089824
172
- NECB 2011,Space Function,Transp. seating,5.799946122,0.099996771,NECB-H-Occupancy,0,0.001546575
173
- NECB 2011,Space Function,Warehouse - fine,10.19990524,0.020020882,NECB-A-Occupancy,0.999990712,0.00061863
174
- NECB 2011,Space Function,Warehouse - fine - refrigerated,10.19990524,0.020020882,NECB-A-Occupancy,0.999990712,0.00061863
175
- NECB 2011,Space Function,Warehouse - med/blk,6.399940547,0.010010441,NECB-A-Occupancy,0.999990712,0.000309315
176
- NECB 2011,Space Function,Warehouse - med/blk - refrigerated,6.399940547,0.010010441,NECB-A-Occupancy,0.999990712,0.000309315
177
- NECB 2011,Space Function,Warehouse - med/blk2,10.19990524,0.010010441,NECB-A-Occupancy,0.999990712,0.000309315
178
- NECB 2011,Space Function,Warehouse - med/blk2 - refrigerated,10.19990524,0.010010441,NECB-A-Occupancy,0.999990712,0.000309315
179
- NECB 2011,Space Function,Washroom-sch-A,10.49990246,0.033368137,NECB-A-Occupancy,0.999990712,0
180
- NECB 2011,Space Function,Washroom-sch-B,10.49990246,0.033368137,NECB-B-Occupancy,0.999990712,0
181
- NECB 2011,Space Function,Washroom-sch-C,10.49990246,0.033368137,NECB-C-Occupancy,0.999990712,0
182
- NECB 2011,Space Function,Washroom-sch-D,10.49990246,0.033368137,NECB-D-Occupancy,0.999990712,0
183
- NECB 2011,Space Function,Washroom-sch-E,10.49990246,0.033368137,NECB-E-Occupancy,0.999990712,0
184
- NECB 2011,Space Function,Washroom-sch-F,10.49990246,0.033368137,NECB-F-Occupancy,0.999990712,0
185
- NECB 2011,Space Function,Washroom-sch-G,10.49990246,0.033368137,NECB-G-Occupancy,0.999990712,0
186
- NECB 2011,Space Function,Washroom-sch-H,10.49990246,0.033368137,NECB-H-Occupancy,0.999990712,0
187
- NECB 2011,Space Function,Washroom-sch-I,10.49990246,0.033368137,NECB-I-Occupancy,0.999990712,0
188
- NECB 2011,Convention centre,WholeBuilding,11.59989223,0.124969054,NECB-C-Occupancy,2.499976774,0.001781
189
- NECB 2011,Courthouse,WholeBuilding,11.29989502,0.066628634,NECB-A-Occupancy,4.999953548,0.0019
190
- NECB 2011,Motion picture theatre,WholeBuilding,8.899917321,0.124969054,NECB-C-Occupancy,0.999990712,0.001781
191
- NECB 2011,Performing arts theatre,WholeBuilding,14.99986064,0.124969054,NECB-C-Occupancy,0.999990712,0.001781
192
- NECB 2011,Police station,WholeBuilding,10.29990431,0.040041764,NECB-H-Occupancy,7.499930322,0.00171
193
- NECB 2011,Religious,WholeBuilding,11.29989502,0.199993542,NECB-I-Occupancy,0.999990712,0.001425
194
- NECB 2011,School/university,WholeBuilding,10.6999006,0.124969054,NECB-D-Occupancy,4.999953548,0.003562
195
- NECB 2011,Town hall,WholeBuilding,9.899908022,0.040041764,NECB-D-Occupancy,7.499930322,0.00171
196
- NECB 2011,Automotive facility,WholeBuilding,8.799918246,0.050052205,NECB-E-Occupancy,4.999953548,0.002137
197
- NECB 2011,Fire station,WholeBuilding,7.599929396,0.040041764,NECB-F-Occupancy,2.499976774,0.007599
198
- NECB 2011,Parking garage,WholeBuilding,2.699974912,0.000968752,NECB-H-Occupancy,0,0
199
- NECB 2011,Exercise centre,WholeBuilding,9.499911746,0.099996771,NECB-B-Occupancy,0.999990712,0.004274
200
- NECB 2011,Gymnasium,WholeBuilding,10.79989967,0.099996771,NECB-B-Occupancy,0.999990712,0.004274
201
- NECB 2011,Health-care clinic,WholeBuilding,9.399912671,0.050052205,NECB-A-Occupancy,7.499930322,0.002137
202
- NECB 2011,Office,WholeBuilding,9.699909884,0.040041764,NECB-A-Occupancy,7.499930322,0.00171
203
- NECB 2011,Post office,WholeBuilding,9.399912671,0.040041764,NECB-A-Occupancy,7.499930322,0.00171
204
- NECB 2011,Retail,WholeBuilding,15.09985972,0.033368137,NECB-C-Occupancy,2.499976774,0.000633
205
- NECB 2011,Sports arena,WholeBuilding,8.399921959,0.099996771,NECB-B-Occupancy,0.999990712,0.004274
206
- NECB 2011,Transportation,WholeBuilding,8.299922896,0.066628634,NECB-H-Occupancy,0.999990712,0.002058
207
- NECB 2011,Library,WholeBuilding,12.69988202,0.050052205,NECB-C-Occupancy,2.499976774,0.002137
208
- NECB 2011,Museum,WholeBuilding,11.39989409,0.050052205,NECB-C-Occupancy,2.499976774,0.001425
209
- NECB 2011,Hospital,WholeBuilding,12.99987923,0.050052205,NECB-H-Occupancy,7.499930322,0.002137
210
- NECB 2011,Manufacturing facility,WholeBuilding,11.89988945,0.033368137,NECB-A-Occupancy,9.999907096,0.001425
211
- NECB 2011,Workshop,WholeBuilding,12.89988016,0.033368137,NECB-A-Occupancy,9.999907096,0.001425
212
- NECB 2011,Hotel,WholeBuilding,10.79989967,0.040041764,NECB-F-Occupancy,2.499976774,0.009498
213
- NECB 2011,Motel,WholeBuilding,9.499911746,0.040041764,NECB-F-Occupancy,2.499976774,0.009498
214
- NECB 2011,Multi-unit residential,WholeBuilding,6.49993961,0.016684068,NECB-G-Occupancy,4.999953548,0.003958
215
- NECB 2011,Dormitory,WholeBuilding,6.599938685,0.033368137,NECB-G-Occupancy,2.499976774,0.007915
216
- NECB 2011,Penitentiary,WholeBuilding,10.39990338,0.033368137,NECB-H-Occupancy,2.499976774,0.006332
217
- NECB 2011,Dining - bar/lounge,WholeBuilding,10.6999006,0.099996771,NECB-B-Occupancy,0.999990712,0.005462
218
- NECB 2011,Dining - cafeteria,WholeBuilding,9.699909884,0.099996771,NECB-B-Occupancy,0.999990712,0.005462
219
- NECB 2011,Dining - family,WholeBuilding,9.599910809,0.099996771,NECB-B-Occupancy,0.999990712,0.005462
220
- NECB 2011,Warehouse,WholeBuilding,7.099934035,0.000645835,NECB-A-Occupancy,0.999990712,9.50E-05
221
- NECB 2011,Warehouse - refrigerated,WholeBuilding,7.099934035,0.000645835,NECB-A-Occupancy,0.999990712,9.50E-05
222
- NECB 2011,Space Function,Workshop space,17.09984114,0.033368137,NECB-A-Occupancy,9.999907096,0.001425822
223
- NECB 2011,Space Function,Office - enclosed - occsens,10.70991548,0.050052205,NECB-A-Occupancy,7.499940809,0.002138732
224
- NECB 2011,Space Function,Storage area - occsens,6.119951702,0.010010441,NECB-E-Occupancy,0.99999211,0.00142675
225
- NECB 2011,Space Function,Storage area - refrigerated - occsens,6.119951702,0.010010441,NECB-E-Occupancy,0.99999211,0.00142675
@@ -1,79 +0,0 @@
1
- require 'openstudio'
2
-
3
- # BTAP Analysis:
4
- # Class to instantiate post-analysis mechanisms like costing or carbon
5
- # calculation.
6
- # Can be done during a simulation or without one given an OSM file and its SQL
7
- # file, along with a few other parameters.
8
-
9
- # Abstract class, only instantiate BTAPNoSimAnalysis or BTAPDatapointAnalysis.
10
- class BTAPAnalysis
11
- def initialize(output_folder:, template:)
12
- @output_folder = output_folder
13
- @template = template
14
- @cp = CommonPaths.instance
15
- end
16
-
17
- def run_costing(costs_csv: @cp.costs_path, factors_csv: @cp.costs_local_factors_path)
18
- costing = BTAPCosting.new(costs_csv: costs_csv, factors_csv: factors_csv, attributes: @attributes)
19
-
20
- cost_result, btap_items = costing.cost_audit_all(
21
- model: @model,
22
- prototype_creator: @standard,
23
- template_type: @template)
24
-
25
- if not @qaqc.nil?
26
- @qaqc[:costing_information] = cost_result
27
- end
28
-
29
- # disable openstudio-version; for debugging only
30
- # cost_result["openstudio-version"] = OpenstudioStandards::VERSION
31
- File.open(File.join(@output_folder, 'cost_results.json'), 'w') do |f|
32
- f.write(JSON.pretty_generate(cost_result, allow_nan: true))
33
- end
34
- puts "Wrote File cost_results.json in #{@output_folder} "
35
-
36
- return cost_result
37
- end
38
-
39
- def run_carbon
40
- carbon = BTAPCarbon.new(attributes: @attributes, standards_data: @standard.standards_data)
41
- carbon_result = carbon.audit_embodied_carbon
42
-
43
- if not @qaqc.nil?
44
- @qaqc[:carbon_information] = carbon_result
45
- end
46
-
47
- File.open(File.join(@output_folder, 'carbon_results.json'), 'w') do |f|
48
- f.write(JSON.pretty_generate(carbon_result, allow_nan: true))
49
- end
50
- puts "Wrote File carbon_results.json in #{@output_folder} "
51
-
52
- return carbon_result
53
- end
54
- end
55
-
56
- # For a no-simulation run, the SQL file, template, and datapoint ID must be provided.
57
- class BTAPNoSimAnalysis < BTAPAnalysis
58
- def initialize(model_path:, sql_file_path:, output_folder:, template:, datapoint_id:, analysis_id: SecureRandom.uuid)
59
- super(output_folder: output_folder, template: template)
60
- @model = BTAP::FileIO.load_osm(model_path)
61
- @template = template
62
- @standard = Standard.build(template)
63
- @datapoint_id = datapoint_id
64
- @analysis_id = analysis_id
65
- @attributes = BTAP::Attributes.new(@model, @standard)
66
- @model.setSqlFile(OpenStudio::SqlFile.new(sql_file_path))
67
- @qaqc = BTAPDatapoint.build_qaqc(@model, @standard, @datapoint_id, @analysis_id)
68
- end
69
- end
70
-
71
- class BTAPDatapointAnalysis < BTAPAnalysis
72
- def initialize(model:, output_folder:, template:, standard:, qaqc:)
73
- super(output_folder: output_folder, template: template)
74
- @model = model
75
- @standard = standard
76
- @qaqc = qaqc
77
- @attributes = BTAP::Attributes.new(@model, @standard)
78
- end
79
- end