MarkGotham / When-in-Rome

meta-corpus of and code library for the functional harmonic analysis of music
58 stars 12 forks source link

Fix all tests #59

Closed giamic closed 1 year ago

giamic commented 1 year ago

Some tests still fail. The reasons for error I identified are two:

MarkGotham commented 1 year ago

Thanks!

giamic commented 1 year ago

Missing file: OpenScore-LiederCorpus/Hensel,_Fanny_(Mendelssohn)/5_Lieder,_Op.10/1_Nach_Süden/slices.tsv . Should it be slices_with_analysis.tsv?

giamic commented 1 year ago

Corpus stats: Yes, agreed, but then it shouldn't be a test maybe. It could be offered as a script to get statistics about the corpus.

giamic commented 1 year ago

Also, looking a bit better into the errors:

  1. One error (on Schubert / Schwanengesang D957 / 02_Kriegers_Ahnung / analysis_on_score.mxl) says

    music21.roman.RomanNumeralException: Invalid figure: i
    t

    The t is probably the German functional notation, and the version of music21 I'm using is probably not supporting it yet. A solution to this would be to specify the minimum version of music21 in the environment.yml file. Another solution is to rewrite the code to catch this kind of situations and make them compatible with more versions of music21.

  2. A test failure seems to be pretty musicological, on Hensel,_Fanny_(Mendelssohn) / 5_Lieder,_Op.10 / 1_Nach_Süden / analysis_on_score.mxl. The error message is

    'm15 b1 VD b3 iio b1 V7D' != 'm15 b1 V b2 iio b3 V7'
MarkGotham commented 1 year ago

Ok thanks for this.

  1. Schubert / analysis_on_score files. Yes the analysis_on_score output now puts functional labels in a second lyric line ... ever since I started teaching in Germany ;). So in the rare event where we are reading these lyrics in from an analysis_on_score file, we probably want to take lyric line one only.
  2. Hensel: The analysis.txt has the proper, syntactical version here m15 b1 V b2 iio b3 V7, and the test is returning the nonsense side (m15 b1 VD b3 iio b1 V7D). this looks like the same issue as 1: D is being added to V. Same fix.
  3. Slices. I think we agreed to drop/modify these tests to use only whatever's in the example folder where the slices and other files are stored. We can change the example to the Schumann hosted there, or something else. We can have more than one score there but only if really necessary ... there's 30+ files in the example output so doing that multiple times over is not ideal. This only applies to cases where we need the additional files (slices, analysis_on_score, etc.); the score and analysis files are always provided where so any test that requires only them can take on any file pair in the corpus.
giamic commented 1 year ago

I have opened PR #62 to work on this but I need your help with fixes 1 and 2 (don't know where to select the lyrics line)