Hi all - as just discussed with @oliver.sanders, am wanting to have a workflow which can run a given graph in one of two modes:
- near-real-time: vanilla 6H recurrence cycling - am fine writing the graph recurrence syntax for this
- historic “case study” mode: same graph, but running through a set of past events, each event defined by a start (initial cycle point) & end (final cycle point), again at 6H recurrence.
It’s the graph recurrence syntax for the latter which I’m struggling with.
- I don’t think I can use the irregular date cycling example as-is as this doesn’t cover the final cycle point
- I’ve been toying with the idea of the
generate()helper routine Oliver suggested in Date Time Cycling Recurrence Syntax - Start Date / Stop Date / Increment? , but I’m not sure if this is sensible
In case it’s of use, below I’ve put a Jinja snippet from my proto-workflow illustrating the characteristics of the overall event set:
- as you can see, the duration for a given event changes (i.e. start & end dates are separated by different, per-event intervals)
- note there is no linking between events - these are all well-separated in time, and independent
- if performance considerations come in (see this has come up in discussions linked above), overall there will be OoM(10) events (~20-30), each of this sort of few day (<10 day) duration - so under OoM(10) recurrences per event
- performance is a secondary consideration for these historic runs - fine with slightly sluggish!
- note we’re likely to do some parametric exploration - “workflow_Run_A through events with model_config_A; workflow_Run_B seeing what happens with model_config_B; …”. But we’re fine to run these sort of experiments serially, rather than in parallel
# RISER event dates
# * TODO: replace hardcoded values here with dynamic pandas-based reading from csv of event list
{%
set riser_events = (
{"Event": "R01", "Start": "2024-03-23T21Z", "End": "2024-03-24T18Z", "Kp_max": "8"},
{"Event": "R02", "Start": "2023-09-19T00Z", "End": "2023-09-25T00Z", "Kp_max": "6"},
{"Event": "R03", "Start": "2019-08-31T09Z", "End": "2019-09-01T12Z", "Kp_max": "5"},
)
%}