urbanopt-reporting 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/.github/ISSUE_TEMPLATE/bug_report.md +19 -0
  3. data/.github/ISSUE_TEMPLATE/feature_request.md +15 -0
  4. data/.github/pull_request_template.md +13 -0
  5. data/.rdoc_options +36 -0
  6. data/CHANGELOG.md +10 -0
  7. data/RDOC_MAIN.md +10 -0
  8. data/deploy_docs.sh +5 -0
  9. data/docs/.gitignore +3 -0
  10. data/docs/.vuepress/components/InnerJsonSchema.vue +76 -0
  11. data/docs/.vuepress/components/JsonSchema.vue +12 -0
  12. data/docs/.vuepress/components/ScenarioSchema.vue +12 -0
  13. data/docs/.vuepress/components/StaticLink.vue +8 -0
  14. data/docs/.vuepress/config.js +25 -0
  15. data/docs/.vuepress/highlight.js +8 -0
  16. data/docs/.vuepress/json-schema-deref-loader.js +22 -0
  17. data/docs/.vuepress/public/custom_rdoc_styles.css +78 -0
  18. data/docs/.vuepress/styles/palette.styl +1 -0
  19. data/docs/.vuepress/utils.js +17 -0
  20. data/docs/README.md +9 -0
  21. data/docs/package-lock.json +10018 -0
  22. data/docs/package.json +30 -0
  23. data/docs/schemas/scenario-schema.md +3 -0
  24. data/lib/measures/default_feature_reports/measure.rb +53 -44
  25. data/lib/urbanopt/reporting/default_reports/end_uses.rb +38 -38
  26. data/lib/urbanopt/reporting/default_reports/feature_report.rb +35 -19
  27. data/lib/urbanopt/reporting/default_reports/location.rb +11 -11
  28. data/lib/urbanopt/reporting/default_reports/program.rb +86 -86
  29. data/lib/urbanopt/reporting/default_reports/reporting_period.rb +78 -78
  30. data/lib/urbanopt/reporting/default_reports/schema/scenario_schema.json +80 -80
  31. data/lib/urbanopt/reporting/default_reports/thermal_storage.rb +10 -10
  32. data/lib/urbanopt/reporting/version.rb +1 -1
  33. data/urbanopt-reporting-gem.gemspec +4 -4
  34. metadata +35 -13
@@ -263,69 +263,69 @@
263
263
  "end_date": {
264
264
  "$ref": "#/definitions/Date"
265
265
  },
266
- "total_site_energy": {
267
- "description": "Total energy used on site, does not include generation (kBtu)",
266
+ "total_site_energy_kwh": {
267
+ "description": "Total energy used on site, does not include generation (kWh)",
268
268
  "type": "number"
269
269
  },
270
- "total_source_energy": {
271
- "description": "Total source energy used, does not include generation (kBtu)",
270
+ "total_source_energy_kwh": {
271
+ "description": "Total source energy used, does not include generation (kWh)",
272
272
  "type": "number"
273
273
  },
274
- "net_site_energy": {
275
- "description": "Net site energy (kBtu)",
274
+ "net_site_energy_kwh": {
275
+ "description": "Net site energy (kWh)",
276
276
  "type": "number"
277
277
  },
278
- "net_source_energy": {
279
- "description": "Net source energy (kBtu)",
278
+ "net_source_energy_kwh": {
279
+ "description": "Net source energy (kWh)",
280
280
  "type": "number"
281
281
  },
282
- "total_utility_cost": {
283
- "description": "Total utility cost",
282
+ "total_utility_cost_dollar": {
283
+ "description": "Total utility cost ($)",
284
284
  "type": "number"
285
285
  },
286
- "net_utility_cost": {
287
- "description": "Net utility cost for reporting period includes generation",
286
+ "net_utility_cost_dollar": {
287
+ "description": "Net utility cost for reporting period includes generation ($)",
288
288
  "type": "number"
289
289
  },
290
- "utility_costs": {
290
+ "utility_costs_dollar": {
291
291
  "type": "array",
292
292
  "items": {
293
293
  "$ref": "#/definitions/UtilityCost"
294
294
  }
295
295
  },
296
- "electricity": {
296
+ "electricity_kwh": {
297
297
  "description": "Sum of all electricity used, does not include electricity produced (kWh)",
298
298
  "type": "number"
299
299
  },
300
- "natural_gas": {
301
- "description": "Sum of all natural gas end uses consumption (kBtu)",
300
+ "natural_gas_kwh": {
301
+ "description": "Sum of all natural gas end uses consumption (kWh)",
302
302
  "type": "number"
303
303
  },
304
- "additional_fuel": {
305
- "description": "Sum of all additional fuel end uses consumption (kBtu)",
304
+ "additional_fuel_kwh": {
305
+ "description": "Sum of all additional fuel end uses consumption (kWh)",
306
306
  "type": "number"
307
307
  },
308
- "district_cooling": {
309
- "description": "Sum of all distric cooling end uses consumption (kBtu)",
308
+ "district_cooling_kwh": {
309
+ "description": "Sum of all distric cooling end uses consumption (kWh)",
310
310
  "type": "number"
311
311
  },
312
- "district_heating": {
313
- "description": "Sum of all distric heating end uses consumption (kBtu)",
312
+ "district_heating_kwh": {
313
+ "description": "Sum of all distric heating end uses consumption (kWh)",
314
314
  "type": "number"
315
315
  },
316
- "water": {
316
+ "water_qbft": {
317
317
  "description": "Sum of all water end uses consumption (ft^3)",
318
318
  "type": "number"
319
319
  },
320
- "electricity_produced": {
320
+ "electricity_produced_kwh": {
321
321
  "description": "Sum of all electricity produced (kWh)",
322
322
  "type": "number"
323
323
  },
324
324
  "end_uses": {
325
325
  "$ref": "#/definitions/EndUses"
326
326
  },
327
- "energy_production": {
328
- "description": "Energy produced for reporting period. Electricity reported in kWh, water in m^3, all others in kBtu.",
327
+ "energy_production_kwh": {
328
+ "description": "Energy produced for reporting period. Water reported in m^3, all others in kWh.",
329
329
  "type": "object",
330
330
  "properties": {
331
331
  "electricity_produced": {
@@ -362,25 +362,25 @@
362
362
  "additionalProperties": false
363
363
  },
364
364
  "EndUses": {
365
- "description": "End uses for reporting period. Does not include energy produced. Electricity reported in kWh, water in m^3, all others in kBtu.",
365
+ "description": "End uses for reporting period. Does not include energy produced. Water reported in m^3, all others in kWh.",
366
366
  "type": "object",
367
367
  "properties": {
368
- "electricity": {
368
+ "electricity_kwh": {
369
369
  "$ref": "#/definitions/EndUse"
370
370
  },
371
- "natural_gas": {
371
+ "natural_gas_kwh": {
372
372
  "$ref": "#/definitions/EndUse"
373
373
  },
374
- "additional_fuel": {
374
+ "additional_fuel_kwh": {
375
375
  "$ref": "#/definitions/EndUse"
376
376
  },
377
- "district_cooling": {
377
+ "district_cooling_kwh": {
378
378
  "$ref": "#/definitions/EndUse"
379
379
  },
380
- "district_heating": {
380
+ "district_heating_kwh": {
381
381
  "$ref": "#/definitions/EndUse"
382
382
  },
383
- "water": {
383
+ "water_qbft": {
384
384
  "$ref": "#/definitions/EndUse"
385
385
  }
386
386
  },
@@ -546,15 +546,15 @@
546
546
  "Location": {
547
547
  "type": "object",
548
548
  "properties": {
549
- "latitude": {
549
+ "latitude_deg": {
550
550
  "description": "latitude for the centroid of the feature (deg)",
551
551
  "type": "number"
552
552
  },
553
- "longitude": {
553
+ "longitude_deg": {
554
554
  "description": "longitude for the centroid of the feature (deg)",
555
555
  "type": "number"
556
556
  },
557
- "surface_elevation": {
557
+ "surface_elevation_ft": {
558
558
  "description": "The surface elevation (above NAVD88 datum) (ft).",
559
559
  "type": "number"
560
560
  },
@@ -573,27 +573,27 @@
573
573
  "Program": {
574
574
  "type": "object",
575
575
  "properties": {
576
- "site_area": {
576
+ "site_area_sqft": {
577
577
  "description": "Area of the entire site or lot (ft^2)",
578
578
  "type": "number"
579
579
  },
580
- "floor_area": {
580
+ "floor_area_sqft": {
581
581
  "description": "Building gross floor area (ft^2)",
582
582
  "type": "number"
583
583
  },
584
- "conditioned_area": {
584
+ "conditioned_area_sqft": {
585
585
  "description": "Building conditioned floor area (ft^2)",
586
586
  "type": "number"
587
587
  },
588
- "unconditioned_area": {
588
+ "unconditioned_area_sqft": {
589
589
  "description": "Building unconditioned floor area (ft^2)",
590
590
  "type": "number"
591
591
  },
592
- "footprint_area": {
592
+ "footprint_area_sqft": {
593
593
  "description": "Building floorprint area (ft^2)",
594
594
  "type": "number"
595
595
  },
596
- "maximum_roof_height": {
596
+ "maximum_roof_height_ft": {
597
597
  "description": "Maximum height of the roof relative to surface elevation (ft)",
598
598
  "type": "number"
599
599
  },
@@ -605,7 +605,7 @@
605
605
  "description": "The maximum number of building stories above ground",
606
606
  "type": "number"
607
607
  },
608
- "parking_area": {
608
+ "parking_area_sqft": {
609
609
  "description": "Parking gross area (ft^2)",
610
610
  "type": "number"
611
611
  },
@@ -617,11 +617,11 @@
617
617
  "description": "Number of parking spaces with electric vehicle charging",
618
618
  "type": "number"
619
619
  },
620
- "parking_footprint_area": {
620
+ "parking_footprint_area_sqft": {
621
621
  "description": "Parking floorprint area (ft^2)",
622
622
  "type": "number"
623
623
  },
624
- "maximum_parking_height": {
624
+ "maximum_parking_height_ft": {
625
625
  "description": "Maximum height of the parking structure relative to surface elevation (ft)",
626
626
  "type": "number"
627
627
  },
@@ -643,84 +643,84 @@
643
643
  "$ref": "#/definitions/BuildingType"
644
644
  }
645
645
  },
646
- "window_area": {
646
+ "window_area_sqft": {
647
647
  "description": "Exterior windows gross area (ft^2)",
648
648
  "type": "object",
649
649
  "properties": {
650
- "north_window_area": {
650
+ "north_window_area_sqft": {
651
651
  "type": "number"
652
652
  },
653
- "south_window_area": {
653
+ "south_window_area_sqft": {
654
654
  "type": "number"
655
655
  },
656
- "east_window_area": {
656
+ "east_window_area_sqft": {
657
657
  "type": "number"
658
658
  },
659
- "west_window_area": {
659
+ "west_window_area_sqft": {
660
660
  "type": "number"
661
661
  },
662
- "total_window_area": {
662
+ "total_window_area_sqft": {
663
663
  "type": "number"
664
664
  }
665
665
  },
666
666
  "required": [
667
- "total_window_area"
667
+ "total_window_area_sqft"
668
668
  ],
669
669
  "additionalProperties": false
670
670
  },
671
- "wall_area": {
671
+ "wall_area_sqft": {
672
672
  "description": "exterior walls gross area (ft^2)",
673
673
  "type": "object",
674
674
  "properties": {
675
- "north_wall_area": {
675
+ "north_wall_area_sqft": {
676
676
  "type": "number"
677
677
  },
678
- "south_wall_area": {
678
+ "south_wall_area_sqft": {
679
679
  "type": "number"
680
680
  },
681
- "east_wall_area": {
681
+ "east_wall_area_sqft": {
682
682
  "type": "number"
683
683
  },
684
- "west_wall_area": {
684
+ "west_wall_area_sqft": {
685
685
  "type": "number"
686
686
  },
687
- "total_wall_area": {
687
+ "total_wall_area_sqft": {
688
688
  "type": "number"
689
689
  }
690
690
  },
691
691
  "required": [
692
- "north_wall_area",
693
- "south_wall_area",
694
- "east_wall_area",
695
- "west_wall_area",
696
- "total_wall_area"
692
+ "north_wall_area_sqft",
693
+ "south_wall_area_sqft",
694
+ "east_wall_area_sqft",
695
+ "west_wall_area_sqft",
696
+ "total_wall_area_sqft"
697
697
  ],
698
698
  "additionalProperties": false
699
699
  },
700
- "roof_area": {
700
+ "roof_area_sqft": {
701
701
  "type": "object",
702
702
  "properties": {
703
- "equipment_roof_area": {
703
+ "equipment_roof_area_sqft": {
704
704
  "type": "number"
705
705
  },
706
- "photovoltaic_roof_area": {
706
+ "photovoltaic_roof_area_sqft": {
707
707
  "type": "number"
708
708
  },
709
- "available_roof_area": {
709
+ "available_roof_area_sqft": {
710
710
  "description": "gross roof area (ft^2)",
711
711
  "type": "number"
712
712
  },
713
- "total_roof_area": {
713
+ "total_roof_area_sqft": {
714
714
  "description": "Exterior roofs gross area (ft^2)",
715
715
  "type": "number"
716
716
  }
717
717
  },
718
718
  "required": [
719
- "total_roof_area"
719
+ "total_roof_area_sqft"
720
720
  ],
721
721
  "additionalProperties": false
722
722
  },
723
- "orientation": {
723
+ "orientation_deg": {
724
724
  "description": "Rotation of longest axis from East-West,about up axis (deg)",
725
725
  "type": "number"
726
726
  },
@@ -728,22 +728,22 @@
728
728
  "description": "Ratio of longest to shortest axis",
729
729
  "type": "number"
730
730
  },
731
- "total_construction_cost": {
731
+ "total_construction_cost_dollar": {
732
732
  "description": "total construction cost calculated from the defined cost per floor area ($)",
733
733
  "type": "number"
734
734
  }
735
735
  },
736
736
  "required": [
737
- "floor_area",
738
- "conditioned_area",
739
- "unconditioned_area",
740
- "footprint_area",
741
- "maximum_roof_height",
737
+ "floor_area_sqft",
738
+ "conditioned_area_sqft",
739
+ "unconditioned_area_sqft",
740
+ "footprint_area_sqft",
741
+ "maximum_roof_height_ft",
742
742
  "number_of_residential_units",
743
743
  "building_types",
744
- "window_area",
745
- "wall_area",
746
- "roof_area"
744
+ "window_area_sqft",
745
+ "wall_area_sqft",
746
+ "roof_area_sqft"
747
747
  ],
748
748
  "additionalProperties": false
749
749
  },
@@ -873,4 +873,4 @@
873
873
  }
874
874
  }
875
875
  }
876
- }
876
+ }
@@ -42,17 +42,17 @@ module URBANopt
42
42
  ##
43
43
  # _Float_ - Total ice storage capacity on central plant loop in kWh
44
44
  #
45
- attr_accessor :its_size
45
+ attr_accessor :its_size_kwh
46
46
 
47
47
  # _Float_ - Total ice storage capacity distributed to packaged systems in kWh
48
48
  #
49
- attr_accessor :ptes_size
49
+ attr_accessor :ptes_size_kwh
50
50
 
51
51
  def initialize(hash = {})
52
52
  hash.delete_if { |k, v| v.nil? }
53
53
 
54
- @its_size = hash[:its_size]
55
- @ptes_size = hash[:ptes_size]
54
+ @its_size = hash[:its_size_kwh]
55
+ @ptes_size = hash[:ptes_size_kwh]
56
56
 
57
57
  # initialize class variables @@validator and @@schema
58
58
  @@validator ||= Validator.new
@@ -67,8 +67,8 @@ module URBANopt
67
67
  ##
68
68
  def defaults
69
69
  hash = {}
70
- hash[:its_size] = nil
71
- hash[:ptes_size] = nil
70
+ hash[:its_size_kwh] = nil
71
+ hash[:ptes_size_kwh] = nil
72
72
 
73
73
  return hash
74
74
  end
@@ -78,8 +78,8 @@ module URBANopt
78
78
  ##
79
79
  def to_hash
80
80
  result = {}
81
- result[:its_size] = @its_size if @its_size
82
- result[:ptes_size] = @ptes_size if @ptes_size
81
+ result[:its_size_kwh] = @its_size_kwh if @its_size_kwh
82
+ result[:ptes_size_kwh] = @ptes_size_kwh if @ptes_size_kwh
83
83
 
84
84
  return result
85
85
  end
@@ -100,8 +100,8 @@ module URBANopt
100
100
  # Merge thermal storage
101
101
  ##
102
102
  def self.merge_thermal_storage(existing_tes, new_tes)
103
- existing_tes.its_size = add_values(existing_tes.its_size, new_tes.its_size)
104
- existing_tes.ptes_size = add_values(existing_tes.ptes_size, new_tes.ptes_size)
103
+ existing_tes.its_size_kwh = add_values(existing_tes.its_size_kwh, new_tes.its_size_kwh)
104
+ existing_tes.ptes_size_kwh = add_values(existing_tes.ptes_size_kwh, new_tes.ptes_size_kwh)
105
105
 
106
106
  return existing_tes
107
107
  end
@@ -30,6 +30,6 @@
30
30
 
31
31
  module URBANopt
32
32
  module Reporting
33
- VERSION = '0.2.0'.freeze
33
+ VERSION = '0.2.1'.freeze
34
34
  end
35
35
  end
@@ -12,6 +12,7 @@ Gem::Specification.new do |spec|
12
12
  spec.summary = 'Library to report URBANopt results'
13
13
  spec.description = 'Library include scenario default reporting measure and scenario defaults reports schema and classes'
14
14
  spec.homepage = 'https://github.com/urbanopt'
15
+ spec.licenses = 'Nonstandard'
15
16
 
16
17
  # Specify which files should be added to the gem when it is released.
17
18
  # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
@@ -26,8 +27,7 @@ Gem::Specification.new do |spec|
26
27
  spec.add_development_dependency 'bundler', '~> 2.1'
27
28
  spec.add_development_dependency 'rake', '~> 13.0'
28
29
  spec.add_development_dependency 'rspec', '~> 3.7'
29
-
30
- spec.add_dependency 'json-schema'
31
- spec.add_dependency 'json_pure'
32
- spec.add_dependency 'openstudio-extension', '~> 0.2.3'
30
+ spec.add_runtime_dependency 'json-schema', '~> 2.8'
31
+ spec.add_runtime_dependency 'json_pure', '~> 2.3'
32
+ spec.add_runtime_dependency 'openstudio-extension', '~> 0.2.5'
33
33
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: urbanopt-reporting
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rawad El Kontar
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2020-09-21 00:00:00.000000000 Z
12
+ date: 2020-11-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -57,44 +57,44 @@ dependencies:
57
57
  name: json-schema
58
58
  requirement: !ruby/object:Gem::Requirement
59
59
  requirements:
60
- - - ">="
60
+ - - "~>"
61
61
  - !ruby/object:Gem::Version
62
- version: '0'
62
+ version: '2.8'
63
63
  type: :runtime
64
64
  prerelease: false
65
65
  version_requirements: !ruby/object:Gem::Requirement
66
66
  requirements:
67
- - - ">="
67
+ - - "~>"
68
68
  - !ruby/object:Gem::Version
69
- version: '0'
69
+ version: '2.8'
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: json_pure
72
72
  requirement: !ruby/object:Gem::Requirement
73
73
  requirements:
74
- - - ">="
74
+ - - "~>"
75
75
  - !ruby/object:Gem::Version
76
- version: '0'
76
+ version: '2.3'
77
77
  type: :runtime
78
78
  prerelease: false
79
79
  version_requirements: !ruby/object:Gem::Requirement
80
80
  requirements:
81
- - - ">="
81
+ - - "~>"
82
82
  - !ruby/object:Gem::Version
83
- version: '0'
83
+ version: '2.3'
84
84
  - !ruby/object:Gem::Dependency
85
85
  name: openstudio-extension
86
86
  requirement: !ruby/object:Gem::Requirement
87
87
  requirements:
88
88
  - - "~>"
89
89
  - !ruby/object:Gem::Version
90
- version: 0.2.3
90
+ version: 0.2.5
91
91
  type: :runtime
92
92
  prerelease: false
93
93
  version_requirements: !ruby/object:Gem::Requirement
94
94
  requirements:
95
95
  - - "~>"
96
96
  - !ruby/object:Gem::Version
97
- version: 0.2.3
97
+ version: 0.2.5
98
98
  description: Library include scenario default reporting measure and scenario defaults
99
99
  reports schema and classes
100
100
  email:
@@ -103,20 +103,41 @@ executables: []
103
103
  extensions: []
104
104
  extra_rdoc_files: []
105
105
  files:
106
+ - ".github/ISSUE_TEMPLATE/bug_report.md"
107
+ - ".github/ISSUE_TEMPLATE/feature_request.md"
108
+ - ".github/pull_request_template.md"
106
109
  - ".gitignore"
110
+ - ".rdoc_options"
107
111
  - ".rubocop.yml"
108
112
  - CHANGELOG.md
109
113
  - CONTRIBUTING.md
110
114
  - Gemfile
111
115
  - Jenkinsfile
112
116
  - LICENSE.md
117
+ - RDOC_MAIN.md
113
118
  - README.md
114
119
  - Rakefile
120
+ - deploy_docs.sh
115
121
  - doc_templates/LICENSE.md
116
122
  - doc_templates/README.md.erb
117
123
  - doc_templates/copyright_erb.txt
118
124
  - doc_templates/copyright_js.txt
119
125
  - doc_templates/copyright_ruby.txt
126
+ - docs/.gitignore
127
+ - docs/.vuepress/components/InnerJsonSchema.vue
128
+ - docs/.vuepress/components/JsonSchema.vue
129
+ - docs/.vuepress/components/ScenarioSchema.vue
130
+ - docs/.vuepress/components/StaticLink.vue
131
+ - docs/.vuepress/config.js
132
+ - docs/.vuepress/highlight.js
133
+ - docs/.vuepress/json-schema-deref-loader.js
134
+ - docs/.vuepress/public/custom_rdoc_styles.css
135
+ - docs/.vuepress/styles/palette.styl
136
+ - docs/.vuepress/utils.js
137
+ - docs/README.md
138
+ - docs/package-lock.json
139
+ - docs/package.json
140
+ - docs/schemas/scenario-schema.md
120
141
  - lib/measures/.rubocop.yml
121
142
  - lib/measures/default_feature_reports/LICENSE.md
122
143
  - lib/measures/default_feature_reports/README.md
@@ -152,7 +173,8 @@ files:
152
173
  - lib/urbanopt/reporting/version.rb
153
174
  - urbanopt-reporting-gem.gemspec
154
175
  homepage: https://github.com/urbanopt
155
- licenses: []
176
+ licenses:
177
+ - Nonstandard
156
178
  metadata: {}
157
179
  post_install_message:
158
180
  rdoc_options: []