-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
@COBrogan
Example: flowby is calculated AFTER available_mgd, resulting in available_mgd having yesterdays flowby, which can result in no available water flows are receding (which happens a lot).
-
Try setting run hierarchy of
available_mgd= 1: Note, this should NOT be necessary, since availabl_mgd is an equation and equations have a very well vetted dependency functionality. -
Check the property execution ordering in the
reportsfile:
# get report - TBD migrate this code to dHVariablePluginDefault.R OMModelObject plugin class
elid <- fac_prop$get_prop('om_element_connection')$propvalue
report_fname <- paste0(omsite,'/data/proj3/out/', 'report', elid,'-',runid,'.log')
report_file <- httr::GET(report_fname, encode = "text")
content(report_file, as="text")
- Example Had to do some work in Strasburg, using "exec_hierarch" property in the models. The equations and lookups should order automatically based on their dependencies, but sometimes that fails, when for instance they are somehow circular. In this case, when I modified the flowby, the flowby started getting evaluated after the available_mgd, which resulted in less available water than should have been there when the hydrograph is receding. Sometimes, when the recession is steep enough, it results in significantly less water than is requested, i.e., if yesterdays flow is more than 10% higher than todays flow, and your available_mgd is or just a result of the new components added in the exempt work.
The code below is what I used, and it is quite simple and we could rapidly deploy as needed. (note: facprop is the facility model)
flowby <- fac_prop$get_prop('flowby')
exec_hierarch <- flowby$set_prop('exec_hierarch', propvalue=1)
available_mgd <- fac_prop$get_prop('available_mgd')
exec_hierarch <- available_mgd$set_prop('exec_hierarch', propvalue=2)
Metadata
Metadata
Assignees
Labels
No labels