Opening PDF with Audiveris in MuseScore
Hi,
By using Audiveris and MuseSCore you can import PDFs in MuseScore, as shown here http://www.youtube.com/watch?v=n6x7KBA8BmM&feature=related
I'm trying to install Audiveris as a plugin in MuseScore as described here http://wiki.musichackday.org/index.php?title=MuseScore_PDF_import
Starting MuseScore I get the following message "C:/Program Files (x86)/MuseScore/plugins/audiveris.js in line 1: Syntax Error: Parse Error"
Line 1 define the location of Audiveris this way: var audiverisHome = "C:/Audiveris4.1beta";
Does anyone have any idea what might be the problem?
All help would be appreciated!
regards
Haakon Kvidal
email: post@musikkteknologi.no
web: www.musikkteknologi.no
Comments
Works just fine for me. I had to rename the Audivers dir though to match the entry in the plugin (could have done it in there instead)
Hey, lasconic: why isn't this plugin available on the plugins page ?
In reply to Works just fine for me by Jojo-Schmitz
Because Audiveris 4.1 is still in beta. The plugin was a quick hack during Music Hack Day Boston. Moreover it works only on Windows for the moment. So I don't want to expose it on the plugins page just yet.
In reply to Because Audiveris 4.1 is by [DELETED] 5
I believe to have found an issue with the plugin: it is lacking the init function. This seems only to lead to errors if it is the 1st plugin in the list, could that be? It usually would be the 2nd, after ABC-Import, but becomes the first when instelld in the user's plugin dir rather than the system one.
However, the fix is simple: just add an empty init function, like the plugin documentation says:
[code]
function init () {};
[/code]
BTW: I've translated it into German, attached
In reply to I believe to have found an by Jojo-Schmitz
init has been added. Good catch.
In reply to init has been added. Good by [DELETED] 5
It complains
It works though, sort of (the result is not as usefull as I hoped for).
Where to get that font and where to to it?
Well, actually this, again, is more an Audiveris problem, than one of the plugin... but maybe you know anyway?
In reply to It complains:[code] by Jojo-Schmitz
Can this be the font you ar e looking for http://www.coolfonts.info/font-5659-musicalsymbols.php
My fault! Used Notepad in Windows to edit the .js file, and your answer reminded me that Notpad aint’ the right tool. Edited the .js with Notepad++ and now the plugin is available in MuseScore. Thanks!
But: Seems like I can’t get Audiveris to perform the OMR process. Have tried with several PDFs and a .png fila but the analyzing process stops with: “Conversion failed: No MusicXML file generated” and last lines below reads:
Error in performing [SCALE, GRID, SPLIT, MEASURES, VERTICALS, HORIZONTALS, SYMBOLS, PATTERNS, PAGES, MERGE, EXPORT] [java.lang.NullPointerException]
omr.Main.doMain(Main.java:436) -- INFO: Checking 1 task(s)
omr.Main.doMain(Main.java:455) -- INFO: SHUTTING DOWN ...
In reply to My fault! Used Notepad in by haakonk
That seems to be more an Audiveris issues than a MuseScore one, isn't it?
In reply to My fault! Used Notepad in by haakonk
(corrected)
To get better error reports when importing an image, modify the file "audiveris.js" located in folder "plugins/audiveris" of MuseScore installation folder.
Around line #51 of file audiveris.js, before or after the "-batch" parameter line, insert the following line:
"-option log.Logger.printStackOnWarning=TRUE",
This option tells Audiveris to print out the call stack whenever an exception is encountered (this option will be on by default in next Audiveris release).
You can then publish the log in this MuseScore forum, or directly in Audiveris issues at http://kenai.com/projects/audiveris
/Hervé
In reply to Reporting Audiveris bugs by hbitteur
Thanks for the tip. I added this option in the plugin.
In reply to Reporting Audiveris bugs by hbitteur
My mistake! The correct constant name is omr.log.Logger.printStackOnWarning (and not log.Logger.printStackOnWarning as written too quickly in my previous post)
/Hervé
Corrected message:
To get better error reports when importing an image, modify the file "audiveris.js" located in folder "plugins/audiveris" of MuseScore installation folder.
Around line #51 of file audiveris.js, before or after the "-batch" parameter line, insert the following line:
"-option omr.log.Logger.printStackOnWarning=TRUE",
This option tells Audiveris to print out the call stack whenever an exception is encountered (this option will be on by default in next Audiveris release).
You can then publish the log in this MuseScore forum, or directly in Audiveris issues at http://kenai.com/projects/audiveris
In reply to Reporting Audiveris bugs (FIXED) by hbitteur
Actually it is in line 64.
In reply to Reporting Audiveris bugs (FIXED) by hbitteur
It's now fixed at github. Also added a link to Audiveris home.
You can download the plugin at : https://github.com/lasconic/Audiveris/zipball/master
In reply to It's now fixed at github. You by [DELETED] 5
you don't like my translation? Save for later?
Updated here
In reply to you don't like my by Jojo-Schmitz
I don't see the need to make the plugin more accessible in term of languages now. It's a small plugin, tied to Audiveris and Audiveris is still in heavy development. If one doesn't speak english or french, one will not report bugs to Audiveris.
In general, I don't support translations in my plugin. The current workflow for translation is too time consuming. When we will have an actual plugin manager and plugin translation integrated with e.g. http://translate.musescore.org that might change.
In reply to I don't see the need to make by [DELETED] 5
fair enough ;-)
Perhaps we should provide it with Audiveris zip archive.
For the time being, you can find MusicalSymbols.ttf on various sites, such as
http://simplythebest.net/fonts/fonts/musical_symbols.html
Simply install the font in standard windows/font folder.
Nota: The font is mandatory for Audiveris to work, even when run in batch mode, because some symbols characteristics are derived from the font itself.
/Hervé
Hello,
i have a similar problem and i really hope someone can make a suggestion since i'm no programmer, just following instructions works for me.
When trying to open the PDF with the audiveris plugin I get the following error:
"Error loading plug-in "C:/users/herairness/application data/local/muse/musescore/plugins line 90:
TypeError: Result of expression 'form' [null] is not an object."
Unfortunatelly I have no idea what it means, so any help would be appreciated!
In reply to similar error problem by herairnes
You probably didn't unzip all the plugin files at the right place. The program complains about a missing UI file. Try to install the plugin again and restart MuseScore. See Plugins to learn how to install a plugin.
In reply to You probably didn't unzip all by [DELETED] 5
Great, thanks, I had missed the ui. But now there's another error, which i don't get because I've set the path to the file and it's not read only or anything. Help?
"Conversion failed. No MusicXML file generated:
Unable to access jarfile D:/Audiveris4.1beta/dist/audiveris-4.1beta.jar"
In reply to fixed ui, new error by herairnes
And is that file at that spot? Probably not, so you need to edit the .js to point to the right location
In reply to fixed ui, new error by herairnes
Hello!
I have the same error with Audiveris in MuseScore when I tried open the PDF file with Audiveris (plugin):
Error
Conversion failed: No MusicXML file generated
Error: Unable to access jarfile D:/Audiveris4.1beta/dist/audiveris-4.1beta.jar
Solution
In audiveris.js file find this line with /*comments*/
/*********** MODIFY THIS VALUE *****************/
var audiverisHome = "D:/Audiveris4.1beta";
/*********** MODIFY THIS VALUE *****************/
and modify the directory where you have installed (unpacked) your Audiveris file (from Kenai website), for example: C:/Program Files/audiveris-4.1beta-full-20120201 and save the audiveris.js file.
With Best regards anta
In reply to fixed new error by anta
Hi,
I tried modifying the value, but the same error occurs:
Conversion failed: no MusicXML file generated
Unable to access jarfile C:Program Files (x86)AudiverisLtdaudiveris-4.1beta/dist/audiveris-4.1beta.jar
I edited the js file using notepad on my windows 7, do I need to use notepad++?
Here is how I edited it:
/*********** MODIFY THIS VALUE *****************/
var audiverisHome = "C:\Program Files (x86)\AudiverisLtd\audiveris-4.1beta";
/*********** MODIFY THIS VALUE *****************/
Thanks in advance!
In reply to still not working for me by gummyjeff
Try using
var audiverisHome = "C:/Program Files (x86)/AudiverisLtd\audiveris-4.1beta";
instead, i.e. / rather than \
In reply to / rather than \ by Jojo-Schmitz
I tried your suggestion and it gave me the same error. I'm going to reinstall and see if that changes anything. Thanks anyway!
In reply to didn't work again =[ by gummyjeff
Just in case it matters, Jojo's example had a mixture of "/" and "\" characters. I've not tried this but according to the previous post from Anta they all must be "/" forward slashes.
In reply to Just in case it matters, by schepers
Oh, sorry...
In reply to didn't work again =[ by gummyjeff
YAY! It turns out the problem was that I used musescore 1.1 before and I just needed to download 1.2. Also the forward slash (/) was needed instead of the backslash.
In reply to worked! by gummyjeff
After import and converted to MuseScore are the finished work editable? I see the last mail on this subject was last year.
Wena
In reply to Opening PDF with Audiveris in MuseScore by Wena D Parry
If you can get Audiveris to create a reasonable MusicXML file for you, then yes, importing that into MuseScore will create a normal editabke score just like any other. But do realize that optical score recognition software like Audiveris is still highly experimental technology, so don't expect miracles.
I didn't understand nothing to convert a pdf file in the program musescore.
Can you help me? Thanks :-)
In reply to Help me, please!!! by [DELETED] 830681
MuseScore can't convert PDF into any of its own formats (the upcoming version 2.0 might, not sure).
Audiveris can convert PDF to MusicXML and MuseScore can read that.
The plugin that is the topic of this thread is connecting the dot, i.e. calls audiveris with the PDF, lets it convert into MusicXML and opens that in MuseScore.
But don't expect too much, the result is not likely to be too usefull in most cases.
In reply to MuseScore can't convert PDF by Jojo-Schmitz
Ok, but I can't convert PDF to Music XML, can you explain me please?
In reply to Ok, but I can't convert PDF by [DELETED] 830681
Using Audivers and this MuseScore Plugin?
How does it fail, did you adjust the settings in the plugin, like decribed in this thread?
In reply to Using Audivers and this by Jojo-Schmitz
I put the plugin in MuseScore, but the plugin say Error: Unable to access jarfile D:/Audiveris4.1beta/dist/audiveris-4.1beta.jar; Why???
In reply to I put the plugin in by [DELETED] 830681
Is it there? Under this name?
If not you need to either put it there or modify the plugin code.
In reply to I put the plugin in by [DELETED] 830681
Did you install audiveris? Can you run it directly from your desktop? You don't really need the plugin for MuseScore - you can simply run Audiveris yourself, load the PDf, save as MusicXML, then load the MusicXML into MuseScore. The plugin just automates this.
But don't get your hopes up. The technology employed by Audiveris to try to "understand" a PDF and convert it to MusicXML is still very much experimental. It's still entirely likely that youd get better results faster entering a score by hand.
In reply to Did you install audiveris? by Marc Sabatella
@Mark
Have you tried latest Audiveris version (4.2) released just one month ago?
If not, please give it a try.
In reply to I put the plugin in by [DELETED] 830681
@Mario
1/ Make sure you download and install latest Audiveris version (4.2) from http://www.audiveris.org
2/ Adjust the plugin content so that it points to the precise location where you installed Audiveris.
I don't have the plugin source available right now, but I think I remember there is a line similar to the following:
var audiverisHome = <path-to-audiveris-jar-file>
You have to manually modify this <path-to-audiveris-jar-file> so that it points to Audiveris jar file
In reply to Fix path to Audiveris by hbitteur
hbitteur, I am no programmer, can you give me the correct line and where to find it in Musescroe, and which version of it. please.
Wena
In reply to Opening PDF with Audiveris in MuseScore by Wena D Parry
If you have that plugin already, you should know where you have put it.
If you don't have if, get it from https://github.com/lasconic/Audiveris/zipball/master, place it as per http://musescore.org/en/handbook/plugins, open the audiveris.js file with a text editor of your choice (e.g. WordPad, NotePad won't work) and modify is as per http://musescore.org/en/node/13597#comment-51977
In reply to Fix path to Audiveris by hbitteur
@hbitteur: I' just downloaded and installed Audiversi 4.2, modified the plugin code in 2 places (the path to the jar file and the name of the jar file) and tried to convete a PDF. I got an alert:
"
Runtime Error!
Program: C:\Womdows\system32\java.exe
R6034
An application has made an attempt to load the C runtime libtrary incorrectly,
Please contact the application's support team for more information.
"
I'm getting this twice. I get it too, when opening and transscribing the PDF in Audiveris directly, so it is not connected to anything the plugin does.
Here's the log:
omr.Main.process(Main.java:436) -- INFO: Running in batch mode
omr.Main.doMain(Main.java:132) -- INFO: Submitting 1 task(s)
omr.Main$1.call(Main.java:240) -- INFO: Launching [EXPORT] on C:/Dokumente und Einstellungen/Jojo/Eigene Dateien/Neue Wege/Web/011_Kommt_herbei,_singt_dem_Herrn.pdf
omr.sheet.picture.PictureLoader.loadImages(PictureLoader.java:96) -- INFO: Loading C:\Dokumente und Einstellungen\Jojo\Eigene Dateien\Neue Wege\Web\011_Kommt_herbei,_singt_dem_Herrn.pdf ...
omr.sheet.picture.PictureLoader.loadImageIO(PictureLoader.java:183) -- INFO: Loaded image #1 (2,479 x 3,508)
omr.step.Stepping.scheduleScoreStepSet(Stepping.java:592) -- INFO: scheduling [SCALE, GRID, SYSTEMS, MEASURES, TEXTS, STICKS, SYMBOLS, PAGES, SCORE, EXPORT]
omr.step.Stepping.notifyMsg(Stepping.java:539) -- INFO: SCALE
omr.sheet.ScaleBuilder.retrieveScale(ScaleBuilder.java:186) -- INFO: Binarization {GLOBAL threshold:140}
omr.sheet.ScaleBuilder.retrieveScale(ScaleBuilder.java:227) -- INFO: {Scale line:(1,2,3) interline:(16,18,21) beam:10}
omr.step.Stepping.notifyMsg(Stepping.java:539) -- INFO: GRID
omr.grid.LinesRetriever.retrieveLines(LinesRetriever.java:411) -- INFO: Global slope: 0
omr.grid.ClustersRetriever.buildInfo(ClustersRetriever.java:227) -- INFO: Retrieved line clusters: 4 of size: 5 with interline: 18
omr.grid.BarsRetriever.buildSystems(BarsRetriever.java:581) -- INFO: Systems top staff ids: [1, 1, 3, 4]
omr.grid.BarsRetriever.retrieveMeasureBars(BarsRetriever.java:268) -- INFO: Parts top staff ids: [1, 2, 3, 4]
omr.step.Stepping.notifyMsg(Stepping.java:539) -- INFO: SYSTEMS
omr.sheet.SystemsBuilder.reportResults(SystemsBuilder.java:360) -- INFO: 2 parts, 3 systems
omr.sheet.BorderBuilder.getRawBorder(BorderBuilder.java:411) -- WARNING: Border between systems S#1 & S#2 got closed at x:2,072 y:1,094
omr.step.Stepping.notifyMsg(Stepping.java:539) -- INFO: MEASURES
omr.score.entity.Page.dumpMeasureCounts(Page.java:195) -- INFO: 16 raw measures: [5 in system#1, 5 in system#2, 6 in system#3]
omr.step.Stepping.notifyMsg(Stepping.java:539) -- INFO: TEXTS
omr.Main.doMain(Main.java:139) -- INFO: Checking 1 task(s)
omr.Main.doMain(Main.java:146) -- WARNING: Future exception [java.util.concurrent.CancellationException]
java.util.concurrent.CancellationException
at java.util.concurrent.FutureTask$Sync.innerGet(Unknown Source)
at java.util.concurrent.FutureTask.get(Unknown Source)
at omr.Main.doMain(Main.java:144)
at Audiveris.main(Audiveris.java:47)
omr.Main.doMain(Main.java:167) -- WARNING: Exit with failure status
omr.step.ProcessingCancellationException: java.lang.InterruptedException
at omr.step.AbstractSystemStep.doitPerSystem(AbstractSystemStep.java:212)
at omr.step.AbstractSystemStep.doit(AbstractSystemStep.java:122)
at omr.step.AbstractStep.doStep(AbstractStep.java:103)
at omr.step.Stepping.doOneSheetStep(Stepping.java:103)
at omr.step.Stepping.doSheetStepSet(Stepping.java:517)
at omr.step.Stepping.doScoreStepSet(Stepping.java:493)
at omr.step.Stepping.scheduleScoreStepSet(Stepping.java:625)
at omr.step.Stepping.processScore(Stepping.java:279)
at omr.Main$1.call(Main.java:248)
at omr.Main$1.call(Main.java:234)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.InterruptedException
at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(Unknown Source)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerGet(Unknown Source)
at java.util.concurrent.FutureTask.get(Unknown Source)
at java.util.concurrent.AbstractExecutorService.invokeAll(Unknown Source)
at omr.step.AbstractSystemStep.doitPerSystem(AbstractSystemStep.java:209)
... 14 more
It did finish though and the result looks quite OK, much better that I had expected from past experience.
In reply to @hbitteur: I' just downloaded by Jojo-Schmitz
What Java version do you have running Jojo?
In reply to Java version by Thomas
1.7.0_09-b02
In reply to 1.7.0_09-b02 by Jojo-Schmitz
I think you need to switch back to 1.5 or 1.6.
In reply to 1.5-1.6 by Thomas
1.6 (actually 1.6.0_30-12) doesn't work at all:
java.lang.UnsupportedClassVersionError: Audiveris : Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(Unknown Source)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$000(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
Could not find the main class: Audiveris. Program will exit.
Exception in thread "main"
http://audiveris.kenai.com/docs/manual/handbook.html mentions that Java 1.7 is needed.
The latest and greates 1.7.0_10 doesn't solve the problem.
In reply to 1.6 (actually 1.6.0_30-12) by Jojo-Schmitz
I found the installing and use of audiveris very easy. the only thing I needed to do was to get a Java update to 7. 10. No need for updates. my platform is Windows XP and the MuseScore 1.2. As far as I can see there is no errors in the peace.
The document was a PDF I already had on my computer.
It may just be the good air hear in Wales!!!!
Wena
In reply to I found the installing and by Wena D Parry
Google hinted at my problem being related to VisualStudio and some Microsoft DLL.
Ok, I'm not able to do this, but if I give you the file http://www.scribd.com/doc/119335612, can you convert in format XML and send it to me to this email ms135@live.com please?? the file is not a virus
In reply to Ok, I'm not able to do this, by [DELETED] 830681
Just download audiveris and do it yourself, it's not that difficult.
You don't need the MuseScore plugin, but even getting that to work is not really difficult, it needs to get adjusted in 2 places for Audiveris 4.2
In reply to Just download audiveris and by Jojo-Schmitz
So what dos the plugin do?
I seem to have by passed it!
Wena
In reply to The plugin by Wena D Parry
It calls Audiveris in batchmode (i.e. without its GUI), feeds it a PDF and opens the resulting XML in MuseScore.
In reply to It calls Audiveris in by Jojo-Schmitz
ok, I open audiveris, I load the PDF file, I click on store and press export but nothing works
In reply to ok, I open audiveris, I load by [DELETED] 830681
I don't see 'Store'. Just 'Score'. I think you need to use 'Transscribe' first, then 'Export'?
The Audiveris manual might be of help here, ofline or online at http://audiveris.kenai.com/docs/manual/handbook.html
Hmm, apparently Score->Export is enough and creates an XML file
In reply to ok, I open audiveris, I load by [DELETED] 830681
Se hai già digitato Audiveris nella casella ricerca della pagina italiana ignora questa righe.
In caso contrario vai a dare un'occhiata, qualche spunto lo troverai.
Franz
In reply to Ciao Mario, by Shoichi
But audiveris have block the button transcrive...
For Shoichi= mi potresti aiutare tu almeno?? :-)
In reply to But audiveris have block the by [DELETED] 830681
Under Plugins in audiveris there is one that produces an xml for musecore.
I find that the ap don't seem to be able to see repeats. It often gets the time signature incorrect. I wonder if there is a system for reporting bugs?
It dose not seem to like one of my favorite peaces "Blaenwern" HAVE A GO ANY ONE!!!
Wena D Parry
Form South Wales, U.K.
In reply to But audiveris have block the by [DELETED] 830681
Skip to forum in Italian, we chat...
In reply to @Mario135 by Shoichi
Mario 135, read the attached , ciao, Franz
In reply to job done by Shoichi
CIao Shoichi, ho eseguito tutta la procedura ma, non mi esce niente. Se me lo puoi convertire ecco il file http://www.scribd.com/doc/119335612/7-Pdfsam-Mozart-Werke-Breitkopf-Ser… e per inviarmela ecco l'e-mail ms135@live.com ! Grazie
Is there someone who would be willing to help me and take the time to either convert 5 PDF's to xml for me, or show me how? My email is roblo1@aol.com I have tried using audiveris but i am too technically stupid. What I am trying to do is take 5 lead sheets to songs that just have the melody line and chord symbols and I want to actually write out the notes for the chords as I dont do well with chord symbols. Can someone be generous with their time and help me?
Thanks
In reply to PDF to xml problem by roblo1
Realistically, you'll get those lead sheets into MuseScore much faster and more accurately just entering the notes by hand. It isn't hard. Starting with the video tutorials on the main musescore.org page, then also check out my tutorial on lead sheets specifically at http://musescore.org/en/node/11723.
In reply to Realistically, you'll get by Marc Sabatella
Hi Marc
Thanks for writing, but maybe I am not explaining my problem well enough, I wanted to import them so I would have a starting point to write out the actual notes to the chords on staffs below the lead. Does that make sense???
In reply to Lead sheet by roblo1
It does make sense. I'm not talking about that second part - turning the chord symbols into notes. I'm just talking anout the first part - getting the notes from the lead sheet into MuseScore. And what I'm saying is, you'll almost certainly get better results faster simoly entering the motes by hand, as opposed to trying to get some sort of automatic reading of the PDF. It takes all of a few minutes to enter the notes for a lead sheet by hand, but you could easily spend hours or days fighting with scanners and PDF reading software to attempt to get anything at all onto MuseScore. and then you'd still need to spend time fixing up the results.
As an analogy, say you had a YouTube video of a two-minute speech, and you wanted to get a transcript of that speech into Microsoft Word. Well, you could either spend hours or days fighting with software that might be able to transcribe the speech from the video, and then still spend time correcting the mistakes the software would probably make - or you could simply type it in yourself. Typing it in yourslef would almost certainly get you better results faster. And it's the same with teyng to get music into MuseScore via PDF versus simply entering it yourself.
In reply to It does make sense. I'm not by Marc Sabatella
,for instance.
Each to his own, of course, but once I got used to MuseScore I found that trying to scan files, importing MP3s etc. was a waste of time. My best strategy to date is to use a wide monitor and have MS taking up the left and central 1/3s and an image of the original score on the right of the screen.
In reply to "Ish bin ein Ber<u>lee</u>ner" by underquark
Audiveris is a tool, as such one needs the skel to use it, I have had some good results with it and at the same time learnt a great deal on how to use MuseScore when having to edit the Audiveris tool.
Like MuseScore it is a development,
Wena