Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tutorials/asr/ASR_with_Transducers.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -827,7 +827,7 @@
" monitor=\"val_wer\",\n",
" mode=\"min\",\n",
" always_save_nemo=True,\n",
" save_best_model=True,\n",
" save_best_model=False,\n",
" ),\n",
")\n",
"\n",
Expand Down Expand Up @@ -1342,4 +1342,4 @@
},
"nbformat": 4,
"nbformat_minor": 0
}
}
2 changes: 1 addition & 1 deletion tutorials/asr/Multilang_ASR.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@
},
"outputs": [],
"source": [
"asr_model = nemo_asr.models.EncDecRNNTBPEModel.from_pretrained(model_name=\"stt_enes_contextnet_large\")"
"asr_model = nemo_asr.models.EncDecRNNTBPEModel.from_pretrained(model_name=\"stt_enes_conformer_transducer_large\")"
]
},
{
Expand Down
18 changes: 13 additions & 5 deletions tutorials/asr/Streaming_ASR_Pipelines.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,17 @@
"# - vllm: required for LLM-based Speech Translation\n",
"#\n",
"# For a complete Docker-based setup for speech translation with vLLM, see:\n",
"# https://github.com/NVIDIA/NeMo/blob/main/scripts/installers/Dockerfile.speech_translation_vllm\n",
"# https://github.com/NVIDIA-NeMo/Speech/blob/main/scripts/installers/Dockerfile.speech_translation_vllm\n",
"\n",
"import importlib.util\n",
"import subprocess\n",
"import sys\n",
"\n",
"!pip install nemo_text_processing\n",
"!pip install vllm==0.12.0"
"\n",
"# Avoid replacing the container's matched vLLM/flashinfer packages.\n",
"if importlib.util.find_spec(\"vllm\") is None:\n",
" subprocess.check_call([sys.executable, \"-m\", \"pip\", \"install\", \"vllm==0.12.0\"])"
]
},
{
Expand Down Expand Up @@ -220,9 +227,6 @@
"import numpy as np\n",
"import matplotlib.pyplot as plt\n",
"\n",
"# Allow loading trusted checkpoints that hold non-tensor objects (torch>=2.6 weights_only default).\n",
"os.environ[\"TORCH_FORCE_NO_WEIGHTS_ONLY_LOAD\"] = \"1\"\n",
"\n",
"from omegaconf import OmegaConf\n",
"from nemo.collections.asr.inference.factory.pipeline_builder import PipelineBuilder, BasePipeline\n",
"from nemo.collections.asr.inference.streaming.framing.request_options import ASRRequestOptions\n",
Expand Down Expand Up @@ -483,6 +487,7 @@
" \"streaming.batch_size\": batch_size,\n",
" \"streaming.stateful\": stateful,\n",
" \"asr_decoding_type\": \"rnnt\",\n",
" \"asr.decoding.greedy.use_cuda_graph_decoder\": False,\n",
" \"log_level\": log_level,\n",
" },\n",
")\n",
Expand Down Expand Up @@ -717,6 +722,7 @@
" \"streaming.batch_size\": 8,\n",
" \"streaming.stateful\": True,\n",
" \"asr_decoding_type\": \"rnnt\",\n",
" \"asr.decoding.greedy.use_cuda_graph_decoder\": False,\n",
" \"log_level\": 40,\n",
" \"asr.decoding.greedy.preserve_frame_confidence\": True, # enable per-token confidence scores\n",
" },\n",
Expand Down Expand Up @@ -997,6 +1003,7 @@
" \"streaming.batch_size\": 8,\n",
" \"streaming.stateful\": True,\n",
" \"asr_decoding_type\": \"rnnt\",\n",
" \"asr.decoding.greedy.use_cuda_graph_decoder\": False,\n",
" \"log_level\": 40,\n",
" \"enable_itn\": True, # compile & load ITN grammar at startup\n",
" \"lang\": \"en\", # language code for the ITN grammar; required when enable_itn=True\n",
Expand Down Expand Up @@ -1159,6 +1166,7 @@
" \"streaming.batch_size\": 8,\n",
" \"streaming.stateful\": True,\n",
" \"asr_decoding_type\": \"rnnt\",\n",
" \"asr.decoding.greedy.use_cuda_graph_decoder\": False,\n",
" \"log_level\": 40,\n",
" \"enable_nmt\": True,\n",
" \"nmt.model_name\": \"utter-project/EuroLLM-1.7B-Instruct\",\n",
Expand Down
5 changes: 2 additions & 3 deletions tutorials/asr/Transducers_with_HF_Datasets.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,6 @@
"# If you're using Google Colab and not running locally, run this cell.\n",
"import os\n",
"\n",
"# Allow loading trusted checkpoints that hold non-tensor objects (torch>=2.6 weights_only default).\n",
"os.environ[\"TORCH_FORCE_NO_WEIGHTS_ONLY_LOAD\"] = \"1\"\n",
"\n",
"# # Install dependencies\n",
"!pip install wget\n",
"!apt-get install sox libsndfile1 ffmpeg\n",
Expand Down Expand Up @@ -616,6 +613,8 @@
"outputs": [],
"source": [
"del asr_model\n",
"# Restore the notebook-generated model with PyTorch's default safe state-dict path.\n",
"os.environ.pop(\"TORCH_FORCE_NO_WEIGHTS_ONLY_LOAD\", None)\n",
"asr_model = ASRModel.restore_from(\"telugu_asr_model.nemo\")\n",
"\n",
"!rm -r telugu_asr_model.nemo # remove the model to save space\n",
Expand Down
Loading