Skip to content

Comments

Addresses #4615, wrap OutputControl:Table:Style and Output:SQLite#171

Merged
jmarrec merged 4 commits intodevelopfrom
output-control
Aug 31, 2022
Merged

Addresses #4615, wrap OutputControl:Table:Style and Output:SQLite#171
jmarrec merged 4 commits intodevelopfrom
output-control

Conversation

@joseph-robertson
Copy link
Contributor

@joseph-robertson joseph-robertson commented Jul 21, 2022

Pull request overview

Tests demonstrating NatLabRockies/OpenStudio#4625

Link to relevant GitHub Issue(s) if appropriate:

Link to the Linux.deb installer to use for CI Testing. If not set, it will default to latest official release.
[OpenStudio Installer]: http://openstudio-ci-builds.s3-website-us-west-2.amazonaws.com/PR-4625/OpenStudio-3.4.1-alpha%2B3c33c84f02-Ubuntu-18.04.deb

This Pull Request is concerning:

  • Case 1 - NewTest: a new test for a new model API class,

Case 1: New test for a new model API class

Please include which class(es) you are adding a test to specifically test for:

  • OutputControl:Table:Style
  • Output:SQLite

Work Checklist

The following has been checked to ensure compliance with the guidelines:

  • Tests pass either:

    • with official OpenStudio release (include version):

    • with current develop (incude SHA): Addresses #4615, wrap OutputControl:Table:Style and Output:SQLite OpenStudio#4625

      • The label PendingOSM has been added to this PR
      • A matching OSM test has not yet been added because the official release is pending, but model_tests.rb has a TODO.
      • No out.osw have been committed as they need to be run with an official OpenStudio version
  • Ruby test is stable: when run multiple times on the same machine, it produces the same total site kBTU.
    Please paste the heatmap png generated after running the following commands:

    • I ensured that I assign systems/loads/etc in a repeatable manner (eg: if I assign stuff to thermalZones, I do model.getThermalZones.sort_by{|z| z.name.to_s}.each do ... so I am sure I put the same ZoneHVAC systems to the same zones regardless of their order)
    • I tested stability using process_results.py (see python process_results.py --help for usage).
  • Object has been added to autosize_hvac.rb to ensure the autosizedXXX values methods do work


Review Checklist

  • Code style (indentation, variable names, strip trailing spaces)
  • Functional code review (it has to work!)
  • Matching OSM test has been added or # TODO added to model_tests.rb
  • Appropriate out.osw have been committed
  • Test is stable
  • Object is tested in autosize_hvac as appropriate
  • The appropriate labels have been added to this PR:
    • One of: NewTest, TestFix, NewTestForExisting, Other
    • If NewTest: add PendingOSM or AddedOSM

@joseph-robertson joseph-robertson added NewTest PR type: a new test for a new model API class PendingOSM A matching OSM test has yet to be added with the next official OpenStudio Release labels Jul 21, 2022
@joseph-robertson joseph-robertson self-assigned this Jul 21, 2022
github-rubocop-actions[bot] and others added 2 commits July 21, 2022 23:17

model = BaselineModel.new

# make a 1 story, 100m X 50m, 1 zone building
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

Comment on lines +47 to +61
###############################################################################
# OUTPUTCONTROL:TABLE:STYLE #
###############################################################################

outputcontrol_table_style = model.getOutputControlTableStyle
outputcontrol_table_style.setColumnSeparator('HTML')
outputcontrol_table_style.setUnitConversion('InchPound')

###############################################################################
# OUTPUT:SQLITE #
###############################################################################

output_sqlite = model.getOutputSQLite
output_sqlite.setOptionType('SimpleAndTabular')
output_sqlite.setUnitConversionforTabularData('None')
Copy link
Contributor

Choose a reason for hiding this comment

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

👍 Simple and clear. Did you check the resulting IDF manually to ensure you have the required objects?

Comment on lines +771 to +778
def test_output_objects_2_rb
result = sim_test('output_objects_2.rb')
end

# TODO: To be added in the next official release after: 3.4.0
# def test_output_objects_2_osm
# result = sim_test('output_objects_2.osm')
# end
Copy link
Contributor

@jmarrec jmarrec Jul 25, 2022

Choose a reason for hiding this comment

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

👍

@jmarrec jmarrec merged commit 3be6e13 into develop Aug 31, 2022
@jmarrec jmarrec deleted the output-control branch August 31, 2022 12:56
@jmarrec jmarrec added AddedOSM A matching OSM test has been added with an official OpenStudio release and removed PendingOSM A matching OSM test has yet to be added with the next official OpenStudio Release labels Jan 10, 2023
jmarrec added a commit that referenced this pull request Jan 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AddedOSM A matching OSM test has been added with an official OpenStudio release NewTest PR type: a new test for a new model API class

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants