Repository navigation
Add opt-in BF16 activation rounding for Qwen3 TTS - #1248
Merged
Merged
Conversation
0xShug0
force-pushed
the
fix/qwen3-tts-bf16-activations
branch
from
November 9, 2026 14:49
0a750b6 to
3750467
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
BF16 GGUF weight storage alone does not reproduce the original model’s BF16 activation arithmetic. On the Russian VoiceDesign fixture in #1244, the default path produces a female-sounding voice despite the requested male description.
Add
qwen3_tts.activation_type=f32|bf16, defaulting tof32. The opt-in BF16 path uses existing framework rounding and decoder policies for text projection, talker and code-predictor activations. No shared framework or kernel changes. Weight storage andperf_moderemain independent.To enable:
Validation
git diff --checkpassed.Performance cost
Both rows use flash attention and the same request. These are single-request measurements, not a controlled warmed benchmark; the generated audio lengths differ.
BF16 rounding increased RTF by approximately 72% in this comparison. It is a compatibility option, not a performance preset. It does not guarantee identical tokens or waveforms across PyTorch attention implementations or hardware.
Closes #1244.