Datasets:
Confirm access to Gangqinpu v1.0.0
Read the CC BY-NC-SA 4.0 license and check both confirmations. Access is granted automatically after confirmation.
These confirmations acknowledge the existing license terms and do not grant rights in underlying third-party works.
Log in or Sign Up to review the conditions and access this dataset content.
Gangqinpu v1.0.0
18,786 piano score–performance pairs, covering 1,007.1 hours of source audio, with automatically transcribed performance MIDI, score MIDI, note-level alignments, and beat/downbeat annotations.
The code is open source; the dataset and classifier weights are released under CC BY-NC-SA 4.0 for non-commercial use.
- Paper: arXiv:2610.34694.
- Dataset: Hugging Face.
- Code: GitHub.
Tasks include performance-to-score transcription, note alignment, beat/downbeat tracking and expressive-performance analysis. Source audio, original CCMZ/MusicXML scores and (n)ASAP files are not included; source URLs and reference paths are provided.
Load with Hugging Face Datasets
Accept the license and confirm non-commercial use on the dataset page, then install and sign in:
python -m pip install "datasets==4.4.1"
hf auth login
Load the default configuration:
from datasets import load_dataset
dataset = load_dataset("Wayne42/gangqinpu", token=True)
sample = dataset["train"][0]
To stream the test split:
test = load_dataset(
"Wayne42/gangqinpu", split="test", streaming=True, token=True
)
test_sample = next(iter(test))
Original files (optional):
originals = load_dataset("Wayne42/gangqinpu", name="originals", token=True)
record = originals["train"][0]
midi_bytes = record["files"]["performance_refined.mid"]
originals preserves 11 files per sample with the default configuration’s splits. Join by sample_id.
External (n)ASAP reference metadata:
asap = load_dataset("Wayne42/gangqinpu", name="asap_reference", token=True)
For reproducible experiments, use the same revision commit SHA for all configuration loads.
Read local Parquet
Read the downloaded default shards:
from pathlib import Path
from datasets import load_dataset
root = Path("LOCAL_PARQUET_ROOT")
files = {
split: sorted(str(p) for p in (root / "data").glob(f"{split}-*.parquet"))
for split in ("train", "validation", "test")
}
local_data = load_dataset("parquet", data_files=files, streaming=True)
sample = next(iter(local_data["train"]))
Score time in quarter notes
Each score_notes item provides both seconds and musical time:
| Field | Unit | Meaning |
|---|---|---|
time |
seconds | Onset on the score-MIDI timeline. |
duration |
seconds | Duration on the score-MIDI timeline. |
onset_quarter |
quarter notes | Onset from the saved score-MIDI origin. |
duration_quarter |
quarter notes | Duration independent of the MIDI tempo. |
pitch |
MIDI integer | Note pitch. |
velocity |
MIDI integer | Score-MIDI velocity. |
Quarter-note units: quarter = 1.0, eighth = 0.5, sixteenth = 0.25, dotted quarter = 1.5. Values are MIDI ticks / ticks per quarter for unfolded, realized MIDI events. Source-note durations and grace labels are in notation.notes.
Example:
import numpy as np
notes = sample["score_notes"]
onsets = np.array([note["onset_quarter"] for note in notes])
# Match score positions in quarter notes to performance onsets in seconds.
a = sample["alignment"]
performance_indices = np.asarray(a["performance_note_indices"], dtype=int)
observed = (performance_indices >= 0) & ~np.asarray(a["interpolated_mask"], dtype=bool)
matched_score_quarters = onsets[observed]
matched_performance_seconds = np.array([
sample["performance_notes"][i]["time"]
for i in performance_indices[observed]
])
Alignment indices address the saved note order in either time unit. Apply alignment before sorting or filtering the lists.
Meter and key signatures
Each beats record includes the signatures active at that score position:
| Field | Type | Meaning |
|---|---|---|
time_signature |
string | Meter, such as 4/4 or 6/8. |
beats_per_bar |
integer | Beat count in the annotation convention: 4/4 has 4; 6/8 has 2 dotted-quarter beats. |
key_signature.fifths |
integer | Number of sharps (positive) or flats (negative); 0 means no sharps or flats. |
key_signature.major_tonic_pitch_class |
integer | Major-key tonic associated with the signature, C = 0 through B = 11; two flats give 10 (B-flat). |
time_signature_inferred marks inferred meters. To select the first annotated beat of each measure, including pickups:
measures = [
beat for i, beat in enumerate(sample["beats"])
if i == 0 or beat["measure"] != sample["beats"][i - 1]["measure"]
]
Explicit measure intervals are in notation.measures.
Optional export to original files
For tools that require MIDI/NPZ files on disk, install the code repository with pip install -e ".[hub]", then export the configurations loaded above:
from gangqinpu import GangqinpuDataset, export_original_files
# Export all splits; include the optional reference metadata for the full manifest.
export_original_files(originals, dataset, "gangqinpu", references=asap)
local = GangqinpuDataset("gangqinpu", split="train")
This restores gangqinpu_v1.0.0/<sample_id>/ and writes gangqinpu_meta_v1.0.0.csv. Use an output directory without an existing manifest; existing sample files must match the exported contents. Reference metadata does not download (n)ASAP files.
Structured notation
The default configuration has 31 columns. notation.version = 2 identifies the notation schema.
score_notes contains realized MIDI events. notation.notes contains source
pitched notes with ties merged and grace durations set to zero. Rest events, written note types, tie segments and engraving details are outside this schema.
notation field |
Meaning |
|---|---|
version |
Notation schema version, 2. |
source_sha256 |
SHA256 of the source XML used for extraction. |
midi_origin_offset_quarter |
Construction quarter position minus saved refined-MIDI quarter position. |
parts |
Part records {id, staff_count}; counts include declared staves and note/rest rows. |
notes |
Source-note records, defined below. |
measures |
Unfolded measure records, defined below. |
alignment_complete |
True when every performance note, including interpolated notes, has exactly one source-note link. |
issues |
Source/parsing diagnostics. |
Source-note fields
| Field | Meaning |
|---|---|
id |
Identifier for the unfolded note occurrence, scoped to the sample. |
part_index |
Zero-based index into notation.parts. |
pitch |
MIDI pitch integer. |
onset_quarter, duration_quarter |
Construction-score onset and tie-merged duration, in quarter notes. Grace duration is 0; unavailable duration is null. |
measure_index |
Zero-based index into notation.measures. |
staff |
Zero-based staff index within the part, or null. |
voice |
Local integer voice label within the piece/part, or null. |
is_grace |
Source grace-note flag. |
source_order |
Ordering rank stored for this release, including grace ordering; not an XML row number. |
performance_note_index |
Direct index into performance_notes, or null for an unresolved/unmatched link. |
Measure fields
| Field | Meaning |
|---|---|
part_index |
Zero-based index into notation.parts. |
onset_quarter, duration_quarter |
Start and length of the extracted construction-score measure interval. The first interval can include virtual pickup padding. |
time_signature |
Meter string, such as 4/4 or 6/8. |
time_signature_inferred |
Whether the meter was inferred during extraction. |
key_fifths |
Key-signature fifths, or null when unassigned. |
is_pickup |
Pickup-measure flag. |
Indices address lists in the same sample. measure_index indexes the measure table; beats.measure is an annotation label. Unknown values are null; zero is a valid staff, voice or key-signature value.
Note links
The two score views have separate link conventions:
| Link | Source list | Destination list | Missing value |
|---|---|---|---|
alignment.performance_note_indices[i] |
score_notes[i] |
performance_notes |
-1 |
notation.notes[i].performance_note_index |
notation.notes[i] |
performance_notes |
null |
For observed-only notation pairs, map interpolation status to performance-note indices:
a = sample["alignment"]
interpolated_by_performance = {
p: a["interpolated_mask"][i]
for i, p in enumerate(a["performance_note_indices"]) if p >= 0
}
observed = [
n for n in sample["notation"]["notes"]
if n["performance_note_index"] is not None
and not interpolated_by_performance[n["performance_note_index"]]
]
for note in observed[:3]:
performed = sample["performance_notes"][note["performance_note_index"]]
print(note["pitch"], note["staff"], note["onset_quarter"], performed["time"])
Pedal and time coordinates
performance_pedal stores track-0 CC64 events {time, value} from
performance_clean.mid, in performance/audio seconds. Values retain the MIDI
range 0–127; ≥64 means pedal down. An empty list means no recorded events. Pedal events remain separate from note durations.
| Data | Time representation |
|---|---|
| Performance-note onsets, pedal and beat timestamps | Performance/audio seconds |
performance_notes.duration |
Seconds |
score_notes.time, score_notes.duration |
Saved score-MIDI seconds |
score_notes.onset_quarter |
Saved score-MIDI quarter-note origin |
Notation onsets and beats.score_onset_quarter |
Construction-score quarter-note origin |
All duration_quarter fields |
Quarter-note lengths |
See Score-time origins for the quarter-position conversion.
Local extraction
See the code repository for notation extraction and packing all configurations. These tools require recovered local score.musicxml files.
Dataset structure
data/ 4 structured Parquet shards
originals/ 4 optional original-file Parquet shards
metadata/asap_*.parquet 3 external-reference metadata tables
gangqinpu_meta_v1.0.0.csv complete 25-column manifest
BUILD_INFO.json schema and source-revision provenance
build_report.json per-sample extraction diagnostics
validation.json integrity and loader-check summary
README.md, LICENSE, SHA256SUMS
| Configuration | Columns | Content |
|---|---|---|
gangqinpu (default) |
31 | 25 metadata fields plus performance_notes, score_notes, alignment, beats, notation, performance_pedal. |
originals |
5 | sample_id, source, split, sample_dir, and files (11 named binary contents). |
asap_reference |
25 | External (n)ASAP reference metadata, with 955/50/61 train/validation/test rows. |
The Hub layout includes all configurations. Read downloaded default shards with the Parquet example above. Both primary configurations have two training shards, one validation shard and one test shard. Hugging Face's split name validation corresponds to CSV value val. sample_id is a string. Missing metadata is represented as null in Parquet and an empty cell in CSV.
Structured fields
| Field | Structure and units |
|---|---|
performance_notes |
List of {time, duration, pitch, velocity} from track 0 of performance_refined.mid. Time and duration are performance/audio seconds; pitch and velocity are integers. Includes interpolated notes. |
score_notes |
List of {time, duration, pitch, velocity, onset_quarter, duration_quarter} from track 0 of score_refined.mid. time and duration are score-MIDI seconds; onset_quarter and duration_quarter are quarter-note units (see usage). Alignment indices refer to this list, not the multi-track construction file score_MS.mid. |
alignment |
The decoded arrays/scalars of performance_refined_align.npz, with the same names and indices described below. JSON diagnostics remain strings, as in the NPZ. |
beats |
Beat times, score positions, meter/key signatures, confidence and diagnostics; see Beat fields. |
notation |
Source parts, tie-merged notes, measures, direct performance links and extraction diagnostics; see Structured notation. |
performance_pedal |
List of {time, value} CC64 events in performance/audio seconds, with raw MIDI values 0–127. |
Original NPZ, MIDI, JSON and TSV files are in originals; parsed notation is in the default Parquet.
Beat fields
| Field | Type / unit | Meaning |
|---|---|---|
measure |
integer | Measure label from the unfolded score. |
beat_in_measure |
float | 1-based beat position; a pickup may start after beat 1. |
score_onset_quarter |
float / quarter notes | Construction-score position; see score-time origins. |
performance_time_sec, time_sec |
float / seconds | Performance/audio onset; the two fields are aliases. |
is_downbeat |
boolean | Metrical position 1, excluding initial pickups. |
is_pickup |
boolean | Beat belongs to a pickup measure. |
time_valid |
boolean | Timestamp is finite, within the source-audio duration, and outside any non-increasing adjacent pair. |
time_signature_inferred |
boolean | Meter was inferred from the measure span. |
method |
string | matched_anchor, interpolated_between_anchors, extrapolated or inside_alignment_hole. |
confidence |
float | Heuristic beat confidence. |
label |
string | db (downbeat), b (beat) or bR (low-confidence beat). |
time_signature, beats_per_bar, key_signature |
string / integer / struct | Active signatures, defined in Meter and key signatures. |
Time validity and confidence are separate. To select beats without flagged timestamp defects:
valid_beats = [beat for beat in sample["beats"] if beat["time_valid"]]
Metadata columns
gangqinpu_meta_v1.0.0.csv contains 19,852 rows: 18,786 Gangqinpu samples and 1,066 (n)ASAP references. It is comma-separated UTF-8 with BOM. Types below refer to Parquet; CSV cells are text. Paths are relative to the filesystem export root. Gangqinpu files are restored by export; (n)ASAP files require the upstream download.
ASAP reference rows. These refer to the (n)ASAP extension of ASAP, using the snapshot documented in ASAP reference data. Reference rows use source="asap"; their paths, durations and note counts describe external (n)ASAP files. (source, sample_id) identifies a row.
| Column | Type | Description |
|---|---|---|
sample_id |
string | Gangqinpu: the source website's numeric score ID, also the folder name. ASAP: a path-derived ID. |
source |
string | gangqinpu or asap ((n)ASAP reference data). |
split |
string | Fixed train / val / test assignment (see Splits). |
group_id |
string | Conservative joint split group (Gangqinpu + ASAP). All members share one split. Do not separate a group when making other partitions. |
score_group_id |
string | Gangqinpu score-similarity group: identical or highly similar scores, including transpositions. This is an operational grouping, not a verified composition identity. Empty for ASAP. |
title |
string | Title from the source metadata (Gangqinpu) or ASAP piece name. |
composer |
string | ASAP composer. Empty for Gangqinpu; composer attribution is not inferred from the uploader account. |
genre |
string | pop, classical, folk_traditional, jazz, rock, blues, other or unknown. Labels are automatic and weak. ASAP rows are classical by corpus scope. |
genre_source |
string | metadata_qwen_flash (LLM on metadata), audio_clap_heuristic (CLAP on audio, used when metadata was inconclusive), unknown, or dataset_scope_asap. |
audio_duration_seconds |
float (seconds) | Duration of the source recording, in seconds. |
duration_seconds |
float (seconds) | Offset of the last note of the performance MIDI, in seconds from MIDI time 0. |
note_count |
integer | Notes in performance_refined.mid, including interpolated notes. |
score_note_count |
integer | Notes in the score MIDI (score_MS.mid for Gangqinpu). |
score_bar_count |
integer | Measures in the piano part of the source score. |
annotation_beat_count |
integer | Length of performance_beats, including low-confidence beats. |
annotation_downbeat_count |
integer | Length of performance_downbeats, including low-confidence downbeats. |
sample_dir |
string | Folder relative to the export root. |
performance_midi_path |
string | performance_refined.mid, the recommended performance MIDI. |
score_midi_path |
string | Construction score score_MS.mid; the refined alignment instead indexes score_refined.mid. |
alignment_path |
string | Gangqinpu: performance_refined_align.npz. (n)ASAP: note-alignment TSV, a .match fallback, or empty when unavailable (see below). |
annotations_path |
string | alignment_metadata.json. |
metadata_path |
string | metadata.json. |
source_page_url |
string | Public score page on the source website. |
audio_url |
string | Source-audio URL recorded at collection time. |
score_ccmz_url |
string | Source-CCMZ URL recorded at collection time. |
Original files: originals[split][i]["files"]
Each originals record contains the following 11 named files as bytes. Optional export restores them under gangqinpu_v1.0.0/<sample_id>/. Processing order: audio_transkun.mid → performance_clean.mid → DualDTW alignment (performance_align.npz) → RAScoP refinement (*_refined*) → annotations.
| File | Content |
|---|---|
metadata.json |
Source metadata: score_id, title, author / author_id (the uploader account, not verified composer or performer attribution), detail_url, date_published. |
audio_transkun.mid |
Raw audio transcription by Transkun v2. |
performance_clean.mid |
Transcription merged to one track, with duplicate and very short notes removed and same-pitch overlaps cut. Keeps the performance time axis. |
score_MS.mid |
Score MIDI exported from the unfolded score (repeats expanded, grace notes and ornaments realised). It is in score time, not performance time. |
performance_align.npz |
Raw DualDTW note alignment between score_MS.mid and performance_clean.mid (see below). |
score_refined.mid |
Score MIDI after RAScoP refinement; refined alignment arrays index its track-0 notes. |
performance_refined.mid |
Performance MIDI after RAScoP refinement. Some notes are interpolated, not observed in the audio; see interpolated_mask. |
performance_refined_align.npz |
Refined score-to-performance note mapping (see below). |
alignment_metadata.json |
Beats/downbeats, signatures, alignment statistics, classifier output (see below). |
performance_annotations.txt |
ASAP-style beat/meter/key events in performance (audio) seconds. |
midi_score_annotations.txt |
Events in actual score_MS.mid seconds, using the same clock as midi_score_beats. |
performance_align.npz (raw alignment)
Indices are 0-based and refer to notes sorted by (onset, pitch, duration): score notes of the unfolded score table, and performance notes of performance_clean.mid. Raw score onsets use the construction score-table coordinate, including virtual pickup padding; this differs from the saved score-MIDI origin for 58 samples (see below).
| Array | Meaning |
|---|---|
matched_score_indices, matched_performance_indices |
Matched pairs, element-wise. |
deleted_score_indices |
Score notes without a performance match. |
inserted_performance_indices |
Performance notes without a score match. |
matched_score_pitches / _onsets, matched_performance_pitches / _onsets |
MIDI pitches (integers). Score onsets are in quarter notes; performance onsets are in seconds. |
deleted_score_pitches / _onsets, inserted_performance_pitches / _onsets |
Same for unmatched notes. |
The raw insertion rate (inserted / performance notes) and deletion rate (deleted / score notes) are both ≤ 10 % for every released sample.
performance_refined_align.npz (refined alignment)
The five per-score-note arrays below have length S = number of notes in score_refined.mid. Observed-pair arrays have length equal to the observed match count; RAScoP diagnostics are scalars or JSON strings.
| Array | Meaning |
|---|---|
performance_note_indices |
For each score note, the index of its note in performance_refined.mid, or -1 if unmatched. Filter out -1 before indexing. |
interpolated_mask |
True if the matched performance note was interpolated by RAScoP. |
refined_performance_onsets |
Performance onset (s) of the matched note, or -1. |
alignment_hole_mask |
Same as interpolated_mask in this release. |
score_note_source_indices |
Identity map to score_notes. |
real_matched_score_indices, real_matched_performance_indices |
Observed pairs indexing score_notes and performance_notes, respectively. |
rascop_recall, rascop_precision, rascop_metrics, rascop_stage_times |
RAScoP diagnostics; the last two are JSON strings. |
Sixteen samples retain unmatched refined score notes (-1). Note indices refer to track 0 of score_refined.mid / performance_refined.mid in the order produced by symusic. With other MIDI readers, verify the order against refined_performance_onsets and the pitches.
alignment_metadata.json
| Key(s) | Meaning |
|---|---|
performance_beats, performance_downbeats |
Beat/downbeat times in performance (audio) seconds. |
midi_score_beats, midi_score_downbeats |
Beat/downbeat times in the actual score_MS.mid seconds, using its tempo map and serialized origin. |
performance_beats_type, midi_score_beats_type |
Time (string) → label: db downbeat, b beat, bR ambiguous (low confidence). Equal timestamps collapse. |
performance_beat_details |
One record per score beat: measure, beat_in_measure, score_onset_quarter, performance_time_sec, is_downbeat, is_pickup, time_signature_inferred, method (matched_anchor, interpolated_between_anchors, extrapolated, inside_alignment_hole), confidence, label. |
onset_anchors |
Construction-score onset (quarters) → performance time and heuristic support counts/confidence. num_real_notes counts non-interpolated source-table rows, which can include unmatched rows; use the alignment arrays for strictly observed-note counts. |
perf_time_signatures, midi_score_time_signatures |
Time → [meter, beats per bar]. Compound x/8 meters count dotted-quarter beats. |
perf_key_signatures, midi_score_key_signatures |
Time → [major-key tonic pitch class, fifths]. |
downbeats_score_map |
Measure offset of each downbeat relative to the first score measure. |
raw_note_match_rate, refined_note_match_rate, performance_note_usage_rate |
Raw matches / score notes; observed refined matches / score notes; unique raw-matched performance notes / cleaned performance notes. |
num_alignment_holes, largest_alignment_hole_length, num_interpolated_notes |
Runs in the interpolation mask, their maximum length, and interpolated-note count; these do not enumerate all remaining unmatched score notes. |
num_low_confidence_beats, num_low_confidence_downbeats, num_inferred_time_signature_measures, num_tempo_jumps |
Diagnostics. |
whether_downbeats_are_monotonic, score_and_performance_aligned |
Pipeline consistency flags. |
num_score_notes, num_performance_notes, num_raw_performance_notes |
Note counts at the score-table, cleaned and raw transcription stages. |
raw_alignment_insertion_rate, raw_alignment_deletion_rate |
Filter 3 statistics. |
aligner_backend, rascop_* |
Alignment backend and RAScoP diagnostics. |
expressive_performance_classifier |
label (expressive), proba_expressive, the eight input features, match statistics and warnings. |
paths |
Published original-file identifiers relative to the optional export root. performance_midi points to the raw transcription; CSV performance_midi_path points to the refined output. |
A direct beat anchor uses matched notes within ±0.05 quarter notes. It receives confidence 0.95 if any supporting note is observed, otherwise 0.40; mixed sets contribute both observed and interpolated onset times. Beats without direct support interpolate between onset anchors (0.75 times the lower anchor confidence) or extrapolate (0.25). Onset-anchor confidence separately reflects observed/interpolated support. Alignment-hole beats are multiplied by 0.35. These are heuristic confidence scores.
Annotation TSV files
Tab-separated, without a header: start_seconds end_seconds label. Events are points, so start and end are equal. Labels:
b(beat),db(downbeat),bR(ambiguous beat);- a time signature such as
4/4or6/8; - an integer giving key-signature fifths.
Not every row is a beat, so filter on the labels. Downbeats are always written as db; check their confidence in the JSON.
Score-time origins
Notation and beat quarter positions use the construction-score origin; score_notes.onset_quarter uses the saved refined-MIDI origin. They differ for 58 samples. Convert construction positions with:
note = sample["notation"]["notes"][0]
onset_in_midi_origin = (
note["onset_quarter"] - sample["notation"]["midi_origin_offset_quarter"]
)
Quarter-note durations are unaffected. Score-second annotations and TSV use the saved score-MIDI clock.
Recovering source files
From the code repository:
python tools/download_sources.py --root gangqinpu --ids 1000009
Omit --ids for all samples. The tool uses audio_url and score_ccmz_url, saving audio to gangqinpu_audio/<id>/audio.<ext> and score.ccmz inside each exported sample folder. Convert CCMZ to score.musicxml with a tool such as ccmz-to-midi (GPL-3.0, not bundled). The original converter is not included; other converters may give different results. Links may change or disappear. Respect the source site's terms and request limits.
370 Gangqinpu rows share an audio URL with another row, each paired with a different score upload.
ASAP reference data
We use (n)ASAP, which extends ASAP with note-level score–performance alignments. The reference snapshot is v2.1.1, commit 4097b45757bed854818cf87e77b92323ebf90615. Its 1,066 metadata rows are represented in our manifest, with our joint train/val/test assignments of 955/50/61. The CSV identifier for these references is asap.
The reference MIDI, MusicXML, alignments and audio are not included in Gangqinpu. If using the optional filesystem export, run these commands from its parent directory to obtain the pinned reference files at the paths expected by the CSV:
git clone https://github.com/CPJKU/asap-dataset.git gangqinpu/asap
git -C gangqinpu/asap checkout 4097b45757bed854818cf87e77b92323ebf90615
Audio is recovered separately from MAESTRO v2.0.0 using the upstream initialization instructions. Not every reference performance has audio. Follow the upstream licenses and cite both ASAP and (n)ASAP.
Read the reference rows and their external file paths directly:
import csv
from pathlib import Path
root = Path("gangqinpu")
with (root / "gangqinpu_meta_v1.0.0.csv").open(encoding="utf-8-sig", newline="") as f:
references = [row for row in csv.DictReader(f) if row["source"] == "asap"]
row = next(row for row in references if row["alignment_path"].endswith(".tsv"))
performance_midi = root / row["performance_midi_path"]
score_midi = root / row["score_midi_path"]
with (root / row["alignment_path"]).open(encoding="utf-8-sig", newline="") as f:
note_alignment = list(csv.DictReader(f, delimiter="\t"))
Of the reference alignment_path entries, 1,035 point to TSV files, 28 fall back to .match files where the upstream TSV path is unavailable, and 3 are empty. TSV alignments link MusicXML note IDs to performance-note IDs; they are not Gangqinpu-style NPZ indices. For .match loading, score unfolding and ID-based alignment, follow the upstream usage examples. GangqinpuDataset selects Gangqinpu rows; use the CSV and upstream tools for (n)ASAP. Additional source-file locations, including MusicXML, are available in the upstream metadata.csv.
Splits and groups
| Source | train | val | test |
|---|---|---|---|
| Gangqinpu | 17,773 | 499 | 514 |
| (n)ASAP (reference rows) | 955 | 50 | 61 |
- Splits were assigned by group. Scores are grouped by symbolic similarity, including transpositions, arrangements and excerpts. Grouping was done jointly with ASAP, and related Gangqinpu and ASAP pieces always share a split.
- All groups containing ASAP test pieces of MIDI2ScoreTransformer are in
test. - One validation sample was removed because its audio was identical to a training sample's.
- The Gangqinpu held-out sets were approximately stratified by genre.
- Use the provided splits for comparable results. If you make new partitions, keep each
group_idtogether.
Statistics
| Statistic | Value |
|---|---|
| Score–performance pairs | 18,786 |
| Audio duration | 1,007.1 h (mean 3.22 min, median 3.04 min) |
Score-similarity groups (score_group_id) |
15,645, of which 2,445 have several performances |
Performance notes (performance_refined.mid) |
22,636,600 (median 956 per performance), 2.9 % interpolated |
| Source-notation notes | 22,795,998, including 110,995 grace notes |
| Source parts | 19,002 across 18,786 samples |
| Complete notation-to-performance link coverage | 18,580 samples |
| Sustain-pedal events | 2,529,922 |
Genres (genre) |
pop 8,353 · classical 3,064 · folk/traditional 748 · jazz 321 · rock 80 · blues 58 · other 1,651 · unknown 4,511 |
| Genre label source | metadata (Qwen-Flash) 10,795 · audio (CLAP) 3,480 · unknown 4,511 |
Creation
Pairs were collected from public gangqinpu.com pages. Audio duration ≥ 60 s, score length ≥ 32 measures, and piano-only sounding score parts (by part labels) were required. Transkun v2 transcribed the audio; Partitura/SyMuPe prepared scores; DualDTW and RAScoP aligned and refined notes. Pairs with raw insertion/deletion rates > 10% or expressive-classifier probability < 0.5 were removed. Score beats were transferred to performance time. Genres came from Qwen-Flash metadata classification, with LAION-CLAP audio fallback for unknown labels. Score similarity groups determined the partitions.
Musical annotations and genre labels are generated automatically. The construction code takes source audio and converted MusicXML; the original CCMZ converter is not included.
Data notes
- Automatic annotations: transcription, alignment and beat labels are generated automatically. Some notes are interpolated. Use
interpolated_mask, beatconfidenceandmethodwhen filtering. - Notation coverage: Source-note links are null in 206 multi-part samples; MIDI-level links are available in
alignment. - Missing notation labels: 55,498 voice labels, 4 note durations and 140,330 measure-key labels are unassigned (null); zero remains a valid label.
- Source diagnostics: 1,780 samples have extraction diagnostics: 1,699 contain zero-duration non-grace notes, 210 have notes outside an extracted measure, 57 have zero-length measures, and 1 has an unknown duration. These counts overlap.
- Beat timing: 1,639 samples have repeated or decreasing adjacent beat times; 6 have non-increasing downbeats; 3,120 have at least one beat outside the source-audio duration.
- Source coverage: most titles are in Chinese and pop is the largest genre. Source URLs may become unavailable.
License and removal requests
Author-created metadata, symbolic transcriptions, alignments, and annotations are distributed under CC BY-NC-SA 4.0, which permits non-commercial use subject to attribution and share-alike conditions. Reference rows derive from (n)ASAP, which extends ASAP, under the same license; cite both when using them. Code is open source under MIT, except the Apache-2.0 CLAP converter. Classifier weights are distributed in the code repository under CC BY-NC-SA 4.0; the dataset access-request process does not apply to those weights.
Underlying musical works, recordings, scores, arrangements, and source metadata remain subject to their rights holders' rights. The dataset license does not grant rights to those underlying works. Users must comply with applicable rights and source-site terms when recovering or using source files.
Rights holders may request removal through the contact below, identifying the sample IDs or source URLs.
Citation
@misc{gangqinpu2026,
title = {Gangqinpu: A Multi-Genre, Multi-Task Piano Dataset with Aligned Audio, {MIDI}, and Musical Scores},
author = {Zeng, Wei and Mathur, Anvay and Wang, Ye},
year = {2026},
eprint = {2610.34694},
archivePrefix = {arXiv},
primaryClass = {cs.SD},
url = {https://arxiv.org/abs/2610.34694}
}
For reference rows, also cite ASAP (Foscarin et al., ISMIR 2020) and (n)ASAP: Automatic Note-Level Score-to-Performance Alignments in the ASAP Dataset (Peter et al., TISMIR 2023).
Authors and contact
Wei Zeng, Anvay Mathur, and Ye Wang
Contact: w.zeng@u.nus.edu
- Downloads last month
- 37