Skip to content

Commit 6ad895f

Browse files
committed
Merge branch 'master' of https://github.com/NREL/OpenStudio-HPXML into stochastic_occupancy_paper
# Conflicts: # BuildResidentialScheduleFile/measure.xml
2 parents bb16756 + b4b0889 commit 6ad895f

33 files changed

+1610
-1582
lines changed

BuildResidentialHPXML/measure.rb

+19-19
Original file line numberDiff line numberDiff line change
@@ -3440,7 +3440,7 @@ def arguments(model) # rubocop:disable Lint/UnusedMethodArgument
34403440
# @param model [OpenStudio::Model::Model] OpenStudio Model object
34413441
# @param runner [OpenStudio::Measure::OSRunner] OpenStudio Runner object
34423442
# @param user_arguments [OpenStudio::Measure::OSArgumentMap] OpenStudio measure arguments
3443-
# @return [Boolean] TODO
3443+
# @return [Boolean] true if successful
34443444
def run(model, runner, user_arguments)
34453445
super(model, runner, user_arguments)
34463446

@@ -3982,7 +3982,7 @@ def self.unavailable_period_exists(hpxml, column_name, begin_month, begin_day, b
39823982
# @param runner [OpenStudio::Measure::OSRunner] OpenStudio Runner object
39833983
# @param hpxml [HPXML] HPXML object
39843984
# @param args [Hash] Map of :argument_name => value
3985-
# @return [Boolean] TODO
3985+
# @return [Boolean] true if no errors, otherwise false
39863986
def self.set_header(runner, hpxml, args)
39873987
errors = []
39883988

@@ -4647,7 +4647,7 @@ def self.set_air_infiltration_measurements(hpxml_bldg, args)
46474647
#
46484648
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
46494649
# @param args [Hash] Map of :argument_name => value
4650-
# @param sorted_surfaces [TODO] TODO
4650+
# @param sorted_surfaces [Array<OpenStudio::Model::Surface>] surfaces sorted by deterministically assigned Index
46514651
def self.set_roofs(hpxml_bldg, args, sorted_surfaces)
46524652
args[:geometry_roof_pitch] *= 12.0
46534653
if (args[:geometry_attic_type] == HPXML::AtticTypeFlatRoof) || (args[:geometry_attic_type] == HPXML::AtticTypeBelowApartment)
@@ -4695,7 +4695,7 @@ def self.set_roofs(hpxml_bldg, args, sorted_surfaces)
46954695
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
46964696
# @param model [OpenStudio::Model::Model] OpenStudio Model object
46974697
# @param args [Hash] Map of :argument_name => value
4698-
# @param sorted_surfaces [TODO] TODO
4698+
# @param sorted_surfaces [Array<OpenStudio::Model::Surface>] surfaces sorted by deterministically assigned Index
46994699
def self.set_rim_joists(hpxml_bldg, model, args, sorted_surfaces)
47004700
sorted_surfaces.each do |surface|
47014701
next if surface.surfaceType != 'Wall'
@@ -4757,7 +4757,7 @@ def self.set_rim_joists(hpxml_bldg, model, args, sorted_surfaces)
47574757
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
47584758
# @param model [OpenStudio::Model::Model] OpenStudio Model object
47594759
# @param args [Hash] Map of :argument_name => value
4760-
# @param sorted_surfaces [TODO] TODO
4760+
# @param sorted_surfaces [Array<OpenStudio::Model::Surface>] surfaces sorted by deterministically assigned Index
47614761
def self.set_walls(hpxml_bldg, model, args, sorted_surfaces)
47624762
sorted_surfaces.each do |surface|
47634763
next if surface.surfaceType != 'Wall'
@@ -4850,7 +4850,7 @@ def self.set_walls(hpxml_bldg, model, args, sorted_surfaces)
48504850
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
48514851
# @param model [OpenStudio::Model::Model] OpenStudio Model object
48524852
# @param args [Hash] Map of :argument_name => value
4853-
# @param sorted_surfaces [TODO] TODO
4853+
# @param sorted_surfaces [Array<OpenStudio::Model::Surface>] surfaces sorted by deterministically assigned Index
48544854
def self.set_foundation_walls(hpxml_bldg, model, args, sorted_surfaces)
48554855
sorted_surfaces.each do |surface|
48564856
next if surface.surfaceType != 'Wall'
@@ -4936,7 +4936,7 @@ def self.set_foundation_walls(hpxml_bldg, model, args, sorted_surfaces)
49364936
#
49374937
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
49384938
# @param args [Hash] Map of :argument_name => value
4939-
# @param sorted_surfaces [TODO] TODO
4939+
# @param sorted_surfaces [Array<OpenStudio::Model::Surface>] surfaces sorted by deterministically assigned Index
49404940
def self.set_floors(hpxml_bldg, args, sorted_surfaces)
49414941
if [HPXML::FoundationTypeBasementConditioned,
49424942
HPXML::FoundationTypeCrawlspaceConditioned].include?(args[:geometry_foundation_type]) && (args[:floor_over_foundation_assembly_r] > 2.1)
@@ -5018,7 +5018,7 @@ def self.set_floors(hpxml_bldg, args, sorted_surfaces)
50185018
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
50195019
# @param model [OpenStudio::Model::Model] OpenStudio Model object
50205020
# @param args [Hash] Map of :argument_name => value
5021-
# @param sorted_surfaces [TODO] TODO
5021+
# @param sorted_surfaces [Array<OpenStudio::Model::Surface>] surfaces sorted by deterministically assigned Index
50225022
def self.set_slabs(hpxml_bldg, model, args, sorted_surfaces)
50235023
sorted_surfaces.each do |surface|
50245024
next unless ['Foundation'].include? surface.outsideBoundaryCondition
@@ -5088,7 +5088,7 @@ def self.set_slabs(hpxml_bldg, model, args, sorted_surfaces)
50885088
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
50895089
# @param model [OpenStudio::Model::Model] OpenStudio Model object
50905090
# @param args [Hash] Map of :argument_name => value
5091-
# @param sorted_surfaces [TODO] TODO
5091+
# @param sorted_subsurfaces [Array<OpenStudio::Model::SubSurface>] subsurfaces sorted by deterministically assigned Index
50925092
def self.set_windows(hpxml_bldg, model, args, sorted_subsurfaces)
50935093
sorted_subsurfaces.each do |sub_surface|
50945094
next if sub_surface.subSurfaceType != 'FixedWindow'
@@ -5164,7 +5164,7 @@ def self.set_windows(hpxml_bldg, model, args, sorted_subsurfaces)
51645164
#
51655165
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
51665166
# @param args [Hash] Map of :argument_name => value
5167-
# @param sorted_subsurfaces [TODO] TODO
5167+
# @param sorted_subsurfaces [Array<OpenStudio::Model::SubSurface>] subsurfaces sorted by deterministically assigned Index
51685168
def self.set_skylights(hpxml_bldg, args, sorted_subsurfaces)
51695169
sorted_subsurfaces.each do |sub_surface|
51705170
next if sub_surface.subSurfaceType != 'Skylight'
@@ -5204,7 +5204,7 @@ def self.set_skylights(hpxml_bldg, args, sorted_subsurfaces)
52045204
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
52055205
# @param model [OpenStudio::Model::Model] OpenStudio Model object
52065206
# @param args [Hash] Map of :argument_name => value
5207-
# @param sorted_subsurfaces [TODO] TODO
5207+
# @param sorted_subsurfaces [Array<OpenStudio::Model::SubSurface>] subsurfaces sorted by deterministically assigned Index
52085208
def self.set_doors(hpxml_bldg, model, args, sorted_subsurfaces)
52095209
sorted_subsurfaces.each do |sub_surface|
52105210
next if sub_surface.subSurfaceType != 'Door'
@@ -5912,11 +5912,11 @@ def self.set_duct_leakages(args, hvac_distribution)
59125912
duct_leakage_total_or_to_outside: HPXML::DuctLeakageToOutside)
59135913
end
59145914

5915-
# Get the specific HPXML location based on general location and foundation/attic type
5915+
# Get the specific HPXML foundation or attic location based on general HPXML location and specific HPXML foundation or attic type.
59165916
#
5917-
# @param location [TODO] TODO
5918-
# @param foundation_type [TODO] TODO
5919-
# @param attic_type [TODO] TODO
5917+
# @param location [String] the general HPXML location (crawlspace or attic)
5918+
# @param foundation_type [String] the specific HPXML foundation type (unvented crawlspace, vented crawlspace, conditioned crawlspace)
5919+
# @param attic_type [String] the specific HPXML attic type (unvented attic, vented attic, conditioned attic)
59205920
def self.get_location(location, foundation_type, attic_type)
59215921
return if location.nil?
59225922

@@ -5952,7 +5952,7 @@ def self.get_location(location, foundation_type, attic_type)
59525952
#
59535953
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
59545954
# @param args [Hash] Map of :argument_name => value
5955-
# @param hvac_distribution [TODO] TODO
5955+
# @param hvac_distribution [HPXML::HVACDistribution] HPXML HVAC Distribution object
59565956
def self.set_ducts(hpxml_bldg, args, hvac_distribution)
59575957
ducts_supply_location = get_location(args[:ducts_supply_location], hpxml_bldg.foundations[-1].foundation_type, hpxml_bldg.attics[-1].attic_type)
59585958
ducts_return_location = get_location(args[:ducts_return_location], hpxml_bldg.foundations[-1].foundation_type, hpxml_bldg.attics[-1].attic_type)
@@ -6069,7 +6069,7 @@ def self.set_ducts(hpxml_bldg, args, hvac_distribution)
60696069
# @param hpxml [HPXML] HPXML object
60706070
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
60716071
# @param args [Hash] Map of :argument_name => value
6072-
# @param epw_file [OpenStudio::EpwFile] TODO
6072+
# @param epw_file [OpenStudio::EpwFile] OpenStudio EpwFile object
60736073
# @param weather [WeatherProcess] Weather object
60746074
def self.set_hvac_control(hpxml, hpxml_bldg, args, epw_file, weather)
60756075
return if (args[:heating_system_type] == 'none') && (args[:cooling_system_type] == 'none') && (args[:heat_pump_type] == 'none')
@@ -6488,7 +6488,7 @@ def self.set_water_fixtures(hpxml_bldg, args)
64886488
#
64896489
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
64906490
# @param args [Hash] Map of :argument_name => value
6491-
# @param epw_file [OpenStudio::EpwFile] TODO
6491+
# @param epw_file [OpenStudio::EpwFile] OpenStudio EpwFile object
64926492
def self.set_solar_thermal(hpxml_bldg, args, epw_file)
64936493
return if args[:solar_thermal_system_type] == 'none'
64946494

@@ -6537,7 +6537,7 @@ def self.set_solar_thermal(hpxml_bldg, args, epw_file)
65376537
#
65386538
# @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
65396539
# @param args [Hash] Map of :argument_name => value
6540-
# @param epw_file [OpenStudio::EpwFile] TODO
6540+
# @param epw_file [OpenStudio::EpwFile] OpenStudio EpwFile object
65416541
def self.set_pv_systems(hpxml_bldg, args, epw_file)
65426542
return unless args[:pv_system_present]
65436543

BuildResidentialHPXML/measure.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
<schema_version>3.1</schema_version>
44
<name>build_residential_hpxml</name>
55
<uid>a13a8983-2b01-4930-8af2-42030b6e4233</uid>
6-
<version_id>e32945f6-3cb8-4f34-95fe-cf1733b6f48e</version_id>
7-
<version_modified>2024-06-05T21:34:41Z</version_modified>
6+
<version_id>5bba0282-12b2-4602-b7cf-7242adce2cab</version_id>
7+
<version_modified>2024-06-20T23:43:28Z</version_modified>
88
<xml_checksum>2C38F48B</xml_checksum>
99
<class_name>BuildResidentialHPXML</class_name>
1010
<display_name>HPXML Builder</display_name>
@@ -7360,13 +7360,13 @@
73607360
<filename>measure.rb</filename>
73617361
<filetype>rb</filetype>
73627362
<usage_type>script</usage_type>
7363-
<checksum>D0586A5E</checksum>
7363+
<checksum>D8FCCD88</checksum>
73647364
</file>
73657365
<file>
73667366
<filename>geometry.rb</filename>
73677367
<filetype>rb</filetype>
73687368
<usage_type>resource</usage_type>
7369-
<checksum>A5BBD88A</checksum>
7369+
<checksum>F6952477</checksum>
73707370
</file>
73717371
<file>
73727372
<filename>test_build_residential_hpxml.rb</filename>

0 commit comments

Comments
 (0)