Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Save and write a Standardtrack object #18

Open
ChristosSgouropoulos opened this issue Apr 9, 2021 · 2 comments
Open

Save and write a Standardtrack object #18

ChristosSgouropoulos opened this issue Apr 9, 2021 · 2 comments

Comments

@ChristosSgouropoulos
Copy link

Hello and thank you for freely providing us this great work!

I am using a 5 track midi. I can use read() function to read it as a multitrack object. Also I am able to save it to .npz and I can recreate a midi file using write function.

I would like to save each track in different .npz files, and also create different .midi files for each track. When I try to save a track
I get this error:

AttributeError: 'StandardTrack' object has no attribute 'resolution'

When I try to write a track to midi I get this error:

AttributeError: 'StandardTrack' object has no attribute 'tempo'

Is there a way I could do this?

Thank you in advance,

Chris

@FelixDeMan
Copy link

Same problem here, also cannot save multitrack objects because of
AttributeError: 'MultiTrack' object has no attribute 'pianoroll'

Did you find a solution?

Thanks,
Felix

@George-Ogden
Copy link
Contributor

Create a new MultiTrack object using the attributes from the previous MultiTrack object and then copy only the tracks you want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants