Skip to content

[Bug] Higgs Audio TTS: periodic click every ~5.12 s — chunked codec decode overlap (8 frames) is smaller than the decoder receptive field (~27 frames per side) #429

Closed

Description

@HaujetZhao

Environment

  • Build: audio-v0.7.1-bin-windows-x64-cuda13.3.zip (Windows 10 x64, CUDA 13.3 backend)
  • Model: higgs_audio_tts_4b_q8_0
  • Commit analyzed: a088f90

Symptom

When generating longer audio with Higgs Audio TTS, the output has an audible click/glitch roughly every 5 seconds (at ~5 s, ~10 s, ~15 s, ~20 s, ...), as if the waveform breaks at a seam. Short generations (≈10 s or less) sound fine.

Root cause

The official Python implementation decodes the whole sequence in one shot (HiggsAudioTokenizer.decode() in boson_multimodal/audio_processing/higgs_audio_tokenizer.py). src/models/higgs_audio_tts/codec.cpp adds chunked decoding (not present upstream) to bound memory:

constexpr int64_t kCodecDecodeWindowFrames  = 128;  // 128 frames = 128 × 960 / 24000 = 5.12 s
constexpr int64_t kCodecDecodeOverlapFrames = 8;    // only 8 frames of left context, hard-trimmed concat

(codec.cpp:64-65; the chunk loop is around codec.cpp:1584. Frames ≤ 512 take the single-window path, which is why short audio is unaffected — and why the seams land at every 128 frames from sample 0, i.e. every 5.12 s.)

The problem: the overlap is far smaller than the decoder's receptive field. This DAC-style decoder is purely convolutional (5 × ConvTranspose blocks with residual units at dilations 1/3/9, all symmetric padding, i.e. non-causal). Walking the structure layer by layer:

Item Value
Decoder total receptive field ≈ 53 frames (≈ 27 frames per side ≈ 1.1 s of audio)
Left context provided by chunking 8 frames
Missing right context at each window tail ≈ 27 frames

Since the decoder is non-causal, samples up to ~1 s past each trim point deviate from the full-sequence decode, and each window tail also lacks right context. The hard concat at seams then produces a waveform discontinuity — the periodic click.

Proposed fixes

Option A: widen the context window (recommended, minimal change)

Borrow 32 frames on both sides and trim both after decoding:

constexpr int64_t kCodecDecodeContextFrames = 32;   // ≥ 27, covers the RF; aligns with the 32-frame graph capacity bucket

// window: [emit_start - 32, emit_end + 32), emit region still 128 frames
// trim 32 × 960 samples from each side before concatenating

Because the decoder is purely convolutional with no global ops (no attention/LSTM), once every emitted frame's full receptive field lies inside its window the chunked output is bit-identical to the full-sequence decode; the zero padding at the first window's left edge and the last window's right edge also matches the full decode exactly.

  • Touches only the decode_codes() chunk loop, and mirrors the pattern already used by qwen3_tts in this repo (kLeftContextCodes = 25 + drop in tokenizer_speech_decoder.cpp).
  • Cost: ~1.4× per-window compute (192/136 frames). The codec decoder is a tiny fraction of the pipeline (AR generation dominates), so end-to-end impact is negligible.

Option B: stateful streaming chunks (more compute-efficient, much bigger change)

Carry the conv input history explicitly across chunks so each chunk computes only new frames:

  • The DAC decoder has 5 time scales (cumulative strides 3/6/24/120/960); each scale needs its own ring buffer of layer history, and the single HiggsCodecDecodeGraph would need to be split into a dozen-plus subgraphs with state passed between them.

  • Benefit: removes the redundant re-decode and naturally supports decode-while-generating streaming.

  • Caveat: the decoder is non-causal, so even with full layer state, streaming the tail ≈1.1 s of audio still has to wait for future code frames — i.e. this does not remove streaming latency; it only saves the re-decode compute (<1% end-to-end).

Suggestion

Ship Option A first (bit-exact, small diff, imperceptible cost). If decode-while-generating streaming is wanted later, it can be driven at the generator/session level per chunk (state = the last 32 code frames) without touching the codec internals; Option B can remain a perf optimization.

Activity

  1. self-assigned this
    on Sep 3, 2026
  2. 0xShug0 commented on Sep 3, 2026

    @0xShug0
    Owner

    @HaujetZhao Please provide the exact cmd, test input, and output. Please also check if the issue is consistent across different seeds. I can’t reproduce this issue, so I don’t want to chase the wrong target.

    build/debug/bin/audiocpp_cli \
      --task tts \
      --family higgs_audio_tts \
      --model Higgs-Audio-v3-TTS-4B-GGUF/higgs-audio-v3-tts-4b-q8_0.gguf \
      --backend cuda \
      --threads 8 \
      --text "This is a reproducible Higgs Audio voice clone test for audio.cpp. It uses a git tracked voice asset from this repository. The sample is long enough to cross codec decode chunk boundaries. Listen near five seconds, ten seconds, fifteen seconds, twenty seconds, and twenty five seconds for periodic clicks or small waveform breaks. The test is complete." \
      --voice-ref assets/resources/b.wav \
      --reference-text "Some call me nature. Others call me Mother Nature. I've been here for over 4.5 billion years. 22,500 times longer than you." \
      --seed 429 \
      --out  repro-voice-clone-tracked.wav \
      --metrics \
      --log 
    

    repro-voice-clone-tracked.wav

    Also another random run

    longform_test.wav

  3. HaujetZhao commented on Sep 4, 2026

    @HaujetZhao
    Author

    Thanks for the reply. Here are the exact repro steps.

    Input / Output files

    Commands

    English test:

    ./audiocpp_cli `
      --task tts `
      --family higgs_audio_tts `
      --model models/Higgs-Audio-v3-TTS-4B-GGUF/higgs-audio-v3-tts-4b-q8_0.gguf `
      --backend cuda `
      --threads 8 `
      --text "This is a reproducible Higgs Audio voice clone test for audio.cpp. It uses a git tracked voice asset from this repository. The sample is long enough to cross codec decode chunk boundaries. Listen near five seconds, ten seconds, fifteen seconds, twenty seconds, and twenty five seconds for periodic clicks or small waveform breaks. The test is complete." `
      --voice-ref Vivian.wav `
      --reference-text "你好,我是千问,你今天过得好吗?" `
      --seed 429 `
      --out repro-voice-clone-tracked-english.wav `
      --metrics `
      --log

    Chinese test:

    ./audiocpp_cli `
      --task tts `
      --family higgs_audio_tts `
      --model models/Higgs-Audio-v3-TTS-4B-GGUF/higgs-audio-v3-tts-4b-q8_0.gguf `
      --backend cuda `
      --threads 8 `
      --text "后又开始对佛道儒神的逐步理解,就差把日月神教的宗义也整出来了,却始终找不到答案,一个20岁的小伙子又有什么资历去在别人终其一生都悟不通一门的东西上找到答案,更何况还是大杂烩一起上。现在想起真是可笑。" `
      --voice-ref Vivian.wav `
      --reference-text "你好,我是千问,你今天过得好吗?" `
      --seed 429 `
      --out repro-voice-clone-tracked-chinese.wav `
      --metrics `
      --log

    Environment: audio-v0.7.1-bin-windows-x64-cuda13.3.zip, Windows 10 x64, CUDA backend, model higgs-audio-v3-tts-4b-q8_0.gguf.

    Why it is easy to miss in English

    I only noticed this with Chinese input at first, and I think the masking is worth explaining. Every ~5.12 s the codec decode seam lands mid-utterance; whether you hear it depends on what the voice is doing at that instant:

    • In English, words are built from several phonemes with constant pitch/formant transitions, plus frequent stops, fricatives and pauses. A short broadband click almost always lands on one of these transitions or gaps and gets masked.
    • In Chinese, each syllable is a fairly steady, sustained vowel of a few hundred ms, so a click landing mid-syllable stands out clearly. The Chinese sample above is the easy one to hear.

    In the English sample the click is audible at ~10 s right on "c̶r̶o̶s̶s̶" (a sustained /ɔ/), but inaudible at 15 s because the seam lands in a speech gap.

    On seeds

    I have only tested seed 429 so far. Note the decode path is deterministic given the generated codes — any seed whose output exceeds ~10 s crosses the >512-frame chunked path, so per the root-cause analysis in the issue body it should show seams at multiples of 128 frames (5.12 s) regardless of seed; the only variable is whether a seam lands somewhere masked or on a sustained vowel. If you test, I'd suggest the Chinese text above — it's the easiest to hear.

    Suspected cause (same as in the issue body)

    kCodecDecodeOverlapFrames = 8 frames of left context vs a decoder receptive field of ≈27 frames per side (≈53 frames total), with hard-trim concat, in decode_codes() (src/models/higgs_audio_tts/codec.cpp). The official Python tokenizer decodes the full sequence in one shot. Proposed Option A: borrow 32 frames on both sides and trim both — bit-exact for this purely-convolutional decoder.

    Logs

    English:

    [TRACE ts=20260904-083035] runtime.model.family higgs_audio_tts
    [TRACE ts=20260904-083035] runtime.model.variant v3-4b
    [TRACE ts=20260904-083035] runtime.model.root C:\Users\Haujet\AppData\Local\Temp\audiocpp-gguf\96f0e1a202ea133a
    [TRACE ts=20260904-083035] runtime.model.discovered_config_count 4
    [TRACE ts=20260904-083035] runtime.model.discovered_weight_count 1
    [TRACE ts=20260904-083035] runtime.model.task_count 1
    [TRACE ts=20260904-083035] runtime.model.language_count 1
    [TRACE ts=20260904-083035] runtime.model.supports_speaker_reference 1
    [TRACE ts=20260904-083035] runtime.model.supports_style_condition 0
    [TRACE ts=20260904-083035] runtime.model.supports_timestamps 0
    ggml_cuda_init: found 1 CUDA devices (Total VRAM: 8150 MiB):
      Device 0: NVIDIA GeForce RTX 5050 Laptop GPU, compute capability 12.0, VMM: yes, VRAM: 8150 MiB
    load_backend: loaded CUDA backend from C:\Users\Haujet\Downloads\Compressed\audio.cpp\ggml-cuda.dll
    load_backend: loaded CPU backend from C:\Users\Haujet\Downloads\Compressed\audio.cpp\ggml-cpu-haswell.dll
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_audio.sample_rate 24000
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_audio.channels 1
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_audio.samples shape=[78720] size=78720 samples=[0:0,2018:0.0264282,4036:-0.0827026,6055:0.00189209,8073:-0.00524902,10091:-0.128418,12110:-0.0842896,14128:-0.014679,16147:-0.000854492,18165:-3.05176e-05,20183:0.000183105,22202:9.15527e-05,24220:0.000244141,26239:-0.0980835,26240:-0.0934448,28625:-0.0456543,31010:-0.0814209,33396:0.0996094,35781:0.285645,38166:0.019104,40552:-0.152588,42937:0.0716553,45322:0.000640869,47708:0,50093:-9.15527e-05,52479:0.00466919,52480:0.00372314,54498:-0.0488586,56516:-0.210205,58535:0.251221,60553:-0.0371704,62571:-0.0682373,64590:-0.0631104,66608:-0.00292969,68627:-0.0255127,70645:0.0284729,72663:-0.0834961,74682:0.0894775,76700:-0.0157166,78719:-3.05176e-05]
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_cache.capacity 1
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_cache.size 0
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_cache.hit 0
    [TIMING ts=20260904-083041] higgs_audio_tts.codec.encode.graph.build_ms 1.5648
    [TRACE ts=20260904-083041] higgs_audio_tts.codec.encode.input_frames 82
    [TRACE ts=20260904-083041] higgs_audio_tts.codec.encode.input_acoustic_24k shape=[78720] size=78720 samples=[0:0,2018:0.0264282,4036:-0.0827026,6055:0.00189209,8073:-0.00524902,10091:-0.128418,12110:-0.0842896,14128:-0.014679,16147:-0.000854492,18165:-3.05176e-05,20183:0.000183105,22202:9.15527e-05,24220:0.000244141,26239:-0.0980835,26240:-0.0934448,28625:-0.0456543,31010:-0.0814209,33396:0.0996094,35781:0.285645,38166:0.019104,40552:-0.152588,42937:0.0716553,45322:0.000640869,47708:0,50093:-9.15527e-05,52479:0.00466919,52480:0.00372314,54498:-0.0488586,56516:-0.210205,58535:0.251221,60553:-0.0371704,62571:-0.0682373,64590:-0.0631104,66608:-0.00292969,68627:-0.0255127,70645:0.0284729,72663:-0.0834961,74682:0.0894775,76700:-0.0157166,78719:-3.05176e-05]
    [TRACE ts=20260904-083041] higgs_audio_tts.codec.encode.input_semantic_16k shape=[52800] size=52800 samples=[0:0,1353:0,2707:-0.0410111,4061:0.02576,5415:-0.159204,6768:-0.00693847,8122:0.0594634,9476:0.0595001,10830:0.00142098,12183:-0.000202429,13537:-0.000156421,14891:0.000195622,16245:0.000350459,17599:0.0476778,17600:0.0328737,19199:-0.00682171,20799:0.0107592,22399:-0.262369,23999:0.0454947,25599:0.189531,27199:-0.156163,28799:0.0152566,30399:0.000931859,31999:-0.000259162,33599:-0.000231289,35199:0.00860786,35200:0.00976957,36553:-0.0143577,37907:-0.132778,39261:-0.23943,40615:0.0141809,41968:0.14718,43322:-0.0706537,44676:0.0143206,46030:0.0104373,47383:-0.0318875,48737:0.094269,50091:0.0146719,51445:-0.00157601,52799:0]
    [TIMING ts=20260904-083041] higgs_audio_tts.codec.encode_input_upload_ms 2.5362
    [TIMING ts=20260904-083041] higgs_audio_tts.codec.encode.graph.compute_ms 152.6333
    [TIMING ts=20260904-083041] higgs_audio_tts.codec.encode_output_read_ms 0.4465
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_codes.frames 82
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_codes.codebooks 8
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_codes.values shape=[82,8] size=656 samples=[0:244,16:679,33:243,50:227,66:858,83:882,100:508,116:508,133:920,150:417,166:417,183:981,200:321,217:603,218:69,237:606,257:774,277:641,297:618,317:850,336:672,356:629,376:87,396:283,416:916,436:130,437:94,453:259,470:72,487:212,504:131,520:684,537:351,554:482,571:487,587:170,604:78,621:153,638:409,655:438]
    [TIMING ts=20260904-083041] higgs_audio_tts.codec.encode_reference_ms 160.1955
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_audio.sample_rate 24000
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_audio.channels 1
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_audio.samples shape=[78720] size=78720 samples=[0:0,2018:0.0264282,4036:-0.0827026,6055:0.00189209,8073:-0.00524902,10091:-0.128418,12110:-0.0842896,14128:-0.014679,16147:-0.000854492,18165:-3.05176e-05,20183:0.000183105,22202:9.15527e-05,24220:0.000244141,26239:-0.0980835,26240:-0.0934448,28625:-0.0456543,31010:-0.0814209,33396:0.0996094,35781:0.285645,38166:0.019104,40552:-0.152588,42937:0.0716553,45322:0.000640869,47708:0,50093:-9.15527e-05,52479:0.00466919,52480:0.00372314,54498:-0.0488586,56516:-0.210205,58535:0.251221,60553:-0.0371704,62571:-0.0682373,64590:-0.0631104,66608:-0.00292969,68627:-0.0255127,70645:0.0284729,72663:-0.0834961,74682:0.0894775,76700:-0.0157166,78719:-3.05176e-05]
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_cache.capacity 1
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_cache.size 1
    [TRACE ts=20260904-083041] higgs_audio_tts.reference_cache.hit 1
    [TRACE ts=20260904-083041] higgs_audio_tts.text_chunk_size 1024
    [TRACE ts=20260904-083041] higgs_audio_tts.text_chunk_mode default
    [TRACE ts=20260904-083041] higgs_audio_tts.text_chunk_count 1
    [TRACE ts=20260904-083041] higgs_audio_tts.request.text This is a reproducible Higgs Audio voice clone test for audio.cpp. It uses a git tracked voice asset from this repository. The sample is long enough to cross codec decode chunk boundaries. Listen near five seconds, ten seconds, fifteen seconds, twenty seconds, and twenty five seconds for periodic clicks or small waveform breaks. The test is complete.
    [TRACE ts=20260904-083041] higgs_audio_tts.request.reference_text 你好,我是千问,你今天过得好吗?
    [TRACE ts=20260904-083041] higgs_audio_tts.request.text_chars 352
    [TRACE ts=20260904-083041] higgs_audio_tts.request.reference_text_chars 48
    [TRACE ts=20260904-083041] higgs_audio_tts.request.max_tokens 2048
    [TRACE ts=20260904-083041] higgs_audio_tts.request.temperature 0.800000011920929
    [TRACE ts=20260904-083041] higgs_audio_tts.request.top_p 0.800000
    [TRACE ts=20260904-083041] higgs_audio_tts.request.top_k 30
    [TRACE ts=20260904-083041] higgs_audio_tts.request.repetition_penalty 1.100000023841858
    [TRACE ts=20260904-083041] higgs_audio_tts.request.has_seed 1
    [TRACE ts=20260904-083041] higgs_audio_tts.request.seed 429
    [TRACE ts=20260904-083041] higgs_audio_tts.request.reference_codes shape=[82,8] size=656 samples=[0:244,16:679,33:243,50:227,66:858,83:882,100:508,116:508,133:920,150:417,166:417,183:981,200:321,217:603,218:69,237:606,257:774,277:641,297:618,317:850,336:672,356:629,376:87,396:283,416:916,436:130,437:94,453:259,470:72,487:212,504:131,520:684,537:351,554:482,571:487,587:170,604:78,621:153,638:409,655:438]
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.text_tokens 69
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.text_ids shape=[69] size=69 samples=[0:1986,1:374,3:52723,5:472,6:61147,8:7743,10:1273,11:369,13:7208,15:1084,16:5711,18:16345,20:7743,22:504,23:419,25:13,27:6077,29:1293,31:311,33:34647,35:11879,37:13,39:3143,41:6486,43:5779,45:11,46:36655,47:6486,49:17073,51:11,52:323,54:4236,56:369,57:38345,59:476,61:72364,62:18303,64:576,66:374,68:13]
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.reference_text_tokens 11
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.reference_text_ids shape=[11] size=11 samples=[0:108386,1:3837,2:104198,3:99320,4:56007,5:3837,6:56568,7:100644,8:108178,9:110201,10:11319]
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.tokens 174
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.token_ids shape=[174] size=174 samples=[0:151667,4:104198,8:56568,13:151679,17:0,21:0,26:0,30:0,35:0,39:0,43:0,48:0,52:0,57:0,58:0,63:0,68:0,73:0,78:0,83:0,89:0,94:0,99:0,104:1986,109:472,115:369,116:7699,120:5711,124:7743,129:13,133:1293,137:34647,142:32149,146:11,151:6486,155:11,159:6486,164:2613,168:576,173:151670]
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.delayed_reference_rows 89
    [TRACE ts=20260904-083041] higgs_audio_tts.prompt.delayed_reference_codes shape=[89,8] size=712 samples=[0:244,18:468,36:843,54:118,72:986,90:95,108:687,127:84,145:872,163:113,181:738,199:291,217:951,236:783,237:765,258:614,279:984,301:360,322:204,344:878,365:384,387:716,408:489,430:63,451:966,473:728,474:549,492:717,510:788,528:331,546:812,565:882,583:280,601:916,619:584,638:845,656:1025,674:1025,692:1025,711:438]
    [TRACE ts=20260904-083041] higgs_audio_tts.ar.prefill.text_tokens shape=[174] size=174 samples=[0:151667,4:104198,8:56568,13:151679,17:0,21:0,26:0,30:0,35:0,39:0,43:0,48:0,52:0,57:0,58:0,63:0,68:0,73:0,78:0,83:0,89:0,94:0,99:0,104:1986,109:472,115:369,116:7699,120:5711,124:7743,129:13,133:1293,137:34647,142:32149,146:11,151:6486,155:11,159:6486,164:2613,168:576,173:151670]
    [TRACE ts=20260904-083041] higgs_audio_tts.ar.prefill.fused_code_ids shape=[174,8] size=1392 samples=[0:0,35:0,71:0,106:0,142:7180,178:2279,213:5234,249:1415,284:4766,320:59,356:4928,391:8166,427:3133,463:7734,464:885,506:2155,548:4292,590:6839,632:684,674:2652,716:4569,758:6715,800:1025,842:0,884:0,927:0,928:0,963:0,999:0,1034:0,1070:0,1106:0,1141:0,1177:0,1212:0,1248:0,1284:0,1319:0,1355:0,1391:0]
    [TRACE ts=20260904-083041] higgs_audio_tts.ar.prefill.text_gate shape=[174] size=174 samples=[0:1,4:1,8:1,13:1,17:0,21:0,26:0,30:0,35:0,39:0,43:0,48:0,52:0,57:0,58:0,63:0,68:0,73:0,78:0,83:0,89:0,94:0,99:0,104:1,109:1,115:1,116:1,120:1,124:1,129:1,133:1,137:1,142:1,146:1,151:1,155:1,159:1,164:1,168:1,173:1]
    [TRACE ts=20260904-083041] higgs_audio_tts.ar.prefill.code_gate shape=[174] size=174 samples=[0:0,4:0,8:0,13:0,17:1,21:1,26:1,30:1,35:1,39:1,43:1,48:1,52:1,57:1,58:1,63:1,68:1,73:1,78:1,83:1,89:1,94:1,99:1,104:0,109:0,115:0,116:0,120:0,124:0,129:0,133:0,137:0,142:0,146:0,151:0,155:0,159:0,164:0,168:0,173:0]
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.reference_prefix_cache_hit 1
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.reference_prefix_steps 103
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.reference_kv_cache_hit 0
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.prefill_start_step 0
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.prefill_run_steps 174
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.kv_cache_steps 512
    [TRACE ts=20260904-083041] higgs_audio_tts.generator.kv_cache_rebuild 1
    [TIMING ts=20260904-083041] higgs_audio_tts.ar.prefill.graph.build_ms 2.7802
    [TIMING ts=20260904-083042] higgs_audio_tts.ar.decode.graph.build_ms 0.9127
    [TIMING ts=20260904-083042] higgs_audio_tts.generator.prefill_ms 1017.5332
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.prefill_logits shape=[8,1026] size=8208 samples=[0:43.1884,210:42.8786,420:44.4682,631:44.7946,841:45.5087,1051:50.6013,1262:53.5051,1472:51.9039,1683:49.7699,1893:51.5316,2103:64.3793,2314:67.9824,2524:65.0533,2735:63.8134,2736:63.3443,2984:64.7693,3233:88.1411,3481:89.8848,3730:87.257,3979:88.0601,4227:107.048,4476:105.996,4725:106.101,4973:107.595,5222:106.518,5471:102.22,5472:102.837,5682:103.814,5892:103.728,6103:100.658,6313:123.999,6523:126.59,6734:124.655,6944:125.959,7155:125.51,7365:99.3729,7575:99.6531,7786:97.1418,7996:98.1301,8207:-29.4414]
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.temperature 0.800000011920929
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.has_seed 1
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.seed 429
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.top_p 0.800000
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.top_k 30
    [TRACE ts=20260904-083042] higgs_audio_tts.sampler.first_output_codes shape=[8] size=8 samples=[0:489,1:1024,2:1024,3:1024,4:1024,5:1024,6:1024,7:1024]
    [TIMING ts=20260904-083042] higgs_audio_tts.ar.decode.step0.input_upload_ms 0.1247
    [TIMING ts=20260904-083042] higgs_audio_tts.ar.decode.step0.mask_upload_ms 0.0249
    [TIMING ts=20260904-083042] higgs_audio_tts.ar.decode.step0.graph.compute_ms 27.3424
    [TIMING ts=20260904-083042] higgs_audio_tts.ar.decode.step0.output_read_ms 0.2208
    [TIMING ts=20260904-083042] higgs_audio_tts.generator.decode.step0.ar_ms 28.3348
    [TIMING ts=20260904-083042] higgs_audio_tts.generator.decode.step0.sampler_ms 0.0997
    ggml_backend_cuda_graph_compute: CUDA graph warmup complete
    [TRACE ts=20260904-083048] higgs_audio_tts.generator.kv_cache_grown_steps 1024
    [TIMING ts=20260904-083048] higgs_audio_tts.ar.decode.graph.build_ms 0.9179
    ggml_backend_cuda_graph_compute: CUDA graph warmup complete
    [TIMING ts=20260904-083052] higgs_audio_tts.ar.decode.steps 598
    [TIMING ts=20260904-083052] higgs_audio_tts.ar.decode.input_upload_ms 80.34340000000003
    [TIMING ts=20260904-083052] higgs_audio_tts.ar.decode.mask_upload_ms 27.594699999999996
    [TIMING ts=20260904-083052] higgs_audio_tts.ar.decode.graph.compute_ms 9135.668800000003
    [TIMING ts=20260904-083052] higgs_audio_tts.ar.decode.output_read_ms 59.48110000000002
    [TIMING ts=20260904-083052] higgs_audio_tts.generator.decode.sampler_ms 56.66030000000001
    [TIMING ts=20260904-083052] higgs_audio_tts.generator.decode_ms 9762.3323
    [TRACE ts=20260904-083052] higgs_audio_tts.generator.delayed_codes shape=[599,8] size=4792 samples=[0:489,122:143,245:216,368:28,491:386,613:306,736:725,859:128,982:423,1104:114,1227:688,1350:276,1473:948,1596:927,1597:477,1742:442,1887:733,2032:815,2177:327,2322:111,2467:452,2612:401,2757:965,2902:296,3047:304,3193:203,3194:205,3316:955,3439:944,3562:134,3685:871,3808:321,3931:452,4053:692,4176:882,4299:153,4422:53,4545:53,4668:36,4791:563]
    [TRACE ts=20260904-083052] higgs_audio_tts.generator.delayed_codes_head8 shape=[8,8] size=64 samples=[0:489,1:1024,3:1024,4:1024,6:1024,7:1024,9:267,10:1024,12:1024,13:1024,15:1024,16:705,18:861,20:1024,21:1024,22:1024,24:220,26:715,28:1024,30:1024,31:1024,33:910,35:580,37:1024,39:1024,41:440,42:91,43:149,45:552,46:1024,48:874,50:602,51:383,53:325,54:233,56:461,58:452,59:560,61:238,63:563]
    [TRACE ts=20260904-083052] higgs_audio_tts.generator.raw_codes_for_codec shape=[592,8] size=4736 samples=[0:489,121:389,242:815,363:375,485:839,606:903,727:40,849:940,970:465,1091:120,1213:483,1334:152,1455:537,1577:220,1578:671,1721:202,1864:58,2008:151,2151:177,2295:786,2438:593,2582:293,2725:599,2869:552,3012:290,3156:682,3157:844,3278:38,3399:388,3521:23,3642:124,3763:736,3885:553,4006:203,4128:3,4249:939,4370:558,4492:128,4613:15,4735:563]
    [TRACE ts=20260904-083052] higgs_audio_tts.codec.decode.input_frames 592
    [TRACE ts=20260904-083052] higgs_audio_tts.codec.decode.input_codebooks 8
    [TRACE ts=20260904-083052] higgs_audio_tts.codec.decode.input_codes shape=[592,8] size=4736 samples=[0:489,121:389,242:815,363:375,485:839,606:903,727:40,849:940,970:465,1091:120,1213:483,1334:152,1455:537,1577:220,1578:671,1721:202,1864:58,2008:151,2151:177,2295:786,2438:593,2582:293,2725:599,2869:552,3012:290,3156:682,3157:844,3278:38,3399:388,3521:23,3642:124,3763:736,3885:553,4006:203,4128:3,4249:939,4370:558,4492:128,4613:15,4735:563]
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode.graph.build_ms 0.656
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_input_upload_ms 2.8374
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode.graph.compute_ms 49.5936
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_output_read_ms 0.174
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_input_upload_ms 0.1244
    ggml_backend_cuda_graph_compute: CUDA graph warmup complete
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode.graph.compute_ms 52.2323
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_output_read_ms 0.1848
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_input_upload_ms 0.0922
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode.graph.compute_ms 42.4483
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_output_read_ms 0.2014
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_input_upload_ms 0.1172
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode.graph.compute_ms 41.9457
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_output_read_ms 0.1954
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_input_upload_ms 0.1218
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode.graph.compute_ms 41.4177
    [TIMING ts=20260904-083052] higgs_audio_tts.codec.decode_output_read_ms 0.1874
    [TRACE ts=20260904-083052] higgs_audio_tts.codec.decode.output_audio shape=[568320] size=568320 samples=[0:-6.4373e-06,14572:0.0864781,29144:-0.0683681,43716:0.00686151,58288:0.0244663,72861:0.0826328,87433:0.161979,102005:-0.00775641,116577:-0.000766933,131150:-0.0373623,145722:0.107413,160294:-0.0979702,174866:-0.0687343,189439:0.0562962,189440:0.0550144,206661:-4.94123e-05,223883:-0.124582,241105:0.00297815,258326:-0.0853969,275548:0.0959385,292770:-0.122934,309992:-0.169931,327213:0.0102833,344435:8.74996e-05,361657:0.0284031,378879:-0.0737392,378880:-0.0925991,393452:-0.00173205,408024:-0.135385,422596:-5.40614e-05,437168:0.000341713,451741:-0.0789272,466313:-0.0693447,480885:-0.110604,495457:0.0452488,510030:-0.0485927,524602:7.45058e-06,539174:-0.00305098,553746:0.0601414,568319:0.000984967]
    [TIMING ts=20260904-083052] higgs_audio_tts.generator.codec_decode_ms 236.0282
    [TIMING ts=20260904-083052] session.wall_ms 11022.0299
    family=higgs_audio_tts
    task=tts
    mode=offline
    audio_out=repro-voice-clone-tracked-english.wav
    metrics.wall_ms=11184.1
    metrics.audio_duration_ms=23680
    metrics.rtf=0.472302
    metrics.x_realtime=2.11729
    metrics.audio_duration_source=output
    metrics.sample_rate=24000
    metrics.channels=1
    

    Chinese:

    [TRACE ts=20260904-083149] runtime.model.family higgs_audio_tts
    [TRACE ts=20260904-083149] runtime.model.variant v3-4b
    [TRACE ts=20260904-083149] runtime.model.root C:\Users\Haujet\AppData\Local\Temp\audiocpp-gguf\96f0e1a202ea133a
    [TRACE ts=20260904-083149] runtime.model.discovered_config_count 4
    [TRACE ts=20260904-083149] runtime.model.discovered_weight_count 1
    [TRACE ts=20260904-083149] runtime.model.task_count 1
    [TRACE ts=20260904-083149] runtime.model.language_count 1
    [TRACE ts=20260904-083149] runtime.model.supports_speaker_reference 1
    [TRACE ts=20260904-083149] runtime.model.supports_style_condition 0
    [TRACE ts=20260904-083149] runtime.model.supports_timestamps 0
    ggml_cuda_init: found 1 CUDA devices (Total VRAM: 8150 MiB):
      Device 0: NVIDIA GeForce RTX 5050 Laptop GPU, compute capability 12.0, VMM: yes, VRAM: 8150 MiB
    load_backend: loaded CUDA backend from C:\Users\Haujet\Downloads\Compressed\audio.cpp\ggml-cuda.dll
    load_backend: loaded CPU backend from C:\Users\Haujet\Downloads\Compressed\audio.cpp\ggml-cpu-haswell.dll
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_audio.sample_rate 24000
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_audio.channels 1
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_audio.samples shape=[78720] size=78720 samples=[0:0,2018:0.0264282,4036:-0.0827026,6055:0.00189209,8073:-0.00524902,10091:-0.128418,12110:-0.0842896,14128:-0.014679,16147:-0.000854492,18165:-3.05176e-05,20183:0.000183105,22202:9.15527e-05,24220:0.000244141,26239:-0.0980835,26240:-0.0934448,28625:-0.0456543,31010:-0.0814209,33396:0.0996094,35781:0.285645,38166:0.019104,40552:-0.152588,42937:0.0716553,45322:0.000640869,47708:0,50093:-9.15527e-05,52479:0.00466919,52480:0.00372314,54498:-0.0488586,56516:-0.210205,58535:0.251221,60553:-0.0371704,62571:-0.0682373,64590:-0.0631104,66608:-0.00292969,68627:-0.0255127,70645:0.0284729,72663:-0.0834961,74682:0.0894775,76700:-0.0157166,78719:-3.05176e-05]
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_cache.capacity 1
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_cache.size 0
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_cache.hit 0
    [TIMING ts=20260904-083155] higgs_audio_tts.codec.encode.graph.build_ms 1.5309
    [TRACE ts=20260904-083155] higgs_audio_tts.codec.encode.input_frames 82
    [TRACE ts=20260904-083155] higgs_audio_tts.codec.encode.input_acoustic_24k shape=[78720] size=78720 samples=[0:0,2018:0.0264282,4036:-0.0827026,6055:0.00189209,8073:-0.00524902,10091:-0.128418,12110:-0.0842896,14128:-0.014679,16147:-0.000854492,18165:-3.05176e-05,20183:0.000183105,22202:9.15527e-05,24220:0.000244141,26239:-0.0980835,26240:-0.0934448,28625:-0.0456543,31010:-0.0814209,33396:0.0996094,35781:0.285645,38166:0.019104,40552:-0.152588,42937:0.0716553,45322:0.000640869,47708:0,50093:-9.15527e-05,52479:0.00466919,52480:0.00372314,54498:-0.0488586,56516:-0.210205,58535:0.251221,60553:-0.0371704,62571:-0.0682373,64590:-0.0631104,66608:-0.00292969,68627:-0.0255127,70645:0.0284729,72663:-0.0834961,74682:0.0894775,76700:-0.0157166,78719:-3.05176e-05]
    [TRACE ts=20260904-083155] higgs_audio_tts.codec.encode.input_semantic_16k shape=[52800] size=52800 samples=[0:0,1353:0,2707:-0.0410111,4061:0.02576,5415:-0.159204,6768:-0.00693847,8122:0.0594634,9476:0.0595001,10830:0.00142098,12183:-0.000202429,13537:-0.000156421,14891:0.000195622,16245:0.000350459,17599:0.0476778,17600:0.0328737,19199:-0.00682171,20799:0.0107592,22399:-0.262369,23999:0.0454947,25599:0.189531,27199:-0.156163,28799:0.0152566,30399:0.000931859,31999:-0.000259162,33599:-0.000231289,35199:0.00860786,35200:0.00976957,36553:-0.0143577,37907:-0.132778,39261:-0.23943,40615:0.0141809,41968:0.14718,43322:-0.0706537,44676:0.0143206,46030:0.0104373,47383:-0.0318875,48737:0.094269,50091:0.0146719,51445:-0.00157601,52799:0]
    [TIMING ts=20260904-083155] higgs_audio_tts.codec.encode_input_upload_ms 2.9209
    [TIMING ts=20260904-083155] higgs_audio_tts.codec.encode.graph.compute_ms 164.3764
    [TIMING ts=20260904-083155] higgs_audio_tts.codec.encode_output_read_ms 0.4633
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_codes.frames 82
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_codes.codebooks 8
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_codes.values shape=[82,8] size=656 samples=[0:244,16:679,33:243,50:227,66:858,83:882,100:508,116:508,133:920,150:417,166:417,183:981,200:321,217:603,218:69,237:606,257:774,277:641,297:618,317:850,336:672,356:629,376:87,396:283,416:916,436:130,437:94,453:259,470:72,487:212,504:131,520:684,537:351,554:482,571:487,587:170,604:78,621:153,638:409,655:438]
    [TIMING ts=20260904-083155] higgs_audio_tts.codec.encode_reference_ms 172.2406
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_audio.sample_rate 24000
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_audio.channels 1
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_audio.samples shape=[78720] size=78720 samples=[0:0,2018:0.0264282,4036:-0.0827026,6055:0.00189209,8073:-0.00524902,10091:-0.128418,12110:-0.0842896,14128:-0.014679,16147:-0.000854492,18165:-3.05176e-05,20183:0.000183105,22202:9.15527e-05,24220:0.000244141,26239:-0.0980835,26240:-0.0934448,28625:-0.0456543,31010:-0.0814209,33396:0.0996094,35781:0.285645,38166:0.019104,40552:-0.152588,42937:0.0716553,45322:0.000640869,47708:0,50093:-9.15527e-05,52479:0.00466919,52480:0.00372314,54498:-0.0488586,56516:-0.210205,58535:0.251221,60553:-0.0371704,62571:-0.0682373,64590:-0.0631104,66608:-0.00292969,68627:-0.0255127,70645:0.0284729,72663:-0.0834961,74682:0.0894775,76700:-0.0157166,78719:-3.05176e-05]
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_cache.capacity 1
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_cache.size 1
    [TRACE ts=20260904-083155] higgs_audio_tts.reference_cache.hit 1
    [TRACE ts=20260904-083155] higgs_audio_tts.text_chunk_size 1024
    [TRACE ts=20260904-083155] higgs_audio_tts.text_chunk_mode default
    [TRACE ts=20260904-083155] higgs_audio_tts.text_chunk_count 1
    [TRACE ts=20260904-083155] higgs_audio_tts.request.text 后又开始对佛道儒神的逐步理解,就差把日月神教的宗义也整出来了,却始终找不到答案,一个20岁的小伙子又有什么资历去在别人终其一生都悟不通一门的东西上找到答案,更何况还是大杂烩一起上。现在想起真是可笑。
    [TRACE ts=20260904-083155] higgs_audio_tts.request.reference_text 你好,我是千问,你今天过得好吗?
    [TRACE ts=20260904-083155] higgs_audio_tts.request.text_chars 293
    [TRACE ts=20260904-083155] higgs_audio_tts.request.reference_text_chars 48
    [TRACE ts=20260904-083155] higgs_audio_tts.request.max_tokens 2048
    [TRACE ts=20260904-083155] higgs_audio_tts.request.temperature 0.800000011920929
    [TRACE ts=20260904-083155] higgs_audio_tts.request.top_p 0.800000
    [TRACE ts=20260904-083155] higgs_audio_tts.request.top_k 30
    [TRACE ts=20260904-083155] higgs_audio_tts.request.repetition_penalty 1.100000023841858
    [TRACE ts=20260904-083155] higgs_audio_tts.request.has_seed 1
    [TRACE ts=20260904-083155] higgs_audio_tts.request.seed 429
    [TRACE ts=20260904-083155] higgs_audio_tts.request.reference_codes shape=[82,8] size=656 samples=[0:244,16:679,33:243,50:227,66:858,83:882,100:508,116:508,133:920,150:417,166:417,183:981,200:321,217:603,218:69,237:606,257:774,277:641,297:618,317:850,336:672,356:629,376:87,396:283,416:916,436:130,437:94,453:259,470:72,487:212,504:131,520:684,537:351,554:482,571:487,587:170,604:78,621:153,638:409,655:438]
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.text_tokens 69
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.text_ids shape=[69] size=69 samples=[0:33447,1:99518,3:32664,5:44793,6:102907,8:9370,10:101128,11:3837,13:99572,15:8903,16:9754,18:99182,20:100401,22:74763,23:63431,25:3837,27:101217,29:102349,31:46944,33:15,35:113225,37:104139,39:81202,41:18493,43:99501,45:104478,46:71268,47:100579,49:109747,51:17447,52:101958,54:3837,56:99998,57:26288,59:120489,61:17447,62:1773,64:105545,66:30440,68:1773]
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.reference_text_tokens 11
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.reference_text_ids shape=[11] size=11 samples=[0:108386,1:3837,2:104198,3:99320,4:56007,5:3837,6:56568,7:100644,8:108178,9:110201,10:11319]
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.tokens 174
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.token_ids shape=[174] size=174 samples=[0:151667,4:104198,8:56568,13:151679,17:0,21:0,26:0,30:0,35:0,39:0,43:0,48:0,52:0,57:0,58:0,63:0,68:0,73:0,78:0,83:0,89:0,94:0,99:0,104:33447,109:44793,115:3837,116:80158,120:9754,124:100401,129:3837,133:102349,137:15,142:51125,146:101106,151:100579,155:17447,159:113210,164:100018,168:105545,173:151670]
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.delayed_reference_rows 89
    [TRACE ts=20260904-083155] higgs_audio_tts.prompt.delayed_reference_codes shape=[89,8] size=712 samples=[0:244,18:468,36:843,54:118,72:986,90:95,108:687,127:84,145:872,163:113,181:738,199:291,217:951,236:783,237:765,258:614,279:984,301:360,322:204,344:878,365:384,387:716,408:489,430:63,451:966,473:728,474:549,492:717,510:788,528:331,546:812,565:882,583:280,601:916,619:584,638:845,656:1025,674:1025,692:1025,711:438]
    [TRACE ts=20260904-083155] higgs_audio_tts.ar.prefill.text_tokens shape=[174] size=174 samples=[0:151667,4:104198,8:56568,13:151679,17:0,21:0,26:0,30:0,35:0,39:0,43:0,48:0,52:0,57:0,58:0,63:0,68:0,73:0,78:0,83:0,89:0,94:0,99:0,104:33447,109:44793,115:3837,116:80158,120:9754,124:100401,129:3837,133:102349,137:15,142:51125,146:101106,151:100579,155:17447,159:113210,164:100018,168:105545,173:151670]
    [TRACE ts=20260904-083155] higgs_audio_tts.ar.prefill.fused_code_ids shape=[174,8] size=1392 samples=[0:0,35:0,71:0,106:0,142:7180,178:2279,213:5234,249:1415,284:4766,320:59,356:4928,391:8166,427:3133,463:7734,464:885,506:2155,548:4292,590:6839,632:684,674:2652,716:4569,758:6715,800:1025,842:0,884:0,927:0,928:0,963:0,999:0,1034:0,1070:0,1106:0,1141:0,1177:0,1212:0,1248:0,1284:0,1319:0,1355:0,1391:0]
    [TRACE ts=20260904-083155] higgs_audio_tts.ar.prefill.text_gate shape=[174] size=174 samples=[0:1,4:1,8:1,13:1,17:0,21:0,26:0,30:0,35:0,39:0,43:0,48:0,52:0,57:0,58:0,63:0,68:0,73:0,78:0,83:0,89:0,94:0,99:0,104:1,109:1,115:1,116:1,120:1,124:1,129:1,133:1,137:1,142:1,146:1,151:1,155:1,159:1,164:1,168:1,173:1]
    [TRACE ts=20260904-083155] higgs_audio_tts.ar.prefill.code_gate shape=[174] size=174 samples=[0:0,4:0,8:0,13:0,17:1,21:1,26:1,30:1,35:1,39:1,43:1,48:1,52:1,57:1,58:1,63:1,68:1,73:1,78:1,83:1,89:1,94:1,99:1,104:0,109:0,115:0,116:0,120:0,124:0,129:0,133:0,137:0,142:0,146:0,151:0,155:0,159:0,164:0,168:0,173:0]
    [TRACE ts=20260904-083155] higgs_audio_tts.generator.reference_prefix_cache_hit 1
    [TRACE ts=20260904-083155] higgs_audio_tts.generator.reference_prefix_steps 103
    [TRACE ts=20260904-083156] higgs_audio_tts.generator.reference_kv_cache_hit 0
    [TRACE ts=20260904-083156] higgs_audio_tts.generator.prefill_start_step 0
    [TRACE ts=20260904-083156] higgs_audio_tts.generator.prefill_run_steps 174
    [TRACE ts=20260904-083156] higgs_audio_tts.generator.kv_cache_steps 512
    [TRACE ts=20260904-083156] higgs_audio_tts.generator.kv_cache_rebuild 1
    [TIMING ts=20260904-083156] higgs_audio_tts.ar.prefill.graph.build_ms 2.818
    [TIMING ts=20260904-083156] higgs_audio_tts.ar.decode.graph.build_ms 0.7548
    [TIMING ts=20260904-083156] higgs_audio_tts.generator.prefill_ms 1024.4008
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.prefill_logits shape=[8,1026] size=8208 samples=[0:44.2004,210:40.5257,420:46.4267,631:46.3873,841:43.196,1051:52.2632,1262:54.0753,1472:52.5636,1683:50.0812,1893:51.5875,2103:63.5055,2314:67.5238,2524:65.8124,2735:62.9567,2736:63.2542,2984:64.6855,3233:87.9841,3481:90.1137,3730:87.3634,3979:87.532,4227:106.645,4476:106.83,4725:106.032,4973:107.574,5222:105.839,5471:102.377,5472:103.003,5682:103.88,5892:103.445,6103:100.603,6313:123.687,6523:126.612,6734:124.542,6944:125.582,7155:125.273,7365:98.5974,7575:98.7605,7786:96.8287,7996:98.3091,8207:-30.2978]
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.temperature 0.800000011920929
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.has_seed 1
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.seed 429
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.top_p 0.800000
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.top_k 30
    [TRACE ts=20260904-083156] higgs_audio_tts.sampler.first_output_codes shape=[8] size=8 samples=[0:489,1:1024,2:1024,3:1024,4:1024,5:1024,6:1024,7:1024]
    [TIMING ts=20260904-083156] higgs_audio_tts.ar.decode.step0.input_upload_ms 0.1245
    [TIMING ts=20260904-083156] higgs_audio_tts.ar.decode.step0.mask_upload_ms 0.0238
    [TIMING ts=20260904-083156] higgs_audio_tts.ar.decode.step0.graph.compute_ms 27.9388
    [TIMING ts=20260904-083156] higgs_audio_tts.ar.decode.step0.output_read_ms 0.0917
    [TIMING ts=20260904-083156] higgs_audio_tts.generator.decode.step0.ar_ms 28.5255
    [TIMING ts=20260904-083156] higgs_audio_tts.generator.decode.step0.sampler_ms 0.0961
    ggml_backend_cuda_graph_compute: CUDA graph warmup complete
    [TRACE ts=20260904-083202] higgs_audio_tts.generator.kv_cache_grown_steps 1024
    [TIMING ts=20260904-083202] higgs_audio_tts.ar.decode.graph.build_ms 0.8511
    ggml_backend_cuda_graph_compute: CUDA graph warmup complete
    [TIMING ts=20260904-083206] higgs_audio_tts.ar.decode.steps 582
    [TIMING ts=20260904-083206] higgs_audio_tts.ar.decode.input_upload_ms 74.16819999999997
    [TIMING ts=20260904-083206] higgs_audio_tts.ar.decode.mask_upload_ms 24.633600000000012
    [TIMING ts=20260904-083206] higgs_audio_tts.ar.decode.graph.compute_ms 8726.736700000005
    [TIMING ts=20260904-083206] higgs_audio_tts.ar.decode.output_read_ms 54.96820000000002
    [TIMING ts=20260904-083206] higgs_audio_tts.generator.decode.sampler_ms 60.94299999999994
    [TIMING ts=20260904-083206] higgs_audio_tts.generator.decode_ms 9416.2439
    [TRACE ts=20260904-083206] higgs_audio_tts.generator.delayed_codes shape=[583,8] size=4664 samples=[0:489,119:787,238:117,358:546,477:182,597:633,716:22,836:849,955:257,1075:149,1194:983,1314:753,1433:174,1553:697,1554:931,1695:334,1836:281,1977:184,2119:232,2260:656,2401:886,2542:610,2684:347,2825:495,2966:152,3108:280,3109:746,3228:721,3348:788,3467:337,3587:647,3706:563,3826:848,3945:508,4065:74,4184:534,4304:99,4423:447,4543:81,4663:544]
    [TRACE ts=20260904-083206] higgs_audio_tts.generator.delayed_codes_head8 shape=[8,8] size=64 samples=[0:489,1:1024,3:1024,4:1024,6:1024,7:1024,9:1004,10:1024,12:1024,13:1024,15:1024,16:693,18:861,20:1024,21:1024,22:1024,24:118,26:688,28:1024,30:1024,31:1024,33:860,35:799,37:1024,39:1024,41:402,42:585,43:919,45:617,46:1024,48:9,50:554,51:1005,53:552,54:926,56:945,58:452,59:344,61:785,63:708]
    [TRACE ts=20260904-083206] higgs_audio_tts.generator.raw_codes_for_codec shape=[576,8] size=4608 samples=[0:489,118:808,236:147,354:681,472:314,590:619,708:207,826:124,944:889,1062:536,1180:340,1298:753,1416:344,1535:177,1536:525,1675:880,1815:161,1954:205,2094:740,2233:704,2373:65,2512:1012,2652:347,2791:287,2931:788,3071:380,3072:878,3190:428,3308:618,3426:753,3544:577,3662:503,3780:307,3898:256,4016:321,4134:458,4252:435,4370:65,4488:782,4607:544]
    [TRACE ts=20260904-083206] higgs_audio_tts.codec.decode.input_frames 576
    [TRACE ts=20260904-083206] higgs_audio_tts.codec.decode.input_codebooks 8
    [TRACE ts=20260904-083206] higgs_audio_tts.codec.decode.input_codes shape=[576,8] size=4608 samples=[0:489,118:808,236:147,354:681,472:314,590:619,708:207,826:124,944:889,1062:536,1180:340,1298:753,1416:344,1535:177,1536:525,1675:880,1815:161,1954:205,2094:740,2233:704,2373:65,2512:1012,2652:347,2791:287,2931:788,3071:380,3072:878,3190:428,3308:618,3426:753,3544:577,3662:503,3780:307,3898:256,4016:321,4134:458,4252:435,4370:65,4488:782,4607:544]
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode.graph.build_ms 0.9729
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_input_upload_ms 2.8849
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode.graph.compute_ms 48.8245
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_output_read_ms 0.1773
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_input_upload_ms 0.0855
    ggml_backend_cuda_graph_compute: CUDA graph warmup complete
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode.graph.compute_ms 51.6756
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_output_read_ms 0.2247
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_input_upload_ms 0.1357
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode.graph.compute_ms 42.9747
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_output_read_ms 0.1954
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_input_upload_ms 0.1255
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode.graph.compute_ms 43.1825
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_output_read_ms 0.2706
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_input_upload_ms 0.1216
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode.graph.compute_ms 42.9754
    [TIMING ts=20260904-083206] higgs_audio_tts.codec.decode_output_read_ms 0.2077
    [TRACE ts=20260904-083206] higgs_audio_tts.codec.decode.output_audio shape=[552960] size=552960 samples=[0:-8.22544e-05,14178:-0.0922939,28356:0.147452,42535:-0.0157406,56713:-0.00920981,70891:-5.14984e-05,85070:-0.0153057,99248:0.138907,113427:-0.00995749,127605:-0.0236294,141783:0.133536,155962:0.000181019,170140:-0.0299007,184319:0.0743321,184320:0.0365818,201076:-4.90546e-05,217832:-0.160531,234588:-0.0721523,251345:0.0475987,268101:0.016898,284857:0.000427783,301613:-0.295663,318370:-0.0792934,335126:-0.00126094,351882:-0.00415534,368639:-0.0376675,368640:0.197257,382818:8.41022e-05,396996:0.0496128,411175:2.01464e-05,425353:-0.0649502,439531:0.00322419,453710:-0.0183346,467888:-0.0602505,482067:-6.59227e-05,496245:-0.0575344,510423:0.0223148,524602:6.91414e-06,538780:0.0307224,552959:-0.000158846]
    [TIMING ts=20260904-083206] higgs_audio_tts.generator.codec_decode_ms 237.8776
    [TIMING ts=20260904-083206] session.wall_ms 10683.87
    family=higgs_audio_tts
    task=tts
    mode=offline
    audio_out=repro-voice-clone-tracked-chinese.wav
    metrics.wall_ms=10858.6
    metrics.audio_duration_ms=23040
    metrics.rtf=0.471295
    metrics.x_realtime=2.12181
    metrics.audio_duration_source=output
    metrics.sample_rate=24000
    metrics.channels=1
    
  4. 0xShug0 commented on Sep 4, 2026

    @0xShug0
    Owner

    @HaujetZhao Could you check these wavs? Created based on your test cases. Maybe my speakers are bad, so I can’t really tell whether there’s noise...

    repro-voice-clone-tracked-english.wav
    repro-voice-clone-tracked-chinese.wav

  5. HaujetZhao commented on Sep 4, 2026

    @HaujetZhao
    Author

    I checked your wavs — the clicks are definitely there. On my headphones they are clearly audible:

    longform_test.wav very obvious at ~10s, right in the middle of the word "together", very obvious at ~25s, right in the middle of the word "cpp" , very obvious at ~36s, right in the middle of the word "convelutional"
    repro-voice-clone-tracked.wav very obvious at ~15s, right in the middle of the sustained vowel in "ten"
    repro-voice-clone-tracked-english.wav: most obvious at ~10s, right in the middle of the sustained vowel in "cross"
    repro-voice-clone-tracked-chinese.wav: very obvious at ~5s and ~10s, landing mid-syllable

    A suggestion for hearing it: Use headphones. The click is a short broadband discontinuity, and laptop may speakers mask it badly.

  6. 0xShug0 commented on Sep 4, 2026

    @0xShug0
    Owner

    Okay. I opened a PR for you to test. Let me know if it works. Also could you share the before vs after PR RTF changes?

  7. 0xShug0 commented on Sep 4, 2026

    @0xShug0
    Owner

    I'm too old to hear those noises ☹️

  8. HaujetZhao commented on Sep 4, 2026

    @HaujetZhao
    Author

    repro-voice-clone-tracked.wav very obvious at ~15s, right in the middle of the sustained vowel in "ten"

    The noise in "ten" sound is so bad, can you try to listen to it again?

    I can't test the pr today, maybe tomorrow would be ok.

  9. 0xShug0 commented on Sep 4, 2026

    @0xShug0
    Owner

    repro-voice-clone-tracked.wav very obvious at ~15s, right in the middle of the sustained vowel in "ten"

    The noise in "ten" sound is so bad, can you try to listen to it again?

    I can't test the pr today, maybe tomorrow would be ok.

    I have to be honest, I can’t really hear it :( But I trust your judgment. I’ll merge the PR once you confirm it.

  10. HaujetZhao commented on Sep 4, 2026

    @HaujetZhao
    Author

    Tested — the fix works. ✅

    Setup: I rebuilt from main with only the fix commit (038dac4) cherry-picked on top, so the A/B is clean (just the codec change, nothing else from the PR branch base). CUDA 13.3 backend, RTX 5050 Laptop, same seed (429), same voice-clone prompt.

    Listening check: generated both a Chinese and an English long-form sample (~21 s / ~25 s), which cross 3–4 decode seams (each at 5.12 s intervals). All the periodic clicks are gone. Comparing the waveforms old vs. new, the seam positions now join smoothly — no discontinuity visible or audible at 5.12 / 10.24 / 15.36 / 20.48 s.

    Image

    Although you may not hear the difference, you can clearly see the difference at the seams on the waveform diagram.

    repro-voice-clone-tracked-chinese.wav
    repro-voice-clone-tracked-chinese-pr436.wav

    RTF (before vs. after, 3 runs each):

    Sample before after Δ
    Chinese, 21.4 s 0.454 0.446 −1.8%
    English, 24.7 s 0.437 0.439 +0.5%

    Both deltas are within run-to-run noise, so there's no measurable end-to-end regression — as expected, since the codec decoder is <3% of total wall time and the wider window only costs ~1.4× on that small slice.

    One takeaway for chunked conv audio decoders in general: if you split decoding into windows, the left/right context buffers must be at least the decoder's receptive field per side (here ≈27 frames, so 32 is a comfortable margin) — otherwise the hard concat at seams produces exactly this kind of periodic click. For Higgs this is cheap because the codec is a small fraction of the pipeline. But when the decoder is the expensive part (e.g. Qwen3-TTS's audio decoder), re-decoding ~1.4× of overlap every window adds up. In that case the overlap can be eliminated entirely by carrying conv state explicitly across chunks: keep the last RF-frames of conv input as a ring buffer, feed [history | new_frames] through the conv chain, trim only the left side of the output, and hold back a few lookahead frames until the next chunk (flush with an is_last flag). Each frame then gets decoded exactly once — true streaming, zero redundant compute.

    I did exactly that for the Qwen3-TTS codec decoder in my Qwen3-TTS-GGUF project: the ONNX export wraps the decoder as a stateful step graph (inputs/outputs are the conv-history / latent-buffer / KV-cache states, see 13-Export-Decoder.py and DecoderPart3Upsample in qwen3_tts_gguf/export/codec_export.py). I'm only a Python guy so the wrapper itself probably isn't C++-ready as-is, but the state layout might be a useful reference if you ever want the stateful (Option B) route for Higgs.

    Good to merge from my side. Thanks for the quick turnaround!

  11. 0xShug0 commented on Sep 4, 2026

    @0xShug0
    Owner

    @HaujetZhao Thank you for the information!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions