Anti-Aliasing for High-Frequency Neural TTS Vocoders
Neural vocoders frequently suffer from aliasing artifacts when generating high-frequency audio, leading to metallic distortion and degraded vocal fidelity. This article explores how anti-aliasing techniques eliminate frequency folding errors introduced during upsampling and non-linear activation steps, allowing neural Text-to-Speech (TTS) models to synthesize crisp, natural high-frequency sounds like fricatives and breath tones at high sample rates.
The Origin of Aliasing in Neural Vocoders
Neural vocoders, such as HiFi-GAN, WaveGlow, and BigVGAN, generate continuous-time audio waveforms from discrete linguistic or acoustic features (like mel-spectrograms). This transformation relies heavily on two operations: transposed convolutions for upsampling and non-linear activation functions (such as LeakyReLU, Snake, or SIREN).
Both operations inherently expand the spectral bandwidth of the intermediate feature maps:
- Transposed Convolutions (Upsampling): Expanding the sampling rate without adequate filtering introduces imaging artifacts, reflecting spectral copies above the original Nyquist frequency.
- Non-Linear Activations: Applying non-linear functions to an audio signal generates harmonic overtones. If these generated harmonics exceed the Nyquist frequency (half the sampling rate of the current layer), they reflect back across the Nyquist threshold into lower frequency bands, a phenomenon known as frequency folding.
In the final audio output, this folded energy manifests as harsh, metallic buzzes, phase incoherence, and muffled or robotic high-frequency sounds.
Anti-Aliasing Mechanisms in Neural Vocoders
To prevent spectral folding, modern neural vocoders incorporate digital signal processing (DSP) principles directly into their deep learning architectures. The primary techniques include:
1. Low-Pass Filtering in Upsampling
Traditional transposed convolution upsamples by interleaving zeros or applying unconstrained learned kernels, which often fail to completely suppress mirror spectra. Anti-aliasing replaces or augments these layers with polyphase resampling filters or integrated low-pass Finite Impulse Response (FIR) filters. These filters strictly attenuate energy above the target Nyquist cutoff, ensuring that only valid, non-redundant acoustic information is passed to subsequent layers.
2. Anti-Aliased Non-Linearities
Because activations generate harmonics that violate the Nyquist-Shannon sampling theorem, anti-aliased architectures filter the signal around the activation:
- Local Upsampling: The feature representation is temporarily upsampled to a higher intermediate sampling rate (creating headroom).
- Activation Application: The non-linear function is applied in this higher-resolution space, allowing generated harmonics to exist without exceeding the temporary Nyquist limit.
- Low-Pass Filtering and Downsampling: A steep FIR low-pass filter (often designed using Kaiser or sinc windows) suppresses frequencies that would fold over before downsampling the signal back to the working resolution.
3. Alias-Free Convolutions
Recent vocoder architectures, inspired by Alias-Free GAN concepts, introduce continuous representations to guarantee scale and translation equivariance. By ensuring that every layer limits its frequency response relative to the current feature resolution, high-frequency energy generated in deep layers cannot reflect into the audible human speech spectrum.
Impact on High-Frequency Audio Quality
Implementing anti-aliasing directly improves the perceptual quality and technical fidelity of synthesized speech in several key areas:
- Clear Fricatives and Sibilants: Unvoiced speech sounds—such as /s/, /sh/, /f/, and /th/—rely on broad, chaotic high-frequency noise bands ranging from 4 kHz up to 16 kHz. Anti-aliasing preserves the natural, airy distribution of this noise without turning it into harsh, tonal ringing.
- Elimination of "Phase Buzz": By preventing folded spectral copies from interfering with fundamental frequencies and low harmonics, the synthesized voice retains warm, clear tonal characteristics without a robotic overlay.
- Robust High-Resolution Synthesis: Anti-aliasing makes high-fidelity sampling rates (such as 44.1 kHz and 48 kHz) practical in neural vocoders, allowing out-of-distribution pitch ranges and wide dynamic variations to sound transparent and production-ready.