DatasetRefReader¶
- 
class lsst.daf.butler.registry.queries.DatasetRefReader(dataset_type: lsst.daf.butler.core.datasets.type.DatasetType, *, full: bool = True, translate_collection: Optional[collections.abc.Callable[Any, str], None] = None, records: bool = False, record_caches: Optional[collections.abc.Mapping[lsst.daf.butler.core.dimensions._elements.DimensionElement, collections.abc.Mapping[lsst.daf.butler.core.dimensions._coordinate.DataCoordinate, lsst.daf.butler.core.dimensions._records.DimensionRecord]], None] = None)¶
- Bases: - object- Reader class that extracts - DatasetRefobjects from query result rows.- Parameters: - dataset_type : DatasetType
- Dataset type for extracted references. 
- full : bool, optional
- Whether to expect and extract implied dimensions as well as required dimensions. 
- translate_collection : Callable, optional
- Callable that returns - strcollection names given collection primary key values. Optional only for registries that use names as primary keys, or if- runis always passed to- read.
- records : bool, optional
- Whether to attach dimension records to data IDs. 
- record_caches : Mapping, optional
- Nested mapping (outer keys are dimension element names, inner keys are data IDs for that element) of cached dimension records. Ignored unless - records=True.
 - Attributes Summary - columns_required- Methods Summary - read(row, Any], *, run, data_id)- Read a - DatasetReffrom a query result row.- Attributes Documentation - 
columns_required¶
 - Methods Documentation - 
read(row: Mapping[ColumnTag, Any], *, run: str | None = None, data_id: DataCoordinate | None = None) → DatasetRef¶
- Read a - DatasetReffrom a query result row.- Parameters: - row : Mapping
- Mapping with - ColumnTagkeys representing a query result row.
- run : str, optional
- Name of the - RUNcollection; when provided the run key does not need to be present in the result row, and- translate_collectiondoes not need to be provided at construction.
- data_id : DataCoordinate, optional
- Data ID; when provided the dimensions do not need to be present in the result row. 
 
- row : 
 
- dataset_type :