MatchboxNet on JetsonNano

Hi all.

I’m trying to run the MatchboxNet model provided in the Nvidia Catalog (https://ngc.nvidia.com/catalog/models/nvidia:nemospeechmodels) on the Jetson Nano, but having some issues with the preprocessing process.

In this demo (https://github.com/NVIDIA/NeMo/blob/main/tutorials/asr/04_Online_Offline_Speech_Commands_Demo.ipynb) it uses the preprocessor directly, but I don’t know how to implement this with TensorRT.

The preprocessor uses torchaudio, which I can not install on the Jetson Nano. Is the preprocessor code available somewhere so that I can use another library to extract the audio features?

Thank you!

Best regards.

Hi,

You can install PyTorch with the instruction shared in this topic.

For example,

PyTorch v1.7:

$ wget https://nvidia.box.com/shared/static/cs3xn3td6sfgtene6jdvsxlr366m2dhq.whl -O torch-1.7.0-cp36-cp36m-linux_aarch64.whl
$ sudo apt-get install python3-pip libopenblas-base libopenmpi-dev 
$ pip3 install Cython
$ pip3 install numpy torch-1.7.0-cp36-cp36m-linux_aarch64.whl

Torchaudio v0.7.0:

$ git clone --branch release/0.7 https://github.com/pytorch/audio torchaudio
$ cd torchaudio
$ export BUILD_VERSION=0.7.0
$ sudo python3 setup.py install

Thanks.

I tried to do that, but when I did “sudo python3 setup.py install” I got the error: “Illegal instruction”.

Getting that error also when trying to import torch, what was working previously.

Thank you for your quick response!

Hi,

Are you using JetPack 4.4.1?

Please noted that the JetPack version and package have some dependency on CUDA.
So you will need to use the package built with the same environment for compatibility.

You can find the dependency on details in the topic 72048.
Thanks.

When doing “dpkg-query --show nvidia-l4t-core” I get “nvidia-l4t-core 32.4.3-20200625213809”.

The info of my Jetson Nano is:

NVIDIA Jetson Nano (Developer Kit Version)
L4T 32.4.3 [ JetPack 4.4 ]
Ubuntu 18.04.4 LTS
Kernel Version: 4.9.140-tegra
CUDA 10.2.89
CUDA Architecture: 5.3

The PyTorch version I installed was 1.7.0.

I also realized it is not only the torch module the one that gives me that “Illegal instruction” error, but also other modules such as numpy, librosa or onnxruntime.

I managed to make it work, but having another problem when trying to use TorchAudio: “RuntimeError: fft: ATen not compiled with MKL support”.

It seems that MKL library is not supported on ARM architectures.
So, in the end, as MatchboxNet audio preprocess is done with TorchAudio, is it possible to use it on Jetson Nano?
Don’t know what to do with that MKL error.