NeMo ASR Module not found

I’m trying to run the ASR example. The error I am getting is:

File “/home/seanle/espnet/venv/lib/python3.6/site-packages/deeppavlov/models/nemo/”, line 21, in
from nemo.collections.asr import AudioToMelSpectrogramPreprocessor, JasperEncoder, JasperDecoderForCTC, GreedyCTCDecoder
ModuleNotFoundError: No module named ‘nemo.collections’

I can’t figure out why I am getting this. My virtual environment “site-packages” folder does have a nemo folder, and does have a collections folder. I don’t know why it isn’t finding it.

Hi @seanle24245,

If your current working directory has a nemo folder (or maybe file), python might try to look for the collection model there and not in site-packages.

You can run python -c "import nemo; print(nemo.__path__)" in bash to see where python is trying to load the nemo package from.

I just ran the command and it returns the path inside of site-packages. It should not matter where I run the ASR script from, correct? I don’t know why I’m still running into the issue.

Actually, I left the print statement inside of where it was being called and it returned a different path. There was another nemo folder I created in my working directory that I’m no longer using so it was using that instead. thank you!