Compare two lines and say why they scored what they did.
The metric is a normalised edit distance over the interval sequence, weighted
against the same over the rhythmic profile. Intervals rather than pitches,
because the same tune in another key is the same tune; edit distance rather
than a step-by-step correlation, because a variant that adds a passing note or
drops one still has to line up with its model, and only an alignment-based
measure can do that. Substituting one interval for another costs by how far
apart they are rather than a flat step, so an answer that widens a third to a
fourth stays close to its model while one that replaces it with a leap does
not. The rhythm carries the smaller share: a melody is recognised mostly by
its pitch shape, but a figure in a wholly different rhythm is a different
figure.
Both lines are expected to be monophonic, as analyzeVoice expects a
voice to be. Notes struck together are read as one event, the highest of them
standing for it, so a chord is reduced to its top voice rather than read as a
line of its own.
Compare two lines and say why they scored what they did.
The metric is a normalised edit distance over the interval sequence, weighted against the same over the rhythmic profile. Intervals rather than pitches, because the same tune in another key is the same tune; edit distance rather than a step-by-step correlation, because a variant that adds a passing note or drops one still has to line up with its model, and only an alignment-based measure can do that. Substituting one interval for another costs by how far apart they are rather than a flat step, so an answer that widens a third to a fourth stays close to its model while one that replaces it with a leap does not. The rhythm carries the smaller share: a melody is recognised mostly by its pitch shape, but a figure in a wholly different rhythm is a different figure.
Both lines are expected to be monophonic, as analyzeVoice expects a voice to be. Notes struck together are read as one event, the highest of them standing for it, so a chord is reduced to its top voice rather than read as a line of its own.