nemo_automodel.components.training
nemo_automodel.components.training
Training utilities shared across recipes.
Submodules
nemo_automodel.components.training._mamba_ssd_prewarmnemo_automodel.components.training._prewarm_utilsnemo_automodel.components.training.batchnemo_automodel.components.training.domain_mixturenemo_automodel.components.training.emanemo_automodel.components.training.embedding_row_repairnemo_automodel.components.training.garbage_collectionnemo_automodel.components.training.model_output_utilsnemo_automodel.components.training.neftunenemo_automodel.components.training.prewarmnemo_automodel.components.training.rngnemo_automodel.components.training.signal_handlernemo_automodel.components.training.step_schedulernemo_automodel.components.training.timersnemo_automodel.components.training.utils
Package Contents
Classes
API
User-facing step scheduler configuration.
These fields correspond to the YAML-configurable parameters of the
training loop. Runtime-only values (dataloader, dp_size,
local_batch_size) are passed separately to build_step_scheduler.
Save a checkpoint every N optimizer steps.
None defaults to once per epoch.
Force gc.collect() every N steps.
None disables manual GC.
Total samples per optimizer step across all GPUs.
Log to WandB / MLflow every N steps.
Rolling window size for averaged training loss metrics.
Hard cap on optimizer steps. None means derive from
num_epochs * epoch_len.
Number of training epochs. When None the builder
derives it from max_steps. Default: 10.
Signal(s) that trigger a graceful preemption checkpoint, each given as
a signal number, name (e.g. "SIGTERM"), or a list thereof. None disables
preemption checkpointing. Default: "SIGTERM".
Also checkpoint at every epoch boundary.
Initial epoch (for checkpoint resume).
Initial global step (for checkpoint resume).
Run validation every N optimizer steps.
None disables periodic validation.
Also run validation on checkpoint steps.
Build the step scheduler.
Parameters:
The training dataloader, or None when max_steps is explicit.
The size of the data parallel group.
The size of the local batch.
Process group whose ranks participate in distributed signal handling. All ranks participating in training must also agree on stream completion.
Whether to coordinate complete accumulation windows and
stop at final source exhaustion without restarting the loader. None
uses the loader’s synchronized_stream capability, defaulting to False.
Returns: StepScheduler
Configured StepScheduler.