improve(model): compute WeSpeaker fbank features on MPS (#2087)

This commit is contained in:
Irakli Salia authored and GitHub committed 2026-11-07 14:29:23 +01:00
1 parent 755a98c23c
commit eec9b7d665
2 files changed
+2 -6

No files matched your search

+1
View File
@@ -5,6 +5,7 @@
- BREAKING(cli): remove gap-filling optimization (`--optimize`) and `OptimizedMinDurationOff` outputs from the `benchmark` command
- BREAKING: require Python 3.11 or newer; Python 3.10 is no longer supported
- fix(model): restore `fbank_only` mode in WeSpeaker embedding models
- improve(model): compute WeSpeaker fbank features on MPS instead of falling back to CPU [@Isalia20](https://github.com/Isalia20)
- fix(task): avoid training crashes with `spawn`/`forkserver` workers, including
Python 3.14's default on Linux, by warning and using `num_workers=0`
- fix(pipeline): fix `VBxClustering` crashing when more speakers are requested than there are embeddings to cluster [@MohammadHijjawi97](https://github.com/MohammadHijjawi97)
@@ -126,12 +126,7 @@ class BaseWeSpeakerResNet(Model):
waveforms = waveforms * (1 << 15)
# fall back to CPU for FFT computation when using MPS
# until FFT is fixed in MPS
device = waveforms.device
fft_device = torch.device("cpu") if device.type == "mps" else device
features = torch.vmap(self._fbank)(waveforms.to(fft_device)).to(device)
features = torch.vmap(self._fbank)(waveforms)
# center features with global average
if self.hparams.fbank_centering_span is None: