Pitch Contour Tokenization using VQ-VAE
and Its Application on Korean Traditional Music Analysis

Seonguk Ju1, Seola Cho1, Suin Chung1, Danbinaerin Han2, Dasaem Jeong1
1Sogang University, South Korea   2KAIST, South Korea
{jinin5113, dasaemj}@sogang.ac.kr
ISMIR 2026

Abstract

Computational analysis of music often relies on discrete representations, yet many musical traditions are organized around continuous pitch movement that resists segmentation into note-like units. For such traditions, the discrete units that analysis would build on are not given in advance. We address this gap by learning a vocabulary of local pitch-contour patterns directly from unlabeled audio, using a VQ-VAE that quantizes fixed-length contour segments into a finite codebook. To make the learned tokens stable across segmentation positions and small variations in timing and pitch range, we train the model with a reconstruction objective evaluated under the best alignment among a set of candidate temporal and pitch-domain transformations. Applied to Korean traditional music, the learned tokens recover information about expert-defined sigimsae categories without supervision, and in pansori individual tokens align with the two principal modes, Gyemyeonjo and Ujo, supporting their use as units for corpus-level analysis of contour-centric traditions.

Model Architecture

The model is a VQ-VAE over fixed-length pitch-contour segments. An encoder maps each segment to a latent vector, vector quantization assigns it to the nearest codebook entry, and a decoder reconstructs the contour from the selected entry, so that every segment is represented by a single discrete token. The reconstruction loss is evaluated under the best alignment among a set of candidate temporal and pitch-domain transformations of the decoded contour, and only the minimum error is backpropagated. This keeps the tokens stable across segmentation positions and robust to differences in key and tempo, so each token captures a local contour shape.

Architecture overview

Overview of the proposed model.

Quantitative Results

We evaluate the learned tokens from two perspectives. Token consistency measures how stable the tokenization is when the segmentation window is shifted: the agreement accuracy (Acc) between tokens of shifted segmentations and the KL divergence (KLD) between the resulting token distributions, for shift ranges of 0–60 and 0–124 frames. Downstream classification reports macro-F1 and mAP for expert-labeled sigimsae classification on the NIA dataset (all recordings and the vocal-only subset), predicting the category from the assigned token. ED-TCN, a supervised approach, is included as a reference.

Token Consistency

Method Acc ↑ KLD ↓
0–60 0–124 0–60 0–124
Autoencoder0.1000.1151.7472.085
VQ-VAE0.4620.4880.6570.859
+ temporal align0.5190.5610.5310.735
+ all transformations0.4560.4950.6520.881

Downstream Classification

Method \(F1_{macro}\) ↑ mAP ↑
NIA (all) NIA (vocal) NIA (all) NIA (vocal)
Autoencoder0.2840.3240.2650.290
VQ-VAE0.2660.3190.2480.302
+ temporal align0.2850.3200.2720.317
+ all transformations0.2850.3310.2780.324
ED-TCN (supervised) 0.4630.541 0.5790.531

Sigimsae Prototype Tokens: VQ-VAE vs. Autoencoder

For each expert-defined sigimsae (ornament) category, we show the decoded contour of the most representative token — the token with the highest \(P(\text{token}\mid\text{label})\) — for our VQ-VAE (with the transformation-minimized loss) and the autoencoder baseline, together with real audio excerpts of instances assigned to that token (original NIA recordings). The VQ-VAE recruits six distinct tokens matching each category's canonical realization, while the autoencoder collapses the six categories onto only three tokens.

VQ-VAE tokens and P values match the paper (Fig. 2) exactly. The autoencoder's UMAP+KMeans tokenization was re-fitted for this page, so its token IDs differ from the paper figure (196/16/190) while showing the same collapse behavior.

Category
VQ-VAE (+ all transformations)
Autoencoder baseline (re-fitted)

Southern-style descending flick

VQ-VAE Token 58

Token 58 · \(P(\text{token}\mid\text{S. desc. flick})=0.0196\)

AE Token 168

Token 168 · \(P(\text{token}\mid\text{S. desc. flick})=0.0243\)

Southern-style vibrato

VQ-VAE Token 180

Token 180 · \(P(\text{token}\mid\text{S. vibrato})=0.0361\)

AE Token 168

Token 168 · \(P(\text{token}\mid\text{S. vibrato})=0.0689\)

Western-style vibrato

VQ-VAE Token 135

Token 135 · \(P(\text{token}\mid\text{W. vibrato})=0.0671\)

AE Token 201

Token 201 · \(P(\text{token}\mid\text{W. vibrato})=0.0470\)

Soft vibrato

VQ-VAE Token 4

Token 4 · \(P(\text{token}\mid\text{Soft vibrato})=0.1321\)

AE Token 168

Token 168 · \(P(\text{token}\mid\text{Soft vibrato})=0.0305\)

Upward accent

VQ-VAE Token 243

Token 243 · \(P(\text{token}\mid\text{Upward accent})=0.0759\)

AE Token 178

Token 178 · \(P(\text{token}\mid\text{Upward accent})=0.0886\)

Descending slide

VQ-VAE Token 178

Token 178 · \(P(\text{token}\mid\text{Desc. slide})=0.0685\)

AE Token 178

Token 178 · \(P(\text{token}\mid\text{Desc. slide})=0.0281\)

Mode-Characteristic Tokens in Pansori

Tokens with the highest \(P(\text{mode}\mid\text{token})\) for the two principal pansori modes, Gyemyeonjo and Ujo. Each panel shows the decoded token contour (black) with median-subtracted original contours assigned to that token, a manually drawn staff-notation transcription of a representative occurrence, and real audio excerpts (vocal-separated) of instances assigned to the token.

Token 87 decoded contour

Token 87 · \(P(\text{Gyemyeonjo}\mid\text{token})=0.8376\) — upper-turn gesture

Token 87 staff notation

Staff-notation transcription

Real excerpt (separated vocals)

Pattern excerpt

Token 141 decoded contour

Token 141 · \(P(\text{Gyemyeonjo}\mid\text{token})=0.8292\) — downward gliding contour

Token 141 staff notation

Staff-notation transcription

Real excerpt (separated vocals)

Pattern excerpt

Token 54 decoded contour

Token 54 · \(P(\text{Ujo}\mid\text{token})=0.8126\) — descending major second with wide vibrato

Token 54 staff notation

Staff-notation transcription

Real excerpt (separated vocals)

Pattern excerpt

Token 171 decoded contour

Token 171 · \(P(\text{Ujo}\mid\text{token})=0.8146\) — melodic phrase frequent in Ujo

Token 171 staff notation

Staff-notation transcription

Real excerpt (separated vocals)

Pattern excerpt

More Mode-Characteristic Tokens

Additional tokens with high \(P(\text{mode}\mid\text{token})\), shown with the decoded token contour and real audio excerpts of assigned instances.

Token 148 decoded contour

Token 148 · \(P(\text{Gyemyeonjo}\mid\text{token})=0.8335\)

Token 122 decoded contour

Token 122 · \(P(\text{Gyemyeonjo}\mid\text{token})=0.8247\)

Token 143 decoded contour

Token 143 · \(P(\text{Gyemyeonjo}\mid\text{token})=0.8199\)

Token 240 decoded contour

Token 240 · \(P(\text{Ujo}\mid\text{token})=0.8460\)

Token 137 decoded contour

Token 137 · \(P(\text{Ujo}\mid\text{token})=0.7936\)

BibTeX

% TODO(camera-ready): replace with the final ISMIR 2026 BibTeX entry (page numbers, DOI)
@inproceedings{ju2026pitchcontour,
  title     = {Pitch Contour Tokenization using {VQ-VAE} and Its Application on Korean Traditional Music Analysis},
  author    = {Ju, Seonguk and Cho, Seola and Chung, Suin and Han, Danbinaerin and Jeong, Dasaem},
  booktitle = {Proceedings of the 27th International Society for Music Information Retrieval Conference (ISMIR)},
  year      = {2026}
}