Settings

Theme

Show HN: Warp, a Python based music-theory aware MIDI sequencer

warpseq.com

98 points by mpdehaan2 5 years ago · 35 comments

Reader

mpdehaan2OP 5 years ago

Hi everyone,

I've been making music with synthesizers for a long time, and I always saw great ideas in DAW tools and in hardware, but never all of those ideas in one place. I wanted more music theory awareness in my compositional tools, like the ability to access easy scale changes. I wanted patterns to be symlinks, and to make it easy to have multiple patterns in a single clip.

I wrote Warp to make it happen. Today there's a Python API that can make full songs, and the work on the UI is getting started, which will be available this Fall.

The Python API doesn't technically even require using a loop, so it should be accessible to programmers who aren't Python experts.

Let me know if there are questions, and if you'd like updates, you can also follow @warpseq on twitter.

  • tachyonbeam 5 years ago

    Hello there. This looks interesting, but I think that from a promotional standpoint, your website needs screenshots or a video of the user interface for your program. It's cool that you can make this music with it, but I would like to quickly get a feel for how your program is used.

    IMO, most people will want to see that before they invest time reading documentation or downloading and installing your software.

    Just my two cents! I hope this is helpful.

    • mpdehaan2OP 5 years ago

      Yep, that's true. For now there isn't a user interface and doing some youtubes about the API is definitely planned. the API will remain around forever though, and is useful for generative composition today.

      Do a checkout and you can see quite a few song files in the examples dir which should be helpful in getting a feel for it. UI should be out in a few months and will be more photogenic for youtube and will also ship with some demo tracks showing how all of the patterns work.

  • dangoor 5 years ago

    Neat project! You might find TheoryBoard interesting[1]. It's a midi controller that tries to embed knowledge of scales.

    [1]: https://www.kickstarter.com/projects/irijule/theoryboard-thy...

    • mpdehaan2OP 5 years ago

      that's a cool interface - "impossible to play a wrong note" kinda leaves out the ability for intentional accidentals, but... not bad for a lot of things. Bonus points if they get the glowing holograms floating in the air working :)

      • dangoor 5 years ago

        Yeah, true that wrong notes are sometimes the right thing to do!

        and I would totally back that kickstarter if they had floating holograms

      • xzel 5 years ago

        They actually have some cool features to allow multiple scales and scale changes, so intentional accidentals are promoted. This looks a lot like the Ableton Push controllers besides the direct Ableton integrations. I think the unintentional accidents are what would be missed, and those can be just as good.

Mizza 5 years ago

This is cool!

I've build a much cruder version that I use for generating chord sequences to bring into DAWS:

https://github.com/Miserlou/chords2midi

It even has voice leading, which required translating an "algorithm" written in German in the 1800's!

  • mpdehaan2OP 5 years ago

    oh cool, I had a friend who mentioned (I think another one though) program that generated tiny MIDI clips. That would be great for dragging into a DAW and repositioning them around. Nice!

StavrosK 5 years ago

I tried to use this, but the PYTHONPATH weirdness was a minor impediment, I tried to actually install it but setup.py is missing a quote, installing it doesn't actually install the notation module, and then finally relenting and redefining PYTHONPATH runs to the point where it tells me I need a MIDI device, and I don't have one.

Can I not just make it output sound to my computer speakers?

  • jestar_jokin 5 years ago

    A MIDI sequencer just outputs MIDI instructions, it doesn't generate sound unless it implements a synth (sound generator) of some sort.

    You'd need to install something like loopMIDI, and direct the output of the sequencer to the input of a VST host, where you can load whatever synths you want.

    • mpdehaan2OP 5 years ago

      to add to the above, on OS X, instead of loop MIDI, you can create a Virtual IAC bus instead. For someone with a Windows machine that has loopMIDI, if you want to send me a patch for Windows setup instructions, I'd love to add them.

      I mostly develop on a Mac myself.

      There are also some soft synths that don't need a VST host, some mentioned here - https://blog.landr.com/the-7-best-free-synth-vst-plugins/

      I will admit I haven't used the setup.py having copied it from a previous project, and that's a stupid shortcut to make... I'll take a look at take care of the space issue.

kbob 5 years ago

This looks a little like the NDLR from Conductive Labs. The NDLR is a hardware box. While you can enter chord progressions into it, it's intended for live performance where you enter chords as it plays them.

My issue with the NDLR is that its sequences have no random variation. If you don't keep tweaking the parameters ("noodling"), it starts sounding repetitive quickly.

Any idea whether Warp would run on MicroPython? The NDLR, or a box like it, might make a nice UI.

  • jsilence 5 years ago

    Would be awesome if it ran on Micropython or Circuitpython. Preferably on a Teensy 4.0.

  • mpdehaan2OP 5 years ago

    Yeah, I don't know what it would take. We're currently using very few dependencies so... maybe? Shoot me an email using the links on the homepage if you like and we can continue the conversation.

LeoPanthera 5 years ago

I love the idea, but if successful, I don't how the Warp record label will feel about the name. https://warp.net

TaupeRanger 5 years ago

"music theory aware"? Like...it snaps sequences to scales like every other decent sequencer? I can't actually tell why this is useful from the front page description.

  • mpdehaan2OP 5 years ago

    Nope! With those systems you have no way to input accidentals. Here, notes are entered in scale degree, so if you say "4 5 6" you get the 4th, 5th, and 6th scale note, every time. If you later want to transpose to Eb Pentatonic, everything remains musical. The arp can also tranpose by scale notes instead of just semitones too.

    Also, there's quite a bit more, all in the docs. There's a ton more there.

    • TaupeRanger 5 years ago

      What you've just described after "Nope!" is exactly what I mentioned in my post, which is now downvoted I guess. Many many sequencers let you ask for "4 5 6" and adjust for any scale you want. What are you claiming is new here?

      • mpdehaan2OP 5 years ago

        Those sequencers do not include Ableton, the Monomachine, Bitwig, Logic, or any that I have experience with. They all use force to scale mechanics that make accidentals impossible.

        I suspect Numerology might. I've only seen semitone transpose in most arp implementations, never the ability to work within scale notes. I've never seen an arp that can walk across chords and probabilistically invert them.

        The Cirklon had a lot of great ideas including some things like random step transpositions and variables - but generally, in DAWs, it's not something you have access to. Nobody's even tried to get something like Electron parameter locks going, which is a shame, because they are awesome.

        I don't have enough karma or levels or superpowers to down vote anyone. I have no idea how this website works in that regard.

    • TheOtherHobbes 5 years ago

      What happens to "6 7 8" in a mapping from (e.g.) a straight minor to a pentatonic scale?

      • mpdehaan2OP 5 years ago

        The "6" would be the first note of the next octave, and 7 and 8 would be up that 1 and 2 scale notes.

        Except there's no "from" the straight minor per se, because entry is in scale degrees vs notes from the start.

        • TheOtherHobbes 5 years ago

          Not if you're moving from one kind of scale to another, as you've said you can.

          6 7 8 are functionally different to 1 2 etc in an eight-step key.

          In fact they're different across different 8 step keys. 6 7 8 in Phrygian are structurally different compared to 6 7 8 in Minor, even though they're the same pitches.

          Chords and melodies that use them do not have the same shapes - not because of accidentals, but because they're fundamentally not the same thing and they move through the scale space in different ways.

          And in harmonic minor 6 7 8 ascending and descending are different - not just made different with accidentals, but contextually different.

          Meanwhile pentatonic melodies can have a pentatonic harmony, or they can have harmonies in other scales and modes. How do you know what "4" is supposed to mean if you're not aware of this?

          Of course you can trivially map Thing to Other Thing in Python, but if you don't understand these relationships you're destroying the musical meaning. This is fine for vaguely ambient noodling, but not for building a genuine theory-aware sequencer.

          In music theory you don't just play with numbers, you play with style conventions, context, and meaning - and solving that is a much harder problem than you've managed here.

          • mpdehaan2OP 5 years ago

            Yes you can definitely do non-musical thing without thinking, you should in that case maybe just not do those things if you know better :)

            Clarification: you can also type "1 O+1".

henearkr 5 years ago

Maybe Julia would be the more natural language for music theory, as both are one-based indexed.

  • mpdehaan2OP 5 years ago

    Here the Python API is just expressing the pattern language to user land, the user does not have to deal with python arrays at all.

    See some examples at https://bitbucket.org/laserllama/warpseq/src/master/examples...

    And then you can imagine the web interface growing up around those simple lists of strings.

  • kazinator 5 years ago

    Two wrongs won't make a right.

    A much better idea is to represent intervals internally in such a way that unison is zero.

    The jury may be out on how to enumerate items in a sequence, but a delta offset must be zero-based. That is simply not negotiable.

    Western music theory is crazy.

    Come on: every seven diatonic notes, we get another octave? What? And then we need a "rule of nine" for inverting an interval?

    • mpdehaan2OP 5 years ago

      I completely concur with Western music theory being crazy.

      I would love to be raised by aliens where music was cleanly lined up with decimals or base negative three integers or ... anything.

      There's all the string vibration stuff that leads to 4ths and 5ths though, which as I think fundamental to how we got here, but even little things, like "starting at C" for octaves... it's all weird :)

      The "whole whole half" thing is a mess, and then you get semitones and notes that are missing on the keyboard, etc. Fun times!

      • flak48 5 years ago

        As someone with very little music theory knowledge is there a better alternative to getting into music theory to be able to write music, than the western system, that can be recommended?

        Like how it would feel to grow up learning in metric instead of imperial units for example?

        Sorry if I didn't understand what you and GP were trying to say

        • mpdehaan2OP 5 years ago

          Not sure if that is exactly the answer, but frustration with sheet music is kind of why guitar tab also exists... except I don't play guitar.

          The Roman numeral analysis is somewhat related to https://en.wikipedia.org/wiki/Nashville_Number_System

          If you really want to read things faster than key signatures, there are a bunch of music books you can buy where everything is transcribed to C.

          Anyway, that's kind of all the point of just typing in the scale degrees in Warp... not having to worry about what notes are in what scale, and being able to quickly "draw" out the pattern, which is problematic in most DAWs.

        • main_gi 5 years ago

          Hey there, I'm currently writing an alternative to music theory that is informed by my own self-taught composing. In the western system the 7 note system is used because of the diatonic scale (you may have heard it as the "Major scale", this is usually an inaccurate term and half the time "diatonic scale" is correct). This 7-note system is relied on for almost all the terminology in western theory, which means there is a lot of fudging to make the notes fit, as the diatonic scale is not actually equally spaced apart. That's the reason there is a "minor" and "major" third and not just one "third".

          In addition all these terms are one-indexed because zero was not invented yet, so "unison" in western theory, which refers to two of the same note being played, gets the number 1 (uni-). The same goes for the minor/major second, and so on. This is what causes all the terrible addition problems.

          The diatonic scale's strong relevance in music theory is not completely unjustified because almost all consonant (or "good sounding") music is made in it, but it's not very helpful to have to deconvert these terms to any other scale.

          I visualize all scales as 12-note equally spaced scales and strongly recommend anyone else to do the same. It's known as the chromatic scale. In this system a unison is just 0, a minor second is 1, major second is 2... and so on. You'll see this system used in "music set theory" https://en.wikipedia.org/wiki/Interval_(music)#Generic_and_s... - look at the semitone number to see the amount of equally-spaced spaces between the notes. Although, the word "semitone" is also a poorly thought out choice due to the diatonic scale (it implies a base unit of "2" instead of "1" since semitone corresponds to 1). Music set theory terminology is much better than western theory IMO, but I think a lot of music set theory buys into too many mathematics-based hypotheses (when it tries to draw equivocations between scales), so I find it has its own issues.

          • flak48 5 years ago

            Thanks, you gave me some great starting points to delve into this. Had never heard of music set theory, will take a look

adamnemecek 5 years ago

I've been working in an IDE for music composition http://ngrid.io. Releasing soon.

  • main_gi 5 years ago

    Are there previews or short videos with this?

    • mpdehaan2OP 5 years ago

      no videos at this time, there are source codes all the tracks in git (linked below the soundcloud player on the homepage) - and that should give an overview. Basically I'd be talking through the source code. If you go up one directory, you'll hit "api/examples" which is more functonal (but less song-like) demos of particular features.

      Basically the API is "step 1" to building the final sequencer, but we always want to have the API available for the generative music crowd (and also our own use). Conceptually I think this would be really great to build an ear training program out of, because it's so easy to tell it to generate a ton of chords, scales, and intervals. Maybe that will come later too.

      Anyway, video is still something on my radar!

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection