Skip to content

Commit

Permalink
fix path (NVIDIA#11121)
Browse files Browse the repository at this point in the history
Signed-off-by: Chen Cui <[email protected]>
  • Loading branch information
cuichenx authored and XuesongYang committed Jan 18, 2025
1 parent 26bf509 commit 05cb0d8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion nemo/collections/llm/gpt/data/fine_tuning.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,10 @@ def _extract_tokenizer_model_name(self) -> str:
tokenizer_model_name = self.packed_sequence_specs.tokenizer_model_name
elif isinstance(self.tokenizer, AutoTokenizer):
name = self.tokenizer.tokenizer.name_or_path
if name.endswith("nemo_tokenizer"):
if name.endswith("context/nemo_tokenizer"):
# NEMO_HOME/hf_org/hf_model/context/nemo_tokenizer => hf_org--hf_model
tokenizer_model_name = '--'.join(name.split("/")[-4:-2])
elif name.endswith("nemo_tokenizer"):
# NEMO_HOME/hf_org/hf_model/nemo_tokenizer => hf_org--hf_model
tokenizer_model_name = '--'.join(name.split("/")[-3:-1])
else:
Expand Down

0 comments on commit 05cb0d8

Please sign in to comment.