1

The automated scale/mode detection programs that I am aware of such as Mixed in Key can only detect major and minor scales, in addition to the key. Could there also be programs that could perform automated scale/mode detection beyond just the major and minor scales? (e.g., detect if a song is using the Phrygian mode)

piiperi Reinstate Monica
  • 27,967
  • 1
  • 37
  • 91
Franck Dernoncourt
  • 1,427
  • 2
  • 15
  • 40
  • 1
    Where and how would you use this, what's the need and intended purpose? What does this "Mixed in key" program print for a Phrygian snippet and how can you tell that its output is not right? – piiperi Reinstate Monica Jan 04 '24 at 22:05
  • @piiperiReinstateMonica generic music analysis, e.g. understanding typical scales in a given music genre. this "Mixed in key" program print only prints minor or major, as well as the key. – Franck Dernoncourt Jan 04 '24 at 22:07
  • Sorry, software recommendations are off-topic here. Feel free to ask in the chat room, though; there was some talk about AI-based theory analysis there recently. – Andy Bonner Jan 04 '24 at 22:19
  • @AndyBonner Thanks, I read "I think the consensus is not that software recs are on topic, but that some can be, if the question is written well." and I saw some non-closed recommendation questions eg https://music.stackexchange.com/q/10576/2589 I can ask on another SE but just to make sure I understand the policy here. – Franck Dernoncourt Jan 04 '24 at 22:32
  • Questions like this are asked so often that I think it should be perfectly reasonable to get some answers. Well, product and resource recommendations are off-topic, because they're opinion-based and the answers go out of date very quickly, because new products and resources are released all the time. But if the question was something like, why don't tools show me modes, and how could I get mode information. – piiperi Reinstate Monica Jan 04 '24 at 23:26
  • @piiperiReinstateMonica I don't see how frequency of the appearance of a question is related to whether the question is or should be on-topic. – Todd Wilcox Jan 05 '24 at 00:42
  • @ToddWilcox There must be a real need that's generating so many questions, and to me it looks like, the askers are basically just told to go away. If a piece of software should ever appear that can actually handle and communicate this stuff, maybe the questions will stop. But until that happens, or this site's practices are somehow adjusted, the people cannot be helped. If the OP could change the question to state the need he's trying to fulfill, maybe we could get somewhere. – piiperi Reinstate Monica Jan 05 '24 at 00:51
  • It should be noted that a fair number of songs in various popular idioms have repeating chord progressions that are ambiguous as to the tonic. But for a program such as Mixed in Key, identifying the tonic isn't the end goal, it seems; the true goal is to identify which songs have compatible keys. If song A is in A minor and song B has chords Dm, F, G, A, it's not going to matter whether song B is in D Dorian or A minor or even G mixolydian; they are going to work just fine. – phoog Jan 05 '24 at 11:14
  • @FranckDernoncourt Since you have access to the "Mixed in key" application, could you check what key it reports for something in C Phrygian? Does it say C minor? For this question, it would be great to know how it works. – piiperi Reinstate Monica Jan 06 '24 at 16:13

1 Answers1

2

TL;DR: The concept of key as in "home pitch and the third above it in harmonic resting position" is much more widely applicable than the narrower concept of mode. For a piece in F Dorian, it's not wrong to tell (pop) musicians it's in F minor.

The authors of "Mixed in key" must have forgotten to explain what they mean by key and why it's useful for the mixing thing. I haven't tried it, but I assume that for a sample in C Dorian and another in C Phrygian it will say "C minor" for both, meaning that they would be mix-compatible in the intended approximate sense.


First off, your question reveals a common misconception:

Could there also be programs that could perform automated scale/mode detection beyond just the major and minor scales?

I don't know this program, but I'm quite sure it doesn't detect scales. Key does not mean scale, it means the harmonic center pitch, and whether the third above it is minor or major. Key is not scale. For a key there is a "default" scale that's denoted in the key signature, because a lot of Western music tends to use those pitches more than others, so this reduces the average number of accidentals needed in sheet music notation. But a song in any key can use any pitch, the only thing that matters is the home note and third, then you know the key.

I am not currently aware of such programs, which would take any random music and declare that it should be categorized as being in one of the church modes. To get some understanding why that might be, read these questions and answers about the Music21 Python programming library

Basically, if you analyze entire songs, chances are that they don't mechanically stick to any single mode for the duration of the whole piece. There needs to be a sliding window and multiple simultaneous possibilities. AND the concept of key as in "home pitch and the third above it in harmonic resting position" is much more widely applicable than the more rarely applicable concept of mode. For a piece in F Dorian, it's not wrong to tell musicians it's in F minor.

Furthermore the algorithms are rather simplistic, they're based on simple statistics like what pitches are used most often.

In reality, the perception of harmonic balance is affected by all aspects of music like pulse, meter and rhythmic weight. Pure pitch relationship based harmony only exists in theory - actual music has a time dimension, and the dimensions of music are not completely separate and independent of each other. And perception also depends on each listener's personal history.

I haven't checked, but to me it looks like the "mode" classification in things like the mentioned Music21's analyze fuction says "major" or "minor" only meaning a coarse category relative to the key center (tonic, home note). It does not mean "100% ionian scale only" or "100% aeolian scale only". I suppose it means that the third above the tonic is mostly major or minor, and everything else can be anything. And this is actually a rather accurate description of how pop/jazz musicians of today understand the concept of key. *)

In this meaning, something in Phrygian would fall in the "minor key" category, because the third is a minor third. And for the rest of the pitches we don't care. Music in Dorian, Aeolian and Locrian would similarly go under "minor key". They are all minor modes.

To see if the "Mixed in key" application works like this, feed it something in C Phrygian and see if it says it's in C minor.

To actually tell whether something is "really" in a mode, modal, ... then we'll have to let a group of music theory and history nerds have a debate about it.

*) "Today": when I was young and learned pop music in the 1980s-1990s. If we really speak about literally TODAY, 2024, it seems that for many mouse+DAW pop makers, key means scale. Just like the OP in this question... Where is that harmful misinformation coming from. If these people figure out that a tune uses an out-of-scale note, their heads explode because the laws of physics were broken.

piiperi Reinstate Monica
  • 27,967
  • 1
  • 37
  • 91
  • Thanks! "Chances are that they don't mechanically stick to any single mode for the duration of the whole piece." yes my follow-up question was asking for a program that can keep track of key/scale changes throughout an audio file. – Franck Dernoncourt Jan 05 '24 at 01:13
  • 1
    @FranckDernoncourt Then we come to the question: if the mode seems to change, is the music really "modal" at all. And as we study more, we may even realize that there are many different meanings for the words "mode" and "key", and there are different cultures and perspectives. If we study very long, we may even understand that when reading or listening to someone talking about modes and something "being" in such and such mode, we realize that we must ask ourselves, "What does this person mean by these words?" And then we could put computer programs' "music measurements" into perspective. – piiperi Reinstate Monica Jan 05 '24 at 01:26
  • @FranckDernoncourt Can you verify if the "Mixed in key" application works like what I'm suggesting here? Feed it something in C Phrygian and see if the application says "C minor". – piiperi Reinstate Monica Jan 05 '24 at 01:54
  • Thanks, I was watching a video earlier today that reported some F Phrygian song on Beatport that got misclassifed by Beatport as F Major. But that's only one example and you make a good point about the third above the tonic. That'd be interesting to look at the confusion matrix of this classification task. I don't know what matters the most between the notes of the scales or the third above the tonic for the automated scale/mode detection models. – Franck Dernoncourt Jan 05 '24 at 03:32
  • Could the downvoter please explain? That'd help me learn. Thanks! – Franck Dernoncourt Jan 05 '24 at 03:33
  • @FranckDernoncourt The question is off topic and should not have been answered, because that encourages future off-topic questions. – Aaron Jan 05 '24 at 05:02
  • 1
    @FranckDernoncourt But you can make the question on-topic by changing it to "how come I haven't found a tool that shows exact modes beyond major/minor", and then the question would be about the meaning of modes and keys and what is so special about them that an app for showing an exact mode is very hard and/or not practical to make. – piiperi Reinstate Monica Jan 05 '24 at 08:16
  • @Aaron There, I fixed it! – piiperi Reinstate Monica Jan 05 '24 at 08:27
  • @piiperiReinstateMonica Yes, I removed my close vote, upvoted both question and answer, and upvoted your comment that the question could be modified. Not sure what else you want. – Aaron Jan 05 '24 at 08:52
  • @Aaron Nothing, I'm not here for points and votes. Saying "there I fixed it" is a meme I find funny – piiperi Reinstate Monica Jan 05 '24 at 08:58
  • 1
    @piiperiReinstateMonica Ah, got it. Wasn't expecting that meme in a situation where something was actually fixed. – Aaron Jan 05 '24 at 21:32
  • But doesn't F minor and dorian have different diatonic chords? That would make an accompanist more probable to play the wrong chords? Wouldn't "X minor/Y major with F as home tone" or something be better? – Emil Jan 10 '24 at 07:19
  • @Emil "F minor" means a key, not a scale. "F Dorian" means the mode. Modes have rigid scales, keys don't. A song that's in a key, can use any notes and chords. Key is about the center, not scale. Since Dorian is a minor mode, a song that's entirely Dorian could be classified in the wider category of minor keys. IF we're talking to pop musicians. – piiperi Reinstate Monica Jan 10 '24 at 08:35
  • If you say F minor at least I would assume you mean the tonic F is ^6 of the major scale of X (I guess it would be A major?) not ^3 (which would be Db major I guess?) and not ^2 (which would be Eb major I guess?). Dorian is the one that starts at ^2 so you would make me play a ton of chords and melodies that sound wrong for the mode. I don't care at all about the difference of scales, keys, to me its just a pitchset and a tonic and a chordset. – Emil Jan 11 '24 at 06:17
  • At least thats how I memorize it, "perfect intervals U1, P4 and P5 are the major chords, the others 2,3,6 are minor chords except 7 which is dim". And I am not a trained musician so chances are I am more similar to pop musicians than classical since bands like Beatles didn't train themselves first either. All of these chords should be pretty safe to play, and then if you get a solo or a bridge you can play funnier chords. Thats kind of the misty naive view I have. – Emil Jan 11 '24 at 06:32
  • That is why I said it would be kinder to say its in Eb Major but we moved the home note to ^2 or whatever – Emil Jan 11 '24 at 07:07
  • @Emil Maybe the culture at large has changed and people effectively don't know what "key" means anymore and are unable to comprehend music with chromatic alterations. I'm still going to act as if people do know that stuff, because that hopefully creates pressure to learn and slows down the spread of ignorance even a tiny bit. :) The Beatles most definitively knew what key means. – piiperi Reinstate Monica Jan 11 '24 at 10:29
  • @Emil "I don't care at all about the difference of scales, keys, to me its just a pitchset and a tonic and a chordset." If you say you don't know and you don't care what key means, I have a hard time understanding why you are spending time on this site. Everyone is of course free to make up their own concepts and meanings for words, but it feels unrealistic to assume that other people start acknowledging them. Don't you think? To me, ignorance is not a virtue, but YMMV. – piiperi Reinstate Monica Jan 11 '24 at 10:40
  • I know exactly what a scale and a key is. I am not talking about that. I am saying if you say A minor, me and many more will think you want the notes C, D, E, F, G, A, B, with A as the tonal center. What we will not assume is that you want Cb, Db, Eb, Fb, G, A, B with A as tonal center. Do you understand. Just saying "minor" leaves out essential information about which notes are a part of the pitchset. The name of the scale starting at ^2 of the major scale is not named minor. This is not standard nomenclature. – Emil Jan 13 '24 at 00:23
  • If you are gonna be inexact at least be less inexact than using the wrong word. This is minor-ish would be better. – Emil Jan 13 '24 at 00:32
  • @Emil I hope you all the best on your musical journey. – piiperi Reinstate Monica Jan 13 '24 at 00:34