Skip to main content
Topic: NWCCONVERTOR (Read 70568 times) previous topic - next topic

Re: NWCCONVERTOR

Reply #100
b) And would it be possible that invisible notes are not emitted into the MusicXML file? I use especially invisible cue notes for some purposes which should not be visible anywhere - but MusicXML files transport them as normal visible notes, and then they turn up in e.g. MuseScore.
This could of course also be a checkbox in the "Options", e.g. "Ignore invisible notes".

If invisible notes are ingnored, should they be replaced by rests?
An example file with such invisible cue notes should also be helpful.
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #101
Hi HM,

If invisible notes are ingnored, should they be replaced by rests?
An example file with such invisible cue notes should also be helpful.

I noticed you used them in the previous files you provided.
Aside of being invisible, they're also grace notes and muted.
So maybe I should add a checkbox 'Convert invisible muted grace notes' in the 'Options' (default unticked)?
Always look on the bright side of life!


Re: NWCCONVERTOR

Reply #103
New version 1.0.7.3:
    - for "wavy line" with span = 1 : creating a "type=stop" element immediately after the "type=start" element.
    - new checkbox in 'OPTIONS': 'convert invisible muted grace notes', default unticked.

see https://www.opagust.be/content/nwcconvertor
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #104
Very good tool - but the first dialog opens at weird places. Now, after having converted 5 or 6 files, it opens almost fully outside my screen - see attachment. So I cannot click on it, and the standard keyboard bindings seem not to apply (Y or J for yes; N for no; Enter for the standard button) - game over  :D

Edit: Ah, could open it by reducing screen enlargement from 125% to 100% - see second attachment. However, one can see that the window is ridiculously large. I have attached the nwctxt input file producing this.

Edit 2: 26 staves - a large wind band - seem to be listed from left to right - see one more attachment ...

H.M.


Re: NWCCONVERTOR

Reply #106
Hi Harold,

I just took a quick look and here are my first findings:
  • The GUI tool I use sets the window size  to the maximum size of any part of it. In your case it's the 'Staves/Parts' tab of the 'Setup' window, where  the staff name + checkbox is shown for 26 staves.
    So I think I can solve this by limiting the number of staves per line. (So when setting that limit to 6, there would be 5 lines needed for 26  staves.)
  • I tried Musescore 3 and that didn't crash.
  • When I played it, I heard only piano. Maybe due to unchecked  'Send Patch' in the staves?
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #107
Thank you!

- First item  :)) .
- Second, I had not installed MS3 on my new laptop - did it, it worked (well enough), thank you for trying and telling me!
- Third, I do not need correct playback - it's just that a certain website requires a MusicXML to be added, so I needed one. For actual listening, I have a youtube link to a playback with NWC Viewer (and Reaper + some soundfonts for the actual sound).

H.M.

Re: NWCCONVERTOR 1.0.7.2

Reply #108
Trouble with a score ... this one says with ERROR. I do have a time signature in "P2, voice 1" as far as I can see. What's wrong?

(In case you ask about that spacer-filled staff: It is for somewhat more smooth playing in the Viewer, like so).

Thank you!
H.M.

Re: NWCCONVERTOR 1.0.7.2

Reply #109
I do have a time signature in "P2, voice 1" as far as I can see. What's wrong?

You have a (grace, invisible, muted) chords and rests before the time signature.
Code: [Select · Download]
!NoteWorthyComposerClip(2.751,Single)
|Clef|Type:Treble
|User|RangePitchMarker.hmm|Pos:7|Class:Span|Color:1
|Chord|Dur:Half,Grace|Pos:-6,6|Opts:Stem=Down,Lyric=Never,Muted|Visibility:Never
|Rest|Dur:Half,Grace|Visibility:Never
|User|RangePitchMarker.hmm|Pos:7|Class:Span|Color:7
|Chord|Dur:Half,Grace|Pos:-5,4|Opts:Stem=Down,Lyric=Never,Muted|Visibility:Always
|Rest|Dur:Half,Grace|Visibility:Always
|User|RangePitchMarker.hmm|Pos:7|Class:Span|Color:2|Visibility:Always
|Chord|Dur:Half,Grace|Pos:-2,1|Opts:Stem=Down,Lyric=Never,Muted|Visibility:Always
|Bar|Visibility:Always
|Boundary|Style:Reset|Visibility:TopStaff
|User|PageTxt.nw|Pos:0|Fnt:PageTitleText|PgCtrl:Once|XLoc:Center|PgStyle:Title|YLoc:Top|Text:%Title%|Visibility:TopStaff
|User|PageTxt.nw|Pos:0|Fnt:PageText|PgCtrl:Once|PgStyle:Author|Text:%Author%|YLoc:Top|CY:10|XLoc:Right|Visibility:TopStaff
|User|PageTxt.nw|Pos:0|Fnt:PageText|YLoc:Top|CY:4|PgStyle:Lyricist|XLoc:Left|Text:%Lyricist%|Visibility:TopStaff
|User|PageTxt.nw|Pos:0|Fnt:PageSmallText|YLoc:Bottom|CY:-6|PgStyle:Copyright|XLoc:Center|Text:%Copyright1%%br%%Copyright2%|Visibility:TopStaff
|User|Acciaccatura.ms|Pos:0|Class:StaffSig
|User|CueHeads.ms|Pos:1|Class:StaffSig|Size:70
|User|Melismatic.nw|Pos:0|Class:StaffSig
|Key|Signature:F#|Tonic:G
|TimeSig|Signature:2/4
!NoteWorthyComposerClip-End

My convertor doesn't seem to like that.

Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #110
Mhm. Seems I need to change my templates - these are RangePitchMarkers I use now at many places ... or I delete them manually (using GroupOps) to create specific "convertor nwctxt files"; that's probably what I'll do.

Thanks!
H.M.

Re: NWCCONVERTOR

Reply #111
Mhm. Seems I need to change my templates - these are RangePitchMarkers I use now at many places ... or I delete them manually (using GroupOps) to create specific "convertor nwctxt files"; that's probably what I'll do.

Thanks!
H.M.
Or you may move the time signature before the RangePitchMarkers?
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #112
Or you may move the time signature before the RangePitchMarkers?
I hesitate to do this, for two reasons ...

a) I have all the "fixed things" on the left (which includes the RangePitchMarkers), and then start with the piece (which includes the time sig).
b) The key signature goes before the time signature, so the key signature would be before the RangePitchMarkers, and then those would need full accidentals ... which, thinking about it, wouldn't be too bad anyway ...

... those staff headers anyway got too chaotic, so I might want to clean them up; and then see whether the (or - aha! - some (maybe invisible)!) time signature could go before them. More "clerical work" to do, instead of writing music ;-)

Thanks!
H.M.

Re: NWCCONVERTOR

Reply #113
Just found your converter and gave it a try for migrating NWC files to Notion and other programs. I’m quite impressed. Thanks for this!

Re: NWCCONVERTOR

Reply #114
One issue with the GUI: after completing a conversion and saving the file, the "Select a file to convert" button is disabled. In order to convert another file, I need to exit the converter and start it again for the button to re-enable. Dealing with multiple files to convert, it does slow things down. (Using version 1.0.7.4)

Another GUI recommendation, but minor: have an option to set a default output path, so that the save puts it there rather than defaulting to the input path. As well, currently, after changing the save path, the save destination becomes the default for the input path. Keeping them separate improves workflow.

(The conversions themselves seem really quite good so far!)

Re: NWCCONVERTOR

Reply #115
One issue with the GUI: after completing a conversion and saving the file, the "Select a file to convert" button is disabled. In order to convert another file, I need to exit the converter and start it again for the button to re-enable. Dealing with multiple files to convert, it does slow things down. (Using version 1.0.7.4)

Another GUI recommendation, but minor: have an option to set a default output path, so that the save puts it there rather than defaulting to the input path. As well, currently, after changing the save path, the save destination becomes the default for the input path. Keeping them separate improves workflow.

(The conversions themselves seem really quite good so far!)

I have been working on version 2.0 for some time now. The reason for that is the GUI software I was using (PySimpleGUI).
That software has changed its policy. Now it's necessary to get a paid license in order to distribute applications that use this GUI software.
This means I can't do any updates any more without switching to a different GUI software, since I don't want to get the paid license. And that's the case for all my user tools of the last years.

After some experimenting, I chose the PYSide6 GUI, but I had to do some learning with trial and error to master it.
And then I decided that NWCONVERSION would be the first user tool to be converted to that GUI.

It's now finished for about 80%.

So, about your comments:
 - Disabling the select button was a deliberate choice I made. Closing and restarting the tool is the safest way to to start over with a clean slate.
 - In this new version, in accordance to your suggestion, when selecting or saving a file the chosen folders will be saved in the configuration file in 4 different parameters, for each combination select/save and nwc -> musicxml/musicxml -> nwc.

Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #116
Hey Opagust,
Like many of us we're needing to find ways to exchange our NWC-based music to other folks who are using MusicXML.
I'd love to try your NWCConvertor, but can't register on https://www.opagust.be/user/register
I get
"403
Sorry, this page is only for people I recognize
Please introduce yourself"

But I can't login if I haven't registered (you'll probably see my attempt to reset my password, but I've never registered there, so I doubt it will work).
EDIT: Lawrie has set me straight. I can now get in with the login you mentioned at the very top of this post. Thanks, Lawrie!

I sometimes itch to get back to programming for music, but so many people have already solved my needs that I find little need to sweat over code any more! And my code with NWC was really messy!!

Re: NWCCONVERTOR

Reply #117
I'd love to try your NWCConvertor, but can't register on https://www.opagust.be/user/register
I get
"403
Sorry, this page is only for people I recognize
Please introduce yourself"

I recently made some security changes to diminish spam comments on the site. I must have set the register page unreachable for non registered users.
It's now working again.
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #118
A wish: Could NWCCONVERTOR replace rests and notes of lengths in the MusicXML which it does not understand with a "nearby length"? Examples:

- replace notes and rests with 3 or more dots with 2 dots;
- replace rests and notes that are shorter than 1/64th with a 64th;
- replace rests and notes that are longer than a whole note with a whole note?
- all this also in triplets
- ignore quintuplets etc.

Scanned music coming from Audiveris via e.g. MuseScore or Capella often contains spurious notes and rests to "make measures and time signatues fit". NWCCONVERTOR, if I understand it correctly, fails when it encounters them. It would be helpful it the (already garbled up) file just becomes a little more garbled up on output to NWCTXT, where I then would have to repair all the wrong things anyway.
In the attachment is an MXL file (inside the ZIP) which fails right now - I have added both the mxl file and the MuseScore file, maybe this is helpful; and an example of a measure with such "padding rests" that I would have to edit out.

Thank you!
Harald

Re: NWCCONVERTOR

Reply #119
A wish: Could NWCCONVERTOR replace rests and notes of lengths in the MusicXML which it does not understand with a "nearby length"? Examples:
....

Isn't it possible to correct the Musescore file, so it matches the scanned score and then export it as a mxl file and use that one as input for NWCCONVERTOR?
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #120
Isn't it possible to correct the Musescore file, so it matches the scanned score and then export it as a mxl file and use that one as input for NWCCONVERTOR?
Mhm ... well ... yeah ... Actually, I tried to learn MuseScore - I'm not bright enough, it seems. For correcting those rests, I actually asked there (https://musescore.org/en/comment/1246588#comment-1246588), but the answers are essentially "write it anew". For this one measure - ok (although it would take me, a MuseScore dummy, a minute?); but not for many more of such "shifting rests". I tried to load the MusicXML into Capella, with which I can work more or less ... but as the MusicXML is in itself partly broken (Audiveris seems to create such things), and Capella is worse than MuseScore in figuring out such broken files, this didn't work either. Maybe a tool chain Audiveris -> MuseScore (to repair) -> Capella (to edit) -> NWCConvertor -> NWC would work ... but you see what I get at?:

An NWCConvertor which is more forgiving would be a great help for me ... please! But I understand that this is not what you want to do - "prepping" NWCConvertor for arbitrarily broken files.

(In the end, I might rewrite the whole thing in NWC from scratch - now that would be quick :-) ).

H.M.

Re: NWCCONVERTOR

Reply #121
The error in NWCCONVERTOR occurred in the processing in which invisible rests are added to a measure to obtain the correct measure length. In this case no correct duration could be found.

As mentioned in one of the previous posts, I am working on version 2.0. However, I still want to test it more thoroughly before publishing them.

But I have now made a small adjustment to neglect incorrect durations during the fore-mentioned processing, the result of which can be found in the attachment.
Hopefully this can help you for now.
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #122
Absolutely a million thanks for this! - a few repair actions, and then - practice  :D

H.M.

Re: NWCCONVERTOR

Reply #123
Absolutely a million thanks for this! - a few repair actions, and then - practice  :D

H.M.

Glad it helped.
Thanks accepted, I'm not going to count them though.
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #124
Version 2.0 is now available on https://www.opagust.be/content/nwcconvertor

- New user interface
- Seperate menu choices for selecting Nwc or MusiXml file.
- Folders for selecting and saving are saved in the configuration file in 4 different parameters, for each combination select/save and nwc -> musicxml/musicxml -> nwc.
- Removing choise 'Convert'. The conversion will start when clicking 'OK' on the setup window.
- Neglecting incorrect durations in MusicXml file.
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #125
First attempt did not go well

The program didn't open - All I got was this error message

Traceback (most recent call last):
  File "nwc_convertor.py", line 839, in <module>
  File "nwc_convertor.py", line 811, in main
  File "general.py", line 99, in log
  File "general.py", line 632, in add_to_report
AttributeError: 'bool' object has no attribute 'loggings_frame'

The window title said "Unhandled exception in Script
Then
Failed to execute script 'nwc_converter'due to unhandled exception : 'bool' object has no attribute 'loggings frame'

All double dutch to me but you will know (I hope)

Rich

Rich.

Re: NWCCONVERTOR

Reply #126
The program tried to put a message in the logging frame that the new parameters were added in the configuration file.
 But the logging frame wasn't  yet created at that moment.
I modified the program, so that this message is no longer created.

You can now download the new version 2.0
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #127
Thanks

Works well now.

Only two comments so far - that is that in the parts/staves tab, your instruction is to click the pencil icon to change the properties.
1. There is no pencil icon, but clicking  in the empty edit box allows you to change properties.
2. If the program cannot convert and xml file to nwctxt then it gives the reasons in the warnings window but it doesn't say anything else. A message that at the end of the warnings saying not converted, please exit program would be useful. Also the ability to copy the warnings window would be useful for making corrections so that another attempt can be made after trying to make corrections.

I like the loggings window,

Cheers - great job.
Rich.

Re: NWCCONVERTOR

Reply #128
Thanks

Works well now.

Only two comments so far - that is that in the parts/staves tab, your instruction is to click the pencil icon to change the properties.
1. There is no pencil icon, but clicking  in the empty edit box allows you to change properties.
2. If the program cannot convert and xml file to nwctxt then it gives the reasons in the warnings window but it doesn't say anything else. A message that at the end of the warnings saying not converted, please exit program would be useful. Also the ability to copy the warnings window would be useful for making corrections so that another attempt can be made after trying to make corrections.

I like the loggings window,

Cheers - great job.

1. Pencil icon: download the icon from attachment and store it in the folder where nwcconvertor is placed.
2. Warnings are not a reason why the conversion can't complete. I tested with the file you did send me, there seems to be a bug in the processing of octave-shift tags. I think I know how to correct it. if I succeed, I'll send you the resulting output file.

I note the following for a future version 2.0.01:
- correct processing for octave-shift
- buttons beneath loggings and warnings frame 'Copy to clipboard'
- including the pencil_icon in the zip file.
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #129
Thanks - btw - pencil still does not show !

Rich.
Rich.


Re: NWCCONVERTOR

Reply #131
May I ask for a different color combination?
Or, better, the program adapting its colors to the OS theme?

P.S. thank you for the drag & drop!


Re: NWCCONVERTOR

Reply #133
Never had any doubt, but it all depends on the OS theme.
I like the dark one...

Re: NWCCONVERTOR

Reply #134
New version 2.0.02 in https://www.opagust.be/content/nwcconvertor
- some layout changes
- adding processing for attributes/transpose/octave-change
- correction bug for instrument object without 'patch' attribute

Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #135
Version 2.0.03 is available in https://www.opagust.be/content/nwcconvertor

- Correction of a typo that caused a fatal error (reported by William Ashworth).
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #136
Hey Gust, can you please add a mechanism to the captcha on your website to allow a user to ask for a new one - half the time I can't tell which case some of the letters are and it can take multiple attempts to get in.
I plays 'Bones, crumpets, coronets, floosgals, youfonymums 'n tubies.

Re: NWCCONVERTOR

Reply #137
Hey Gust, can you please add a mechanism to the captcha on your website to allow a user to ask for a new one - half the time I can't tell which case some of the letters are and it can take multiple attempts to get in.
If you press the login button without filling the captcha, you will get a new one (with a free error message :) )
Always look on the bright side of life!

Re: NWCCONVERTOR

Reply #138
Yes, but then you have to fill in the other fields again.

Sorry mate, just being a bit grumpy...
I plays 'Bones, crumpets, coronets, floosgals, youfonymums 'n tubies.

Re: NWCCONVERTOR

Reply #139
It would be helpful if the updating of the Convertor was carried out using a specific "updating" system, from within the Converter itelf,  rather than the downloading of a new version with the rather irritating logging-in procedure.
MusicJohn, 7/Nov/24

 

Re: NWCCONVERTOR

Reply #140
Hi Gust,

My belated thanks for your tool. Used it just now to convert a simple piece of mine to see how things look. The resulting MusicXML file opened without errors in MuseScore 4 and apparently requires minimal post editing.

I'm sure there is a valid reason behind saving the MusicXML file as NWCTXT but I admit it took a minute to figure it out. Afterwards it was a breeze.

Re: NWCCONVERTOR

Reply #141
Dear Opagust,

Today I tried the following scenario:

Open a PDF file in MuseScore Studio 4.xxx (latest version, downloaded today)
The conversion to a music file is done on the webpage https://musescore.com/import and after downloading the mscz-file I could open it in MuseScore Studio.
I exported the file as MXL file but when trying to convert it to NWC, the program seems to be pending.
I used your latest version (nwcconvertor-2.0.03.zip)
My only option is to exit the program.

It's unclear what is preventing the conversion of this file to the end.
Maybe I can bypass the blocking code by disabling something in MuseScore, but your help will be needed.
Screenshot of the pending situation is added as well as the mscz-file and mxl file (both included in the zipfile).

Thanks in advance.






Re: NWCCONVERTOR

Reply #143
Many thanks, Opagust.

I downloaded nwcconvertor-2.0.05.zip and tried it with another piece that was converted from PDF to mscz and further into mxl, and it worked perfectly.

Best regards,
Bart