File not found

#4
by tridm - opened

I can not found config.yaml file

NVIDIA org

Hi @tridm , can you try download model from huggingface and restore checkpoint from local?

tridm changed discussion status to closed
tridm changed discussion status to open

Hi @tridm , has your problem been solved? If it solved, could you close this discussion?

Hi @hoanguyen0705
I'm running the script on macOS and encounter a FileNotFoundError for model_config.yaml.

Environment:

  • OS: macOS
  • NeMo: 2.6.1

Script:

import nemo.collections.asr as nemo_asr
asr_model = nemo_asr.models.ASRModel.from_pretrained("nvidia/parakeet-ctc-0.6b-Vietnamese")

The model nvidia/parakeet-ctc-0.6b-Vietnamese is successfully downloaded from HuggingFace,
but during restoration NeMo raises:

FileNotFoundError: No such file or directory: model_config.yaml

Is this a macOS-related issue, a HuggingFace loading issue, or is the model missing the config file?
Any guidance would be appreciated. Thanks!

image
I can't run this model. After I install NeMo using the command (!pip install -U nemo_toolkit['asr']), Colab automatically restarts. Please help me. Thank you.

Hi @PhucTinh @ltlonggg , you can try asr_model = nemo_asr.models.ASRModel.from_pretrained("nvidia/parakeet-ctc-0.6b-vi") as the acoustic model.
For the best results, I suggest downloading the model from Hugging Face to local storage so you can get the language model and follow the tutorial for inference with an n-gram and a lexicon.
You can follow this tutorial to download: https://huggingface.co/docs/huggingface_hub/en/guides/download

Thank, I see 'parakeet-ctc-0.6b-vi.nemo' file and many other file in Files but i don't know how to run those file. Can you guide me ?
Thank you so much.
(I've found the way to do it)

And currently it's experiencing library conflicts. Do you have any way to fix this problem?

image

image
Thank you

Hi @hoanguyen0705
Thanks! I followed your suggestion and was able to run inference successfully.

Hi @ltlonggg
I used the following script and was able to run inference successfully:

import librosa
import soundfile as sf
import os

def preprocess_audio(audio_path):
    target_sr = 16000
    y, sr = librosa.load(audio_path, sr=target_sr, mono=True)
    
    processed_path = "temp_mono_16k.wav"
    sf.write(processed_path, y, target_sr)
    return processed_path

import nemo.collections.asr as nemo_asr

model_path = "nvidia_parakeet_ctc_0.6b_vietnamese/parakeet-ctc-0.6b-vi.nemo"

asr_model = nemo_asr.models.ASRModel.restore_from(restore_path=model_path)

raw_audio = "audio.wav"
ready_audio = preprocess_audio(raw_audio)

transcriptions = asr_model.transcribe([ready_audio])
print(f"Kết quả: {transcriptions[0].text}")

if os.path.exists(ready_audio):
    os.remove(ready_audio)

hi @PhucTinh , thank you for this code snippet. But while install 'nemo_asr' library, I see that the libraries are in conflict with each other beacause I am running in Colab, therefore, I would like to ask how to fix that conflict error, and by the way, what platform are you running your code on ?
Thank you so much

@ltlonggg
Hi, I’m running this code locally in a Jupyter Notebook inside Cursor.

My tries :
Ran successfully within nemo_toolkit === 2.5.0
Ran failed within latest nemo_toolkit 2.6.0+

Error log of v2.6.0

[NeMo I 2026-02-02 17:01:14 nemo_logging:393] PADDING: 0
[NeMo I 2026-02-02 17:01:15 nemo_logging:393] Model EncDecCTCModelBPE was successfully restored from /Users/khanhicetea/.cache/torch/NeMo/NeMo_2.6.1/hf_hub_cache/nvidia/parakeet-ctc-0.6b-Vietnamese/ad1356a8c624a67221ed80e50d009746/parakeet-ctc-0.6b-vi.nemo.
[NeMo W 2026-02-02 17:01:16 nemo_logging:405] The following configuration keys are ignored by Lhotse dataloader: use_start_end_token
[NeMo W 2026-02-02 17:01:16 nemo_logging:405] You are using a non-tarred dataset and requested tokenization during data sampling (pretokenize=True). This will cause the tokenization to happen in the main (GPU) process,possibly impacting the training speed if your tokenizer is very large.If the impact is noticable, set pretokenize=False in dataloader config.(note: that will disable token-per-second filtering and 2D bucketing features)
Traceback (most recent call last):
  File "/Users/khanhicetea/Code/labs/nemo_paraket/abc.py", line 25, in <module>
    transcriptions = asr_model.transcribe([ready_audio])
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/asr/models/ctc_models.py", line 181, in transcribe
    return super().transcribe(
           ^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/torch/utils/_contextlib.py", line 124, in decorate_context
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/asr/parts/mixins/transcription.py", line 270, in transcribe
    for processed_outputs in generator:
                             ^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/asr/parts/mixins/transcription.py", line 356, in transcribe_generator
    dataloader = self._transcribe_input_processing(audio, transcribe_cfg)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/asr/parts/mixins/transcription.py", line 473, in _transcribe_input_processing
    temp_dataloader = self._setup_transcribe_dataloader(ds_config)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/asr/models/ctc_bpe_models.py", line 207, in _setup_transcribe_dataloader
    temporary_datalayer = self._setup_dataloader_from_config(config=DictConfig(dl_config))
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/asr/models/ctc_bpe_models.py", line 98, in _setup_dataloader_from_config
    return get_lhotse_dataloader_from_config(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/common/data/lhotse/dataloader.py", line 266, in get_lhotse_dataloader_from_config
    return get_lhotse_dataloader_from_single_config(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/common/data/lhotse/dataloader.py", line 306, in get_lhotse_dataloader_from_single_config
    sampler, use_iterable_dataset = get_lhotse_sampler_from_config(
                                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/nemo/collections/common/data/lhotse/dataloader.py", line 595, in get_lhotse_sampler_from_config
    sampler = DynamicCutSampler(
              ^^^^^^^^^^^^^^^^^^
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/lhotse/dataset/sampling/dynamic.py", line 120, in __init__
    super().__init__(
  File "/Users/khanhicetea/Code/labs/nemo_paraket/.venv/lib/python3.12/site-packages/lhotse/dataset/sampling/base.py", line 76, in __init__
    super().__init__(
TypeError: object.__init__() takes exactly one argument (the instance to initialize)

Sign up or log in to comment