Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
3

Openstudio run fails after successful simulation

asked 9 years ago

bryane's avatar

updated 9 years ago

I am trying to use the 'annual_end_use_breakdown' measure but my simulation run fails. The E+ simulation is fine as verified by the E+.err file. What steps can be taken to diagnose ruby script failures? I'm not sure where to start....

The measure works fine on the test model that is included on the BCL for the same ruby script

Preview: (hide)

Comments

This is likley a bug in the measure. If you send the model to OpenStudio@NREL.gov I can test and fix the issue, and post an updated measure to BCL. If you don't have the annual end use breakdown in the workflow do you see the typical OpenStudio reports or do those not show up. I may be making a query into a section that doesn't exist in some models, for example if they don't have water use equipment. If that is the case it should be easy for me to fix.

David Goldwasser's avatar David Goldwasser  ( 9 years ago )

1 Answer

Sort by » oldest newest most voted
3

answered 9 years ago

updated 9 years ago

Found the bug, I'll add update to this as soon as I test and post. It was a type when I copied and pasted code for electrical equipment to lighting. " instance.designLevel.get > 0" should be " instance.lightingLevel.get > 0"

  instances = spaceType.lights
  instances.each do |instance|
    def_display = instance.definition.name
    if instance.lightingLevel.is_initialized and instance.designLevel.get > 0
      def_value = instance.designLevel.get
      def_value_neat = OpenStudio::toNeatString(def_value,0,true)
      def_units = "W"
    elsif instance.powerPerFloorArea.is_initialized and instance.powerPerFloorArea.get > 0
      def_value = instance.powerPerFloorArea.get / OpenStudio::convert(1,"m^2","ft^2").get
      def_value_neat = OpenStudio::toNeatString(def_value,4,true)
      def_units = "W/ft^2"
    elsif instance.powerPerPerson .is_initialized and instance.powerPerPerson .get > 0
      def_value = OpenStudio::convert(instance.powerPerPerson .get,"m^2","ft^2").get
      def_value_neat = OpenStudio::toNeatString(def_value,0,true)
      def_units = "W/person"
    end
    count = instance.multiplier
    @output_data_space_type_details[:data] << [def_display,def_value_neat,def_units,count]
  end

Update: Updated Measure is online

For reference on how to trace these down. The screenshot below shows how to find the errors in the tree, and then where the error is in the stderr file. In "Apply Measures Now" and in PAT measure warnings and errors are much easier to see.

image description

Preview: (hide)
link

Comments

1

23 hours to turn this around from bug-to-public-solution is simply unacceptable! Please turn around the next issue in -10 hours! Yes, that's negative 10. Tachyons, get with them!

__AmirRoth__'s avatar __AmirRoth__  ( 9 years ago )
2

The ones what I stumble across first that you never hear about kind of fall into the -10 category:) I made a new post about how to know if there are newer measures. It is a passive system now. As a measure/component writer I can' t either alert or push my update to users who have older version. They have to go looking for it.


I can actually write a measure that updates all the other measures you have, but maybe a bit too inception like.

David Goldwasser's avatar David Goldwasser  ( 9 years ago )

Inception please!

__AmirRoth__'s avatar __AmirRoth__  ( 9 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Training Workshops

Careers

Question Tools

1 follower

Stats

Asked: 9 years ago

Seen: 295 times

Last updated: Apr 27 '15