From 19797e0e593bbe64fb60ab6c9a3d0ec6482300e1 Mon Sep 17 00:00:00 2001 From: Reuben Morais Date: Sun, 2 Aug 2020 17:27:21 +0200 Subject: [PATCH] Handle rename to Mozilla Voice STT --- mic_vad_streaming/mic_vad_streaming.py | 4 ++-- tests.sh | 4 ++-- vad_transcriber/wavTranscriber.py | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/mic_vad_streaming/mic_vad_streaming.py b/mic_vad_streaming/mic_vad_streaming.py index c56f817..074e5b2 100755 --- a/mic_vad_streaming/mic_vad_streaming.py +++ b/mic_vad_streaming/mic_vad_streaming.py @@ -1,7 +1,7 @@ import time, logging from datetime import datetime import threading, collections, queue, os, os.path -import deepspeech +import mozilla_voice_stt as stt import numpy as np import pyaudio import wave @@ -160,7 +160,7 @@ def main(ARGS): print('Initializing model...') logging.info("ARGS.model: %s", ARGS.model) - model = deepspeech.Model(ARGS.model) + model = stt.Model(ARGS.model) if ARGS.scorer: logging.info("ARGS.scorer: %s", ARGS.scorer) model.enableExternalScorer(ARGS.scorer) diff --git a/tests.sh b/tests.sh index 8569a50..8764cb3 100755 --- a/tests.sh +++ b/tests.sh @@ -14,10 +14,10 @@ get_python_wheel_url() extract_python_versions "${this_python_version}" "pyver" "pyver_pkg" "py_unicode_type" "pyconf" "pyalias" - echo "$(get_python_pkg_url "${pyver_pkg}" "${py_unicode_type}" "deepspeech" https://community-tc.services.mozilla.com/api/queue/v1/task/${DEP_TASK_ID}/artifacts/public)" + echo "$(get_python_pkg_url "${pyver_pkg}" "${py_unicode_type}" "mozilla_voice_stt" https://community-tc.services.mozilla.com/api/queue/v1/task/${DEP_TASK_ID}/artifacts/public)" } get_npm_package_url() { - echo "https://community-tc.services.mozilla.com/api/queue/v1/task/${DEP_TASK_ID}/artifacts/public/deepspeech-${DS_VERSION}.tgz" + echo "https://community-tc.services.mozilla.com/api/queue/v1/task/${DEP_TASK_ID}/artifacts/public/mozilla_voice_stt-${DS_VERSION}.tgz" } diff --git a/vad_transcriber/wavTranscriber.py b/vad_transcriber/wavTranscriber.py index 2d1fc6f..fce4d5b 100644 --- a/vad_transcriber/wavTranscriber.py +++ b/vad_transcriber/wavTranscriber.py @@ -2,7 +2,7 @@ import glob import webrtcvad import logging import wavSplit -from deepspeech import Model +import mozilla_voice_stt from timeit import default_timer as timer ''' @@ -15,7 +15,7 @@ Returns a list [DeepSpeech Object, Model Load Time, Scorer Load Time] ''' def load_model(models, scorer): model_load_start = timer() - ds = Model(models) + ds = mozilla_voice_stt.Model(models) model_load_end = timer() - model_load_start logging.debug("Loaded model in %0.3fs." % (model_load_end))