dartobsgen.ModelStateProvider#
- class dartobsgen.ModelStateProvider[source]#
Bases:
ABCSupplies one single-timeslice model state per assimilation window.
- __init__()#
Methods
__init__()Return the valid times of every state this provider can serve.
state_for_window(date0, date1)Return the model state for the window
(date0, date1].- abstractmethod state_for_window(date0, date1)[source]#
Return the model state for the window
(date0, date1].The interval is open below and closed above, matching the window
perfect_model_obsis given (first_obs = date0 + 1s,last_obs = date1). A state landing exactly ondate0belongs to the previous window; returning it here would place every observation one second beforefirst_obs.- Returns:
Noneif no model state falls within the window; the window is then skipped (no obs_seq file is written).- Return type:
ModelState or None
- Parameters:
- available_times()[source]#
Return the valid times of every state this provider can serve.
Sorted ascending. The default returns
None, meaning the provider cannot enumerate its states;PerfectModelSourcethen skips its pre-flight coverage check rather than guessing. Override this in providers that index their input up front, so a mismatch between the run’s analysis times and the model output times is reported before any window runs.