Re: Improbable offset for stencil

Yotam Medini יותם מדיני <[email protected]>
Newsgroups gmane.comp.gnu.lilypond.bugs
Message-ID <CAAE-6rb64zDqooOYRP=gcO8KvSMntj1RNGfx+1OthHjZ6c9JYA@mail.gmail.com>
Hello Werner,

Thanks for your reply.
Does the (bug?) report I sent get a ticket in
https://gitlab.com/lilypond/lilypond/-/issues ?

I ran your suggested - "branch regression test":
  [@master, test-baseline, bytecode, @MyBranch, bytecode, check]
Indeed lots of regtests failures.

Another fix attempt is attached.
If I knew how to debug Scheme code, I might have come
with a finer solution.
But with the (C++) suggested fix, the 'make check' produced
much smaller (attached) build/out/test-results/index.html.
To my surprise, also (attached) build/input/regression/midi/out/midi.diff
Could it be that I missed something in the "branch regression test" ?

regards -- yotam

On Mon, Jul 15, 2024 at 10:10 AM Werner LEMBERG <[email protected]> wrote:

>
> > programming error: Improbable offset for stencil: -inf staff space
> > [...]
> > Also attached is a log and a suggested fix.
>
> Thanks for the report.  Your suggested fix essentially undoes commit
> 6ac913499ad6 (from 2013) and unfortunately it makes many regtests
> results worse.
>
> You might run `make bytecode` followed by `make test-baseline` on
> 'master', then applying your change, then running `make bytecode`
> followed by `make check` to create `out/test-restuls/index.html`,
> which you can visit in your browser and which shows you all regtest
> differences.
>
>
>     Werner
>
index.html (text/plain, 6.9 KB)
   click to filter rows by type: [1]ly / [2]midi / [3]log / [4]gittxt /
   [5]reset to all
     __________________________________________________________________

   4282 unchanged

   distance before after
   3.741657 [6]input/regression/scheme-engraver.log
@@ -13,9 +13,9 @@
 #<Mom 0>        : (process-acknowledged)
 #<Mom 0>        : (stop-translation-timestep)
 #<Mom 1/8>      : (start-translation-timestep)
-#<Mom 1/8>      : detected breathing event in #:once listener: #<Prob: Stream_e
vent C++: Stream_event((music-cause . #<Prob: Music C++: Music((length . #<Mom 0
>) (origin . #<location /home/yotam/pub/lilypond/input/regression/scheme-engrave
r.ly:67:3>))((display-methods #<procedure method (a)>) (name . BreathingEvent) (
types event breathing-event) (midi-length . #<procedure breathe::midi-length (a
b)>)) >
+#<Mom 1/8>      : detected breathing event in #:once listener: #<Prob: Stream_e
vent C++: Stream_event((music-cause . #<Prob: Music C++: Music((length . #<Mom 0
>) (origin . #<location /home/yotam/pub/lilypond/input/regression/scheme-engrave
r.ly:67:3>))((display-methods #<procedure method (event)>) (name . BreathingEven
t) (types event breathing-event) (midi-length . #<procedure breathe::midi-length
 (len context)>)) >
 ))((class breathing-event music-event StreamEvent) (length . #<Mom 0>) (origin
. #<location /home/yotam/pub/lilypond/input/regression/scheme-engraver.ly:67:3>)
) >
-#<Mom 1/8>      : detected this rest event: #<Prob: Stream_event C++: Stream_ev
ent((music-cause . #<Prob: Music C++: Music((length . #<Mom 1/8>) (duration . #<
Duration 8 >) (origin . #<location /home/yotam/pub/lilypond/input/regression/sch
eme-engraver.ly:68:3>))((display-methods #<procedure method (a)>) (name . RestEv
ent) (iterator-ctor . #<procedure ly:rhythmic-music-iterator::constructor ()>) (
types event rhythmic-event general-rest-event rest-event)) >
+#<Mom 1/8>      : detected this rest event: #<Prob: Stream_event C++: Stream_ev
ent((music-cause . #<Prob: Music C++: Music((length . #<Mom 1/8>) (duration . #<
Duration 8 >) (origin . #<location /home/yotam/pub/lilypond/input/regression/sch
eme-engraver.ly:68:3>))((display-methods #<procedure method (rest)>) (name . Res
tEvent) (iterator-ctor . #<procedure ly:rhythmic-music-iterator::constructor ()>
) (types event rhythmic-event general-rest-event rest-event)) >
 ) (length . #<Mom 1/8>))((class rest-event general-rest-event rhythmic-event mu
sic-event StreamEvent) (length . #<Mom 1/8>) (duration . #<Duration 8 >) (origin
 . #<location /home/yotam/pub/lilypond/input/regression/scheme-engraver.ly:68:3>
)) >

 #<Mom 1/8>      : created this grob: #<Grob TextScript >
@@ -28,7 +28,7 @@
 #<Mom 1/8>      : (process-acknowledged)
 #<Mom 1/8>      : (stop-translation-timestep)
 #<Mom 1/4>      : (start-translation-timestep)
-#<Mom 1/4>      : detected breathing event in #:once listener: #<Prob: Stream_e
vent C++: Stream_event((music-cause . #<Prob: Music C++: Music((length . #<Mom 0
>) (origin . #<location /home/yotam/pub/lilypond/input/regression/scheme-engrave
r.ly:70:3>))((display-methods #<procedure method (a)>) (name . BreathingEvent) (
types event breathing-event) (midi-length . #<procedure breathe::midi-length (a
b)>)) >
+#<Mom 1/4>      : detected breathing event in #:once listener: #<Prob: Stream_e
vent C++: Stream_event((music-cause . #<Prob: Music C++: Music((length . #<Mom 0
>) (origin . #<location /home/yotam/pub/lilypond/input/regression/scheme-engrave
r.ly:70:3>))((display-methods #<procedure method (event)>) (name . BreathingEven
t) (types event breathing-event) (midi-length . #<procedure breathe::midi-length
 (len context)>)) >
 ))((class breathing-event music-event StreamEvent) (length . #<Mom 0>) (origin
. #<location /home/yotam/pub/lilypond/input/regression/scheme-engraver.ly:70:3>)
) >
 #<Mom 1/4>      : (pre-process-music)
 #<Mom 1/4>      : (process-music)
@@ -41,15 +41,14 @@
 #<Mom 1/4>      : (process-acknowledged)
 #<Mom 1/4>      : (stop-translation-timestep)
 #<Mom 3/8>      : (start-translation-timestep)
-#<Mom 3/8>      : detected breathing event in #:once listener: #<Prob: Stream_e
vent C++: Stream_event((music-cause . #<Prob: Music C++: Music((length . #<Mom 0
>) (origin . #<location /home/yotam/pub/lilypond/input/regression/scheme-engrave
r.ly:73:3>))((display-methods #<procedure method (a)>) (name . BreathingEvent) (
types event breathing-event) (midi-length . #<procedure breathe::midi-length (a
b)>)) >
+#<Mom 3/8>      : detected breathing event in #:once listener: #<Prob: Stream_e
vent C++: Stream_event((music-cause . #<Prob: Music C++: Music((length . #<Mom 0
>) (origin . #<location /home/yotam/pub/lilypond/input/regression/scheme-engrave
r.ly:73:3>))((display-methods #<procedure method (event)>) (name . BreathingEven
t) (types event breathing-event) (midi-length . #<procedure breathe::midi-length
 (len context)>)) >
 ))((class breathing-event music-event StreamEvent) (length . #<Mom 0>) (origin
. #<location /home/yotam/pub/lilypond/input/regression/scheme-engraver.ly:73:3>)
) >
 #<Mom 3/8>      : (pre-process-music)
 #<Mom 3/8>      : (process-music)
 #<Mom 3/8>      : (process-acknowledged)
 #<Mom 3/8>      : (process-acknowledged)
 #<Mom 3/8>      : (process-acknowledged)
-#<Mom 3/8>      : (process-acknowledged)
-#<Mom 3/8>      : (stop-tran
+#<Mom 3/8>      : (process-ack
 Preprocessing graphical objects...
 Calculating line breaks...
 Drawing systems...
@@ -58,5 +57,6 @@
 Layout output to `scheme-engraver-1.eps'...
 Writing scheme-engraver-systems.texi...
 Writing scheme-engraver-systems.tex...
-Writing scheme-engraver-systems.count...slation-timestep)
+Writing scheme-engraver-systems.count...nowledged)
+#<Mom 3/8>      : (stop-translation-timestep)
 #<Mom 3/8>      : (finalize)
[7]

   input/regression/scheme-engraver.log
   0.300030
    BRANCH: master
      HEAD: 5828262395bedbbe72cabae29b951160d2cd4d70
MERGE_BASE: 5828262395bedbbe72cabae29b951160d2cd4d70

    HISTORY
    =======
      HASH: 5828262395bedbbe72cabae29b951160d2cd4d70
   SUBJECT: 61f-Lyrics-GracedNotes.xml: Remove erratic ties

Fri Jul 19 06:19:39 PM IDT 2024

[8]

   input/regression/tree.gittxt
    BRANCH: yotam/translate-minus-infty-to-zero
      HEAD: 773afabd1752786be6073b755057b73798a25bc9
MERGE_BASE: 5828262395bedbbe72cabae29b951160d2cd4d70

    HISTORY
    =======
      HASH: 773afabd1752786be6073b755057b73798a25bc9
   SUBJECT: Stencil::translate modify -inf to zero

      HASH: 5828262395bedbbe72cabae29b951160d2cd4d70
   SUBJECT: 61f-Lyrics-GracedNotes.xml: Remove erratic ties

Fri Jul 19 06:27:36 PM IDT 2024

[9]

   input/regression/tree.gittxt

References

   1. file:///tmp/tmp4lX9LZ.html
   2. file:///tmp/tmp4lX9LZ.html
   3. file:///tmp/tmp4lX9LZ.html
   4. file:///tmp/tmp4lX9LZ.html
   5. file:///tmp/tmp4lX9LZ.html
   6. file:///tmp/input/regression/out-test-baseline/scheme-engraver.log
   7. file:///tmp/input/regression/out-test/scheme-engraver.log
   8. file:///tmp/input/regression/out-test-baseline/tree.gittxt
   9. file:///tmp/input/regression/out-test/tree.gittxt
58282623.diff (text/x-patch, 627 B)
commit 773afabd1752786be6073b755057b73798a25bc9
Author: Yotam Medini <[email protected]>
Date:   Fri Jul 19 18:12:35 2024 +0300

    Stencil::translate modify -inf to zero

diff --git a/lily/stencil.cc b/lily/stencil.cc
index 156b48bf14..1c7bfa7c1e 100644
--- a/lily/stencil.cc
+++ b/lily/stencil.cc
@@ -150,7 +150,11 @@ Stencil::translate (Offset o)
 {
   for (const auto a : {X_AXIS, Y_AXIS})
     {
-      if (std::isinf (o[a])
+      if ((o[a] < 0.0) && (std::isinf (o[a])))
+        {
+          o[a] = 0.0;
+        }
+      else if (std::isinf (o[a])
           || std::isnan (o[a])
 
           // ugh, hardcoded.
midi.diff (text/x-patch, 80.1 KB)
--- /home/yotam/pub/lilypond/input/regression/midi/articulate-repeat.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/articulate-repeat-midi.ly	2024-07-19 18:27:39.958361727 +0300
@@ -1,23 +1,72 @@
-\version "2.25.0"
+% Lily was here -- automatically converted by midi2ly.py from out-test/articulate-repeat.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/articulate-repeat.header
 \header {
-  texidoc = "@code{\\articulate} correctly handles repeats
+texidoc="@code{\articulate} correctly handles repeats
 with alternatives.  They are played in the same order as their
 visual rendition suggests."
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*4 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*4 
+}
+
+trackBchannelB = \relative c {
+  ais'8*7 r8 
+  | % 2
+  b8*7 r8 
+  | % 3
+  ais8*7 r8 
+  | % 4
+  c8*7 
 }
 
-\include "articulate.ly"
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
 
 \score {
-  \articulate {
-    \repeat volta 2 {
-      bes1
-      \alternative {
-        \volta 1 b!
-        \volta 2 bis
-      }
-    }
-  }
-  \midi { }
-  \layout { }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/articulate-trill.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/articulate-trill-midi.ly	2024-07-19 18:27:40.314359632 +0300
@@ -1,17 +1,72 @@
-\version "2.23.9"
+% Lily was here -- automatically converted by midi2ly.py from out-test/articulate-trill.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/articulate-trill.header
 \header {
-  texidoc = "@code{\\articulate} correctly handles trill spans ending on multi-measure rests."
+texidoc=""
+options=""
 }
+% end
 
-\include "articulate.ly"
-\score {
-\unfoldRepeats \articulate {
-   b1 \startTrillSpan |
-   R1 \stopTrillSpan |
-   b2 r |
-   b1
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*4 
 }
-\midi {}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*4 
 }
 
+trackBchannelB = \relative c {
+  c'64 b c b c b c b c b c b c b c b c b c b c b c b c b c b c 
+  b c b c b c b c b c b c b c b c b c b c b c b c b c b c b c b 
+  c b c b 
+  | % 2
+  r1 
+  | % 3
+  b16*7 r16*9 
+  | % 4
+  b8*7 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+\score {
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
+}
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-gap-compatible-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-gap-compatible-target-midi.ly	2024-07-19 18:27:40.646357676 +0300
@@ -1,18 +1,64 @@
-\version "2.19.45"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-gap-compatible-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-gap-compatible-target.header
 \header {
-  texidoc="When there is a gap between the end of a crescendo and a
-  subsequent explicit dynamic, the dynamic performer uses the explicit
-  dynamic as the target of the crescendo."
-
-  %% Note: Choosing this behavior simplified the implementation.  In
-  %% the developer's opinion, it is difficult to argue that choosing a
-  %% target dynamic that under- or overshoots the explicit dynamic is
-  %% more correct.
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2. 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2. 
+}
+
+trackBchannelB = \relative c {
+  c4 c c 
 }
 
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c\! c\f }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-return-crescendo.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-return-crescendo-midi.ly	2024-07-19 18:27:40.982355697 +0300
@@ -1,12 +1,70 @@
-\version "2.19.44"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-return-crescendo.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-return-crescendo.header
 \header {
-  texidoc="The dynamic performer chooses a reasonable peak dynamic and
-  returns to the original dynamic.  The latter, extreme crescendo does
-  not affect the former."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelB = \relative c {
+  c4 c c c 
+  | % 2
+  
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c\> c\< c\sf }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-return-louder-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-return-louder-target-midi.ly	2024-07-19 18:27:41.314353742 +0300
@@ -1,11 +1,64 @@
-\version "2.19.45"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-return-louder-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-return-louder-target.header
 \header {
-  texidoc="The dynamic performer chooses a reasonable peak dynamic and
-  returns to the specified dynamic."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2. 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2. 
+}
+
+trackBchannelB = \relative c {
+  c4 c c 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c\> c\f }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-return-softer-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-return-softer-target-midi.ly	2024-07-19 18:27:41.646351787 +0300
@@ -1,11 +1,64 @@
-\version "2.19.45"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-return-softer-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-return-softer-target.header
 \header {
-  texidoc="The dynamic performer chooses a reasonable peak dynamic and
-  returns to the specified dynamic."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2. 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2. 
+}
+
+trackBchannelB = \relative c {
+  c4 c c 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c\> c\p }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-return-unspecified-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-return-unspecified-target-midi.ly	2024-07-19 18:27:41.982349809 +0300
@@ -1,11 +1,64 @@
-\version "2.19.44"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-return-unspecified-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-return-unspecified-target.header
 \header {
-  texidoc="The dynamic performer chooses a reasonable peak dynamic and
-  returns to the original dynamic."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2. 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2. 
+}
+
+trackBchannelB = \relative c {
+  c4 c c 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c\> c\! }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-single-compatible-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-single-compatible-target-midi.ly	2024-07-19 18:27:42.310347878 +0300
@@ -1,11 +1,64 @@
-\version "2.19.44"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-single-compatible-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-single-compatible-target.header
 \header {
-  texidoc="The velocity of notes during a crescendo is linearly
-  interpolated between the starting and target dynamics."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2. 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2. 
+}
+
+trackBchannelB = \relative c {
+  c4 c c 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c c\f }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/crescendo-single-unspecified-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/crescendo-single-unspecified-target-midi.ly	2024-07-19 18:27:42.646345901 +0300
@@ -1,11 +1,64 @@
-\version "2.19.44"
+% Lily was here -- automatically converted by midi2ly.py from out-test/crescendo-single-unspecified-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/crescendo-single-unspecified-target.header
 \header {
-  texidoc="If no explicit dynamic follows a crescendo, the dynamic
-  performer chooses a reasonable target dynamic."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  c4 c 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\< c\! }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/decrescendo-multiple-compatible-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/decrescendo-multiple-compatible-target-midi.ly	2024-07-19 18:27:42.978343945 +0300
@@ -1,12 +1,68 @@
-\version "2.19.45"
+% Lily was here -- automatically converted by midi2ly.py from out-test/decrescendo-multiple-compatible-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/decrescendo-multiple-compatible-target.header
 \header {
-  texidoc="The dynamic performer apportions changes to consecutive
-  decrescendi in proportion to their duration.  In this case, 1/3 of
-  the change occurs over the first decrescendo."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*2 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*2 
+}
+
+trackBchannelB = \relative c {
+  c4 c c2 
+  | % 2
+  c1 
+  | % 3
+  
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\f\> c\! c2\> | c1\p }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/decrescendo-single-contrary-target.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/decrescendo-single-contrary-target-midi.ly	2024-07-19 18:27:43.310341992 +0300
@@ -1,15 +1,64 @@
-\version "2.19.45"
+% Lily was here -- automatically converted by midi2ly.py from out-test/decrescendo-single-contrary-target.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/decrescendo-single-contrary-target.header
 \header {
-  texidoc="When a decrescendo is followed by an explicit dynamic that
-  is louder than the starting dynamic, the dynamic performer chooses a
-  reasonable target dynamic.  The velocity of notes during the
-  decrescendo is linearly interpolated between the starting and target
-  dynamics, with the explicit dynamic taking effect at the last
-  moment."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2. 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2. 
+}
+
+trackBchannelB = \relative c {
+  c4 c c 
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c\mf\> c c\f }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/dynamic-initial.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/dynamic-initial-midi.ly	2024-07-19 18:27:43.642340036 +0300
@@ -1,15 +1,64 @@
-\version "2.19.44"
+% Lily was here -- automatically converted by midi2ly.py from out-test/dynamic-initial.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/dynamic-initial.header
 \header {
-  texidoc="The MIDI performer uses a default initial dynamic"
+texidoc=""
+options=""
 }
+% end
 
-\score {
-   { c\< c\f }
-   \midi {}
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  c4 c 
 }
 
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-   { c c\< c\f }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/dynamic-voices-sequential.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/dynamic-voices-sequential-midi.ly	2024-07-19 18:27:43.978338059 +0300
@@ -1,15 +1,70 @@
-\version "2.19.47"
+% Lily was here -- automatically converted by midi2ly.py from out-test/dynamic-voices-sequential.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/dynamic-voices-sequential.header
 \header {
-  texidoc="The MIDI performer operates in Voice context by default,
-  so dynamics in different voices are independent."
+texidoc=""
+options=""
 }
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
-\score {
-  \new Staff {
-    \new Voice = "A" c'2\p
-    \new Voice = "A" c'2 % default dynamic expected
-  }
 
+trackBchannelA = {
+  
+  \set Staff.instrumentName = ":A"
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelB = \relative c {
+  c'2 c 
+  | % 2
+  
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+\score {
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/dynamic-voices-simultaneous.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/dynamic-voices-simultaneous-midi.ly	2024-07-19 18:27:44.310336105 +0300
@@ -1,15 +1,61 @@
-\version "2.19.47"
+% Lily was here -- automatically converted by midi2ly.py from out-test/dynamic-voices-simultaneous.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/dynamic-voices-simultaneous.header
 \header {
-  texidoc="The MIDI performer operates in Voice context by default,
-  so dynamics in different voices are independent."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2 
 }
 
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = ":A"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  <e' c >2 
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-  \new Staff <<
-    \new Voice = "A" e'2\p
-    \new Voice = "A" c'2 % default dynamic expected
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
   >>
-
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/key-initial.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/key-initial-midi.ly	2024-07-19 18:27:44.810333163 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out/initial-key.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/key-initial.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -29,16 +23,14 @@ trackAchannelA = {
 
   \key d \minor
     
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
-  
+  \skip 1*2 
 }
 
 trackA = <<
@@ -46,32 +38,33 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative {
+trackBchannelA = {
   
   \set Staff.instrumentName = "trackB:voiceA"
-  d'4 e f g 
-  | % 2
-  a bes cis d
-  | % 3
-  
+  \skip 1*2 
 }
 
-trackB = <<
-  \context Voice = voiceA \trackBchannelA
->>
-
-
-trackCchannelA = {
+trackBchannelB = {
   
   \set Staff.instrumentName = "trackB:"
   
 
   \key d \minor
+  \skip 1*2 
+}
+
+trackBchannelC = \relative c {
+  d'4 e f g 
+  | % 2
+  a bes cis d 
+  | % 3
   
 }
 
-trackC = <<
-  \context Voice = voiceA \trackCchannelA
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelC
 >>
 
 
--- /home/yotam/pub/lilypond/input/regression/midi/key-option-all-staves.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/key-option-all-staves-midi.ly	2024-07-19 18:27:45.266330479 +0300
@@ -1,23 +1,84 @@
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/key-option-all-staves.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/key-option-all-staves.header
 \header {
 texidoc="Midi2ly --key works on all staves, this is G major (--key=1)"
 options="--key=1"
 }
+% end
+
+trackAchannelA = {
+
+
+  \key g \major
+    
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 4 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "treble:one"
+  \skip 4 
+}
+
+trackBchannelB = \relative c {
+  fis''4 
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+trackCchannelA = {
+  
+  \set Staff.instrumentName = "bass:two"
+  \skip 4 
+}
+
+trackCchannelB = \relative c {
+  fis 
+}
+
+trackC = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackCchannelA
+  \context Voice = voiceB \trackCchannelB
+>>
+
 
 \score {
   <<
-    \context Staff = "treble" <<
-      \context Voice="one" \relative {
-	fis''
-      }
-    >>
-    \context Staff = "bass" <<
-      \context Voice="two" \relative {
-	\clef bass
-	fis
-      }
-    >>
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Staff=trackC \trackA
+    \context Staff=trackC \trackC
   >>
   \layout {}
   \midi {}
--- /home/yotam/pub/lilypond/input/regression/midi/key-option.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/key-option-midi.ly	2024-07-19 18:27:45.766327536 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/option-key.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/key-option.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -27,16 +21,16 @@ options="--key=-1"
 trackAchannelA = {
 
 
-  % [SEQUENCE_TRACK_NAME] control track
-  
+  \key f \major
+    
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
-  
+  \skip 1*2 
 }
 
 trackA = <<
@@ -44,9 +38,13 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative {
+trackBchannelA = {
   
   \set Staff.instrumentName = "trackB:voiceA"
+  \skip 1*2 
+}
+
+trackBchannelB = \relative c {
   f'4 g a bes 
   | % 2
   c d e f 
@@ -56,18 +54,7 @@ trackBchannelA = \relative {
 
 trackB = <<
   \context Voice = voiceA \trackBchannelA
->>
-
-
-trackCchannelA = {
-  
-  \set Staff.instrumentName = "trackB:"
-  
-
-}
-
-trackC = <<
-  \context Voice = voiceA \trackCchannelA
+  \context Voice = voiceB \trackBchannelB
 >>
 
 
--- /home/yotam/pub/lilypond/input/regression/midi/lyric-combine-switch-voice.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/lyric-combine-switch-voice-midi.ly	2024-07-19 18:27:46.246324712 +0300
@@ -1,29 +1,72 @@
-\version "2.21.6"
+% Lily was here -- automatically converted by midi2ly.py from out-test/lyric-combine-switch-voice.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/lyric-combine-switch-voice.header
 \header {
-  texidoc = "It is possible to switch the voice that @code{\\lyricsto}
+texidoc="It is possible to switch the voice that @code{\lyricsto}
 follows."
+options=""
 }
+% end
 
-\layout {
-  indent = 0
-  ragged-right = ##t
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2 
 }
 
-music = \fixed c' <<
-  \new Staff <<
-    \new Voice = Va \with \voiceOne { f4 s }
-    \new Voice = Vb \with \voiceTwo { s4 e' }
-  >>
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
-  \new Lyrics \lyricsto Va {
-    \set Lyrics.associatedVoice = Vb
-    Hoo hah.
-  }
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = ":Va"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  f'4 e' 
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+trackCchannelA = \lyricmode {
+  "Hoo" "hah." 
+}
+
+trackC = <<
+  \context Lyrics = voiceA \trackCchannelA
 >>
 
+
 \score {
-  \music
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Lyrics=trackC \trackC
+  >>
   \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/lyric-repeat-count.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/lyric-repeat-count-midi.ly	2024-07-19 18:27:46.606322593 +0300
@@ -1,33 +1,89 @@
-\version "2.23.7"
+% Lily was here -- automatically converted by midi2ly.py from out-test/lyric-repeat-count.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/lyric-repeat-count.header
 \header {
-  texidoc = "This exercises @code{GregorianTranscriptionStaff} and
-@code{GregorianTranscription} with MIDI output enabled."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*7 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  \skip 1*7 
 }
 
-#(ly:set-option 'warning-as-error #t)
+trackBchannelB = \relative c {
+  f'2 g 
+  | % 2
+  a g 
+  | % 3
+  f e 
+  | % 4
+  f1 
+  | % 5
+  g1*2 f1 
+  | % 8
+  
+}
 
-music = \fixed c' {
-  \repeat volta 2 { f2 g }
-  \repeat volta 3 { a g }
-  \repeat volta 4 { f e }
-  \repeat volta 1 f1
-  g\breve f1
-}
-
-words = \lyricmode {
-  \repeat volta 2 { Lo2 -- rem. }
-  \repeat volta 3 { Ip -- sum. }
-  \repeat volta 4 { Do -- lor. }
-  \repeat volta 1 Sit.1
-  A\breve -- met.1
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+trackCchannelA = \lyricmode {
+  "Lo"2 "rem." 
+  | % 2
+  "Ip" "sum." 
+  | % 3
+  "Do" "lor." 
+  | % 4
+  "Sit."1 
+  | % 5
+  "A"1*2 "met."4 " "2. 
+  | % 8
+  
 }
 
+trackC = <<
+  \context Lyrics = voiceA \trackCchannelA
+>>
+
+
 \score {
   <<
-    \new GregorianTranscriptionStaff \music
-    \new GregorianTranscriptionLyrics \words
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Lyrics=trackC \trackC
   >>
-
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/lyric-tie.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/lyric-tie-midi.ly	2024-07-19 18:27:46.942320615 +0300
@@ -1,12 +1,82 @@
-\version "2.23.13"
+% Lily was here -- automatically converted by midi2ly.py from out-test/lyric-tie.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/lyric-tie.header
 \header {
-  texidoc = "In MIDI, lyric ties are rendered as Unicode undertie characters
-(U+203F)."
+texidoc=""
+options=""
 }
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*2 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = ":uniqueContext0"
+  \skip 1*2 
+}
+
+trackBchannelB = \relative c {
+  c'1 
+  | % 2
+  c 
+  | % 3
+  
+}
+
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+trackCchannelA = \lyricmode {
+  "a~~~a" 
+  | % 2
+  "a~~~a~~~a"4 " "2. 
+  | % 3
+  
+}
+
+trackC = <<
+  \context Lyrics = voiceA \trackCchannelA
+>>
+
 
 \score {
-  { c'1 1 }
-  \addlyrics { a~a a~a~a }
-  \midi { }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Lyrics=trackC \trackC
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/lyrics-addlyrics.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/lyrics-addlyrics-midi.ly	2024-07-19 18:27:47.466317532 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out/initial-key.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/lyrics-addlyrics.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -17,23 +11,79 @@
   }
 }
 
-% included from ./out/initial-key.header
+% included from ./out-test/lyrics-addlyrics.header
 \header {
 texidoc="Lyrics are preserved"
 options=""
 }
 % end
 
+trackAchannelA = {
+
+
+  \key g \major
+    
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 6/8 
+  
+  \tempo 4 = 60 
+  \skip 8*11 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = ":uniqueContext0"
+  \skip 8*11 
+}
+
+trackBchannelB = \relative c {
+  d''4 b8 c4 a8 
+  | % 2
+  d4 b8 g4 
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+trackCchannelA = {
+  
+
+  \key g \major
+  \skip 8*11 
+}
+
+trackC = <<
+  \context Voice = voiceA \trackCchannelA
+>>
+
+
+trackDchannelA = \lyricmode {
+  "Girls" "and"8 "boys"4 "come"8 
+  | % 2
+  "out"4 "to"8 "play,"4 
+}
+
+trackD = <<
+  \context Lyrics = voiceA \trackDchannelA
+>>
+
+
 \score {
   <<
-    \relative {
-      \key g \major
-      \time 6/8
-      d''4 b8 c4 a8 | d4 b8 g4
-    }
-    \addlyrics {
-      Girls and \markup \bold boys come | out to play,
-    }
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Lyrics=trackD \trackD
   >>
   \layout {}
   \midi {}
--- /home/yotam/pub/lilypond/input/regression/midi/midi-overlapping-notes.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/midi-overlapping-notes-midi.ly	2024-07-19 18:27:47.802315553 +0300
@@ -1,22 +1,66 @@
+% Lily was here -- automatically converted by midi2ly.py from out-test/midi-overlapping-notes.midi
+\version "2.14.0"
+
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/midi-overlapping-notes.header
 \header {
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*3 
+}
 
-  texidoc = "Notes with equal pitch overlapping in time on the same
-MIDI channel should produce multiple MIDI note-on events, but no
-isolated note-off events before the last of these notes ends."
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
+
+trackBchannelA = {
+  
+  % [INSTRUMENT_NAME] church organ
+  \skip 1*3 
+}
+
+trackBchannelB = \relative c {
+  c'4 c c1. g1 
+  | % 4
+  
 }
 
-\version "2.19.45"
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
 
 \score {
-  \new Staff \with { midiInstrument = "church organ" }
-  \new Voice \relative c' <<
-    % This combination of music expressions should not produce audible
-    % pauses between notes in the MIDI output, in particular, before the
-    % 'g1' note in the first expression.
-    { c1 s1 g1 }
-    { s4 c4 }
-    { s2 c2~ c1 s1 }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
   >>
-  \midi { }
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/midi-polymeter.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/midi-polymeter-midi.ly	2024-07-19 18:27:48.146313530 +0300
@@ -1,16 +1,90 @@
-\version "2.23.7"
+% Lily was here -- automatically converted by midi2ly.py from out-test/midi-polymeter.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/midi-polymeter.header
 \header {
-  texidoc = "@code{\enablePolymeter} can also be used with MIDI output.
-This test should not produce bar check errors."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*3 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  \skip 1*3 
+}
+
+trackBchannelB = \relative c {
+  c'2. c4 
+  | % 2
+  c2 c 
+  | % 3
+  c4 c c c 
+  | % 4
+  
 }
 
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+trackCchannelA = {
+  \skip 1*3 
+}
+
+trackCchannelB = \relative c {
+  c'1 
+  | % 2
+  d 
+  | % 3
+  f 
+  | % 4
+  
+}
+
+trackC = <<
+  \context Voice = voiceA \trackCchannelA
+  \context Voice = voiceB \trackCchannelB
+>>
+
+
 \score {
-  \midi {
-    \enablePolymeter
-  }
   <<
-    \new Staff { \time 3/4 c'2. | 4 2 | 2 4 | 4 4 4 }
-    \new Staff { \time 4/4 c'1 | d' | f' }
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Staff=trackC \trackA
+    \context Staff=trackC \trackC
   >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/music-after-fine-warning.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/music-after-fine-warning-midi.ly	2024-07-19 18:27:48.478311576 +0300
@@ -1,13 +1,64 @@
-\version "2.23.12"
+% Lily was here -- automatically converted by midi2ly.py from out-test/music-after-fine-warning.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/music-after-fine-warning.header
 \header {
-  texidoc="A warning is expected when music follows @code{\\fine}."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 2 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  c4 d 
 }
 
-#(ly:set-option 'warning-as-error #t)
-#(ly:expect-warning (G_ "found music after \\fine"))
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
 
 \score {
-   { c4 \fine d4 }
-   \midi {}
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/pan-position.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/pan-position-midi.ly	2024-07-19 18:27:48.818309577 +0300
@@ -1,44 +1,104 @@
-\version "2.24.1"
+% Lily was here -- automatically converted by midi2ly.py from out-test/pan-position.midi
+\version "2.14.0"
 
-#(ly:set-option 'warning-as-error #t)
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
 
+% included from ./out-test/pan-position.header
 \header {
-  texidoc = "This tests @code{Staff.midiPanPosition}.  The sound
-should begin with an oboe at left and a bassoon at right.  They should
-switch positions in three steps at intervals of two seconds."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 30 
+  \skip 1 
+  | % 2
+  
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+>>
+
+
+trackCchannelA = {
+  
+  % [INSTRUMENT_NAME] oboe
+  \skip 1 
+  | % 2
+  
+}
+
+trackCchannelB = \relative c {
+  a''1 
+  | % 2
+  
+}
+
+trackC = <<
+  \context Voice = voiceA \trackCchannelA
+  \context Voice = voiceB \trackCchannelB
+>>
+
+
+trackDchannelA = {
+  
+  % [INSTRUMENT_NAME] bassoon
+  \skip 1 
+  | % 2
+  
+}
+
+trackDchannelB = \relative c {
+  f, 
+  | % 2
+  
 }
 
+trackD = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackDchannelA
+  \context Voice = voiceB \trackDchannelB
+>>
+
+
 \score {
-  \midi {}
   <<
-    \tempo 4 = 30
-    \new Staff \with {
-      midiInstrument = "oboe" % something sustained for audio verification
-      midiPanPosition = -1.0
-    } <<
-      a'1
-      {
-        \skip 4
-        \set Staff.midiPanPosition = -0.33
-        \skip 4
-        \set Staff.midiPanPosition = 0.33
-        \skip 4
-        \set Staff.midiPanPosition = 1.0
-      }
-    >>
-    \new Staff \with {
-      midiInstrument = "bassoon" % something sustained for audio verification
-      midiPanPosition = 1.0
-    } <<
-      f,1
-      {
-        \skip 4
-        \set Staff.midiPanPosition = 0.33
-        \skip 4
-        \set Staff.midiPanPosition = -0.33
-        \skip 4
-        \set Staff.midiPanPosition = -1.0
-      }
-    >>
+    \context Staff \trackA
+    \context Staff=trackC \trackA
+    \context Staff=trackC \trackC
+    \context Staff=trackD \trackA
+    \context Staff=trackD \trackD
   >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/partcombine.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/partcombine-midi.ly	2024-07-19 18:27:49.358306400 +0300
@@ -1,18 +1,13 @@
-\version "2.21.0"
+% Lily was here -- automatically converted by midi2ly.py from out-test/partcombine.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -16,30 +11,100 @@
   }
 }
 
+% included from ./out-test/partcombine.header
 \header {
 texidoc="PartCombined music is preserved"
 options="--skip"
 }
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*5 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "staff:one"
+  \skip 1*5 
+}
+
+trackBchannelB = {
+  
+  \set Staff.instrumentName = "staff:solo"
+  \skip 1*5 
+}
 
-instrumentOne = \relative {
-  c'4 d e f
-  R1
-  d'4 c b a
-  b4 g2 f4
-  e1
+trackBchannelC = {
+  
+  \set Staff.instrumentName = "staff:shared"
+  \skip 1*5 
 }
 
-instrumentTwo = \relative {
-  R1
-  g'4 a b c
-  d c b a
-  g f( e) d
-  e1
+trackBchannelD = {
+  
+  \set Staff.instrumentName = "staff:two"
+  \skip 1*5 
 }
 
+trackBchannelE = \relative c {
+  \voiceThree
+  s4*13 g''2 
+}
+
+trackBchannelF = \relative c {
+  \voiceTwo
+  s4*13 f'4 e 
+}
+
+trackBchannelG = \relative c {
+  \voiceOne
+  s1*2 d''4 c b a 
+  | % 4
+  <b g > s2 <f d >4 
+  | % 5
+  e1 
+  | % 6
+  
+}
+
+trackBchannelH = \relative c {
+  \voiceFour
+  c'4 d e f 
+  | % 2
+  g a b c 
+  | % 3
+  
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelC
+  \context Voice = voiceD \trackBchannelD
+  \context Voice = voiceE \trackBchannelE
+  \context Voice = voiceF \trackBchannelF
+  \context Voice = voiceG \trackBchannelG
+  \context Voice = voiceH \trackBchannelH
+>>
+
+
 \score {
-<<
-  \new Staff = "staff" \partCombine \instrumentOne \instrumentTwo
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
   >>
   \layout {}
   \midi {}
--- /home/yotam/pub/lilypond/input/regression/midi/performance-name-utf8.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/performance-name-utf8-midi.ly	2024-07-19 18:27:49.698304400 +0300
@@ -1,17 +1,66 @@
-\version "2.23.11"
+% Lily was here -- automatically converted by midi2ly.py from out-test/performance-name-utf8.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/performance-name-utf8.header
 \header {
-  texidoc = "The performance name of the MIDI file can contain
-Unicode characters.  They are encoded in UTF8.
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  \set Staff.instrumentName = "~~~~~~~~~~~~~~~~"
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 4 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
-Note: due to the way the regression test infrastructure currently
-works, any breakage in this test will not be noticed automatically."
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 4 
+}
+
+trackBchannelB = \relative c {
+  c'4 
 }
 
+trackB = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-  \header {
-    title = "Łïłîρøñđ"
-  }
-  { c' }
-  \midi { }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/quantize-duration-2.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/quantize-duration-2-midi.ly	2024-07-19 18:27:50.210301389 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by out/bin/midi2ly from /home/janneke/testmidi.mid
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/quantize-duration-2.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -17,25 +11,26 @@
   }
 }
 
+% included from ./out-test/quantize-duration-2.header
 \header {
 texidoc="@code{midi2ly}'s option @option{--duration-quant} preserves first note length (16)."
 options="--duration-quant=16"
 }
+% end
 
 trackAchannelA = {
 
 
   \key a \major
     
-  % [TEXT_EVENT] Nokia Tune
+  % [TEXT_EVENT] creator: 
   
-  \tempo 4 = 120 
-  
-
-  \key a \major
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 3/8 
   
+  \tempo 4 = 120 
+  \skip 4*1138/384 
 }
 
 trackA = <<
@@ -43,15 +38,33 @@ trackA = <<
 >>
 
 
-trackBchannelB = \relative {
-  e'''4*41/192 r4*7/192 d4*41/192 r4*7/192 fis,4*89/192 r4*7/192 gis4*89/192 
-  r4*7/192 
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "trackB:voiceA"
+  \skip 4*1138/384 
+}
+
+trackBchannelB = {
+  
+  \set Staff.instrumentName = "trackB:"
+  
+
+  \key a \major
+  \skip 4*1138/384 
+}
+
+trackBchannelC = \relative c {
+  e'''16 d fis,8 gis 
   | % 2
-  cis4*41/192 r4*7/192 b4*41/192 r4*7/192 d,4*89/192 r4*7/192 e4*89/192 
+  cis16 b d,8 e 
+  | % 3
+  
 }
 
 trackB = <<
-  \context Voice = voiceA \trackBchannelB
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelC
 >>
 
 
--- /home/yotam/pub/lilypond/input/regression/midi/quantize-duration.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/quantize-duration-midi.ly	2024-07-19 18:27:50.682298613 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/voice-2.midi
-\version "2.16.0"
+% Lily was here -- automatically converted by midi2ly.py from out-test/quantize-duration.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -26,16 +20,14 @@ options="--duration-quant=4"
 
 trackAchannelA = {
   
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
-  
+  \skip 2 
 }
 
 trackA = <<
@@ -43,18 +35,35 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative c {
-  r4*1/8 c4*7/8 
-  c4*7/8 r4*1/8
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "trackB:voiceA"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  \voiceOne
+  r32 c4 
+}
+
+trackBchannelBvoiceB = \relative c {
+  \voiceTwo
+  r4 c 
 }
 
 trackB = <<
+
+  \clef bass
+  
   \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelBvoiceB
 >>
 
 
 \score {
   <<
+    \context Staff=trackB \trackA
     \context Staff=trackB \trackB
   >>
   \layout {}
--- /home/yotam/pub/lilypond/input/regression/midi/quantize-start.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/quantize-start-midi.ly	2024-07-19 18:27:51.138295931 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/voice-2.midi
-\version "2.16.0"
+% Lily was here -- automatically converted by midi2ly.py from out-test/quantize-start.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -26,16 +20,14 @@ options="--start-quant=4"
 
 trackAchannelA = {
   
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
-  
+  \skip 2 
 }
 
 trackA = <<
@@ -43,18 +35,28 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative c {
-  r4*1/8 c4*7/8 
-  c4*7/8 r4*1/8
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "trackB:voiceA"
+  \skip 2 
+}
+
+trackBchannelB = \relative c {
+  c4 c 
 }
 
 trackB = <<
+
+  \clef bass
+  
   \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
 >>
 
 
 \score {
   <<
+    \context Staff=trackB \trackA
     \context Staff=trackB \trackB
   >>
   \layout {}
--- /home/yotam/pub/lilypond/input/regression/midi/rehearsal-mark.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/rehearsal-mark-midi.ly	2024-07-19 18:27:51.470293979 +0300
@@ -1,12 +1,83 @@
-\version "2.23.6"
+% Lily was here -- automatically converted by midi2ly.py from out-test/rehearsal-mark.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/rehearsal-mark.header
 \header {
-  texidoc="Rehearsal marks create MIDI Marker events."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+  % [MARKER] A
+  \skip 1 
+  | % 3
+  
+  % [MARKER] B
+  \skip 1 
+  | % 4
+  
+  % [MARKER] X
+  \skip 1 
+  | % 5
+  
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*4 
+}
+
+trackBchannelB = \relative c {
+  c'1 
+  | % 2
+  d 
+  | % 3
+  e 
+  | % 4
+  f 
+  | % 5
+  
 }
 
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-  \fixed c' {
-    c1 \mark \default d1 \mark \default e1 \mark 23 f1
-  }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/repeat-segno.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/repeat-segno-midi.ly	2024-07-19 18:27:51.810291980 +0300
@@ -1,22 +1,105 @@
-\version "2.23.6"
+% Lily was here -- automatically converted by midi2ly.py from out-test/repeat-segno.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/repeat-segno.header
 \header {
-  texidoc="Segni and coda signs create MIDI Marker events."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+  % [MARKER] ~~~~
+  \skip 1 
+  | % 3
+  
+  % [MARKER] ~~~~
+  \skip 1*3 
+  % [MARKER] ~~~~~~~~
+  \skip 1 
+  | % 7
+  
+  % [MARKER] ~~~~~~~~
+  \skip 1*3 
+  % [MARKER] ~~~~~~~3~~~~~~~
+  \skip 1 
+  | % 11
+  
+  % [MARKER] ~~~~~~~3~~~~~~~
+  \skip 1*2 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*12 
+}
+
+trackBchannelB = \relative c {
+  c'1 
+  | % 2
+  d 
+  | % 3
+  e 
+  | % 4
+  f 
+  | % 5
+  c 
+  | % 6
+  d 
+  | % 7
+  e 
+  | % 8
+  f 
+  | % 9
+  c 
+  | % 10
+  d 
+  | % 11
+  e 
+  | % 12
+  f 
+  | % 13
+  
 }
 
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-  \fixed c' {
-    \repeat unfold 3 {
-      c1
-      \repeat segno 2 {
-        d1
-        \alternative {
-          e1
-          <>
-        }
-      }
-      f1
-    }
-  }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/rest-dynamic.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/rest-dynamic-midi.ly	2024-07-19 18:27:52.282289205 +0300
@@ -1,13 +1,63 @@
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/rest-dynamic.midi
+\version "2.14.0"
+
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/rest-dynamic.header
 \header {
 texidoc="LilyPond respects rests, also when there are dynamics"
 options=""
 }
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 2/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  \skip 1 
+}
+
+trackBchannelB = \relative c {
+  e'4 e 
+  | % 2
+  r4 e 
+  | % 3
+  
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
 
 \score {
-  \new Staff \relative {
-    \time 2/4 e'4 e r4 e\f |
-  }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
   \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/rest.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/rest-midi.ly	2024-07-19 18:27:52.770286335 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/rest.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/rest.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -26,15 +20,15 @@ options=""
 
 trackAchannelA = {
   
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
+  \skip 1 
+  | % 2
   
 }
 
@@ -43,10 +37,16 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative {
-  r4 
+trackBchannelA = {
+  
   \set Staff.instrumentName = "trackB:voiceA"
-  a, r4 a 
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelB = \relative c {
+  r4 a r4 a 
   | % 2
   
 }
@@ -56,6 +56,7 @@ trackB = <<
   \clef bass
   
   \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
 >>
 
 
--- /home/yotam/pub/lilypond/input/regression/midi/section-label.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/section-label-midi.ly	2024-07-19 18:27:53.102284384 +0300
@@ -1,13 +1,73 @@
-\version "2.23.6"
+% Lily was here -- automatically converted by midi2ly.py from out-test/section-label.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/section-label.header
 \header {
-  texidoc="Section labels create MIDI Marker events."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  % [MARKER] Intro
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+  % [MARKER] Coda
+  \skip 1 
+  | % 3
+  
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*2 
+}
+
+trackBchannelB = \relative c {
+  c'1 
+  | % 2
+  d 
+  | % 3
+  
 }
 
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-  \fixed c' {
-    \sectionLabel \markup \smallCaps "Intro" c1
-    \sectionLabel "Coda" d1
-  }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/sequence-name-scoping.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/sequence-name-scoping-midi.ly	2024-07-19 18:27:54.146278246 +0300
@@ -1,7 +1,19 @@
-\version "2.19.25"
+% Lily was here -- automatically converted by midi2ly.py from out-test/sequence-name-scoping.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/sequence-name-scoping.header
 \header {
-  texidoc="If a score has a @code{\header} block which defines a title,
+texidoc="If a score has a @code{\header} block which defines a title,
   this title should override any title defined in a @code{\header} block
   of the score's enclosing @code{\bookpart} or @code{\book} (or a title
   defined in a top-level @code{\header} block) when naming the MIDI
@@ -10,73 +22,57 @@
   using the title defined in the @code{\header} block of the nearest
   enclosing @code{\bookpart}, @code{\book}, or top-level scope that
   contains a title definition."
-  title = "Top-level title"
+options=""
 }
+% end
 
-music = \new Staff { c1 }
+trackAchannelA = {
+  
+  \set Staff.instrumentName = "Book"
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+}
 
-% Book with a title defined in a \header block, and book parts
-\book {
-  \header { title = "Book" }
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
-  % score without a \header block outside of any book part -- the MIDI
-  % sequence should get the title of the book as its name
-  \score {
-    \music
-    \layout { }
-    \midi { }
-  }
 
-  % score with a \header and a title outside of any book part -- the MIDI
-  % sequence should be named with the title from this \header block
-  \score {
-    \music
-    \header { title = "Score in a \book" }
-    \layout { }
-    \midi { }
-  }
-
-  % Book part with a \header block and a title
-  \bookpart {
-    \header { title = "Book part" }
-
-    % score without a \header block -- the MIDI sequence should get its name
-    % from the title of the enclosing book part
-    \score {
-      \music
-      \layout { }
-      \midi { }
-    }
-
-    % score with a \header (and a title) of its own -- the MIDI sequence
-    % should get its name from the title in this \header block
-    \score {
-      \music
-      \header { title = "Score in a book part (w/ a title) of a book" }
-      \layout { }
-      \midi { }
-    }
-  }
+trackBchannelA = {
+  \skip 1 
+  | % 2
+  
+}
 
-  % Book part without a \header block
-  \bookpart {
+trackBchannelB = \relative c {
+  c1 
+  | % 2
+  
+}
 
-    % score without a \header block -- the MIDI sequence should be named
-    % using the title from the enclosing book
-    \score {
-      \music
-      \layout { }
-      \midi { }
-    }
-
-    % score with a \header block and title -- the MIDI sequence should get
-    % its name from the title in this \header block
-    \score {
-      \music
-      \header { title = "Score in a book part (w/o a title) of a book" }
-      \layout { }
-      \midi { }
-    }
-  }
+trackB = <<
 
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+\score {
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/sequence-name.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/sequence-name-midi.ly	2024-07-19 18:27:53.598281468 +0300
@@ -1,7 +1,19 @@
-\version "2.19.25"
+% Lily was here -- automatically converted by midi2ly.py from out-test/sequence-name.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/sequence-name.header
 \header {
-  texidoc="The MIDI sequence generated from a score should get its name
+texidoc="The MIDI sequence generated from a score should get its name
   from the title defined in the score's @code{\header} block (if any).
   The title used for layout can be overridden for MIDI output by
   specifying a separate @code{midititle} in the @code{\header} block.
@@ -9,55 +21,57 @@
   @code{\bookpart}, @code{\book}, or top-level scope with a @code{\header}
   block that defines a title, either, the MIDI sequence should get the
   default name."
+options=""
 }
+% end
 
-music = \new Staff { c1 }
+trackAchannelA = {
+  
+  \set Staff.instrumentName = "Title shared between layout and MIDI"
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+}
 
-% Book without a \header block
-\book {
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
 
-  % score with a \header block including a title -- the MIDI sequence
-  % should get its name from this \header block
-  \score {
-    \music
-    \header { title = "Title shared between layout and MIDI" }
-    \layout { }
-    \midi { }
-  }
 
-  % score with no title, but a midititle defined in a \header block --
-  % the MIDI sequence should be named using the midititle in this \header
-  % block
-  \score {
-    \music
-    \header { midititle = "No title for layout, but a title for MIDI" }
-    \layout { }
-    \midi { }
-  }
-
-  % score with a title and a midititle defined in a \header block -- the
-  % MIDI sequence should get the midititle in this \header block as its
-  % name
-  \score {
-    \music
-    \header {
-      title = "Title for layout"
-      midititle = "Title for MIDI"
-    }
-    \layout { }
-    \midi { }
-  }
+trackBchannelA = {
+  \skip 1 
+  | % 2
+  
+}
 
-  % Book part with no \header block
-  \bookpart {
+trackBchannelB = \relative c {
+  c1 
+  | % 2
+  
+}
 
-    % score without a \header -- the MIDI sequence should get the default
-    % name
-    \score {
-      \music
-      \layout { }
-      \midi { }
-    }
-  }
+trackB = <<
 
+  \clef bass
+  
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
+\score {
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
+  \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/spacer-no-notes.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/spacer-no-notes-midi.ly	2024-07-19 18:27:54.478276295 +0300
@@ -1,16 +1,61 @@
-\version "2.21.7"
+% Lily was here -- automatically converted by midi2ly.py from out-test/spacer-no-notes.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/spacer-no-notes.header
 \header {
-  texidoc = "This test should produce a two-measure MIDI file in the
-key of G minor, but with no notes."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+
+
+  \key g \minor
+    
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*2 
 }
 
-#(ly:set-option 'warning-as-error #t)
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  
+
+  \key g \minor
+  \skip 1*2 
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+>>
+
 
 \score {
-  {
-    \key g \minor
-    s1*2
-  }
+  <<
+    \context Staff \trackA
+  >>
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/staff-map-instrument.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/staff-map-instrument-midi.ly	2024-07-19 18:27:55.038273003 +0300
@@ -1,44 +1,130 @@
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/staff-map-instrument.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/staff-map-instrument.header
 \header {
 texidoc="Midi2ly remaps voices correctly to staves in MIDI-files that use instrument<->channel mapping when combined with voice<->track mapping.  TODO: pianostaff"
 options=""
 }
+% end
+
+trackAchannelA = {
+
+
+  \key c \minor
+    
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*2 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "treble:one"
+  \skip 1*2 
+}
+
+trackBchannelB = {
+  
+  \set Staff.instrumentName = "treble:"
+  
+
+  \key c \minor
+  \skip 1*2 
+}
+
+trackBchannelC = {
+  
+  \set Staff.instrumentName = "treble:two"
+  \skip 1*2 
+}
+
+trackBchannelD = \relative c {
+  \voiceOne
+  f''8 ees16 d c bes aes g f8 aes' g f 
+  | % 2
+  f,16 g aes4 g16 f e2 
+  | % 3
+  
+}
+
+trackBchannelE = \relative c {
+  \voiceTwo
+  c''4 r4. f8 ees d 
+  | % 2
+  <b, d > r8 <b d > r8 <g c >2 
+  | % 3
+  
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelC
+  \context Voice = voiceD \trackBchannelD
+  \context Voice = voiceE \trackBchannelE
+>>
+
+
+trackCchannelA = {
+  
+  \set Staff.instrumentName = "bass:three"
+  \skip 1*2 
+}
+
+trackCchannelB = {
+  
+  \set Staff.instrumentName = "bass:"
+  
+
+  \key c \minor
+  \skip 1*2 
+}
+
+trackCchannelC = \relative c {
+  r8 c'16 b c8 g aes c16 b c8 d 
+  | % 2
+  <c,, c' >1 
+  | % 3
+  
+}
+
+trackC = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackCchannelA
+  \context Voice = voiceB \trackCchannelB
+  \context Voice = voiceC \trackCchannelC
+>>
+
 
 \score {
-%% TODO:PIANOSTAFF  \context PianoStaff <<
   <<
-    \context Staff = "treble" <<
-      \set Score.midiChannelMapping = #'instrument
-      \context Voice="one" \relative {
-	\time 4/4
-	\key c \minor
-	\voiceOne
-%comes
-%7
-	f''8 es16 d c16 bes ! as g f8 as' g f 
-%8	es8 d es f b, c d b |
-	f,16 g as4 g16 f e2 |
-      }
-      \context Voice="two" \relative {
-	\voiceTwo
-%dux
-%7
-	c''4 r4 r8 f es d |
-%8	r8 as g f g f16 es f8 d | 
-	<b, d>8 r <b d> r <g c>2 |
-      }
-    >>
-    \context Staff = "bass" <<
-      \context Voice="three" \relative {
-	\key c \minor
-	\clef bass
-%7
-	r8 c'16 b c8 g as c16 b c8 d |
-%8	g8 c16 b c8 d f,16 g as4 g16 f | 
-	<c,, c'>1
-      }
-    >>
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Staff=trackC \trackA
+    \context Staff=trackC \trackC
   >>
   \layout {}
   \midi {}
--- /home/yotam/pub/lilypond/input/regression/midi/staff-map-voice.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/staff-map-voice-midi.ly	2024-07-19 18:27:55.590269759 +0300
@@ -1,44 +1,109 @@
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/staff-map-voice.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/staff-map-voice.header
 \header {
 texidoc="Midi2ly remaps voices correctly to staves in MIDI-files that use voice<->channel mapping when combined with staff<->track mapping.  TODO: pianostaff"
 options=""
 }
+% end
+
+trackAchannelA = {
+
+
+  \key c \minor
+    
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1*2 
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "treble:one"
+  
+
+  \key c \minor
+  \skip 1*2 
+}
+
+trackBchannelB = \relative c {
+  \voiceOne
+  f''8 ees16 d c bes aes g f8 aes' g f 
+  | % 2
+  f,16 g aes4 g16 f e2 
+  | % 3
+  
+}
+
+trackBchannelC = \relative c {
+  \voiceTwo
+  c''4 r4. f8 ees d 
+  | % 2
+  <b, d > r8 <b d > r8 <g c >2 
+  | % 3
+  
+}
+
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelC
+>>
+
+
+trackCchannelA = {
+  
+  \set Staff.instrumentName = "bass:three"
+  
+
+  \key c \minor
+  \skip 1*2 
+}
+
+trackCchannelB = \relative c {
+  r8 c'16 b c8 g aes c16 b c8 d 
+  | % 2
+  <c,, c' >1 
+  | % 3
+  
+}
+
+trackC = <<
+
+  \clef bass
+  
+  \context Voice = voiceA \trackCchannelA
+  \context Voice = voiceB \trackCchannelB
+>>
+
 
 \score {
-%% TODO:PIANOSTAFF  \context PianoStaff <<
   <<
-    \context Staff = "treble" <<
-      \set Score.midiChannelMapping = #'voice
-      \context Voice="one" \relative {
-	\time 4/4
-	\key c \minor
-	\voiceOne
-%comes
-%7
-	f''8 es16 d c16 bes ! as g f8 as' g f 
-%8	es8 d es f b, c d b |
-	f,16 g as4 g16 f e2 |
-      }
-      \context Voice="two" \relative {
-	\voiceTwo
-%dux
-%7
-	c''4 r4 r8 f es d |
-%8	r8 as g f g f16 es f8 d | 
-	<b, d>8 r <b d> r <g c>2 |
-      }
-    >>
-    \context Staff = "bass" <<
-      \context Voice="three" \relative {
-	\key c \minor
-	\clef bass
-%7
-	r8 c'16 b c8 g as c16 b c8 d |
-%8	g8 c16 b c8 d f,16 g as4 g16 f | 
-	<c,, c'>1
-      }
-    >>
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+    \context Staff=trackC \trackA
+    \context Staff=trackC \trackC
   >>
   \layout {}
   \midi {}
--- /home/yotam/pub/lilypond/input/regression/midi/varcoda.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/varcoda-midi.ly	2024-07-19 18:27:55.926267785 +0300
@@ -1,15 +1,71 @@
-\version "2.23.6"
+% Lily was here -- automatically converted by midi2ly.py from out-test/varcoda.midi
+\version "2.14.0"
 
+\layout {
+  \context {
+    \Voice
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
+  }
+}
+
+% included from ./out-test/varcoda.header
 \header {
-  texidoc="Variant coda signs create MIDI Marker events."
+texidoc=""
+options=""
+}
+% end
+
+trackAchannelA = {
+  
+  % [TEXT_EVENT] creator: 
+  
+  % [TEXT_EVENT] LilyPond 2.25.18              
+  
+  \time 4/4 
+  
+  \tempo 4 = 60 
+  \skip 1 
+  | % 2
+  
+  % [MARKER] ~~~~
+  \skip 1 
+  | % 3
+  
+}
+
+trackA = <<
+  \context Voice = voiceA \trackAchannelA
+>>
+
+
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "\new:"
+  \skip 1*2 
+}
+
+trackBchannelB = \relative c {
+  c'1 
+  | % 2
+  d 
+  | % 3
+  
 }
 
+trackB = <<
+  \context Voice = voiceA \trackBchannelA
+  \context Voice = voiceB \trackBchannelB
+>>
+
+
 \score {
-  \fixed c' {
-    \set Score.codaMarkFormatter = #format-varcoda-mark
-    c1
-    \codaMark \default
-    d1
-  }
+  <<
+    \context Staff=trackB \trackA
+    \context Staff=trackB \trackB
+  >>
+  \layout {}
   \midi {}
 }
--- /home/yotam/pub/lilypond/input/regression/midi/voice-2.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/voice-2-midi.ly	2024-07-19 18:27:56.418264893 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/voice-2.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/voice-2.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -26,15 +20,15 @@ options=""
 
 trackAchannelA = {
   
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
+  \skip 1 
+  | % 2
   
 }
 
@@ -43,16 +37,30 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative {
-  \voiceOne
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "trackB:voiceA"
+  \skip 1 
+  | % 2
   
-  \set Staff.instrumentName = ":1"
+}
+
+trackBchannelB = {
+  
+  \set Staff.instrumentName = "trackB:voiceB"
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelC = \relative c {
+  \voiceOne
   e''4 e e e 
   | % 2
   
 }
 
-trackBchannelB = \relative {
+trackBchannelD = \relative c {
   \voiceTwo
   f' f f f 
   | % 2
@@ -62,6 +70,8 @@ trackBchannelB = \relative {
 trackB = <<
   \context Voice = voiceA \trackBchannelA
   \context Voice = voiceB \trackBchannelB
+  \context Voice = voiceC \trackBchannelC
+  \context Voice = voiceD \trackBchannelD
 >>
 
 
--- /home/yotam/pub/lilypond/input/regression/midi/voice-4.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/voice-4-midi.ly	2024-07-19 18:27:56.926261908 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/voice-4.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/voice-4.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -26,15 +20,15 @@ options=""
 
 trackAchannelA = {
   
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
+  \skip 1 
+  | % 2
   
 }
 
@@ -43,30 +37,60 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative {
-  \voiceOne
+trackBchannelA = {
+  
+  \set Staff.instrumentName = "trackB:voiceA"
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelB = {
+  
+  \set Staff.instrumentName = "trackB:voiceD"
+  \skip 1 
+  | % 2
   
-  \set Staff.instrumentName = ":1"
+}
+
+trackBchannelC = {
+  
+  \set Staff.instrumentName = "trackB:voiceC"
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelD = {
+  
+  \set Staff.instrumentName = "trackB:voiceB"
+  \skip 1 
+  | % 2
+  
+}
+
+trackBchannelE = \relative c {
+  \voiceOne
   <c''' a >2 b 
   | % 2
   
 }
 
-trackBchannelB = \relative {
+trackBchannelF = \relative c {
   \voiceThree
   c''4. d8 e4 f 
   | % 2
   
 }
 
-trackBchannelC = \relative {
+trackBchannelG = \relative c {
   \voiceFour
   d'1 
   | % 2
   
 }
 
-trackBchannelD = \relative {
+trackBchannelH = \relative c {
   \voiceTwo
   c'4 c2 c4 
   | % 2
@@ -78,6 +102,10 @@ trackB = <<
   \context Voice = voiceB \trackBchannelB
   \context Voice = voiceC \trackBchannelC
   \context Voice = voiceD \trackBchannelD
+  \context Voice = voiceE \trackBchannelE
+  \context Voice = voiceF \trackBchannelF
+  \context Voice = voiceG \trackBchannelG
+  \context Voice = voiceH \trackBchannelH
 >>
 
 
--- /home/yotam/pub/lilypond/input/regression/midi/voice-5.ly	2023-10-18 21:06:35.366721450 +0300
+++ out-test/recovered/voice-5-midi.ly	2024-07-19 18:27:57.454258805 +0300
@@ -1,19 +1,13 @@
-% Lily was here -- automatically converted by ../../../scripts/midi2ly.py from out-www/voice-4.midi
-\version "2.19.21"
+% Lily was here -- automatically converted by midi2ly.py from out-test/voice-5.midi
+\version "2.14.0"
 
 \layout {
   \context {
     \Voice
-    \remove "Note_heads_engraver"
-    \consists "Completion_heads_engraver"
-    \remove "Rest_engraver"
-    \consists "Completion_rest_engraver"
-  }
-}
-\midi {
-  \context {
-    \Score
-    midiChannelMapping = #'instrument
+    \remove Note_heads_engraver
+    \consists Completion_heads_engraver
+    \remove Rest_engraver
+    \consists Completion_rest_engraver
   }
 }
 
@@ -26,16 +20,14 @@ options=""
 
 trackAchannelA = {
   
-  % [SEQUENCE_TRACK_NAME] control track
-  
   % [TEXT_EVENT] creator: 
   
-  % [TEXT_EVENT] GNU LilyPond 2.13.54          
+  % [TEXT_EVENT] LilyPond 2.25.18              
   
   \time 4/4 
   
   \tempo 4 = 60 
-  
+  \skip 1*2 
 }
 
 trackA = <<
@@ -43,39 +35,69 @@ trackA = <<
 >>
 
 
-trackBchannelA = \relative {
-  \voiceOne
+trackBchannelA = {
   
-  \set Staff.instrumentName = ":1"
+  \set Staff.instrumentName = "trackB:voiceA"
+  \skip 1*2 
+}
+
+trackBchannelB = {
+  
+  \set Staff.instrumentName = "trackB:voiceE"
+  \skip 1*2 
+}
+
+trackBchannelC = {
+  
+  \set Staff.instrumentName = "trackB:voiceD"
+  \skip 1*2 
+}
+
+trackBchannelD = {
+  
+  \set Staff.instrumentName = "trackB:voiceC"
+  \skip 1*2 
+}
+
+trackBchannelE = {
+  
+  \set Staff.instrumentName = "trackB:voiceB"
+  \skip 1*2 
+}
+
+trackBchannelF = \relative c {
+  \voiceOne
   <c''' a >2 b 
   | % 2
   
 }
 
-trackBchannelB = \relative {
+trackBchannelG = \relative c {
   \voiceThree
   c''4. d8 e4 f 
   | % 2
   
 }
 
-trackBchannelC = \relative {
+trackBchannelH = \relative c {
   \voiceFour
   d'1 
   | % 2
   
 }
 
-trackBchannelD = \relative {
+trackBchannelI = \relative c {
   \voiceTwo
   c'4 c2 c4 
   | % 2
   
 }
 
-trackBchannelE = \relative {
-  s1 d1
+trackBchannelJ = \relative c {
+  r1 
   | % 2
+  d 
+  | % 3
   
 }
 
@@ -85,6 +107,11 @@ trackB = <<
   \context Voice = voiceC \trackBchannelC
   \context Voice = voiceD \trackBchannelD
   \context Voice = voiceE \trackBchannelE
+  \context Voice = voiceF \trackBchannelF
+  \context Voice = voiceG \trackBchannelG
+  \context Voice = voiceH \trackBchannelH
+  \context Voice = voiceI \trackBchannelI
+  \context Voice = voiceJ \trackBchannelJ
 >>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.