from_json_pydantic¶
- lsst.daf.butler.json.from_json_pydantic(cls_: type[SupportsSimple], json_str: str, universe: DimensionUniverse | None = None, registry: Registry | None = None) SupportsSimple ¶
Convert from JSON to a pydantic model.
- Parameters:
- cls_
type
ofSupportsSimple
The Python type being created.
- json_str
str
The JSON string representing this object.
- universe
DimensionUniverse
orNone
, optional The universe required to instantiate some models. Required if
registry
isNone
.- registry
Registry
orNone
, optional Registry from which to obtain the dimension universe if an explicit universe has not been given.
- cls_
- Returns:
- model
SupportsSimple
Pydantic model constructed from JSON and validated.
- model