Trying to use custom wake word, get "error: unrecognized arguments: --custom-model-dir /home/pi/custom/lokal"
Closed this issue · 4 comments
Hi, I am trying to use custom wake word, my start line is this:
ExecStart=/home/pi/wyoming-satellite/script/run --name 'Satelit' --uri 'tcp://0.0.0.0:10700' --mic-command 'arecord -D plughw:CARD=seeed2micvoicec,DEV=0 -r 16000 -c 1 -f S16_LE -t raw' --snd-command 'aplay -D plughw:CARD=seeed2micvoicec,DEV=0 -r 22050 -c 1 -f S16_LE -t raw' --wake-uri 'tcp://127.0.0.1:10400' --custom-model-dir '/home/pi/custom/lokal' --wake-word-name 'Dumbledore' --event-uri 'tcp://127.0.0.1:10500' --awake-wav '/home/pi/wyoming-satellite/sounds/awake.wav' --vad --debug WorkingDirectory=/home/pi/wyoming-satellite
I get this error:
Apr 13 11:59:37 satelite run[1099]: __main__.py: error: unrecognized arguments: --custom-model-dir /home/pi/custom/lokal Apr 13 11:59:37 satelite run[1098]: Traceback (most recent call last): Apr 13 11:59:37 satelite run[1098]: File "/home/pi/wyoming-satellite/script/run", line 12, in <module> Apr 13 11:59:37 satelite run[1098]: subprocess.check_call([context.env_exe, "-m", "wyoming_satellite"] + sys.argv[1:]) Apr 13 11:59:37 satelite run[1098]: File "/usr/lib/python3.11/subprocess.py", line 413, in check_call Apr 13 11:59:37 satelite run[1098]: raise CalledProcessError(retcode, cmd) Apr 13 11:59:37 satelite run[1098]: subprocess.CalledProcessError: Command '['/home/pi/wyoming-satellite/.venv/bin/python3', '-m', 'wyoming_satellite', '--name', 'Satelit', '--uri', 'tcp://0.0.0.0:10700', '--mic-command', 'arecord -D plughw:CARD=seeed2micvoicec,DEV=0 -r 16000 -c 1 -f S16_LE -t raw', '--snd-command', 'aplay -D plughw:CARD=seeed2micvoicec,DEV=0 -r 22050 -c 1 -f S16_LE -t raw', '--wake-uri', 'tcp://127.0.0.1:10400', '--custom-model-dir', '/home/pi/custom/lokal', '--wake-word-name', 'Dumbledore', '--event-uri', 'tcp://127.0.0.1:10500', '--awake-wav', '/home/pi/wyoming-satellite/sounds/awake.wav', '--vad', '--debug']' returned non-zero exit status 2. Apr 13 11:59:37 satelite systemd[1]: wyoming-satellite.service: Main process exited, code=exited, status=1/FAILURE Apr 13 11:59:37 satelite systemd[1]: wyoming-satellite.service: Failed with result 'exit-code'.
Where did you put the .tflite file?..(custom wake word)...I'm sure it's goto be put in /home/pi/wyoming-openwakeword/wyoming_openwakeword/models/....??
You are passing the custom model directory argument to wyoming-satellite, not openwakeword, which is what is responsible for wakewords.
Usage of wyoming-openwakeword
:
/home/pi/wyoming-openwakeword/script/run --help
usage: __main__.py [-h] [--uri URI] [--models-dir MODELS_DIR]
[--custom-model-dir CUSTOM_MODEL_DIR] [--preload-model PRELOAD_MODEL]
[--threshold THRESHOLD] [--trigger-level TRIGGER_LEVEL]
[--output-dir OUTPUT_DIR] [--debug] [--log-format LOG_FORMAT]
[--debug-probability] [--version] [--model MODEL]
optional arguments:
-h, --help show this help message and exit
--uri URI unix:// or tcp://
--models-dir MODELS_DIR
Path to directory with built-in models
--custom-model-dir CUSTOM_MODEL_DIR
Path to directory with custom wake word models
--preload-model PRELOAD_MODEL
Name or path of wake word model(s) to pre-load
--threshold THRESHOLD
Wake word model threshold (0.0-1.0, default: 0.5)
--trigger-level TRIGGER_LEVEL
Number of activations before detection (default: 1)
--output-dir OUTPUT_DIR
Path to save audio and detections
--debug Log DEBUG messages
--log-format LOG_FORMAT
Format for log messages
--debug-probability Log all wake word probabilities (VERY noisy)
--version Print version and exit
--model MODEL Deprecated
Thanks !