FastSpeech<T>

Models & Types · AiDotNet.TextToSpeech.Classic

FastSpeech: non-autoregressive TTS with knowledge-distilled duration predictor for parallel generation.

Inheritance: NeuralNetworkBase<T> → TtsModelBase<T> → VarianceAdaptorTtsModelBase<T> → FastSpeech<T>

Implements: IAcousticModel<T>

For Beginners

/// FastSpeech: non-autoregressive TTS with knowledge-distilled duration predictor for parallel generation. . This model converts text input into speech audio output.

How It Works

References:

  • Paper: “FastSpeech: Fast, Robust and Controllable Text to Speech” (Ren et al., 2019)

Constructors

Constructor Summary
FastSpeech(NeuralNetworkArchitecture<T> architecture, FastSpeechOptions options, IGradientBasedOptimizer<T, Tensor<T>, Tensor<T>> optimizer)
FastSpeech(NeuralNetworkArchitecture<T> architecture, string modelPath, FastSpeechOptions options)

Properties

Property Summary
int FftSize { get; }
int HopSize { get; }
int MaxTextLength { get; }
int MelChannels { get; }

Methods

Method Summary
ModelMetadata<T> GetModelMetadata()
Tensor<T> TextToMel(string text) Generates a mel spectrogram from text (FastSpeech is an acoustic model; pair it with a vocoder).
void LoadConvertedWeights(string path) Copies {ConvertedParameterTensor} from source straight into a parameter vector.