uataq.instruments.Instrument.plan_reads#
- Instrument.plan_reads(group=None, time_range=None)[source]#
Plan which group to read each part of a time range from.
- Parameters:
group (
str|Mapping[str,str] |None) – As forresolve_group(). A name, or a mapping entry naming this instrument, reads the whole range from that group.time_range (
TimeRange|str|tuple[str|datetime|datetime64|None,str|datetime|datetime64|None] |list[str|datetime|datetime64|None] |slice|None) – The requested time range. Default None is the whole installation.
- Returns:
(group, portion)pairs in time order. The portions are half-open, do not overlap, and lie within the requested range clipped toactive_range. Usually a single pair.- Return type:
- Raises:
InactiveInstrumentError – If the requested range misses the installation entirely.
InvalidGroupError – If no registered groupspace operates this instrument.
ReaderError – If no group’s archive covers any of the requested range.
Notes
With no group named, a range that crosses a
group_datesboundary is split there. Each portion goes to the most preferred group whose window covers it – the default group, then the configured order, as inresolve_group()– and portions no group covers are skipped. An instrument withoutgroup_datesgets[(resolve_group(group), clipped range)], as before.