openstudio-calibration 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +29 -0
- data/CHANGELOG.md +14 -0
- data/Gemfile +20 -0
- data/Jenkinsfile +6 -0
- data/LICENSE.md +27 -0
- data/README.md +33 -0
- data/Rakefile +50 -0
- data/doc_templates/LICENSE.md +27 -0
- data/doc_templates/README.md.erb +42 -0
- data/doc_templates/copyright_erb.txt +36 -0
- data/doc_templates/copyright_js.txt +4 -0
- data/doc_templates/copyright_ruby.txt +34 -0
- data/lib/files/.gitkeep +0 -0
- data/lib/measures/AddMonthlyJSONUtilityData/LICENSE.md +27 -0
- data/lib/measures/AddMonthlyJSONUtilityData/README.md +96 -0
- data/lib/measures/AddMonthlyJSONUtilityData/README.md.erb +42 -0
- data/lib/measures/AddMonthlyJSONUtilityData/measure.rb +280 -0
- data/lib/measures/AddMonthlyJSONUtilityData/measure.xml +163 -0
- data/lib/measures/AddMonthlyUtilityData/LICENSE.md +27 -0
- data/lib/measures/AddMonthlyUtilityData/README.md +64 -0
- data/lib/measures/AddMonthlyUtilityData/README.md.erb +42 -0
- data/lib/measures/AddMonthlyUtilityData/measure.rb +312 -0
- data/lib/measures/AddMonthlyUtilityData/measure.xml +115 -0
- data/lib/measures/AddMonthlyUtilityData/tests/AddMonthlyUtilityData_Test.rb +88 -0
- data/lib/measures/AddMonthlyUtilityData/tests/electric_billed_usages.json +198 -0
- data/lib/measures/AddMonthlyUtilityData/tests/gas_billed_usages.json +198 -0
- data/lib/measures/CalibrationReports/LICENSE.md +27 -0
- data/lib/measures/CalibrationReports/README.md +26 -0
- data/lib/measures/CalibrationReports/README.md.erb +42 -0
- data/lib/measures/CalibrationReports/measure.rb +511 -0
- data/lib/measures/CalibrationReports/measure.xml +98 -0
- data/lib/measures/CalibrationReports/resources/report.html.in +379 -0
- data/lib/measures/CalibrationReports/tests/CalibrationReports_Test.rb +523 -0
- data/lib/measures/CalibrationReports/tests/ExampleModel.osm +10497 -0
- data/lib/measures/CalibrationReports/tests/ExampleModelNoDemandInput.osm +10560 -0
- data/lib/measures/CalibrationReports/tests/ExampleModelNoGasInput.osm +10456 -0
- data/lib/measures/CalibrationReports/tests/USA_CO_Golden-NREL.724666_TMY3.epw +8768 -0
- data/lib/measures/CalibrationReportsEnhanced/LICENSE.md +27 -0
- data/lib/measures/CalibrationReportsEnhanced/README.md +143 -0
- data/lib/measures/CalibrationReportsEnhanced/README.md.erb +42 -0
- data/lib/measures/CalibrationReportsEnhanced/measure.rb +798 -0
- data/lib/measures/CalibrationReportsEnhanced/measure.xml +372 -0
- data/lib/measures/CalibrationReportsEnhanced/resources/report.html.in +380 -0
- data/lib/measures/CalibrationReportsEnhanced/tests/CalibrationReportsEnhanced_Test.rb +734 -0
- data/lib/measures/CalibrationReportsEnhanced/tests/ExampleModel.osm +10497 -0
- data/lib/measures/CalibrationReportsEnhanced/tests/ExampleModel_FuelOil.osm +12740 -0
- data/lib/measures/CalibrationReportsEnhanced/tests/USA_CO_Golden-NREL.724666_TMY3.epw +8768 -0
- data/lib/measures/CalibrationReportsEnhanced21/LICENSE.md +27 -0
- data/lib/measures/CalibrationReportsEnhanced21/README.md +109 -0
- data/lib/measures/CalibrationReportsEnhanced21/README.md.erb +42 -0
- data/lib/measures/CalibrationReportsEnhanced21/measure.rb +690 -0
- data/lib/measures/CalibrationReportsEnhanced21/measure.xml +269 -0
- data/lib/measures/CalibrationReportsEnhanced21/resources/report.html.in +380 -0
- data/lib/measures/CoilCoolingDXSingleSpeedMultiplier/LICENSE.md +27 -0
- data/lib/measures/CoilCoolingDXSingleSpeedMultiplier/README.md +48 -0
- data/lib/measures/CoilCoolingDXSingleSpeedMultiplier/README.md.erb +42 -0
- data/lib/measures/CoilCoolingDXSingleSpeedMultiplier/measure.rb +237 -0
- data/lib/measures/CoilCoolingDXSingleSpeedMultiplier/measure.xml +93 -0
- data/lib/measures/CoilCoolingDXSingleSpeedPercentChange/LICENSE.md +27 -0
- data/lib/measures/CoilCoolingDXSingleSpeedPercentChange/README.md +48 -0
- data/lib/measures/CoilCoolingDXSingleSpeedPercentChange/README.md.erb +42 -0
- data/lib/measures/CoilCoolingDXSingleSpeedPercentChange/measure.rb +228 -0
- data/lib/measures/CoilCoolingDXSingleSpeedPercentChange/measure.xml +93 -0
- data/lib/measures/CoilCoolingDXTwoSpeedMultiplier/LICENSE.md +27 -0
- data/lib/measures/CoilCoolingDXTwoSpeedMultiplier/README.md +64 -0
- data/lib/measures/CoilCoolingDXTwoSpeedMultiplier/README.md.erb +42 -0
- data/lib/measures/CoilCoolingDXTwoSpeedMultiplier/measure.rb +280 -0
- data/lib/measures/CoilCoolingDXTwoSpeedMultiplier/measure.xml +111 -0
- data/lib/measures/CoilCoolingDXTwoSpeedPercentChange/LICENSE.md +27 -0
- data/lib/measures/CoilCoolingDXTwoSpeedPercentChange/README.md +64 -0
- data/lib/measures/CoilCoolingDXTwoSpeedPercentChange/README.md.erb +42 -0
- data/lib/measures/CoilCoolingDXTwoSpeedPercentChange/measure.rb +270 -0
- data/lib/measures/CoilCoolingDXTwoSpeedPercentChange/measure.xml +111 -0
- data/lib/measures/CoilCoolingWaterMultiplier/LICENSE.md +27 -0
- data/lib/measures/CoilCoolingWaterMultiplier/README.md +80 -0
- data/lib/measures/CoilCoolingWaterMultiplier/README.md.erb +42 -0
- data/lib/measures/CoilCoolingWaterMultiplier/measure.rb +324 -0
- data/lib/measures/CoilCoolingWaterMultiplier/measure.xml +129 -0
- data/lib/measures/CoilCoolingWaterPercentChange/LICENSE.md +27 -0
- data/lib/measures/CoilCoolingWaterPercentChange/README.md +80 -0
- data/lib/measures/CoilCoolingWaterPercentChange/README.md.erb +42 -0
- data/lib/measures/CoilCoolingWaterPercentChange/measure.rb +311 -0
- data/lib/measures/CoilCoolingWaterPercentChange/measure.xml +129 -0
- data/lib/measures/CoilHeatingElectricMultiplier/LICENSE.md +27 -0
- data/lib/measures/CoilHeatingElectricMultiplier/README.md +48 -0
- data/lib/measures/CoilHeatingElectricMultiplier/README.md.erb +42 -0
- data/lib/measures/CoilHeatingElectricMultiplier/measure.rb +240 -0
- data/lib/measures/CoilHeatingElectricMultiplier/measure.xml +93 -0
- data/lib/measures/CoilHeatingElectricPercentChange/LICENSE.md +27 -0
- data/lib/measures/CoilHeatingElectricPercentChange/README.md +48 -0
- data/lib/measures/CoilHeatingElectricPercentChange/README.md.erb +42 -0
- data/lib/measures/CoilHeatingElectricPercentChange/measure.rb +231 -0
- data/lib/measures/CoilHeatingElectricPercentChange/measure.xml +93 -0
- data/lib/measures/CoilHeatingGasMultiplier/LICENSE.md +27 -0
- data/lib/measures/CoilHeatingGasMultiplier/README.md +64 -0
- data/lib/measures/CoilHeatingGasMultiplier/README.md.erb +42 -0
- data/lib/measures/CoilHeatingGasMultiplier/measure.rb +282 -0
- data/lib/measures/CoilHeatingGasMultiplier/measure.xml +111 -0
- data/lib/measures/CoilHeatingGasPercentChange/LICENSE.md +27 -0
- data/lib/measures/CoilHeatingGasPercentChange/README.md +64 -0
- data/lib/measures/CoilHeatingGasPercentChange/README.md.erb +42 -0
- data/lib/measures/CoilHeatingGasPercentChange/measure.rb +271 -0
- data/lib/measures/CoilHeatingGasPercentChange/measure.xml +111 -0
- data/lib/measures/CoilHeatingWaterMultiplier/LICENSE.md +27 -0
- data/lib/measures/CoilHeatingWaterMultiplier/README.md +48 -0
- data/lib/measures/CoilHeatingWaterMultiplier/README.md.erb +42 -0
- data/lib/measures/CoilHeatingWaterMultiplier/measure.rb +235 -0
- data/lib/measures/CoilHeatingWaterMultiplier/measure.xml +93 -0
- data/lib/measures/CoilHeatingWaterPercentChange/LICENSE.md +27 -0
- data/lib/measures/CoilHeatingWaterPercentChange/README.md +48 -0
- data/lib/measures/CoilHeatingWaterPercentChange/README.md.erb +42 -0
- data/lib/measures/CoilHeatingWaterPercentChange/measure.rb +226 -0
- data/lib/measures/CoilHeatingWaterPercentChange/measure.xml +93 -0
- data/lib/measures/ConstructionLayerZeroMaterialProperties/LICENSE.md +27 -0
- data/lib/measures/ConstructionLayerZeroMaterialProperties/README.md +88 -0
- data/lib/measures/ConstructionLayerZeroMaterialProperties/README.md.erb +42 -0
- data/lib/measures/ConstructionLayerZeroMaterialProperties/measure.rb +221 -0
- data/lib/measures/ConstructionLayerZeroMaterialProperties/measure.xml +194 -0
- data/lib/measures/ElectricBaseboardEfficiencyAndCapacity/LICENSE.md +27 -0
- data/lib/measures/ElectricBaseboardEfficiencyAndCapacity/README.md +40 -0
- data/lib/measures/ElectricBaseboardEfficiencyAndCapacity/README.md.erb +42 -0
- data/lib/measures/ElectricBaseboardEfficiencyAndCapacity/measure.rb +102 -0
- data/lib/measures/ElectricBaseboardEfficiencyAndCapacity/measure.xml +78 -0
- data/lib/measures/ExteriorWallThermalPropertiesMultiplier/LICENSE.md +27 -0
- data/lib/measures/ExteriorWallThermalPropertiesMultiplier/README.md +48 -0
- data/lib/measures/ExteriorWallThermalPropertiesMultiplier/README.md.erb +42 -0
- data/lib/measures/ExteriorWallThermalPropertiesMultiplier/measure.rb +263 -0
- data/lib/measures/ExteriorWallThermalPropertiesMultiplier/measure.xml +97 -0
- data/lib/measures/ExteriorWallThermalPropertiesPercentChange/LICENSE.md +27 -0
- data/lib/measures/ExteriorWallThermalPropertiesPercentChange/README.md +48 -0
- data/lib/measures/ExteriorWallThermalPropertiesPercentChange/README.md.erb +42 -0
- data/lib/measures/ExteriorWallThermalPropertiesPercentChange/measure.rb +253 -0
- data/lib/measures/ExteriorWallThermalPropertiesPercentChange/measure.xml +97 -0
- data/lib/measures/FansMultiplier/LICENSE.md +27 -0
- data/lib/measures/FansMultiplier/README.md +64 -0
- data/lib/measures/FansMultiplier/README.md.erb +42 -0
- data/lib/measures/FansMultiplier/measure.rb +297 -0
- data/lib/measures/FansMultiplier/measure.xml +166 -0
- data/lib/measures/FansPercentChange/LICENSE.md +27 -0
- data/lib/measures/FansPercentChange/README.md +64 -0
- data/lib/measures/FansPercentChange/README.md.erb +42 -0
- data/lib/measures/FansPercentChange/measure.rb +286 -0
- data/lib/measures/FansPercentChange/measure.xml +166 -0
- data/lib/measures/GeneralCalibrationMeasureMultiplier/LICENSE.md +27 -0
- data/lib/measures/GeneralCalibrationMeasureMultiplier/README.md +112 -0
- data/lib/measures/GeneralCalibrationMeasureMultiplier/README.md.erb +42 -0
- data/lib/measures/GeneralCalibrationMeasureMultiplier/measure.rb +639 -0
- data/lib/measures/GeneralCalibrationMeasureMultiplier/measure.xml +229 -0
- data/lib/measures/GeneralCalibrationMeasurePercentChange/LICENSE.md +27 -0
- data/lib/measures/GeneralCalibrationMeasurePercentChange/README.md +112 -0
- data/lib/measures/GeneralCalibrationMeasurePercentChange/README.md.erb +42 -0
- data/lib/measures/GeneralCalibrationMeasurePercentChange/measure.rb +756 -0
- data/lib/measures/GeneralCalibrationMeasurePercentChange/measure.xml +229 -0
- data/lib/measures/HardSizeHvac/LICENSE.md +27 -0
- data/lib/measures/HardSizeHvac/README.md +26 -0
- data/lib/measures/HardSizeHvac/README.md.erb +42 -0
- data/lib/measures/HardSizeHvac/measure.rb +88 -0
- data/lib/measures/HardSizeHvac/measure.xml +81 -0
- data/lib/measures/MaalkaMonthlyJSONUtilityData/LICENSE.md +27 -0
- data/lib/measures/MaalkaMonthlyJSONUtilityData/README.md +104 -0
- data/lib/measures/MaalkaMonthlyJSONUtilityData/README.md.erb +42 -0
- data/lib/measures/MaalkaMonthlyJSONUtilityData/measure.rb +304 -0
- data/lib/measures/MaalkaMonthlyJSONUtilityData/measure.xml +216 -0
- data/lib/measures/RValueOfInsulationForConstructionMultiplier/LICENSE.md +27 -0
- data/lib/measures/RValueOfInsulationForConstructionMultiplier/README.md +40 -0
- data/lib/measures/RValueOfInsulationForConstructionMultiplier/README.md.erb +42 -0
- data/lib/measures/RValueOfInsulationForConstructionMultiplier/measure.rb +196 -0
- data/lib/measures/RValueOfInsulationForConstructionMultiplier/measure.xml +132 -0
- data/lib/measures/RValueOfInsulationForConstructionPercentageChange/LICENSE.md +27 -0
- data/lib/measures/RValueOfInsulationForConstructionPercentageChange/README.md +40 -0
- data/lib/measures/RValueOfInsulationForConstructionPercentageChange/README.md.erb +42 -0
- data/lib/measures/RValueOfInsulationForConstructionPercentageChange/measure.rb +189 -0
- data/lib/measures/RValueOfInsulationForConstructionPercentageChange/measure.xml +132 -0
- data/lib/measures/RoofThermalPropertiesMultiplier/LICENSE.md +27 -0
- data/lib/measures/RoofThermalPropertiesMultiplier/README.md +48 -0
- data/lib/measures/RoofThermalPropertiesMultiplier/README.md.erb +42 -0
- data/lib/measures/RoofThermalPropertiesMultiplier/measure.rb +263 -0
- data/lib/measures/RoofThermalPropertiesMultiplier/measure.xml +97 -0
- data/lib/measures/RoofThermalPropertiesPercentChange/LICENSE.md +27 -0
- data/lib/measures/RoofThermalPropertiesPercentChange/README.md +48 -0
- data/lib/measures/RoofThermalPropertiesPercentChange/README.md.erb +42 -0
- data/lib/measures/RoofThermalPropertiesPercentChange/measure.rb +253 -0
- data/lib/measures/RoofThermalPropertiesPercentChange/measure.xml +97 -0
- data/lib/measures/TimeseriesObjectiveFunction/LICENSE.md +27 -0
- data/lib/measures/TimeseriesObjectiveFunction/README.md +207 -0
- data/lib/measures/TimeseriesObjectiveFunction/README.md.erb +42 -0
- data/lib/measures/TimeseriesObjectiveFunction/measure.rb +748 -0
- data/lib/measures/TimeseriesObjectiveFunction/measure.xml +435 -0
- data/lib/measures/TimeseriesObjectiveFunction/resources/report.html.erb +288 -0
- data/lib/measures/TimeseriesPlot/LICENSE.md +27 -0
- data/lib/measures/TimeseriesPlot/README.md +56 -0
- data/lib/measures/TimeseriesPlot/README.md.erb +42 -0
- data/lib/measures/TimeseriesPlot/measure.rb +302 -0
- data/lib/measures/TimeseriesPlot/measure.xml +137 -0
- data/lib/measures/TimeseriesPlot/resources/report.html.erb +270 -0
- data/lib/measures/WaterHeaterMixedMultiplier/LICENSE.md +27 -0
- data/lib/measures/WaterHeaterMixedMultiplier/README.md +64 -0
- data/lib/measures/WaterHeaterMixedMultiplier/README.md.erb +42 -0
- data/lib/measures/WaterHeaterMixedMultiplier/measure.rb +255 -0
- data/lib/measures/WaterHeaterMixedMultiplier/measure.xml +180 -0
- data/lib/measures/WaterHeaterMixedPercentChange/LICENSE.md +27 -0
- data/lib/measures/WaterHeaterMixedPercentChange/README.md +64 -0
- data/lib/measures/WaterHeaterMixedPercentChange/README.md.erb +42 -0
- data/lib/measures/WaterHeaterMixedPercentChange/measure.rb +245 -0
- data/lib/measures/WaterHeaterMixedPercentChange/measure.xml +180 -0
- data/lib/measures/zone_report/LICENSE.md +27 -0
- data/lib/measures/zone_report/README.md +26 -0
- data/lib/measures/zone_report/README.md.erb +42 -0
- data/lib/measures/zone_report/measure.rb +706 -0
- data/lib/measures/zone_report/measure.xml +67 -0
- data/lib/measures/zone_report/resources/report.html.in +342 -0
- data/lib/openstudio-calibration-measures.rb +36 -0
- data/lib/openstudio/calibration_measures.rb +37 -0
- data/lib/openstudio/calibration_measures/extension.rb +49 -0
- data/lib/openstudio/calibration_measures/version.rb +40 -0
- data/openstudio-calibration.gemspec +30 -0
- metadata +331 -0
@@ -0,0 +1,115 @@
|
|
1
|
+
<measure>
|
2
|
+
<schema_version>3.0</schema_version>
|
3
|
+
<name>add_monthly_utility_data</name>
|
4
|
+
<uid>6da969e0-4256-49bf-9607-26504cc3d421</uid>
|
5
|
+
<version_id>20a22623-b2ff-4b69-b182-2dea1bf995b3</version_id>
|
6
|
+
<version_modified>20200325T030944Z</version_modified>
|
7
|
+
<xml_checksum>9064277D</xml_checksum>
|
8
|
+
<class_name>AddMonthlyUtilityData</class_name>
|
9
|
+
<display_name>AddMonthlyUtilityData</display_name>
|
10
|
+
<description>Reads in custom format and adds utility data</description>
|
11
|
+
<modeler_description>Minimum interval for utility data is one day</modeler_description>
|
12
|
+
<arguments>
|
13
|
+
<argument>
|
14
|
+
<name>electric_json</name>
|
15
|
+
<display_name>Path to electric JSON</display_name>
|
16
|
+
<type>String</type>
|
17
|
+
<required>true</required>
|
18
|
+
<model_dependent>false</model_dependent>
|
19
|
+
</argument>
|
20
|
+
<argument>
|
21
|
+
<name>gas_json</name>
|
22
|
+
<display_name>Path to gas JSON</display_name>
|
23
|
+
<type>String</type>
|
24
|
+
<required>true</required>
|
25
|
+
<model_dependent>false</model_dependent>
|
26
|
+
</argument>
|
27
|
+
<argument>
|
28
|
+
<name>water_json</name>
|
29
|
+
<display_name>Path to water JSON</display_name>
|
30
|
+
<type>String</type>
|
31
|
+
<required>false</required>
|
32
|
+
<model_dependent>false</model_dependent>
|
33
|
+
</argument>
|
34
|
+
<argument>
|
35
|
+
<name>start_date</name>
|
36
|
+
<display_name>Start date</display_name>
|
37
|
+
<type>String</type>
|
38
|
+
<required>true</required>
|
39
|
+
<model_dependent>false</model_dependent>
|
40
|
+
</argument>
|
41
|
+
<argument>
|
42
|
+
<name>end_date</name>
|
43
|
+
<display_name>End date</display_name>
|
44
|
+
<type>String</type>
|
45
|
+
<required>true</required>
|
46
|
+
<model_dependent>false</model_dependent>
|
47
|
+
</argument>
|
48
|
+
</arguments>
|
49
|
+
<outputs/>
|
50
|
+
<provenances/>
|
51
|
+
<tags>
|
52
|
+
<tag>Economics.Life Cycle Cost Analysis</tag>
|
53
|
+
</tags>
|
54
|
+
<attributes>
|
55
|
+
<attribute>
|
56
|
+
<name>Measure Type</name>
|
57
|
+
<value>ModelMeasure</value>
|
58
|
+
<datatype>string</datatype>
|
59
|
+
</attribute>
|
60
|
+
<attribute>
|
61
|
+
<name>Uses SketchUp API</name>
|
62
|
+
<value>false</value>
|
63
|
+
<datatype>boolean</datatype>
|
64
|
+
</attribute>
|
65
|
+
</attributes>
|
66
|
+
<files>
|
67
|
+
<file>
|
68
|
+
<filename>electric_billed_usages.json</filename>
|
69
|
+
<filetype>json</filetype>
|
70
|
+
<usage_type>test</usage_type>
|
71
|
+
<checksum>5F884191</checksum>
|
72
|
+
</file>
|
73
|
+
<file>
|
74
|
+
<filename>gas_billed_usages.json</filename>
|
75
|
+
<filetype>json</filetype>
|
76
|
+
<usage_type>test</usage_type>
|
77
|
+
<checksum>379ABCEE</checksum>
|
78
|
+
</file>
|
79
|
+
<file>
|
80
|
+
<filename>LICENSE.md</filename>
|
81
|
+
<filetype>md</filetype>
|
82
|
+
<usage_type>license</usage_type>
|
83
|
+
<checksum>E0468DD6</checksum>
|
84
|
+
</file>
|
85
|
+
<file>
|
86
|
+
<filename>README.md.erb</filename>
|
87
|
+
<filetype>erb</filetype>
|
88
|
+
<usage_type>readmeerb</usage_type>
|
89
|
+
<checksum>703C9964</checksum>
|
90
|
+
</file>
|
91
|
+
<file>
|
92
|
+
<filename>README.md</filename>
|
93
|
+
<filetype>md</filetype>
|
94
|
+
<usage_type>readme</usage_type>
|
95
|
+
<checksum>A8846AF4</checksum>
|
96
|
+
</file>
|
97
|
+
<file>
|
98
|
+
<version>
|
99
|
+
<software_program>OpenStudio</software_program>
|
100
|
+
<identifier>2.0.0</identifier>
|
101
|
+
<min_compatible>2.0.0</min_compatible>
|
102
|
+
</version>
|
103
|
+
<filename>measure.rb</filename>
|
104
|
+
<filetype>rb</filetype>
|
105
|
+
<usage_type>script</usage_type>
|
106
|
+
<checksum>CC58EE3A</checksum>
|
107
|
+
</file>
|
108
|
+
<file>
|
109
|
+
<filename>AddMonthlyUtilityData_Test.rb</filename>
|
110
|
+
<filetype>rb</filetype>
|
111
|
+
<usage_type>test</usage_type>
|
112
|
+
<checksum>977DB51C</checksum>
|
113
|
+
</file>
|
114
|
+
</files>
|
115
|
+
</measure>
|
@@ -0,0 +1,88 @@
|
|
1
|
+
# *******************************************************************************
|
2
|
+
# OpenStudio(R), Copyright (c) 2008-2020, Alliance for Sustainable Energy, LLC.
|
3
|
+
# All rights reserved.
|
4
|
+
# Redistribution and use in source and binary forms, with or without
|
5
|
+
# modification, are permitted provided that the following conditions are met:
|
6
|
+
#
|
7
|
+
# (1) Redistributions of source code must retain the above copyright notice,
|
8
|
+
# this list of conditions and the following disclaimer.
|
9
|
+
#
|
10
|
+
# (2) Redistributions in binary form must reproduce the above copyright notice,
|
11
|
+
# this list of conditions and the following disclaimer in the documentation
|
12
|
+
# and/or other materials provided with the distribution.
|
13
|
+
#
|
14
|
+
# (3) Neither the name of the copyright holder nor the names of any contributors
|
15
|
+
# may be used to endorse or promote products derived from this software without
|
16
|
+
# specific prior written permission from the respective party.
|
17
|
+
#
|
18
|
+
# (4) Other than as required in clauses (1) and (2), distributions in any form
|
19
|
+
# of modifications or other derivative works may not use the "OpenStudio"
|
20
|
+
# trademark, "OS", "os", or any other confusingly similar designation without
|
21
|
+
# specific prior written permission from Alliance for Sustainable Energy, LLC.
|
22
|
+
#
|
23
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) AND ANY CONTRIBUTORS
|
24
|
+
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
25
|
+
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
26
|
+
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S), ANY CONTRIBUTORS, THE
|
27
|
+
# UNITED STATES GOVERNMENT, OR THE UNITED STATES DEPARTMENT OF ENERGY, NOR ANY OF
|
28
|
+
# THEIR EMPLOYEES, BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
29
|
+
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
30
|
+
# OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
31
|
+
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
32
|
+
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
33
|
+
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
34
|
+
# *******************************************************************************
|
35
|
+
|
36
|
+
require 'openstudio'
|
37
|
+
|
38
|
+
require 'openstudio/ruleset/ShowRunnerOutput'
|
39
|
+
|
40
|
+
require "#{File.dirname(__FILE__)}/../measure.rb"
|
41
|
+
|
42
|
+
require 'minitest/autorun'
|
43
|
+
|
44
|
+
class AddMonthlyUtilityData_Test < Minitest::Test
|
45
|
+
def test_AddMonthlyUtilityData
|
46
|
+
# create an instance of the measure
|
47
|
+
measure = AddMonthlyUtilityData.new
|
48
|
+
|
49
|
+
# create an instance of a runner
|
50
|
+
runner = OpenStudio::Measure::OSRunner.new(OpenStudio::WorkflowJSON.new)
|
51
|
+
|
52
|
+
# make an empty model
|
53
|
+
model = OpenStudio::Model::Model.new
|
54
|
+
|
55
|
+
# get arguments and test that they are what we are expecting
|
56
|
+
arguments = measure.arguments(model)
|
57
|
+
assert_equal(5, arguments.size)
|
58
|
+
assert_equal('electric_json', arguments[0].name)
|
59
|
+
assert_equal('gas_json', arguments[1].name)
|
60
|
+
assert_equal('water_json', arguments[2].name)
|
61
|
+
assert_equal('start_date', arguments[3].name)
|
62
|
+
assert_equal('end_date', arguments[4].name)
|
63
|
+
|
64
|
+
# set argument values to good values and run the measure on model with spaces
|
65
|
+
argument_map = OpenStudio::Measure::OSArgumentMap.new
|
66
|
+
|
67
|
+
electric_json = arguments[0].clone
|
68
|
+
assert(electric_json.setValue(File.dirname(__FILE__) + '/electric_billed_usages.json'))
|
69
|
+
argument_map['electric_json'] = electric_json
|
70
|
+
|
71
|
+
gas_json = arguments[1].clone
|
72
|
+
assert(gas_json.setValue(File.dirname(__FILE__) + '/gas_billed_usages.json'))
|
73
|
+
argument_map['gas_json'] = gas_json
|
74
|
+
|
75
|
+
start_date = arguments[2].clone
|
76
|
+
assert(start_date.setValue('2012-06-19'))
|
77
|
+
argument_map['start_date'] = start_date
|
78
|
+
|
79
|
+
end_date = arguments[3].clone
|
80
|
+
assert(end_date.setValue('2013-05-20'))
|
81
|
+
argument_map['end_date'] = end_date
|
82
|
+
|
83
|
+
measure.run(model, runner, argument_map)
|
84
|
+
result = runner.result
|
85
|
+
show_output(result)
|
86
|
+
assert(result.value.valueName == 'Success')
|
87
|
+
end
|
88
|
+
end
|
@@ -0,0 +1,198 @@
|
|
1
|
+
{ "data": [
|
2
|
+
{
|
3
|
+
"accounts": 1,
|
4
|
+
"from": "2011-12-05T00:00:00Z",
|
5
|
+
"peak": 0,
|
6
|
+
"to": "2012-01-06T00:00:00Z",
|
7
|
+
"tot_kwh": 1
|
8
|
+
},
|
9
|
+
{
|
10
|
+
"accounts": 1,
|
11
|
+
"from": "2012-01-06T00:00:00Z",
|
12
|
+
"peak": 0,
|
13
|
+
"to": "2012-02-02T00:00:00Z",
|
14
|
+
"tot_kwh": 2
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"accounts": 1,
|
18
|
+
"from": "2012-02-02T00:00:00Z",
|
19
|
+
"peak": 0,
|
20
|
+
"to": "2012-03-05T00:00:00Z",
|
21
|
+
"tot_kwh": 3
|
22
|
+
},
|
23
|
+
{
|
24
|
+
"accounts": 1,
|
25
|
+
"from": "2012-03-05T00:00:00Z",
|
26
|
+
"peak": 0,
|
27
|
+
"to": "2012-04-02T00:00:00Z",
|
28
|
+
"tot_kwh": 2
|
29
|
+
},
|
30
|
+
{
|
31
|
+
"accounts": 1,
|
32
|
+
"from": "2012-04-02T00:00:00Z",
|
33
|
+
"peak": 0,
|
34
|
+
"to": "2012-05-02T00:00:00Z",
|
35
|
+
"tot_kwh": 3
|
36
|
+
},
|
37
|
+
{
|
38
|
+
"accounts": 1,
|
39
|
+
"from": "2012-05-02T00:00:00Z",
|
40
|
+
"peak": 0,
|
41
|
+
"to": "2012-06-04T00:00:00Z",
|
42
|
+
"tot_kwh": 2
|
43
|
+
},
|
44
|
+
{
|
45
|
+
"accounts": 1,
|
46
|
+
"from": "2012-06-04T00:00:00Z",
|
47
|
+
"peak": 0,
|
48
|
+
"to": "2012-07-02T00:00:00Z",
|
49
|
+
"tot_kwh": 3
|
50
|
+
},
|
51
|
+
{
|
52
|
+
"accounts": 1,
|
53
|
+
"from": "2012-07-02T00:00:00Z",
|
54
|
+
"peak": 0,
|
55
|
+
"to": "2012-08-02T00:00:00Z",
|
56
|
+
"tot_kwh": 2
|
57
|
+
},
|
58
|
+
{
|
59
|
+
"accounts": 1,
|
60
|
+
"from": "2012-08-02T00:00:00Z",
|
61
|
+
"peak": 0,
|
62
|
+
"to": "2012-09-05T00:00:00Z",
|
63
|
+
"tot_kwh": 3
|
64
|
+
},
|
65
|
+
{
|
66
|
+
"accounts": 1,
|
67
|
+
"from": "2012-09-05T00:00:00Z",
|
68
|
+
"peak": 0,
|
69
|
+
"to": "2012-10-02T00:00:00Z",
|
70
|
+
"tot_kwh": 2
|
71
|
+
},
|
72
|
+
{
|
73
|
+
"accounts": 1,
|
74
|
+
"from": "2012-10-02T00:00:00Z",
|
75
|
+
"peak": 0,
|
76
|
+
"to": "2012-11-05T00:00:00Z",
|
77
|
+
"tot_kwh": 3
|
78
|
+
},
|
79
|
+
{
|
80
|
+
"accounts": 1,
|
81
|
+
"from": "2012-11-05T00:00:00Z",
|
82
|
+
"peak": 0,
|
83
|
+
"to": "2012-12-04T00:00:00Z",
|
84
|
+
"tot_kwh": 3
|
85
|
+
},
|
86
|
+
{
|
87
|
+
"accounts": 1,
|
88
|
+
"from": "2012-12-04T00:00:00Z",
|
89
|
+
"peak": 0,
|
90
|
+
"to": "2013-01-03T00:00:00Z",
|
91
|
+
"tot_kwh": 3
|
92
|
+
},
|
93
|
+
{
|
94
|
+
"accounts": 1,
|
95
|
+
"from": "2013-01-03T00:00:00Z",
|
96
|
+
"peak": 0,
|
97
|
+
"to": "2013-02-01T00:00:00Z",
|
98
|
+
"tot_kwh": 2
|
99
|
+
},
|
100
|
+
{
|
101
|
+
"accounts": 1,
|
102
|
+
"from": "2013-02-01T00:00:00Z",
|
103
|
+
"peak": 0,
|
104
|
+
"to": "2013-03-04T00:00:00Z",
|
105
|
+
"tot_kwh": 3
|
106
|
+
},
|
107
|
+
{
|
108
|
+
"accounts": 1,
|
109
|
+
"from": "2013-03-04T00:00:00Z",
|
110
|
+
"peak": 0,
|
111
|
+
"to": "2013-04-02T00:00:00Z",
|
112
|
+
"tot_kwh": 4
|
113
|
+
},
|
114
|
+
{
|
115
|
+
"accounts": 1,
|
116
|
+
"from": "2013-04-02T00:00:00Z",
|
117
|
+
"peak": 0,
|
118
|
+
"to": "2013-05-03T00:00:00Z",
|
119
|
+
"tot_kwh": 3
|
120
|
+
},
|
121
|
+
{
|
122
|
+
"accounts": 1,
|
123
|
+
"from": "2013-05-03T00:00:00Z",
|
124
|
+
"peak": 0,
|
125
|
+
"to": "2013-06-04T00:00:00Z",
|
126
|
+
"tot_kwh": 2
|
127
|
+
},
|
128
|
+
{
|
129
|
+
"accounts": 1,
|
130
|
+
"from": "2013-06-04T00:00:00Z",
|
131
|
+
"peak": 0,
|
132
|
+
"to": "2013-07-02T00:00:00Z",
|
133
|
+
"tot_kwh": 3
|
134
|
+
},
|
135
|
+
{
|
136
|
+
"accounts": 1,
|
137
|
+
"from": "2013-07-02T00:00:00Z",
|
138
|
+
"peak": 0,
|
139
|
+
"to": "2013-08-02T00:00:00Z",
|
140
|
+
"tot_kwh": 2
|
141
|
+
},
|
142
|
+
{
|
143
|
+
"accounts": 1,
|
144
|
+
"from": "2013-08-02T00:00:00Z",
|
145
|
+
"peak": 0,
|
146
|
+
"to": "2013-09-05T00:00:00Z",
|
147
|
+
"tot_kwh": 3
|
148
|
+
},
|
149
|
+
{
|
150
|
+
"accounts": 1,
|
151
|
+
"from": "2013-09-05T00:00:00Z",
|
152
|
+
"peak": 0,
|
153
|
+
"to": "2013-10-03T00:00:00Z",
|
154
|
+
"tot_kwh": 2
|
155
|
+
},
|
156
|
+
{
|
157
|
+
"accounts": 1,
|
158
|
+
"from": "2013-10-03T00:00:00Z",
|
159
|
+
"peak": 0,
|
160
|
+
"to": "2013-10-31T00:00:00Z",
|
161
|
+
"tot_kwh": 3
|
162
|
+
},
|
163
|
+
{
|
164
|
+
"accounts": 1,
|
165
|
+
"from": "2013-10-31T00:00:00Z",
|
166
|
+
"peak": 0,
|
167
|
+
"to": "2013-12-03T00:00:00Z",
|
168
|
+
"tot_kwh": 4
|
169
|
+
},
|
170
|
+
{
|
171
|
+
"accounts": 1,
|
172
|
+
"from": "2013-12-03T00:00:00Z",
|
173
|
+
"peak": 0,
|
174
|
+
"to": "2014-01-06T00:00:00Z",
|
175
|
+
"tot_kwh": 3
|
176
|
+
},
|
177
|
+
{
|
178
|
+
"accounts": 1,
|
179
|
+
"from": "2014-01-06T00:00:00Z",
|
180
|
+
"peak": 0,
|
181
|
+
"to": "2014-02-03T00:00:00Z",
|
182
|
+
"tot_kwh": 3
|
183
|
+
},
|
184
|
+
{
|
185
|
+
"accounts": 1,
|
186
|
+
"from": "2014-02-03T00:00:00Z",
|
187
|
+
"peak": 0,
|
188
|
+
"to": "2014-03-04T00:00:00Z",
|
189
|
+
"tot_kwh": 3
|
190
|
+
},
|
191
|
+
{
|
192
|
+
"accounts": 1,
|
193
|
+
"from": "2014-03-04T00:00:00Z",
|
194
|
+
"peak": 0,
|
195
|
+
"to": "2014-04-02T00:00:00Z",
|
196
|
+
"tot_kwh": 3
|
197
|
+
}
|
198
|
+
] }
|
@@ -0,0 +1,198 @@
|
|
1
|
+
{ "data": [
|
2
|
+
{
|
3
|
+
"accounts": 1,
|
4
|
+
"from": "2011-12-05T00:00:00Z",
|
5
|
+
"peak": 0,
|
6
|
+
"to": "2012-01-06T00:00:00Z",
|
7
|
+
"tot_therms": 1
|
8
|
+
},
|
9
|
+
{
|
10
|
+
"accounts": 1,
|
11
|
+
"from": "2012-01-06T00:00:00Z",
|
12
|
+
"peak": 0,
|
13
|
+
"to": "2012-02-02T00:00:00Z",
|
14
|
+
"tot_therms": 2
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"accounts": 1,
|
18
|
+
"from": "2012-02-02T00:00:00Z",
|
19
|
+
"peak": 0,
|
20
|
+
"to": "2012-03-05T00:00:00Z",
|
21
|
+
"tot_therms": 3
|
22
|
+
},
|
23
|
+
{
|
24
|
+
"accounts": 1,
|
25
|
+
"from": "2012-03-05T00:00:00Z",
|
26
|
+
"peak": 0,
|
27
|
+
"to": "2012-04-02T00:00:00Z",
|
28
|
+
"tot_therms": 2
|
29
|
+
},
|
30
|
+
{
|
31
|
+
"accounts": 1,
|
32
|
+
"from": "2012-04-02T00:00:00Z",
|
33
|
+
"peak": 0,
|
34
|
+
"to": "2012-05-02T00:00:00Z",
|
35
|
+
"tot_therms": 3
|
36
|
+
},
|
37
|
+
{
|
38
|
+
"accounts": 1,
|
39
|
+
"from": "2012-05-02T00:00:00Z",
|
40
|
+
"peak": 0,
|
41
|
+
"to": "2012-06-04T00:00:00Z",
|
42
|
+
"tot_therms": 2
|
43
|
+
},
|
44
|
+
{
|
45
|
+
"accounts": 1,
|
46
|
+
"from": "2012-06-04T00:00:00Z",
|
47
|
+
"peak": 0,
|
48
|
+
"to": "2012-07-02T00:00:00Z",
|
49
|
+
"tot_therms": 3
|
50
|
+
},
|
51
|
+
{
|
52
|
+
"accounts": 1,
|
53
|
+
"from": "2012-07-02T00:00:00Z",
|
54
|
+
"peak": 0,
|
55
|
+
"to": "2012-08-02T00:00:00Z",
|
56
|
+
"tot_therms": 2
|
57
|
+
},
|
58
|
+
{
|
59
|
+
"accounts": 1,
|
60
|
+
"from": "2012-08-02T00:00:00Z",
|
61
|
+
"peak": 0,
|
62
|
+
"to": "2012-09-05T00:00:00Z",
|
63
|
+
"tot_therms": 3
|
64
|
+
},
|
65
|
+
{
|
66
|
+
"accounts": 1,
|
67
|
+
"from": "2012-09-05T00:00:00Z",
|
68
|
+
"peak": 0,
|
69
|
+
"to": "2012-10-02T00:00:00Z",
|
70
|
+
"tot_therms": 2
|
71
|
+
},
|
72
|
+
{
|
73
|
+
"accounts": 1,
|
74
|
+
"from": "2012-10-02T00:00:00Z",
|
75
|
+
"peak": 0,
|
76
|
+
"to": "2012-11-05T00:00:00Z",
|
77
|
+
"tot_therms": 3
|
78
|
+
},
|
79
|
+
{
|
80
|
+
"accounts": 1,
|
81
|
+
"from": "2012-11-05T00:00:00Z",
|
82
|
+
"peak": 0,
|
83
|
+
"to": "2012-12-04T00:00:00Z",
|
84
|
+
"tot_therms": 3
|
85
|
+
},
|
86
|
+
{
|
87
|
+
"accounts": 1,
|
88
|
+
"from": "2012-12-04T00:00:00Z",
|
89
|
+
"peak": 0,
|
90
|
+
"to": "2013-01-03T00:00:00Z",
|
91
|
+
"tot_therms": 3
|
92
|
+
},
|
93
|
+
{
|
94
|
+
"accounts": 1,
|
95
|
+
"from": "2013-01-03T00:00:00Z",
|
96
|
+
"peak": 0,
|
97
|
+
"to": "2013-02-01T00:00:00Z",
|
98
|
+
"tot_therms": 2
|
99
|
+
},
|
100
|
+
{
|
101
|
+
"accounts": 1,
|
102
|
+
"from": "2013-02-01T00:00:00Z",
|
103
|
+
"peak": 0,
|
104
|
+
"to": "2013-03-04T00:00:00Z",
|
105
|
+
"tot_therms": 3
|
106
|
+
},
|
107
|
+
{
|
108
|
+
"accounts": 1,
|
109
|
+
"from": "2013-03-04T00:00:00Z",
|
110
|
+
"peak": 0,
|
111
|
+
"to": "2013-04-02T00:00:00Z",
|
112
|
+
"tot_therms": 4
|
113
|
+
},
|
114
|
+
{
|
115
|
+
"accounts": 1,
|
116
|
+
"from": "2013-04-02T00:00:00Z",
|
117
|
+
"peak": 0,
|
118
|
+
"to": "2013-05-03T00:00:00Z",
|
119
|
+
"tot_therms": 3
|
120
|
+
},
|
121
|
+
{
|
122
|
+
"accounts": 1,
|
123
|
+
"from": "2013-05-03T00:00:00Z",
|
124
|
+
"peak": 0,
|
125
|
+
"to": "2013-06-04T00:00:00Z",
|
126
|
+
"tot_therms": 2
|
127
|
+
},
|
128
|
+
{
|
129
|
+
"accounts": 1,
|
130
|
+
"from": "2013-06-04T00:00:00Z",
|
131
|
+
"peak": 0,
|
132
|
+
"to": "2013-07-02T00:00:00Z",
|
133
|
+
"tot_therms": 3
|
134
|
+
},
|
135
|
+
{
|
136
|
+
"accounts": 1,
|
137
|
+
"from": "2013-07-02T00:00:00Z",
|
138
|
+
"peak": 0,
|
139
|
+
"to": "2013-08-02T00:00:00Z",
|
140
|
+
"tot_therms": 2
|
141
|
+
},
|
142
|
+
{
|
143
|
+
"accounts": 1,
|
144
|
+
"from": "2013-08-02T00:00:00Z",
|
145
|
+
"peak": 0,
|
146
|
+
"to": "2013-09-05T00:00:00Z",
|
147
|
+
"tot_therms": 3
|
148
|
+
},
|
149
|
+
{
|
150
|
+
"accounts": 1,
|
151
|
+
"from": "2013-09-05T00:00:00Z",
|
152
|
+
"peak": 0,
|
153
|
+
"to": "2013-10-03T00:00:00Z",
|
154
|
+
"tot_therms": 2
|
155
|
+
},
|
156
|
+
{
|
157
|
+
"accounts": 1,
|
158
|
+
"from": "2013-10-03T00:00:00Z",
|
159
|
+
"peak": 0,
|
160
|
+
"to": "2013-10-31T00:00:00Z",
|
161
|
+
"tot_therms": 3
|
162
|
+
},
|
163
|
+
{
|
164
|
+
"accounts": 1,
|
165
|
+
"from": "2013-10-31T00:00:00Z",
|
166
|
+
"peak": 0,
|
167
|
+
"to": "2013-12-03T00:00:00Z",
|
168
|
+
"tot_therms": 4
|
169
|
+
},
|
170
|
+
{
|
171
|
+
"accounts": 1,
|
172
|
+
"from": "2013-12-03T00:00:00Z",
|
173
|
+
"peak": 0,
|
174
|
+
"to": "2014-01-06T00:00:00Z",
|
175
|
+
"tot_therms": 3
|
176
|
+
},
|
177
|
+
{
|
178
|
+
"accounts": 1,
|
179
|
+
"from": "2014-01-06T00:00:00Z",
|
180
|
+
"peak": 0,
|
181
|
+
"to": "2014-02-03T00:00:00Z",
|
182
|
+
"tot_therms": 3
|
183
|
+
},
|
184
|
+
{
|
185
|
+
"accounts": 1,
|
186
|
+
"from": "2014-02-03T00:00:00Z",
|
187
|
+
"peak": 0,
|
188
|
+
"to": "2014-03-04T00:00:00Z",
|
189
|
+
"tot_therms": 3
|
190
|
+
},
|
191
|
+
{
|
192
|
+
"accounts": 1,
|
193
|
+
"from": "2014-03-04T00:00:00Z",
|
194
|
+
"peak": 0,
|
195
|
+
"to": "2014-04-02T00:00:00Z",
|
196
|
+
"tot_therms": 3
|
197
|
+
}
|
198
|
+
] }
|