nemo_automodel.shared.torch_patches#
Torch compatibility patches.
These patches are intentionally NOT applied at import nemo_automodel time to keep
tokenizer-only imports lightweight. Call apply_torch_patches() from code paths
that already depend on torch (training / distributed / dataloading).
Module Contents#
Functions#
Apply small, version/packaging-specific torch monkey patches. |
Data#
API#
- nemo_automodel.shared.torch_patches._logger#
‘getLogger(…)’
- nemo_automodel.shared.torch_patches._TORCH_PATCHES_APPLIED#
False
- nemo_automodel.shared.torch_patches.apply_torch_patches() → None#
Apply small, version/packaging-specific torch monkey patches.
This function is idempotent and safe to call multiple times.