Broken tuples

• Jan 23, 2019 - 09:16

Hi,
I have an issue with importing musicxml files that have "split" or "broken" tuples", that is, measures where the notes of tuple are not adjacent (see screenshot attached). The score is displayed correctly most of the time (although for complex combinations of tuples elements a "musicxml file corrupted' appears), but the elements of the score cannot be manipulated in any way (I cannot select the measure and copy to the next, a message "tuples cannot cross barlines" appears.
I generate the musicxml using music21:

import music21 as m21
n1 = m21.note.Note('C4', quarterLength = 80.041666666666666664) # 8th triplet (1/12)
n2 = m21.note.Note('E4', quarterLength = 8
0.0625) # 16th (1/16)
n3 = m21.note.Note('C4', quarterLength = 80.041666666666666664) # 8th triplet (1/12)
n4 = m21.note.Note('E4', quarterLength = 8
0.0625) # 16th (1/16)
n5 = m21.note.Note('C4', quarterLength = 80.041666666666666664) # 16th triplet (1/24)
n6 = m21.note.Note('E4', quarterLength = 8
0.0625) # 16th (1/16)
n7 = m21.note.Note('E4', quarterLength = 8*0.0625) # 16th (1/16)
s = m21.stream.Score()
m = m21.stream.Measure()
for n in [n1, n2, n3, n4, n5, n6,n7]:
m.append(n)
s.append(m)
s.append(m21.meter.bestTimeSignature(m))
s.write('musicxml')

Any suggestion or explanation of why this happens would be great.
Thanks,
Marco Buongiorno Nardelli,

University Distinguished Research Professor
University of North Texas
CEMI, Center for Experimental Music and Intermedia
iARTA, Initiative for Advanced Research in Technology and the Arts
Departments of Physics and Chemistry
ArtSciLab, ATEC @ the University of Texas at Dallas


Comments

Do you still have an unanswered question? Please log in first to post your question.