DatasetRef¶
-
class
lsst.daf.butler.DatasetRef(datasetType, dataId, id=None, run=None, hash=None, components=None)¶ Bases:
objectReference to a Dataset in a
Registry.A
DatasetRefmay point to a Dataset that currently does not yet exist (e.g., because it is a predicted input for provenance).Parameters: - datasetType :
DatasetType The
DatasetTypefor this Dataset.- dataId :
dictorDataId A
dictofDimensionlink fields that labels the Dataset within a Collection.- id :
int, optional A unique identifier. Normally set to
Noneand assigned byRegistry
Attributes Summary
actualConsumersA sequence of Quantuminstances that list this Dataset in theiractualInputsattributes.componentsNamed DatasetRefcomponents.dataIdA dictofDimensionlink fields that labels the Dataset within a Collection (dictorDataId).datasetTypeThe DatasetTypeassociated with the Dataset theDatasetRefpoints to.dimensionsThe dimensions associated with the underlying DatasetTypehashSecure hash of the DatasetTypename andDataId(bytes).idPrimary key of the dataset ( int)predictedConsumersA sequence of Quantuminstances that list this Dataset in theirpredictedInputsattributes.producerThe Quantuminstance that produced (or will produce) the Dataset.runThe Runinstance that produced (or will produce) the Dataset.Methods Summary
detach()Obtain a new DatasetRef that is detached from the registry. isComponent()Boolean indicating whether this DatasetRefrefers to a component of a composite.isComposite()Boolean indicating whether this DatasetRefis a composite type.Attributes Documentation
-
actualConsumers¶ A sequence of
Quantuminstances that list this Dataset in theiractualInputsattributes.Read-only; update via
Registry.markInputUsed(). May be an empty list if no provenance information is available.
-
components¶ Named
DatasetRefcomponents.Read-only; update via
Registry.attachComponent().
-
dataId¶ A
dictofDimensionlink fields that labels the Dataset within a Collection (dictorDataId).
-
datasetType¶ The
DatasetTypeassociated with the Dataset theDatasetRefpoints to.
-
dimensions¶ The dimensions associated with the underlying
DatasetType
-
hash¶ Secure hash of the
DatasetTypename andDataId(bytes).
-
predictedConsumers¶ A sequence of
Quantuminstances that list this Dataset in theirpredictedInputsattributes.Read-only; update via
Quantum.addPredictedInput(). May be an empty list if no provenance information is available.
-
producer¶ The
Quantuminstance that produced (or will produce) the Dataset.Read-only; update via
addDataset(),addOutput(), orput(). May beNoneif no provenance information is available.
-
run¶ The
Runinstance that produced (or will produce) the Dataset.Read-only; update via
addDataset()orput().
Methods Documentation
-
detach()¶ Obtain a new DatasetRef that is detached from the registry.
Its
idproperty will beNone. This can be used for transfers and similar operations.
-
isComponent()¶ Boolean indicating whether this
DatasetRefrefers to a component of a composite.Returns: - isComponent :
bool Trueif thisDatasetRefis a component,Falseotherwise.
- isComponent :
-
isComposite()¶ Boolean indicating whether this
DatasetRefis a composite type.Returns: - isComposite :
bool Trueif thisDatasetRefis a composite type,Falseotherwise.
- isComposite :
- datasetType :