File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
nemo/collections/speechlm2/models Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -491,7 +491,7 @@ def __init__(self, cfg: dict) -> None:
491491 self ._use_fsdp = False
492492 self ._use_tp = False
493493 if self .cfg .get ("pretrained_model" , None ):
494- self .init_model_from_another_checkpoint (self .cfg .pretrained_model )
494+ self .restore_from_pretrained_checkpoint (self .cfg .pretrained_model )
495495
496496 def get_codec_silence_frame_last_one (self ):
497497 audio = torch .zeros (1 , 10 * self .target_sample_rate ).float ().to (self .device )
@@ -564,9 +564,9 @@ def _load_language_model(self, cfg):
564564 language_model = None
565565 return language_model
566566
567- def init_model_from_another_checkpoint (self , checkpoint_path ):
567+ def restore_from_pretrained_checkpoint (self , checkpoint_path ):
568568 """
569- Loads model weights and config from another checkpoint file, supporting .nemo and PyTorch formats.
569+ Loads model weights a pretrained checkpoint file, supporting partial loading from .nemo and PyTorch formats.
570570
571571 Args:
572572 checkpoint_path (str): Path to checkpoint file.
You can’t perform that action at this time.
0 commit comments