
I started to learn Haskell last year when I wanted a better language to implement a computer-assisted music composition system. As GUI-heavy, it proved too much of a challenge... learning a new paradigm (functional programming), trying to deal with GUI libraries and their documentation shortcomings, and dealing with my actual problem on top of that proved too much. I went back to Python. However, after a time I reassessed my reason for writing any of this code in the first place. I realized it made more sense to put my available time into ear-training in order to make the meat computer between my ears into a better composition system, rather than programming one. In the meantime, some smaller programming tasks came up (non-gui) and I started on them a few weeks ago, writing in Python. This involves translating a MusicXML document into a midi file, applying some custom algorithms I've written to provide greater expressive qualities. The first Python challenge was to parse the document. I am not aware of a MusicXML-specific Python module, so I used their more general XML code. It took me a few weeks to get a basic input system working. I.e. MusicXML documents translated into my own representation, and reasonable error checking. Then I thought, what the heck am I doing? This is a good task for Haskell! It was only the GUI challenge that turned me off to Haskell last year, but this program is smaller and is purely file-in file-out. Working with Haskell tonight, in about four hours I replicated several weeks of Python work. Yup, this is the right approach. Mike

Michael Mossey wrote:
...I went back to Python... Then I thought, what the heck am I doing? This is a good task for Haskell! ...Working with Haskell tonight, in about four hours I replicated several weeks of Python work. Yup, this is the right approach.
Welcome back! Regards, Yitz

It took me a few weeks to get a basic input system working. I.e. MusicXML documents translated into my own representation, and reasonable error checking.
Check out lilypond. http://lilypond.org/about/faq It can process MusicXML to .ly and .ly to .midi However I think that there are some shortcomings using this chain Still lilypond may be of interest to you. Marc Weber
participants (3)
-
Marc Weber
-
Michael Mossey
-
Yitzchak Gale