nvalchemi.training.CheckpointManifest#
- pydantic model nvalchemi.training.CheckpointManifest[source]#
Unified checkpoint manifest and runtime container.
This Pydantic model serves a dual role:
On-disk schema —
manifest.jsonstores component names as sorted string lists together with metadata and associations.Runtime container — after
load_checkpoint()hydrates the components, the same instance carries live(object, spec)tuples.
The
models,optimizers, andschedulersfields accept either alist[str](from JSON) or adict[str, tuple](from code). Serialization always produces sorted name lists viaPlainSerializer.Examples
>>> manifest = CheckpointManifest( ... checkpoint_index=0, models={"main": None}, ... ) >>> manifest.model_dump()["models"] ['main']
- field schema_version: int = 1#
Manifest schema version.
- field checkpoint_index: int [Required]#
Latest checkpoint index written.
- field models: dict[str, tuple[Module, BaseSpec] | None] [Required]#
Model components keyed by name.
- Constraints:
func = <function _component_serialize at 0xeb0b24699260>
json_schema_input_type = PydanticUndefined
return_type = list[str]
when_used = always
- field optimizers: dict[str, tuple[Optimizer, BaseSpec] | None] [Optional]#
Optimizer components keyed by name.
- Constraints:
func = <function _component_serialize at 0xeb0b24699260>
json_schema_input_type = PydanticUndefined
return_type = list[str]
when_used = always
- field schedulers: dict[str, tuple[LRScheduler, BaseSpec] | None] [Optional]#
Scheduler components keyed by name.
- Constraints:
func = <function _component_serialize at 0xeb0b24699260>
json_schema_input_type = PydanticUndefined
return_type = list[str]
when_used = always
- field associations: dict[str, dict[str, Any]] [Optional]#
Model-centric linkage to optimizers/schedulers.