dscripka/openWakeWord

ValueError: No fast pitch-shift ratios could be computed for the given sample rate and transpose range.

Closed this issue · 1 comments

We are trying to build open wake word for 8khz, We have changed the sample frequency to 8000 in data.py, train.py and genrate_samples.py ( in piper-sample-generator folder) but when we are running following step

_# Step 2: Augment the generated clips

!{sys.executable} openwakeword/openwakeword/train.py --training_config my_model.yaml --augment_clips_

we are getting "ValueError: No fast pitch-shift ratios could be computed for the given sample rate and transpose range." error

For easy reference iam attching the script in which we have done modifications and also error screenshot
Screenshot from 2024-04-16 12-20-50

@manushaanabham unfortunately, the underlying models and training code does not support sample rates different from 16000 Hz.

However, this does not mean that you cannot use the models with 8000 Hz input audio. You simply need to upsample the audio to 16000 Hz prior to passing it to the openWakeWord models. If you are training custom models, training on upsampled data will also help ensure that the model has the best possible accuracy for native 8000 Hz audio.