nemo_automodel.components.checkpoint.config
nemo_automodel.components.checkpoint.config
Public config surface for the checkpoint component.
CheckpointingConfig holds the typed parameters that drive checkpointing
behaviour and exposes .build() to construct the :class:Checkpointer
engine (defined in checkpointing.py). Every field has a sensible default
so the recipe layer can construct it directly from the YAML checkpoint:
block plus the model-derived model_repo_id / model_cache_dir /
is_peft arguments — there is no separate builder/adapter.
Module Contents
Classes
Functions
Data
API
Configuration for checkpointing.
Every field has a default so the recipe layer can construct this directly
from the YAML checkpoint: block merged with the model-derived
model_repo_id / model_cache_dir / is_peft values. When
model_cache_dir is None it falls back to the HF hub cache.
Resolve the cache dir, enforce PEFT constraints, and coerce the save format/mode.
Build the :class:Checkpointer engine for this config.
Checkpointer is imported lazily to avoid a circular import
(checkpointing.py imports CheckpointingConfig from this module)
and to keep the heavy DCP/safetensors deps out of module load.
Parameters:
Data-parallel rank.
Tensor-parallel rank.
Pipeline-parallel rank.
Optional device mesh for MoE checkpointing.
Returns: Checkpointer
class:Checkpointer.
Bases: enum.Enum
Controls when consolidated HF safetensors are exported.
Check if the current torch version is greater than or equal to 2.9.0.
Normalize legacy bools and string aliases to a consolidated export mode.