This example uses the Wav2Vec 2.0 model for speech recognition.
The model generation script was adapted from this PyTorch example script.
It is a good idea to use a separate Python environment instead of the system Python. E.g., a new Conda environment.
Run:
python3 -m pip install -r <this directory>/requirements.txt
Run:
<this directory>/gen_model.sh <output directory>
The model will be generated in the given output directory.
In particular, .onnx and .ort model files will be generated. The .ort model file can be used by ONNX Runtime Mobile.