tests
This commit is contained in:
@@ -125,7 +125,6 @@ def main():
|
||||
"--model", model_lm,
|
||||
"--codec", model_cdc,
|
||||
"--seed", str(args.seed),
|
||||
"--text", text,
|
||||
"--lang", args.lang,
|
||||
"--max-new", str(args.max_new_tokens),
|
||||
"--dump", DUMP_CPP,
|
||||
@@ -133,7 +132,7 @@ def main():
|
||||
"--greedy",
|
||||
]
|
||||
print(f"[GGML] Cmd: {' '.join(cmd)}")
|
||||
r = subprocess.run(cmd)
|
||||
r = subprocess.run(cmd, input=text, text=True)
|
||||
if r.returncode != 0:
|
||||
sys.exit(r.returncode)
|
||||
|
||||
|
||||
@@ -455,8 +455,7 @@ def main():
|
||||
"--model", model_lm,
|
||||
"--codec", model_cdc,
|
||||
"--seed", str(args.seed),
|
||||
"--text", text,
|
||||
"--ref-wav", args.ref_wav,
|
||||
"--ref-wav", args.ref_wav,
|
||||
"--ref-text", args.ref_text,
|
||||
"--lang", args.lang,
|
||||
"--max-new", str(args.max_new_tokens),
|
||||
@@ -464,8 +463,8 @@ def main():
|
||||
"-o", args.out_cpp,
|
||||
"--greedy",
|
||||
]
|
||||
print(f"[GGML] Cmd: {' '.join(cmd[:6])} --text [...] --ref-wav {args.ref_wav} --ref-text [...] --lang {args.lang} --max-new {args.max_new_tokens} --dump {DUMP_CPP} -o {args.out_cpp} --greedy")
|
||||
r = subprocess.run(cmd)
|
||||
print(f"[GGML] Cmd: {' '.join(cmd)}")
|
||||
r = subprocess.run(cmd, input=text, text=True)
|
||||
if r.returncode != 0:
|
||||
sys.exit(r.returncode)
|
||||
|
||||
|
||||
@@ -151,7 +151,6 @@ def main():
|
||||
"--model", model_lm,
|
||||
"--codec", model_cdc,
|
||||
"--seed", str(args.seed),
|
||||
"--text", text,
|
||||
"--speaker", args.speaker,
|
||||
"--lang", args.lang,
|
||||
"--max-new", str(args.max_new_tokens),
|
||||
@@ -162,7 +161,7 @@ def main():
|
||||
if args.instruct:
|
||||
cmd[-1:-1] = ["--instruct", args.instruct]
|
||||
print(f"[GGML] Cmd: {' '.join(cmd)}")
|
||||
r = subprocess.run(cmd)
|
||||
r = subprocess.run(cmd, input=text, text=True)
|
||||
if r.returncode != 0:
|
||||
sys.exit(r.returncode)
|
||||
|
||||
|
||||
@@ -9,8 +9,9 @@ Default mode is greedy (do_sample=False on both sides). Cote Python the
|
||||
utterance and the instruction are tokenized separately and passed to
|
||||
model.generate as input_ids and instruct_ids, mirroring exactly what
|
||||
qwen_tts.inference.qwen3_tts_model.generate_voice_design does. Cote C++
|
||||
both strings are passed through --text and --instruct, the prompt builder
|
||||
wraps and tokenizes them in the same order.
|
||||
the utterance is piped on stdin and the instruction is passed via
|
||||
--instruct, the prompt builder wraps and tokenizes them in the same
|
||||
order.
|
||||
|
||||
Dumps land in cpp/tts/ (C++) and python/tts/ (Python).
|
||||
"""
|
||||
@@ -140,7 +141,6 @@ def main():
|
||||
"--model", model_lm,
|
||||
"--codec", model_cdc,
|
||||
"--seed", str(args.seed),
|
||||
"--text", text,
|
||||
"--instruct", args.instruct,
|
||||
"--lang", args.lang,
|
||||
"--max-new", str(args.max_new_tokens),
|
||||
@@ -149,7 +149,7 @@ def main():
|
||||
"--greedy",
|
||||
]
|
||||
print(f"[GGML] Cmd: {' '.join(cmd)}")
|
||||
r = subprocess.run(cmd)
|
||||
r = subprocess.run(cmd, input=text, text=True)
|
||||
if r.returncode != 0:
|
||||
sys.exit(r.returncode)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user