Trying to make BEAST work with BEAGLE

3,251 views
Skip to first unread message

griffinia

unread,
Oct 13, 2010, 3:24:57 PM10/13/10
to beast-users
I am getting the following error message when I try to run BEAST under
BEAGLE, using the command line:

beast -beagle -beagle_CPU -beagle_instances 16 <MY XML FILE>

Error message:
Failed to load parser:
dr.app.beagle.evomodel.parsers.SVSGeneralSubstitutionModelParser
line =
dr.app.beagle.evomodel.parsers.SVSGeneralSubstitutionModelParser

I have the BEAGLE lib installed in the root/lib directory.

Can Marc or Aaron or anyone else tell me what BEAGLE is looking for?

Machine is 32-core AMD-64 running OPEN-SUSE Linux 11.2

Thanks,.
Alan

griffinia

unread,
Oct 13, 2010, 3:59:02 PM10/13/10
to beast-users
OK, the full error log didn;t write because my XML input was not in
unix format. When I converted, I got these additional erros:

Failed to load BEAGLE library: no hmsbeagle-jni in java.library.path
Error running file: Attaleineae_nopartition60.xml
Fatal exception: No acceptable BEAGLE library plugins found. Make sure
that BEAGLE is properly installed or try changing resource
requirements.
java.lang.RuntimeException: No acceptable BEAGLE library plugins
found. Make sure that BEAGLE is properly installed or try changing
resource requirements.
at beagle.BeagleFactory.loadBeagleInstance(Unknown Source)
at
dr.app.beagle.evomodel.treelikelihood.BeagleTreeLikelihood.<init>(Unknown
Source)
at
dr.app.beagle.evomodel.parsers.TreeLikelihoodParser.createTreeLikelihood(Unknown
Source)
at
dr.app.beagle.evomodel.parsers.TreeLikelihoodParser.parseXMLObject(Unknown
Source)
at dr.xml.AbstractXMLObjectParser.parseXMLObject(Unknown
Source)
at dr.xml.XMLParser.convert(Unknown Source)
at dr.xml.XMLParser.convert(Unknown Source)
at dr.xml.XMLParser.parse(Unknown Source)
at dr.app.beast.BeastMain.<init>(Unknown Source)
at dr.app.beast.BeastMain.main(Unknown Source)

So, clearly, I did not succeed in installing BEAGLE properly. Should
all of the files that BEAGLE needs be in a single directory? Should
BEAGLE plugins be in the same location as the BEAST executable? I
tried following the unix build instructions; had to install a number
of things missing such as libtool, javac, gcj, jikes - but I clearly
missed something. I finally got "./ configure" to run properly
without any errors, but I don't think the proper location was set for
the install. I ran "make install" and thought it ran properly the
first time (I tried again and it failed).

I am trying to install BEAGLE into a root folder called common.

Thanks,
Alan

Aaron Darling

unread,
Oct 13, 2010, 4:15:12 PM10/13/10
to beast-users
Hi Alan,

When you built and installed beagle, which directory did you choose for
installation? Did you specify a path with ./configure
--prefix=<installpath> ?
It looks like you ran beast using the beast shell script. That's fine,
but it's not finding beagle wherever it was installed. The shell script
in turn calls java to launch beast, and on the java command-line one
needs to have a -Djava.library.path= setting that gives the path to the
lib directory containing the beagle libs. It's also necessary to have
that same directory listed in the LD_LIBRARY_PATH environment variable
in Linux systems. Sorry if that wasn't obvious. What (if any)
instructions are you following for the beast/beagle usage? Perhaps they
can be fixed to clarify some of these issues.

Incidentally it should really only be necessary to have one working java
compiler, perhaps we can discuss off-list what went wrong that required
installation of all three of gcj, jikes, and sun java.

-Aaron

griffinia

unread,
Oct 13, 2010, 6:56:52 PM10/13/10
to beast-users
Aaron,

I am following the instructions from this page:
https://code.google.com/p/beagle-lib/wiki/UnixBuildInstructions

Initially, I had no Java compiler installed (the Java Runtime
Environment install, native in Open-SUSE, apparently doesn't include a
compiler). I didn't realize that I only needed to install one of them

I thought I specified a path correctly, also set the LD_LIBRARY_PATH
variable, but I did not know anything about the "-Djava.library.path="
statement, so that might be the problem.

The beagle/beast command line was the syntax that Marc Suchard posted
in reply to one of my earlier messages.

Alan

jcs

unread,
Oct 14, 2010, 10:46:24 AM10/14/10
to beast-users
I'm using OpenSUSE 11.3 with a single (and old) video card and use
this script to start up BEAST/BEAGLE:

java -Dbeagle.resource.order=1 -Djava.library.path=/usr/local/lib -cp
build/dist/beast.jar:lib/beagle.jar dr.app.beast.BeastMain -beagle

When I installed BEAGLE, I used:
./configure
instead of:
./configure -prefix=$HOME

So all the Beagle libraries (including the one you are missing) were
installed to /usr/local/lib (the default location). I also set the
LD_LIBRARY_PATH with the beagle lib locations.

griffinia

unread,
Oct 14, 2010, 2:32:48 PM10/14/10
to beast-users
jcs,

But I want to be sure and make use of multiple cores, so I need a
script that will also tell beagle to do that.

Alan

griffinia

unread,
Oct 14, 2010, 3:57:25 PM10/14/10
to beast-users
Eureka! Turns out I had an error in my LD_LIBRARY_PATH variable
statement that, once corrected, allowed the program to run. It is in
fact running right now, seemingly using half of my cores (16 of 32):
0.7 hour/million states. My 10 million state run should thus be
complete in 7 hours. Does that sound like multi-processor
performance? I have only run BEAST on Cornell's BIOHPC, and I can't
remember how long a run with this data set took.

Aaron, what I don't understand is that I did nothing with the "-
Djava.library.path=" statement. So Java must be finding the libs
without it.

Thanks to everyone who provided suggestions.

Alan

On Oct 13, 3:24 pm, griffinia <griffi...@gmail.com> wrote:

Aaron Darling

unread,
Oct 14, 2010, 4:17:05 PM10/14/10
to grif...@gmail.com, beast-users
Glad to hear it's working for you.

On Thu, 2010-10-14 at 12:57 -0700, griffinia wrote:

> Aaron, what I don't understand is that I did nothing with the "-
> Djava.library.path=" statement. So Java must be finding the libs
> without it.

I think I may have misspoke earlier when suggesting that both
-Djava.library.path and LD_LIBRARY_PATH need to be set. It seems like
just setting LD_LIBRARY_PATH is sufficient, as also indicated by this
document on Sun's web site:
http://java.sun.com/docs/books/jni/html/start.html


Reply all
Reply to author
Forward
0 new messages