failed to parse triplets of 1/16 notes (L.G. #245)
- branch pybind
failed to parse triplets of 1/16 notes
on quantized file perf/245-44_78_bandlab0.midi
= MIDI export from MuseScore
with the following grammar ../grammars/schema-44.wta
attached: MEI output245-44_78_bandlab0.pdf
note: in the MEI, the first group in a measure is failed whereas the second is succefully transcripted as triplet. (see e.g. bars 1 and 2)
command line (in Lamarque-Goudard/245-Debussy-Arabesque2
):
../monoparse -v 5 -a ../grammars/schema-44.wta -m perf/245-44_78_bandlab0.midi -config ../params.ini -tempo 78 -ts 4/4 -max -staccato -o qparse/245-44_78_bandlab0.mei
grammar schema-44.wta
:
// penalty model
// WTA model for 4/4 measure
[penalty]
// bar level
0 -> C0 1
0 -> R 1 // whole rest
0 -> E1 1 // whole
0 -> E2 4 // grace-note + whole
0 -> E3 6 // 2 grace-notes + whole
0 -> U2(1, 1) 0.1 // duolet of halves, usual division 4/4
0 -> U3(1, 1, 1) 11 // triplet of halves
//0 -> U5(2, 2, 2, 2, 2) 20
// half bar level = half note
1 -> C0 1 // continuation
1 -> R 1 // half rest
1 -> E1 1 // half note
1 -> E2 4 // grace-note + half
1 -> E3 6 // 2 grace-notes + half
1 -> U2(2, 2) 0.1 // duolet of quarter
1 -> U3(2, 2, 2) 10 // triplet of quarter
//0 -> U5(2, 2, 2, 2, 2) 20
// beat level = quarter note
2 -> C0 1 // continuation
2 -> R 1 // rest
2 -> E1 1 // 1 quarternote
2 -> E2 4 // grace-note + quarter
2 -> E3 9 // 2 grace-notes + quarter
2 -> T2(3, 3) 0.1 // 2 8th notes
2 -> T3(3, 3, 3) 1.1 // triplet of 8th notes
//2 -> T5(4, 4, 4, 4, 4) 3.95
//2 -> T7(4, 4, 4, 4, 4, 4, 4) 6.95
// sub-beat = 8th notes
3 -> C0 1
3 -> R 1
3 -> E1 1
3 -> E2 9
3 -> E3 12
3 -> T2(4, 4) 0.1 // 2 16th notes
3 -> T3(4, 4, 4) 0.1 // triplet 16th notes
// sub-sub-beat = 16th notes
4 -> C0 1
4 -> R 1
4 -> E1 1
4 -> E2 6
4 -> E3 8
4 -> T2(5, 5) 0.1 // 2 32th notes
4 -> T3(5, 5, 5) 0.1 // triplet 32th notes
// 32d notes
5 -> C0 1
5 -> R
5 -> E1 1
Edited by Florent Jacquemard