SerializedDimensionGraph¶
- class lsst.daf.butler.SerializedDimensionGraph(*, names: list[str])¶
Bases:
BaseModel
Simplified model of a
DimensionGraph
suitable for serialization.Attributes Summary
Configuration for the model, should be a dictionary conforming to [
ConfigDict
][pydantic.config.ConfigDict].Metadata about the fields defined on the model, mapping of field names to [
FieldInfo
][pydantic.fields.FieldInfo].Methods Summary
direct
(*, names)Construct a
SerializedDimensionGraph
directly without validators.Attributes Documentation
- model_config: ClassVar[ConfigDict] = {}¶
Configuration for the model, should be a dictionary conforming to [
ConfigDict
][pydantic.config.ConfigDict].
- model_fields: ClassVar[dict[str, FieldInfo]] = {'names': FieldInfo(annotation=list[str], required=True)}¶
Metadata about the fields defined on the model, mapping of field names to [
FieldInfo
][pydantic.fields.FieldInfo].This replaces
Model.__fields__
from Pydantic V1.
Methods Documentation
- classmethod direct(*, names: list[str]) SerializedDimensionGraph ¶
Construct a
SerializedDimensionGraph
directly without validators.- Parameters:
- Returns:
- graph
SerializedDimensionGraph
Model representing these dimensions.
- graph
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
direct
methods.This method should only be called when the inputs are trusted.