Skip to content

Conversation

@joseph-robertson
Copy link
Collaborator

@joseph-robertson joseph-robertson commented Jan 7, 2026

Pull Request Description

Addresses #1499. Adds custom meters to calculate energy use for each dwelling unit.

Checklist

Not all may apply:

  • Schematron validator (EPvalidator.sch) has been updated
  • Sample files have been added/updated (openstudio tasks.rb update_hpxmls)
  • Tests have been added/updated (e.g., HPXMLtoOpenStudio/tests/test*.rb and/or workflow/tests/test*.rb)
  • Documentation has been updated
  • Changelog has been updated
  • openstudio tasks.rb update_measures has been run
  • No unexpected changes to simulation results of sample files

Comment on lines 396 to 397
Outputs.create_unit_fuel_meter(model, EPlus::FuelTypeElectricity, 'ElectricityProduced:Facility')
Outputs.create_unit_fuel_meter(model, EPlus::FuelTypeElectricity, 'ElectricStorage:ElectricityProduced')
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using these meters is motivated by resilience calculations for batteries. Should we additionally create unit meters for MeterCustomElectricityTotal, MeterCustomElectricityNet, and MeterCustomElectricityPV so that we can support reporting out Electricity Total and Net for each unit?

Fuel Use: Unit1: Electricity: Total (MBtu), x
Fuel Use: Unit1: Electricity: Net (MBtu), y
Fuel Use: Unit1: Natural Gas: Total (MBtu), z
...

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. We call create_custom_meters for each unit model in addition to calling create_custom_meters on the merged model.

@joseph-robertson joseph-robertson changed the base branch from master to battery-resilience-refactor January 13, 2026 20:00
@shorowit shorowit moved this from Triage to In progress in OpenStudio-HPXML Jan 16, 2026
@shorowit
Copy link
Contributor

We should think about how this interacts with modeling central/shared systems.

Fuel Use: Coal: Total (MBtu) Includes "coal", "anthracite coal", "bituminous coal", and "coke"
==================================== ===========================

Annual Energy by Fuel Use by Unit
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe unit-level outputs should be reported in a separate, e.g., results_annual_by_unit.csv file? If in the future we decided to report more than just energy use by fuel type, the results_annual.csv file may grow annoyingly long...

Copy link
Collaborator Author

@joseph-robertson joseph-robertson Jan 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another idea is to just append unit-level outputs to the end of results_annual.csv. That way, results become more detailed as you scroll deeper into the file.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a strong opinion, but appending unit-level outputs to the end of results_annual.csv seems reasonable to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In progress

Development

Successfully merging this pull request may close these issues.

3 participants