Audiveris / audiveris

Latest generation of Audiveris OMR engine
https://audiveris.github.io/audiveris
GNU Affero General Public License v3.0
1.47k stars 218 forks source link

Key change in mxl in every export #725

Open Blaxzter opened 3 months ago

Blaxzter commented 3 months ago

Hello everyone, I have to miss a setting somewhere. In every single transcription I do, there is a key change on the new line:

This is the input: image

And this is the mxl file loaded in muse score: image

And also the same happens when transforming to abc notation.

It happens with all the music I tested.

I've looked into the xml file and I see this in the 5th measure:

      <print new-system="yes">
        <system-layout>
          <system-margins>
            <left-margin>1</left-margin>
            <right-margin>2</right-margin>
          </system-margins>
          <system-distance>50</system-distance>
        </system-layout>
      </print>
      <attributes>
        <key>
          <fifths>0</fifths>
        </key>
        <staff-details print-object="yes"></staff-details>
      </attributes>

When I delete that, all following notes of that key will have a natural sign: image

Help pls. I don't know why it does that.

Original start file: 0cfba16e-89ca-4432-9c30-ba67c9502e73__Treu_Gefuehrt_Von_Gottes_Hand

Audiveris Role: Optical Music Recognition Version: 5.4-alpha:698b2bb69 Software license: GNU Affero GPL v3 OCR engine: Tesseract OCR, version 5.3.1 Java vendor: Microsoft Java version: 17.0.10 Java runtime: OpenJDK Runtime Environment (build 17.0.10+7-LTS) Java VM: OpenJDK 64-Bit Server VM (build 17.0.10+7-LTS, mixed mode, sharing) Operating System: Windows 11 10.0 Architecture: amd64

hbitteur commented 3 months ago

Perhaps, this is due to the lack of any header at the beginning of the second staff. Could you try to manually insert a treble clef before the key signature? Just a guess.

hbitteur commented 3 months ago

I can confirm that the root cause is the lack of standard header at the beginning of second staff.

The real solution would be to feed Audiveris with a legal / standard staff.

A manual workaround is as follows (I just tried it):

  1. Remove the starting flat sign (it was not recognized as a key!)
  2. Insert a treble clef (drag n' drop from shape palette, ClefsAndShifts set)
  3. Insert a 1-flat key (drag n' drop from shape palette, Keys set)

Then export.

1 2 50
Blaxzter commented 3 months ago

Thank you for your help.

As my background in in music isn't so deep I didn't know that the sheet music wasn't legal.

As I have currently 500 sheet music with this layout, (with more coming in) fixing them manually would be a bit tedious.

If there is no flag or option I could use that doesn't allow key changes/ or a different default action on faulty staffs than I'll probably have to talk to the team.