From a6dbd9188b13378dc36e2c669b9a22e17b4201d1 Mon Sep 17 00:00:00 2001 From: Georgi Gerganov Date: Sat, 14 Jan 2023 19:20:47 +0200 Subject: [PATCH] stream : fix a bug that inserted a lot of empty audio at the start The quality was terrible due to this --- examples/stream/stream.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/stream/stream.cpp b/examples/stream/stream.cpp index c7aa8717..9f0c16c6 100644 --- a/examples/stream/stream.cpp +++ b/examples/stream/stream.cpp @@ -459,7 +459,7 @@ int main(int argc, char ** argv) { struct whisper_context * ctx = whisper_init_from_file(params.model.c_str()); std::vector pcmf32 (n_samples_30s, 0.0f); - std::vector pcmf32_old(n_samples_30s, 0.0f); + std::vector pcmf32_old; std::vector pcmf32_new(n_samples_30s, 0.0f); std::vector prompt_tokens;