MERTOptions
Options & Configuration · AiDotNet.Audio.Foundations
Configuration options for the MERT music understanding foundation model.
Inheritance: ModelOptions → MERTOptions
For Beginners
MERT is like HuBERT but specialized for music instead of speech. While HuBERT learns by predicting speech units, MERT learns by predicting musical features like pitch and harmony. This means it deeply understands music structure and can be used for tasks like genre classification, instrument detection, and music tagging.
How It Works
MERT (Li et al., 2024) is a self-supervised music understanding model that uses acoustic and musical tokenizers to learn rich music representations. Unlike speech-focused models, MERT incorporates music-specific knowledge through CQT-based teacher targets and codebook clustering, enabling strong performance on 14 music information retrieval tasks.
Constructors
| Constructor | Summary |
|---|---|
MERTOptions() |
Properties
| Property | Summary |
|---|---|
OnnxModelOptions OnnxOptions { get; set; } |
Gets or sets the ONNX runtime options. |
double DropoutRate { get; set; } |
Gets or sets the dropout rate. |
double LearningRate { get; set; } |
Gets or sets the learning rate. |
double MaskProbability { get; set; } |
Gets or sets the masking probability. |
int CQTBins { get; set; } |
Gets or sets the number of CQT bins for music teacher targets. |
int CodebookSize { get; set; } |
Gets or sets the codebook vocabulary size. |
int FeedForwardDim { get; set; } |
Gets or sets the feed-forward inner dimension. |
int HiddenDim { get; set; } |
Gets or sets the model hidden dimension. |
int MaskSpanLength { get; set; } |
Gets or sets the mask span length. |
int NumClusters { get; set; } |
Gets or sets the number of K-means clusters for target quantization. |
int NumCodebooks { get; set; } |
Gets or sets the number of RVQ codebooks for acoustic teacher. |
int NumHeads { get; set; } |
Gets or sets the number of attention heads. |
int NumLayers { get; set; } |
Gets or sets the number of transformer layers. |
int SampleRate { get; set; } |
Gets or sets the audio sample rate in Hz. |
int[] ConvChannels { get; set; } |
Gets or sets the convolutional feature extractor channels. |
string ModelPath { get; set; } |
Gets or sets the path to the ONNX model file. |
string Variant { get; set; } |
Gets or sets the model variant (“base” with 95M params or “large” with 330M). |