

import WhisperModel
@6276797fd1a3373977a66c6f869f92562ee0014c
--- whisper_online.py
+++ whisper_online.py
... | ... | @@ -6,6 +6,7 @@ |
6 | 6 |
import time |
7 | 7 |
from mosestokenizer import MosesTokenizer |
8 | 8 |
|
9 |
+ |
|
9 | 10 |
@lru_cache |
10 | 11 |
def load_audio(fname): |
11 | 12 |
a, _ = librosa.load(fname, sr=16000) |
... | ... | @@ -89,6 +90,8 @@ |
89 | 90 |
sep = "" |
90 | 91 |
|
91 | 92 |
def load_model(self, modelsize=None, cache_dir=None, model_dir=None): |
93 |
+ from faster_whisper import WhisperModel |
|
94 |
+ |
|
92 | 95 |
|
93 | 96 |
if model_dir is not None: |
94 | 97 |
print(f"Loading whisper model from model_dir {model_dir}. modelsize and cache_dir parameters are not used.",file=sys.stderr) |
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?