Wav2Vec2ModelOptions
Options & Configuration · AiDotNet.Models.Options
Configuration options for Wav2Vec2 speech recognition models.
Inheritance: ModelOptions → NeuralNetworkOptions → ModelHyperparameterOptions → AudioNeuralNetworkOptions → Wav2Vec2ModelOptions
Constructors
| Constructor | Summary |
|---|---|
Wav2Vec2ModelOptions() |
Initializes a new instance of the Wav2Vec2ModelOptions class carrying this model’s shipped defaults. |
Properties
| Property | Summary |
|---|---|
bool FreezeFeatureEncoder { get; set; } |
Gets or sets whether fine-tuning leaves the convolutional feature encoder frozen (the paper: “the feature encoder is not trained during fine-tuning”). |
bool StableLayerNorm { get; set; } |
Gets or sets whether the feature encoder uses layer norm on every layer with pre-norm “stable layer norm” Transformer layers (wav2vec 2.0 LARGE-LV60) instead of group norm on the first layer with post-norm layers (BASE). |
double ActivationDropout { get; set; } |
Gets or sets the feed-forward activation dropout (0.1). |
double AttentionDropout { get; set; } |
Gets or sets the attention dropout (0.1). |
double FinalDropout { get; set; } |
Gets or sets the dropout before the CTC head (transformers’ final_dropout, 0.1). |
double HiddenDropout { get; set; } |
Gets or sets the encoder dropout (hidden_dropout, 0.1). |
double LayerDrop { get; set; } |
Gets or sets the probability of skipping a Transformer layer in training (LayerDrop, 0.1). |
double MaskTimeProbability { get; set; } |
Gets or sets the SpecAugment time-mask probability during fine-tuning (0.05). |
int FfDim { get; set; } |
Gets or sets the ff dim. |
int HiddenDim { get; set; } |
Gets or sets the hidden dim. |
int MaxAudioLengthSeconds { get; set; } |
Gets or sets the max audio length seconds. |
int NumHeads { get; set; } |
Gets or sets the num heads. |
int NumTransformerLayers { get; set; } |
Gets or sets the num transformer layers. |
int PositionalConvGroups { get; set; } |
Gets or sets the groups of the convolutional relative positional embedding (16, Baevski et al. |
int SampleRate { get; set; } |
Gets or sets the sample rate. |
string Language { get; set; } |
Gets or sets the language. |
Methods
| Method | Summary |
|---|---|
void Validate() |
Throws if a value this model requires has been left unset or is not positive. |