Dataset Viewer
Auto-converted to Parquet Duplicate
Search is not available for this dataset
audio
audioduration (s)
23.5
2.63k
label
class label
6 classes
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
0baroque
End of preview. Expand in Data Studio

YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

🎹 SONATA (Augmented MAESTRO)

Symmetrically Orchestrated Notes and Audio for Transformer Architectures

License: CC BY-NC-SA 4.0 Audio Modality Symbolic Modality Dataset Balance Corpus Scale Python 3.9+

The Next-Generation Cross-Modal Benchmark for Classical Music Era Classification & Audio-Symbolic Transformers


🌟 Executive Pitch: The Next Big Thing in Music AI & Classification

For nearly a decade, Google Magenta’s MAESTRO (MIDI and Audio Edited for Synchronous TRacks and Organization) has stood as the undisputed gold standard for machine learning in expressive piano performance. Yet for macro-temporal semantic tasksβ€”most notably Musical Era Classificationβ€”MAESTRO suffers from an insidious architectural vulnerability: an extreme 65.3% Romantic monoculture.

When modern deep learning models (Convolutional Neural Networks, Variational Autoencoders, Audio Spectrogram Transformers, and Perceiver architectures) are trained on standard benchmarks, they do not learn the contrapuntal, harmonic, or morphological syntax of Western art music. Instead, they collapse into a trivial majority heuristic, overwhelmed by the loss gradients of Chopin, Liszt, and Rachmaninoff, while starving minority eras (Impressionism at 2.8% and Modernism at 2.8%).

πŸš€ Enter SONATA (Augmented MAESTRO)

SONATA breaks the archive crisis. By fusing Google Magenta MAESTRO v3.0.0, the ASAP Dataset (ISMIR 2020), the ADL Piano MIDI Dataset (ISMIR 2019), and curated master archives from the Classical MIDI Archive, SONATA establishes the first mathematically symmetrical, acoustic-grounded, multi-modal classical era benchmark in MIR history.

           [ BASELINE MAESTRO v3.0.0 ]                    [ SONATA (Augmented MAESTRO) ]
             Severe 65.3% Romantic Skew                     Perfect 16.67% Class Symmetry
 
    Romantic      β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  65.3%      Baroque       β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  200 (16.67%)
    Classical     β–ˆβ–ˆβ–ˆβ–ˆ                  14.6%      Classical     β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  200 (16.67%)
    Baroque       β–ˆβ–ˆβ–ˆβ–ˆ                  12.4%      Romantic      β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  200 (16.67%)
    Late Romantic β–ˆ                      4.3%      Late Romantic β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  200 (16.67%)
    Impressionist ▏                      2.8%      Impressionist β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  200 (16.67%)
    Modern        ▏                      2.8%      Modern        β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  200 (16.67%)
                  (Gini Skew = 0.58)                               (Gini Skew = 0.00)

πŸ’Ž The Four Pillars of Dataset Fusion

SONATA unites the world's most rigorous symbolic transcriptions and concert captures into one cohesive, studio-grade standard:

  1. Google Magenta MAESTRO (v3.0.0):
    • High-resolution Disklavier concert recordings from the Minnesota International Piano-e-Competition.
    • Provides all baseline acoustic ground truth and stratified anchor pieces for Classical and Romantic epochs.
  2. ASAP Dataset (Accelerate, Score, Alignment, and Piano - ISMIR 2020):
    • Synchronized score-to-performance Disklavier human captures (e.g., Prokofiev Toccata, Op. 11), contributing authentic human micro-timing and polyphonic dynamics.
  3. ADL Piano MIDI Dataset (ISMIR 2019):
    • Curated classical pedagogical corpus with vetted tempo maps, polyphonic note matrices, and pristine key signatures.
  4. Classical MIDI Master Archives (John Sankey, Steven Ritchie, Jeff Segor):
    • Scholarly sequenced realizations of Scarlatti, Debussy, Ravel, Satie, FaurΓ©, Scriabin, and BartΓ³k, meticulously cataloged to eliminate arrangement artifacts.

πŸ”¬ Symmetrical Distribution & Multi-Modal Scale

SONATA provides exact 1:1:1:1:1:1 mathematical parity across all six defining epochs of Western art music, completely neutralizing class imbalance gradient bias.

Musical Era Total Tracks Total WAVs Total MIDIs Audio Duration Discrete Note Events Mean RMS Energy Train (80%) Val (10%) Test (10%)
Baroque 200 200 200 14.82 hrs 521,409 0.0612 160 20 20
Classical 200 200 200 26.14 hrs 874,130 0.0594 160 20 20
Romantic 200 200 200 25.48 hrs 912,845 0.0681 160 20 20
Late Romantic 200 200 200 23.95 hrs 789,612 0.0645 160 20 20
Impressionist 200 200 200 20.73 hrs 641,208 0.0583 160 20 20
Modern 200 200 200 22.18 hrs 733,108 0.0710 160 20 20
TOTALS 1,200 1,200 1,200 133.30 hrs 4,472,312 0.0642 960 120 120

πŸ› οΈ The 3-Stage Acoustic & Symbolic Quality Engine

Every single track in SONATA passed through an exhaustive, multi-gate physics and mastering pipeline before inclusion:

[ Raw MIDI Stream ]
        β”‚
        β–Ό
[ Gate 1: SMF Parser & Channel 10 Kill-Switch ] ──► (Drops percussion, sysex, running status errors)
        β”‚
        β–Ό
[ Gate 2: "Clever Hans" Timbral Impostor Purge ] ──► (Purges guitar [Prog 24], strings, flute, choir)
        β”‚
        β–Ό
[ Gate 3: SoundFont 2.04 Velocity Cross-Fading ] ──► (4-zone multisampling, resonant biquad filtering)
        β”‚
        β–Ό
[ Gate 4: Damper Tail Decay Modeling (+0.5s) ] ──► (A(t) = Aβ‚€ e^(-Ξ³t) cos(Ο‰t); avoids Gibbs step artifacts)
        β”‚
        β–Ό
[ Gate 5: Polyphase Resampling & Mastering ] ────► (Standardized 44.1 kHz, 16-bit PCM, 0.95 peak ceiling)
        β”‚
        β–Ό
[ Gate 6: Deep Verification & Synchronization ] ──► (0 missing, 0 silent, 0 dupes, |Ξ”t| < 3.5s)

Why Standard Augmentation Fails (And Why SONATA Solves It)

  • Pitch Shifting: Shifting an Impressionist piece (e.g., Debussy's Voiles, built on a C-whole-tone hexatonic collection) by $\pm 2$ semitones preserves the interval vector $[0,2,4,6,8,10]$, but completely destroys canonical key-color associations and fundamental formant registers.
  • Time Stretching: Compressing or dilating tempo alters note density and pulse rate, but cannot synthesize contrapuntal syntax, voice-leading rules, or cadence morphology.
  • SONATA's Solution: True, compositional supplemental ingestion of authentic historical scores, rendered through physical grand piano acoustics.

πŸ“‚ Repository & Dataset Layout

SONATA (Augmented MAESTRO)/
β”œβ”€β”€ audio/
β”‚   β”œβ”€β”€ baroque/                 # 200 .wav files (44.1 kHz, 16-bit stereo PCM)
β”‚   β”œβ”€β”€ classical/               # 200 .wav files
β”‚   β”œβ”€β”€ romantic/                # 200 .wav files
β”‚   β”œβ”€β”€ late_romantic/           # 200 .wav files
β”‚   β”œβ”€β”€ impressionist/           # 200 .wav files
β”‚   └── modern/                  # 200 .wav files
β”œβ”€β”€ midi/
β”‚   β”œβ”€β”€ baroque/                 # 200 .midi files (General MIDI Type 0/1)
β”‚   β”œβ”€β”€ classical/               # 200 .midi files
β”‚   β”œβ”€β”€ romantic/                # 200 .midi files
β”‚   β”œβ”€β”€ late_romantic/           # 200 .midi files
β”‚   β”œβ”€β”€ impressionist/           # 200 .midi files
β”‚   └── modern/                  # 200 .midi files
β”œβ”€β”€ sonata_dataset.csv           # Master Manifest (MAESTRO v3.0.0 compatible schema)
β”œβ”€β”€ SONATA_Dataset_Report.pdf    # 5-Page Formal Publication Report
└── README.md

Master Manifest Schema (sonata_dataset.csv)

Column Type Description
canonical_composer string Normalized composer name (e.g., Claude Debussy, Domenico Scarlatti)
canonical_title string Official movement / work catalog designation
split string Partition designation: train (80%), validation (10%), test (10%)
year int Performance capture or catalog year
midi_filename string Relative path to symbolic MIDI file (midi/<era>/<file>.midi)
audio_filename string Relative path to master acoustic WAV (audio/<era>/<file>.wav)
duration float Exact audio playback duration in seconds
era string Class label (baroque, classical, romantic, late_romantic, impressionist, modern)

⚑ Quickstart: Loading SONATA with PyTorch

After downloading the archive and extracting it, you should have a folder structure like this:

SONATA/
β”œβ”€β”€ audio/
β”œβ”€β”€ midi/
β”œβ”€β”€ balanced_dataset.csv
β”œβ”€β”€ sonata_dataset.csv
β”œβ”€β”€ README.md
└── SONATA_Dataset_Report.pdf

The key point is that the dataset is meant to be used from the extracted root directory named SONATA. Do not assume the files are placed directly in your current working directory.

1. Dual-Stream Multi-Modal PyTorch Dataset

import torch
from torch.utils.data import Dataset, DataLoader
import torchaudio
import pretty_midi
import pandas as pd
from pathlib import Path

class SonataDataset(Dataset):
    def __init__(self, root_dir, split="train", sample_rate=44100, n_mels=128):
        self.root_dir = Path(root_dir)
        df = pd.read_csv(self.root_dir / "sonata_dataset.csv")
        self.df = df[df["split"] == split].reset_index(drop=True)
        self.sample_rate = sample_rate

        self.mel_spectrogram = torchaudio.transforms.MelSpectrogram(
            sample_rate=sample_rate,
            n_fft=2048,
            hop_length=512,
            n_mels=n_mels,
        )

        self.era_to_idx = {
            "baroque": 0,
            "classical": 1,
            "romantic": 2,
            "late_romantic": 3,
            "impressionist": 4,
            "modern": 5,
        }

    def __len__(self):
        return len(self.df)

    def __getitem__(self, idx):
        row = self.df.iloc[idx]

        wav_path = self.root_dir / row["audio_filename"]
        waveform, _ = torchaudio.load(wav_path)
        if waveform.shape[0] > 1:
            waveform = torch.mean(waveform, dim=0, keepdim=True)
        mel_spec = torch.log(self.mel_spectrogram(waveform) + 1e-6)

        midi_path = self.root_dir / row["midi_filename"]
        pm = pretty_midi.PrettyMIDI(str(midi_path))
        piano_roll = torch.from_numpy(pm.get_piano_roll(fs=50)).float()

        label = torch.tensor(self.era_to_idx[row["era"]], dtype=torch.long)

        return {
            "mel_spectrogram": mel_spec,
            "piano_roll": piano_roll,
            "label": label,
            "composer": row["canonical_composer"],
            "title": row["canonical_title"],
        }

# Example usage after extracting SONATA.zip
root_dir = Path("SONATA")
dataset = SonataDataset(root_dir=root_dir, split="train")
loader = DataLoader(dataset, batch_size=16, shuffle=True)
print(f"Loaded {len(dataset)} training tracks across 6 balanced eras.")

If the archive is extracted somewhere else, just replace Path("SONATA") with the full extracted folder path, such as Path("C:/Users/you/Downloads/SONATA").

2. Minimal CSV loading check

import pandas as pd
from pathlib import Path

root_dir = Path("SONATA")
df = pd.read_csv(root_dir / "sonata_dataset.csv")
print(df.head())
print(df["era"].value_counts().sort_index())

This ensures the extracted zip is valid and that the manifest file points to real audio/... and midi/... paths that exist inside the same folder.


πŸ“Š Scientific Verification & Benchmark Audit

The deep automated auditor evaluated all 1,200 tracks and 2,400 physical files against strict publication criteria:

Verification Metric Target Threshold Measured Result Audit Status
Physical File Completeness 0 missing files 0 missing (2,400 / 2,400 files present) PASSED βœ…
Audio Format Compliance 44.1 kHz, 16-bit stereo PCM 1,200 / 1,200 exact match PASSED βœ…
Silence Detection Peak $\ge 0.05$, RMS $\ge 0.003$ 0 silent tracks (Min peak: 0.125, Mean: 0.863) PASSED βœ…
Audio-MIDI Duration Sync $ \Delta t < 3.5\text{ s}$
Duplicate Paths / Hashes 0 duplicates 0 duplicates found PASSED βœ…
Class Distribution Skew Exactly 200 per class 200 / 200 / 200 / 200 / 200 / 200 PASSED βœ…
Split Symmetry Exactly 160 / 20 / 20 per era 160 train / 20 val / 20 test per era PASSED βœ…

πŸ“œ Citation & Attribution

If you use SONATA (Augmented MAESTRO) in your research, thesis, or commercial models, please cite:

@dataset{sonata_augmented_maestro_2026,
  title     = {SONATA (Augmented MAESTRO): A Hybrid CNN–Transformer–VAE Framework for Classical Music Era Classification},
  author    = {Aryan Rahman Mugdha and Saadman Bin Jashim},
  year      = {2026},
  publisher = {GitHub},
  note      = {A balanced multimodal classical music dataset combining MAESTRO, ASAP, ADL Piano MIDI, and the Classical MIDI Archive}
}

Underlying Datasets & Foundational Citations

  • MAESTRO: Hawthorne et al., "Enabling Factorized Piano Music Modeling and Generation with the MAESTRO Dataset", ICLR 2019.
  • ASAP Dataset: Foscarin et al., "ASAP: a dataset of aligned scores and piano performances", ISMIR 2020.
  • ADL Piano Dataset: Ferreira et al., "Learning to Generate Music with Sentiment", ISMIR 2019.
  • Class Imbalance in Deep Learning: Johnson & Khoshgoftaar, "Survey on deep learning with class imbalance", Journal of Big Data 2019.

Built with scientific rigor for the next generation of Music AI.
Downloads last month
48