pipeline: zero-init qenc_host_ready, value-init PipelineTTS
The lazy-init flag started on stack garbage. When non-zero the encode path skipped the codebook load and silently returned empty RVQ codes.
This commit is contained in:
@@ -19,8 +19,9 @@
|
|||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
bool pipeline_codec_load(PipelineCodec * pc, const char * gguf_path, BackendPair bp) {
|
bool pipeline_codec_load(PipelineCodec * pc, const char * gguf_path, BackendPair bp) {
|
||||||
pc->bp = bp;
|
pc->bp = bp;
|
||||||
pc->backend = bp.backend;
|
pc->backend = bp.backend;
|
||||||
|
pc->qenc_host_ready = false;
|
||||||
|
|
||||||
if (!gf_load(&pc->gguf, gguf_path)) {
|
if (!gf_load(&pc->gguf, gguf_path)) {
|
||||||
qt_log(QT_LOG_ERROR, "[Pipeline] failed to load %s", gguf_path);
|
qt_log(QT_LOG_ERROR, "[Pipeline] failed to load %s", gguf_path);
|
||||||
|
|||||||
+1
-1
@@ -209,7 +209,7 @@ static bool parse_args(int argc, char ** argv, Args & a) {
|
|||||||
static int run(const Args & a) {
|
static int run(const Args & a) {
|
||||||
BackendPair bp = backend_init("Talker");
|
BackendPair bp = backend_init("Talker");
|
||||||
|
|
||||||
PipelineTTS pt;
|
PipelineTTS pt = {};
|
||||||
if (!pipeline_tts_load(&pt, a.model, a.codec, bp)) {
|
if (!pipeline_tts_load(&pt, a.model, a.codec, bp)) {
|
||||||
backend_release(bp.backend, bp.cpu_backend);
|
backend_release(bp.backend, bp.cpu_backend);
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
Reference in New Issue
Block a user