Damper

The sustain pedal, in the MIDI

Most piano transcription gives you the notes and stops there. Without the pedal, a MIDI file of a romantic piece sounds like a piano with the lid slammed shut after every chord.

Why the pedal is the hard part

Pitch and timing are visible in the sound: a note is struck, the spectrum changes, you can find it. The pedal is not. Lifting the dampers does not make a sound of its own — it changes what happens to sounds already ringing. You cannot look for the pedal directly. You have to infer it from what stays alive and what dies.

This is why a MIDI file downloaded from most tools has a flat, clipped quality: every note ends when the finger leaves the key, which is not how anyone plays.

How Damper decides

The rule is deliberately strict, and it is a musical rule rather than a rhythmic one:

The pedal may only move where the harmony heard in the recording actually changes — and it is placed on a real note onset, never on an invented tick.

A five-model ensemble follows chord, quality, root and inversion through the audio. When the harmonic state genuinely changes, the exact moment is taken from a note that was really struck there. Both conditions must hold.

The reason for the second condition is a mistake that is easy to make and very audible. Take a left hand playing C2–E2–G2–C3 under one sustained C major chord. Four low notes, four plausible-looking moments to change the pedal — and a machine that trusts the bass line will pedal four times, chopping the harmony to pieces. Damper does not, because the harmony never changed: it is one chord, arpeggiated. A low note on its own is never allowed to move the pedal.

What comes out

ControllerCC64, the standard sustain controller every DAW understands
PlacementOn an exact note onset, with the small physical delay of a real re-pedal
End of fileThe pedal is always released — no file ends with the dampers stuck up
Note lengthsWritten to match: fingers release early, the pedal holds the sound

How well it does, honestly

The reference is ten pieces whose pedal was corrected by hand, note by note: 433 pedal events. Against that set Damper places roughly three changes out of four within a sixteenth of a beat.

That number deserves its context rather than a badge. It was measured on one specific body of material. A recording with heavy room reverb, a very different instrument, or a performance whose pedalling is unusual will do worse — reverb in particular blurs exactly the evidence the method depends on, because it makes sounds outlive their harmony.

So the pedal you get is a serious starting point, not a finished performance. Play the file, read the sustain lane, fix what you disagree with. That is far quicker than drawing it from nothing, which is the actual alternative.

Where it fails

Transcribe a recording