From 461d7da62889c4e9dced79b08ed06b4e57c7890e Mon Sep 17 00:00:00 2001 From: dscripka Date: Sun, 5 Mar 2023 00:35:42 -0500 Subject: [PATCH] Added argument to control activation sounds in example script --- examples/capture_activations.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/examples/capture_activations.py b/examples/capture_activations.py index 109d4e1..fae900e 100644 --- a/examples/capture_activations.py +++ b/examples/capture_activations.py @@ -68,13 +68,18 @@ parser.add_argument( default=False, required=False ) - parser.add_argument( "--model", help="The model to use for openWakeWord, leave blank to use all available models", type=str, required=False ) +parser.add_argument( + "--disable_activation_sound", + help="Disables the activation sound, clips are silently captured", + action='store_true', + required=False +) args=parser.parse_args() @@ -151,4 +156,5 @@ if __name__ == "__main__": fname = detect_time + f"_{mdl}.wav" scipy.io.wavfile.write(os.path.join(os.path.abspath(args.output_dir), fname), 16000, audio_context) - playBeep(os.path.join(os.path.dirname(__file__), 'audio', 'activation.wav'), audio) + if not args.disable_activation_sound: + playBeep(os.path.join(os.path.dirname(__file__), 'audio', 'activation.wav'), audio)