SerializedDatasetRef¶
- class lsst.daf.butler.SerializedDatasetRef(*, id: UUID, datasetType: SerializedDatasetType | None = None, dataId: SerializedDataCoordinate | None = None, run: str | None = None, component: str | None = None)¶
Bases:
BaseModelSimplified model of a
DatasetRefsuitable for serialization.Attributes Summary
Configuration for the model, should be a dictionary conforming to [
ConfigDict][pydantic.config.ConfigDict].Methods Summary
direct(*, id, run[, datasetType, dataId, ...])Construct a
SerializedDatasetRefdirectly without validators.Attributes Documentation
- model_config: ClassVar[ConfigDict] = {}¶
Configuration for the model, should be a dictionary conforming to [
ConfigDict][pydantic.config.ConfigDict].
Methods Documentation
- classmethod direct(*, id: str, run: str, datasetType: dict[str, Any] | None = None, dataId: dict[str, Any] | None = None, component: str | None = None) SerializedDatasetRef¶
Construct a
SerializedDatasetRefdirectly without validators.- Parameters:
- id
str The UUID in string form.
- run
str The run for this dataset.
- datasetType
dict[str,typing.Any] A representation of the dataset type.
- dataId
dict[str,typing.Any] A representation of the data ID.
- component
strorNone Any component associated with this ref.
- id
- Returns:
- serialized
SerializedDatasetRef A Pydantic model representing the given parameters.
- serialized
Notes
This differs from the pydantic “construct” method in that the arguments are explicitly what the model requires, and it will recurse through members, constructing them from their corresponding
directmethods.The
idparameter is a string representation of dataset ID, it is converted to UUID by this method.This method should only be called when the inputs are trusted.