I am always looking for new knitting patterns, and especially patterns I can connect with. Creating patterns with music will give me both those things, the patterns are easily generated, in many different weights of yarn and whatever music I want.
What it does
Generates knitting patterns using music21 to parse the music. Currently it will only give hat patterns, but there's more to come!
How I built it
I used music21 to parse the music and python to run the script
Challenges I ran into
I had never used music21 before, and there was quite the maze of streams, scores, and other types to try to mold into a workable format for me.
Accomplishments that I'm proud of
I am very happy that my knitting came out looking just like it had a pattern. I was concerned it would look too random or stilted, but I ended up with an interesting pattern that I would definitely make a hat out of.
What I learned
I learned a lot about music21 and parsing music. I spent a long time figuring out how music21 defined its types and how to use them to convert to a workable knitting pattern.
What's next for Music To Knit Py
I will continue implementing knitting designs, such as lace and cables in the pattern based on other aspects of the music. I will also make a hat to make certain all the stitch counts are correct as those were estimated.