From 2560f918592a8ee5d24b7d3fb2ac0bb7da35db1c Mon Sep 17 00:00:00 2001 From: Joshna-Medisetty Date: Thu, 1 Oct 2026 15:45:09 -0700 Subject: [PATCH] fix(ming): build ISTFT spectrogram in float32 (#7538) Signed-off-by: Joshna Medisetty Co-authored-by: Cursor --- vllm_omni/model_executor/models/common/ming/audio_dsp.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vllm_omni/model_executor/models/common/ming/audio_dsp.py b/vllm_omni/model_executor/models/common/ming/audio_dsp.py index d32415352..d94370bb8 100644 --- a/vllm_omni/model_executor/models/common/ming/audio_dsp.py +++ b/vllm_omni/model_executor/models/common/ming/audio_dsp.py @@ -219,7 +219,8 @@ class ISTFTHead(FourierHead): # phase = torch.atan2(y, x) # S = mag * torch.exp(phase * 1j) # better directly produce the complex value - S = mag * (x + 1j * y) + # float32 operands: bf16 promotes to bcomplex32, which torch.fft cannot handle + S = mag.float() * (x.float() + 1j * y.float()) audio, audio_buffer, window_buffer = self.istft( S, audio_buffer=audio_buffer, window_buffer=window_buffer, streaming=streaming, last_chunk=last_chunk )