Re: Beast/Beagle not using GPU

2,269 views
Skip to first unread message

Rupert Collins

unread,
Jun 4, 2013, 3:09:06 PM6/4/13
to beast...@googlegroups.com, pie...@regiondata.se
I am having the same issue as Pierre, so any help would be appreciated.

My Beagle library was compiled from source on Ubuntu 13.04.

Thanks


On 3 June 2013 08:42, Pierre <pie...@regiondata.se> wrote:
Hi,

I´m doing this job for a valued customer and have followed the installation guide. The OS is Debian 7.0 and Best/beagle is latest according to the guide. Everything seems peachy but it doesn't use the GPU.


Trying this command: java -Xmx2024m -d64 -Djava.library.path:/opt/beast/lib/ -Dbeagle.scaling=always -Dbeagle.resource.order=1,2 -cp /opt/beast/lib/beast.jar dr.app.beast.BeastMain -beagle_GPU -beagle_double -overwrite ./benchmark1.xml

That gives me:
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 0: CPU
    with instance flags:  PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALING_DYNAMIC SCALERS_LOG VECTOR_NONE PROCESSOR_GPU PROCESSOR_CELL
  Ignoring ambiguities in tree likelihood.
  With 593 unique site patterns.
  Using rescaling scheme : always
Likelihood computation is using an auto sizing thread pool.
Creating the MCMC chain:
  chainLength=100000
  autoOptimize=true
  autoOptimize delayed for 1000 steps


and this

./beast -beagle -seed 123456 -beagle_GPU /opt/beast/examples/Benchmarks/benchmark1.xml
...that gives me:
sing strict molecular clock model.
Creating state frequencies model 'frequencies': Initial frequencies = {0.25, 0.25, 0.25, 0.25}
Creating HKY substitution model. Initial kappa = 2.0
Creating site model.
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 0: CPU
    with instance flags:  PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALING_DYNAMIC SCALERS_LOG VECTOR_NONE PROCESSOR_GPU PROCESSOR_CELL
  Ignoring ambiguities in tree likelihood.
  With 593 unique site patterns.
  Using rescaling scheme : delayed
Likelihood computation is using an auto sizing thread pool.
Creating the MCMC chain:
  chainLength=100000


Cuda seems ok:
convolutionSeparable, Throughput = 4257.4563 MPixels/sec, Time = 0.00222 s, Size = 9437184 Pixels, NumDevsUsed = 1, Workgroup = 0

Reading back GPU results...

Checking the results...
 ...running convolutionRowCPU()
 ...running convolutionColumnCPU()
 ...comparing the results
 ...Relative L2 norm: 0.000000E+00

Shutting down...
Test passed


...and make check in beagle says everything passes.

Simulating genomic DNA with 16 taxa and 10000 site patterns (5 reps)

Using resource 0:
Rsrc Name : CPU
Impl Name : CPU-4State-Single
logL = -10398.97580 
best run: 0.003898s

Using resource 1:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -10398.97586 
best run: 0.000581s (6.71x CPU)

Using resource 2:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -10398.97586 
best run: 0.000580s (6.72x CPU)

Using resource 3:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -10398.97586 
best run: 0.000584s (6.67x CPU)

Using resource 4:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -10398.97586 
best run: 0.000591s (6.60x CPU)


Simulating genomic 64-state data with 10 taxa and 100 site patterns (5 reps)

Using resource 0:
Rsrc Name : CPU
Impl Name : CPU-Single
logL = -2149.11898 
best run: 0.029105s

Using resource 1:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -2149.11890 
best run: 0.000818s (35.58x CPU)

Using resource 2:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -2149.11890 
best run: 0.000817s (35.62x CPU)

Using resource 3:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -2149.11890 
best run: 0.000820s (35.49x CPU)

Using resource 4:
Rsrc Name : GeForce GTX 590
Impl Name : CUDA-Single
logL = -2149.11890 
best run: 0.000822s (35.41x CPU)

PASS: genomictest.sh
=============
1 test passed
=============

Could someone point me in the right direction? 

Regards

--
You received this message because you are subscribed to the Google Groups "beast-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.
To post to this group, send email to beast...@googlegroups.com.
Visit this group at http://groups.google.com/group/beast-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Eddie Salinas

unread,
Jun 4, 2013, 3:19:46 PM6/4/13
to beast...@googlegroups.com
NOT SURE IF THIS WILL BE HELPFUL.....

see library directory listing 
and beagle vs beagle_GPU

esalina@gtx590:~/Downloads/BEASTv1.7.1$ ll /home/esalina/lib/   ./lib/beast.jar 
-rw-r--r-- 1 esalina esalina 8048867 2012-03-15 17:30 ./lib/beast.jar

/home/esalina/lib/:
total 5468
drwxr-xr-x   3 esalina esalina    4096 2012-01-14 14:10 ./
drwxr-xr-x 143 esalina esalina   12288 2013-06-04 15:12 ../
-rwxr-xr-x   1 esalina esalina    1016 2012-01-14 14:10 libhmsbeagle-cpu.la*
lrwxrwxrwx   1 esalina esalina      25 2012-01-14 14:10 libhmsbeagle-cpu.so -> libhmsbeagle-cpu.so.1.0.0*
lrwxrwxrwx   1 esalina esalina      25 2012-01-14 14:10 libhmsbeagle-cpu.so.1 -> libhmsbeagle-cpu.so.1.0.0*
-rwxr-xr-x   1 esalina esalina  171116 2012-01-14 14:10 libhmsbeagle-cpu.so.1.0.0*
-rwxr-xr-x   1 esalina esalina    1040 2012-01-14 14:10 libhmsbeagle-cpu-sse.la*
lrwxrwxrwx   1 esalina esalina      29 2012-01-14 14:10 libhmsbeagle-cpu-sse.so -> libhmsbeagle-cpu-sse.so.1.0.0*
lrwxrwxrwx   1 esalina esalina      29 2012-01-14 14:10 libhmsbeagle-cpu-sse.so.1 -> libhmsbeagle-cpu-sse.so.1.0.0*
-rwxr-xr-x   1 esalina esalina  176724 2012-01-14 14:10 libhmsbeagle-cpu-sse.so.1.0.0*
-rwxr-xr-x   1 esalina esalina    1051 2012-01-14 14:10 libhmsbeagle-cuda.la*
lrwxrwxrwx   1 esalina esalina      26 2012-01-14 14:10 libhmsbeagle-cuda.so -> libhmsbeagle-cuda.so.1.0.0*
lrwxrwxrwx   1 esalina esalina      26 2012-01-14 14:10 libhmsbeagle-cuda.so.1 -> libhmsbeagle-cuda.so.1.0.0*
-rwxr-xr-x   1 esalina esalina 5126428 2012-01-14 14:10 libhmsbeagle-cuda.so.1.0.0*
-rwxr-xr-x   1 esalina esalina    1041 2012-01-14 14:10 libhmsbeagle-jni.la*
-rwxr-xr-x   1 esalina esalina   23747 2012-01-14 14:10 libhmsbeagle-jni.so*
-rwxr-xr-x   1 esalina esalina     992 2012-01-14 14:10 libhmsbeagle.la*
lrwxrwxrwx   1 esalina esalina      21 2012-01-14 14:10 libhmsbeagle.so -> libhmsbeagle.so.1.0.0*
lrwxrwxrwx   1 esalina esalina      21 2012-01-14 14:10 libhmsbeagle.so.1 -> libhmsbeagle.so.1.0.0*
-rwxr-xr-x   1 esalina esalina   49515 2012-01-14 14:10 libhmsbeagle.so.1.0.0*
drwxr-xr-x   2 esalina esalina    4096 2012-01-14 14:10 pkgconfig/
esalina@gtx590:~/Downloads/BEASTv1.7.1$ 



esalina@gtx590:~/Downloads/BEASTv1.7.1$ java -Djava.library.path=/home/esalina/lib/  -jar ./lib/beast.jar   -beagle   

                  BEAST v1.7.1, 2002-2012
       Bayesian Evolutionary Analysis Sampling Trees
                 Designed and developed by
   Alexei J. Drummond, Andrew Rambaut and Marc A. Suchard
                              
               Department of Computer Science
                   University of Auckland
                  ale...@cs.auckland.ac.nz
                              
             Institute of Evolutionary Biology
                  University of Edinburgh
                     a.ra...@ed.ac.uk
                              
              David Geffen School of Medicine
           University of California, Los Angeles
                     msuc...@ucla.edu
                              
                Downloads, Help & Resources:
                  http://beast.bio.ed.ac.uk
                              
Source code distributed under the GNU Lesser General Public License:
                              
                     BEAST developers:
Alex Alekseyenko, Trevor Bedford, Erik Bloomquist, Joseph Heled, 
Sebastian Hoehna, Denise Kuehnert, Philippe Lemey, Wai Lok Sibon Li, 
Gerton Lunter, Sidney Markowitz, Vladimir Minin, Michael Defoin Platel, 
          Oliver Pybus, Chieh-Hsi Wu, Walter Xie
                              
                         Thanks to:
    Roald Forsberg, Beth Shapiro and Korbinian Strimmer


Random number seed: 1332010462345


Parsing XML file: Flu.xml
  File encoding: UTF8
Looking for plugins in /home/esalina/Downloads/BEASTv1.7.1/plugins
Read alignment: alignment
  Sequences = 21
      Sites = 1698
   Datatype = nucleotide
Creating the tree model, 'treeModel'
  initial tree topology = (((((((GOOSE_SHANTOU_2216_2005,TREESPARROW_HENAN_3_2004),CK_HK_WF157_2003),(DUCK_GUANGZHOU_20_2005,DUCK_VIETNAM_272_2005)),((CHICKEN_HEBEI_326_2005,DUCK_HONGKONG_Y283_1997),(CHICKEN_THAILAND_KANCHANABURI_CK_160_2005,DUCK_VIETNAM_376_2005))),(((GOOSE_HONGKONG_W355_1997,TREESPARROW_HENAN_1_2004),(HONGKONG_1997_1998,VIETNAM_3062_2004)),HONGKONG_538_1997)),(MALLARD_VIETNAM_16_2003,PEREGRINEFALCON_HK_D0028_2004)),((((HUMAN_VIETNAM_CL105_2005,TREESPARROW_HENAN_2_2004),SWINE_ANHUI_2004),TREESPARROW_HENAN_4_2004),CHICKEN_HONGKONG_915_1997))
  tree height = 236.66556069828738
Bayesian skyline plot: 5 stepwise control points
Exponential markov model on parameter skyline.popSize (jeffreys=true, reverse=false)
Using strict molecular clock model.
Creating state frequencies model 'frequencies': Using empirical frequencies from data = {0.34816, 0.18626, 0.22924, 0.23635}
Creating HKY substitution model. Initial kappa = 1.0
Creating site model: 
  with initial relative rate = 1.0
Creating site model: 
  with initial relative rate = 1.0
Creating site model: 
  with initial relative rate = 1.0
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 0: CPU
    with instance flags:  PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_CPU
  Ignoring ambiguities in tree likelihood.
  With 70 unique site patterns.
  Using rescaling scheme : dynamic (rescaling every 10000 evaluations)
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 0: CPU
    with instance flags:  PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_CPU
  Ignoring ambiguities in tree likelihood.
  With 59 unique site patterns.
  Using rescaling scheme : dynamic (rescaling every 10000 evaluations)
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 0: CPU
    with instance flags:  PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_CPU
  Ignoring ambiguities in tree likelihood.
  With 148 unique site patterns.
  Using rescaling scheme : dynamic (rescaling every 10000 evaluations)
Parameter weights for delta exchange are: 566 566 566
Creating the MCMC chain:
  chainLength=3000000
  autoOptimize=true
  autoOptimize delayed for 30000 steps
# BEAST v1.7.1, r4860
# Generated Sat Mar 17 14:54:30 EDT 2012 [seed=1332010462345]
state Posterior   Prior       Likelihood   Root Height Rate        
0 -7913.8245   -142.2678   -7771.5568   236.666     4E-4         -
3000 -4512.7407   -134.7473   -4377.9934   60.8180     4.78687E-4   -
6000 -4502.4280   -125.6709   -4376.7571   47.0309     6.45214E-4   -
9000 -4492.6931   -120.8894   -4371.8036   31.5836     8.2965E-4   -
12000 -4484.0528   -109.9678   -4374.0850   25.0519     9.04848E-4   0.02 hours/million states
15000 -4488.4505   -110.9708   -4377.4798   28.9360     8.55997E-4   0.02 hours/million states
18000 -4483.4926   -111.4470   -4372.0456   26.1984     9.78232E-4   0.02 hours/million states
21000 -4489.8176   -115.8774   -4373.9402   30.4999     8.67411E-4   0.02 hours/million states
24000 -4484.4791   -110.4269   -4374.0521   25.5480     1.02287E-3   0.01 hours/million states
27000 -4485.1951   -109.6987   -4375.4964   27.9856     9.12672E-4   0.01 hours/million states
30000 -4484.1165   -107.7265   -4376.3900   24.8094     1.13959E-3   0.01 hours/million states
33000 -4492.3391   -116.9039   -4375.4352   26.0416     1.02524E-3   0.02 hours/million states
36000 -4475.0707   -100.2022   -4374.8685   22.4282     1.41576E-3   0.02 hours/million states
39000 -4480.6194   -102.1169   -4378.5025   21.7143     1.30581E-3   0.02 hours/million states
42000 -4475.6089   -103.6980   -4371.9109   22.6688     1.29696E-3   0.02 hours/million states
45000 -4466.6152   -96.7176     -4369.8976   20.1383     1.49185E-3   0.02 hours/million states
48000 -4474.2449   -103.3093   -4370.9356   20.0030     1.58137E-3   0.02 hours/million states
51000 -4464.9274   -89.8486     -4375.0788   16.6803     1.83184E-3   0.02 hours/million states
54000 -4452.7621   -87.2665     -4365.4956   15.6564     2.101E-3     0.02 hours/million states
57000 -4449.7697   -82.3427     -4367.4270   14.0061     2.541E-3     0.02 hours/million states
60000 -4444.2895   -78.8047     -4365.4848   12.6918     2.55291E-3   0.02 hours/million states
63000 -4443.1456   -79.2958     -4363.8498   11.8918     2.80812E-3   0.01 hours/million states
66000 -4440.2509   -76.7090     -4363.5419   11.6731     2.84517E-3   0.01 hours/million states
69000 -4444.1556   -73.4062     -4370.7494   10.7075     3.37344E-3   0.01 hours/million states
^Cesalina@gtx590:~/Downloads/BEASTv1.7.1$ less README.txt 







esalina@gtx590:~/Downloads/BEASTv1.7.1$ java -Djava.library.path=/home/esalina/lib/  -jar ./lib/beast.jar   -beagle_GPU   

                  BEAST v1.7.1, 2002-2012
       Bayesian Evolutionary Analysis Sampling Trees
                 Designed and developed by
   Alexei J. Drummond, Andrew Rambaut and Marc A. Suchard
                              
               Department of Computer Science
                   University of Auckland
                  ale...@cs.auckland.ac.nz
                              
             Institute of Evolutionary Biology
                  University of Edinburgh
                     a.ra...@ed.ac.uk
                              
              David Geffen School of Medicine
           University of California, Los Angeles
                     msuc...@ucla.edu
                              
                Downloads, Help & Resources:
                  http://beast.bio.ed.ac.uk
                              
Source code distributed under the GNU Lesser General Public License:
                              
                     BEAST developers:
Alex Alekseyenko, Trevor Bedford, Erik Bloomquist, Joseph Heled, 
Sebastian Hoehna, Denise Kuehnert, Philippe Lemey, Wai Lok Sibon Li, 
Gerton Lunter, Sidney Markowitz, Vladimir Minin, Michael Defoin Platel, 
          Oliver Pybus, Chieh-Hsi Wu, Walter Xie
                              
                         Thanks to:
    Roald Forsberg, Beth Shapiro and Korbinian Strimmer


Random number seed: 1332010490996


Parsing XML file: Flu.xml
  File encoding: UTF8
Looking for plugins in /home/esalina/Downloads/BEASTv1.7.1/plugins
Read alignment: alignment
  Sequences = 21
      Sites = 1698
   Datatype = nucleotide
Creating the tree model, 'treeModel'
  initial tree topology = (((((((((MALLARD_VIETNAM_16_2003,TREESPARROW_HENAN_2_2004),SWINE_ANHUI_2004),TREESPARROW_HENAN_3_2004),PEREGRINEFALCON_HK_D0028_2004),GOOSE_HONGKONG_W355_1997),((((DUCK_VIETNAM_272_2005,HUMAN_VIETNAM_CL105_2005),TREESPARROW_HENAN_4_2004),CHICKEN_THAILAND_KANCHANABURI_CK_160_2005),CHICKEN_HONGKONG_915_1997)),((TREESPARROW_HENAN_1_2004,VIETNAM_3062_2004),DUCK_VIETNAM_376_2005)),(((CHICKEN_HEBEI_326_2005,DUCK_GUANGZHOU_20_2005),DUCK_HONGKONG_Y283_1997),HONGKONG_538_1997)),((GOOSE_SHANTOU_2216_2005,HONGKONG_1997_1998),CK_HK_WF157_2003))
  tree height = 209.91290920859967
Bayesian skyline plot: 5 stepwise control points
Exponential markov model on parameter skyline.popSize (jeffreys=true, reverse=false)
Using strict molecular clock model.
Creating state frequencies model 'frequencies': Using empirical frequencies from data = {0.34816, 0.18626, 0.22924, 0.23635}
Creating HKY substitution model. Initial kappa = 1.0
Creating site model: 
  with initial relative rate = 1.0
Creating site model: 
  with initial relative rate = 1.0
Creating site model: 
  with initial relative rate = 1.0
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 1: GeForce GTX 590
    Global memory (MB): 1536
    Clock speed (Ghz): 1.26
    Number of cores: 512
    with instance flags:  PRECISION_SINGLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_GPU
  Ignoring ambiguities in tree likelihood.
  With 70 unique site patterns.
  Using rescaling scheme : dynamic (rescaling every 10000 evaluations)
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 1: GeForce GTX 590
    Global memory (MB): 1536
    Clock speed (Ghz): 1.26
    Number of cores: 512
    with instance flags:  PRECISION_SINGLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_GPU
  Ignoring ambiguities in tree likelihood.
  With 59 unique site patterns.
  Using rescaling scheme : dynamic (rescaling every 10000 evaluations)
Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 1: GeForce GTX 590
    Global memory (MB): 1536
    Clock speed (Ghz): 1.26
    Number of cores: 512
    with instance flags:  PRECISION_SINGLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_GPU
  Ignoring ambiguities in tree likelihood.
  With 148 unique site patterns.
  Using rescaling scheme : dynamic (rescaling every 10000 evaluations)
Parameter weights for delta exchange are: 566 566 566
Parsing error - poorly formed BEAST file, Flu.xml:
Error parsing '<log>' element with id, 'fileLog':

The log file Flu.log already exists in the working directory.
To allow it to be overwritten, use the '-overwrite' command line option when running
BEAST or select the option in the Run Options dialog box as appropriate.
esalina@gtx590:~/Downloads/BEASTv1.7.1$ find .|grep -Pi 'flu.log'
./Flu.log
esalina@gtx590:~/Downloads/BEASTv1.7.1$ rm -vi Flu.log 
rm: remove regular file `Flu.log'? y

Batra, Dhwani (CDC/OID/NCIRD) (CTR)

unread,
Jun 4, 2013, 5:20:34 PM6/4/13
to beast...@googlegroups.com

Can you send the output of

 

java -Xmx2024m -d64 -Djava.library.path:/opt/beast/lib/ -Dbeagle.scaling=always -Dbeagle.resource.order=1,2 -cp /opt/beast/lib/beast.jar dr.app.beast.BeastMain -beagle_info

Anthony Weaver

unread,
Jun 7, 2013, 8:29:01 AM6/7/13
to beast...@googlegroups.com
Hello,

  I am also having the same problem.  I am using Beast1.7.5 on a Mint Linux box.  I ran the command given by dhwani and can see that my GPU is an available resource (see output given below), but every time I try to run Beast with Beagle to use my GPU, it outputs that it is using resource 0, my CPU and not my GPU even though I select it.  Is it possible that Beast 1.7.5 does not work correctly with GPUs?

OUTPUT FROM JAVA COMMAND given by dhwani:

BEAGLE resources available:
0 : CPU
    Flags: PRECISION_SINGLE PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL EIGEN_COMPLEX SCALING_MANUAL SCALING_AUTO SCALING_ALWAYS SCALING_DYNAMIC SCALERS_RAW SCALERS_LOG VECTOR_SSE VECTOR_NONE THREADING_OPENMP THREADING_NONE PROCESSOR_GPU PROCESSOR_CELL


1 : GeForce GTX 650 Ti
    Global memory (MB): 1023
    Clock speed (Ghz): 0.97
    Number of cores: 768
    Flags: PRECISION_SINGLE PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL EIGEN_COMPLEX SCALING_MANUAL SCALING_AUTO SCALING_ALWAYS SCALERS_RAW SCALERS_LOG VECTOR_SSE VECTOR_NONE THREADING_OPENMP PROCESSOR_GPU PROCESSOR_CELL



Tony

Andrew Rambaut

unread,
Jun 7, 2013, 8:34:54 AM6/7/13
to beast...@googlegroups.com
Does it run on the GPU with the options: -beagle_gpu -beagle_single?

Andrew

Tony Weaver

unread,
Jun 7, 2013, 8:38:48 AM6/7/13
to beast...@googlegroups.com
Andrew,

No it still says it is using resource 0 CPU

Tony

Andrew Rambaut

unread,
Jun 7, 2013, 8:40:07 AM6/7/13
to beast...@googlegroups.com
what about: -beagle_order 1 (no other beagle related commands)?

A.

Tony Weaver

unread,
Jun 7, 2013, 8:48:01 AM6/7/13
to beast...@googlegroups.com
Andrew,

I ran: java -Xmx2024m -d64 -Djava.library.path:/usr/local/BEAS1.7.5/lib/ -cp /usr/local/BEASTv1.7.5/lib/beast.jar dr.app.beast.BeastMain -beagle_order 1. It still used the CPU. The java GUI had CPU selected when I ran it. I re-ran it again, but selected GPU and single precision and it still says it is using CPU. Thank you for your help

Tony

Andrew Rambaut

unread,
Jun 7, 2013, 8:53:41 AM6/7/13
to beast...@googlegroups.com
Hmm. The -Djava.library.path option is wrong. It should be (note the '=' rather than ':'):

-Djava.library.path="/usr/local/BEAS1.7.5/lib:/usr/local/lib"

Although I the fact is was finding the BEAGLE library means this isn't the issue (the command you give creates a property called 'java.library.path:/usr/local/BEAS1.7.5/lib/' which will just be ignored).

Did you install BEAGLE by compiling the source code? If you did, run 'make check' from the BEAGLE directory and see if that runs anything on the GPU.

Andrew

Tony Weaver

unread,
Jun 7, 2013, 8:58:57 AM6/7/13
to beast...@googlegroups.com
Andrew

I did compile from source code and just like Pierre reported in his original post, make check passes all test and indicates that the GPU is there and it works. Here is a small part of that output from make check:


Making check in matrixtest
make[2]: Entering directory `/home/superman/beagle-lib/examples/matrixtest'
make matrixtest
make[3]: Entering directory `/home/superman/beagle-lib/examples/matrixtest'
make[3]: `matrixtest' is up to date.
make[3]: Leaving directory `/home/superman/beagle-lib/examples/matrixtest'
make check-TESTS
make[3]: Entering directory `/home/superman/beagle-lib/examples/matrixtest'
Using resource 1:
Rsrc Name : GeForce GTX 650 Ti
Impl : CUDA-Single
Impl Desc : none

logL = -1574.63611 (PAUP = -1574.63623)

PASS: matrixtest
e is a small part of that output showing that:

Tony

Rupert Collins

unread,
Jun 7, 2013, 9:08:10 AM6/7/13
to beast...@googlegroups.com
I'm having the same experience as Tony. My beagle library was also compiled from source on Linux.

All tests pass when running 'make check', but the GPU is never used when I run beast, even with the '-beagle_gpu' and '-beagle_order 1' commands as suggested.

Cheers.


To unsubscribe from this group and stop receiving emails from it, send an email to beast-users+unsubscribe@googlegroups.com.

To post to this group, send email to beast...@googlegroups.com.
Visit this group at http://groups.google.com/group/beast-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
   
--
You received this message because you are subscribed to the Google Groups "beast-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beast-users+unsubscribe@googlegroups.com.

To post to this group, send email to beast...@googlegroups.com.
Visit this group at http://groups.google.com/group/beast-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


--
You received this message because you are subscribed to the Google Groups "beast-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beast-users+unsubscribe@googlegroups.com.

To post to this group, send email to beast...@googlegroups.com.
Visit this group at http://groups.google.com/group/beast-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.



--
You received this message because you are subscribed to the Google Groups "beast-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beast-users+unsubscribe@googlegroups.com.

Andrew Rambaut

unread,
Jun 7, 2013, 9:11:51 AM6/7/13
to beast...@googlegroups.com
I think a bug has been introduced into BEAGLE in the latest revisions. I am looking into it.

Andrew
> To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.
> To post to this group, send email to beast...@googlegroups.com.
> Visit this group at http://groups.google.com/group/beast-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
> --
> You received this message because you are subscribed to the Google Groups "beast-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.
> To post to this group, send email to beast...@googlegroups.com.
> Visit this group at http://groups.google.com/group/beast-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
> --
> You received this message because you are subscribed to the Google Groups "beast-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.
> To post to this group, send email to beast...@googlegroups.com.
> Visit this group at http://groups.google.com/group/beast-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
> --
> You received this message because you are subscribed to the Google Groups "beast-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.
> To post to this group, send email to beast...@googlegroups.com.
> Visit this group at http://groups.google.com/group/beast-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
>
> --
> You received this message because you are subscribed to the Google Groups "beast-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to beast-users...@googlegroups.com.

Kurt Wollenberg

unread,
Jun 7, 2013, 10:08:19 AM6/7/13
to beast-users
Hello:

I think this is a more general error with Beagle. I am getting it when I run an analysis on my Mac desktop (OS 10.6.8) and check the BEAGLE box on the BEAST interface and explicitly choose to use the GPU processor:


Using BEAGLE TreeLikelihood
  Branch rate model used: strictClockBranchRates
  Using BEAGLE resource 0: CPU
    with instance flags:  PRECISION_DOUBLE COMPUTATION_SYNCH EIGEN_REAL SCALING_MANUAL SCALERS_RAW VECTOR_NONE THREADING_NONE PROCESSOR_CPU

  Ignoring ambiguities in tree likelihood.
  With 1 unique site patterns.
  Using rescaling scheme : delayed

Sorry I didn't jump in earlier but I only just realized this was an error.
Cheers,
Kurt Wollenberg

The most exciting phrase to hear in science, the one that heralds new discoveries, is not "Eureka!" (I found it!) but  "That's funny ..." --Isaac Asimov

Andrew Rambaut

unread,
Jun 7, 2013, 10:13:55 AM6/7/13
to beast...@googlegroups.com
This looks like a bug introduced in BEAGLE quite recently. It is only affecting people downloading and compiling the very latest version. If you are doing doing source code compile it is better to checkout the latest release version:

svn checkout https://beagle-lib.googlecode.com/svn/tags/beagle_release_1_1

Hopefully the bug will be fixed shortly.

Andrew

Andrew Rambaut

unread,
Jun 7, 2013, 10:43:47 AM6/7/13
to beast...@googlegroups.com
I think this is now fixed if anyone wants to try updating their BEAGLE library. I still suggest that unless you really want to live on the edge, you checkout the 1.1 release version.

Andrew

On 7 Jun 2013, at 15:08, Kurt Wollenberg <kurt.wo...@gmail.com> wrote:

Eddie Salinas

unread,
Jun 8, 2013, 7:38:10 AM6/8/13
to beast...@googlegroups.com
ON THE EDGE!!!!

Rupert Collins

unread,
Jun 8, 2013, 3:09:33 PM6/8/13
to beast...@googlegroups.com
Thank you Andrew. GPU is now working, following your help.

Much appreciated.

Kurt Wollenberg

unread,
Jun 10, 2013, 2:16:18 PM6/10/13
to beast-users
Hello:

I've been having the same issue with the installation of BEAST v1.7.5 with BEAGLE v1.0 on my Mac quad-core Xeon desktop with the standard GeForce GT120 graphics card. When I run BEAST without an input file and choose "use BEAGLE", use GPU , and "Show list of available BEAGLE resources" the program indicates it can find my graphics card. I have the latest CUDA drivers installed. When I run an analysis that requires BEAGLE (ancestral state reconstruction) and tell the program to use the GPU with double precision I get the "Using BEAGLE resource 0: CPU" message at the beginning of the analysis. Is this an error or does the program just not run on the GPU with this card? I tried updating with the latest available version of the BEAGLE-1.0.pkg from code.google.com but that didn't fix this. I also tried installing from source using the svn checkout command but this process couldn't find the CUDA drivers and I couldn't find them to supply a correct path. Is this something I should be pursuing or is using BEAGLE GPU acceleration just not going to work with my desktop setup?

Tony Weaver

unread,
Jun 10, 2013, 2:20:27 PM6/10/13
to beast...@googlegroups.com
Kurt,

  If you are building from source did you do a make clean before you built BEAGLE from the latest version?  If not, it might be that you are still using an older version.

Tony
You received this message because you are subscribed to a topic in the Google Groups "beast-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/beast-users/f1WFyeEk6X4/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to beast-users...@googlegroups.com.

Rupert Collins

unread,
Jun 10, 2013, 6:38:14 PM6/10/13
to beast...@googlegroups.com
Before reinstalling, I went into the 'beagle-lib' directory and ran 'sudo make uninstall', which removed the existing libraries.

I then deleted the 'beagle-lib' directory and grabbed the latest revision (1111) from the SVN repo: 'svn checkout http://beagle-lib.googlecode.com/svn/trunk/ beagle-lib'.

I installed again, as per normal, but I found that BEAGLE required a directory called 'NVIDIA_CUDA-5.0_Samples' which I had deleted from the place that I initially installed CUDA from. Once I temporarily restored this directory, it all worked perfectly.

Hope this helps.

antoine_UCSD

unread,
Jun 20, 2013, 5:04:08 PM6/20/13
to beast...@googlegroups.com
Hi
I tried to update Beagle on my Mac following your procedure BUT when I ran the latest command line to check my installation ("sudo make check")
I have an error message "FAIL: genomictest.sh"

# TOTAL: 1
# PASS:  0
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

FAIL: genomictest.sh
====================

CUDA error: "Driver not initialized" from file <GPUInterfaceCUDA.cpp>, line 171.

Simulating genomic DNA with 16 taxa and 10000 site patterns (5 reps)

CUDA error: "Driver not initialized" from file <GPUInterfaceCUDA.cpp>, line 171.

Simulating genomic 64-state data with 10 taxa and 100 site patterns (5 reps)


Any idea to fix it? (I am hardly an expert...)
Thx

Antoine

Eddie Salinas

unread,
Jun 20, 2013, 7:06:07 PM6/20/13
to beast...@googlegroups.com
Not sure if you've had your GPU correctly installed and a driver loaded properly?
I run /usr/bin/nvidia-smi and get information
esalina@gtx590:/usr/bin$ /usr/bin/nvidia-smi 
Thu Jun 20 19:03:16 2013       
+------------------------------------------------------+                       
| NVIDIA-SMI 5.319.23   Driver Version: 319.23         |                       
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GTX 590     Off  | 0000:05:00.0     N/A |                  N/A |
|  0%   43C  N/A     N/A /  N/A |        4MB /  1535MB |     N/A      Default |
+-------------------------------+----------------------+----------------------+
|   1  GeForce GTX 590     Off  | 0000:06:00.0     N/A |                  N/A |
| 40%   45C  N/A     N/A /  N/A |      175MB /  1535MB |     N/A      Default |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Compute processes:                                               GPU Memory |
|  GPU       PID  Process name                                     Usage      |
|=============================================================================|
|    0            Not Supported                                               |
|    1            Not Supported                                               |
+-----------------------------------------------------------------------------+
esalina@gtx590:/usr/bin$ 

also, I can run the "deviceQuery" program that was with the SDK
esalina@gtx590:~$ ~/NVIDIA_CUDA-5.0_Samples/1_Utilities/deviceQuery/deviceQuery 
/home/esalina/NVIDIA_CUDA-5.0_Samples/1_Utilities/deviceQuery/deviceQuery Starting...

 CUDA Device Query (Runtime API) version (CUDART static linking)

Detected 2 CUDA Capable device(s)

Device 0: "GeForce GTX 590"
  CUDA Driver Version / Runtime Version          5.5 / 5.0
  CUDA Capability Major/Minor version number:    2.0
  Total amount of global memory:                 1536 MBytes (1610285056 bytes)
  (16) Multiprocessors x ( 32) CUDA Cores/MP:    512 CUDA Cores
  GPU Clock rate:                                1260 MHz (1.26 GHz)
  Memory Clock rate:                             1728 Mhz
  Memory Bus Width:                              384-bit
  L2 Cache Size:                                 786432 bytes
  Max Texture Dimension Size (x,y,z)             1D=(65536), 2D=(65536,65535), 3D=(2048,2048,2048)
  Max Layered Texture Size (dim) x layers        1D=(16384) x 2048, 2D=(16384,16384) x 2048
  Total amount of constant memory:               65536 bytes
  Total amount of shared memory per block:       49152 bytes
  Total number of registers available per block: 32768
  Warp size:                                     32
  Maximum number of threads per multiprocessor:  1536
  Maximum number of threads per block:           1024
  Maximum sizes of each dimension of a block:    1024 x 1024 x 64
  Maximum sizes of each dimension of a grid:     65535 x 65535 x 65535
  Maximum memory pitch:                          2147483647 bytes
  Texture alignment:                             512 bytes
  Concurrent copy and kernel execution:          Yes with 1 copy engine(s)
  Run time limit on kernels:                     No
  Integrated GPU sharing Host Memory:            No
  Support host page-locked memory mapping:       Yes
  Alignment requirement for Surfaces:            Yes
  Device has ECC support:                        Disabled
  Device supports Unified Addressing (UVA):      Yes
  Device PCI Bus ID / PCI location ID:           5 / 0
  Compute Mode:
     < Default (multiple host threads can use ::cudaSetDevice() with device simultaneously) >

Device 1: "GeForce GTX 590"
  CUDA Driver Version / Runtime Version          5.5 / 5.0
  CUDA Capability Major/Minor version number:    2.0
  Total amount of global memory:                 1535 MBytes (1609760768 bytes)
  (16) Multiprocessors x ( 32) CUDA Cores/MP:    512 CUDA Cores
  GPU Clock rate:                                1260 MHz (1.26 GHz)
  Memory Clock rate:                             1728 Mhz
  Memory Bus Width:                              384-bit
  L2 Cache Size:                                 786432 bytes
  Max Texture Dimension Size (x,y,z)             1D=(65536), 2D=(65536,65535), 3D=(2048,2048,2048)
  Max Layered Texture Size (dim) x layers        1D=(16384) x 2048, 2D=(16384,16384) x 2048
  Total amount of constant memory:               65536 bytes
  Total amount of shared memory per block:       49152 bytes
  Total number of registers available per block: 32768
  Warp size:                                     32
  Maximum number of threads per multiprocessor:  1536
  Maximum number of threads per block:           1024
  Maximum sizes of each dimension of a block:    1024 x 1024 x 64
  Maximum sizes of each dimension of a grid:     65535 x 65535 x 65535
  Maximum memory pitch:                          2147483647 bytes
  Texture alignment:                             512 bytes
  Concurrent copy and kernel execution:          Yes with 1 copy engine(s)
  Run time limit on kernels:                     Yes
  Integrated GPU sharing Host Memory:            No
  Support host page-locked memory mapping:       Yes
  Alignment requirement for Surfaces:            Yes
  Device has ECC support:                        Disabled
  Device supports Unified Addressing (UVA):      Yes
  Device PCI Bus ID / PCI location ID:           6 / 0
  Compute Mode:
     < Default (multiple host threads can use ::cudaSetDevice() with device simultaneously) >

deviceQuery, CUDA Driver = CUDART, CUDA Driver Version = 5.5, CUDA Runtime Version = 5.0, NumDevs = 2, Device0 = GeForce GTX 590, Device1 = GeForce GTX 590
esalina@gtx590:~$ 



antoine_UCSD

unread,
Jun 20, 2013, 7:16:30 PM6/20/13
to beast...@googlegroups.com
Thx.
I think it is an issue with my GPU...
I am a Mac user and when I check CUDA and GPU driver version in the preference/CUDA folder, CUDA driver is uptodate (v5.0.61) BUT no version of GPU Driver Version was found. I did not find the install package on their website for Mac (FYI: I have the latest 13 retina Macbook pro)
A

Kurt Wollenberg

unread,
Jun 28, 2013, 1:43:52 PM6/28/13
to beast-users
Hello again:

So I finally got my desktop system upgraded so I could use the latest CUDA drivers (5.0.61) and finally got everything re-installed and running. When I test my BEAGLE installation it finds my CPU and graphics card. Now when I run my BEAST+BEAGLE test run (which runs using the GPU on our cluster) I still get "Using BEAGLE resource 0: CPU". My computer is a Mac Pro Quad core Xeon running 10.8.4. Could it be that my graphics card (the standard NVIDIA GeForce GT 120 with 512 MB) is deemed too weak by BEAGLE and therefore ignored? If this is true, is there some way I would know this without have to ask the entire user community?


Eddie Salinas

unread,
Jun 28, 2013, 2:19:13 PM6/28/13
to beast...@googlegroups.com

This is just an idea....

See if you can drill diwn into the scripts and find where the commands that launch the test are located.   Look for issues/parameters related to gpu.....take in/out settings and see if you can get test to NOT use the gpu. Experiment similarly in the command you're trying to get to run to get gpu to work.  Since test is successfully using Gpu try to figure out settings/parameters that permit gpu usage.

-eddie

Eddie Salinas

unread,
Jun 28, 2013, 2:51:00 PM6/28/13
to beast...@googlegroups.com

Maybe fruitful to add "env" command and compare environmental settings?

-eddie

Kurt Wollenberg

unread,
Jun 28, 2013, 2:58:32 PM6/28/13
to beast-users
Sorry I wasn't more explicit about this: I'm running BEAST+BEAGLE through the GUI interface, not the command line. If the problem is that a flag hasn't been set, then it's a bug in the interface rather than my graphics card being underpowered.

Eddie Salinas

unread,
Jun 28, 2013, 4:07:33 PM6/28/13
to beast...@googlegroups.com
ah......I have never used the BEAST+BEAGLE GUI interface before....

One thing I did once (before my current GPU) was find the code where the system iterates over devices...(this was several years ago).....I did this to see why my (old) GPU wasn't being listed.  I eventually added in debug/print statements telling me that it wasn't listed because the CUDA requirements being requested were not available in the GPU I had...

-Eddie

Tony Weaver

unread,
Jun 28, 2013, 5:53:30 PM6/28/13
to beast...@googlegroups.com
Kurt,

  I do the beast/beagle GUI and it works fine with my GPU (minus a possible bug with the relax clock model).  Did you rebuild beagle so that it is compiled with the NVDIA CUDA stuff?

Prof. Weaver
Visiting instructor
Dept. of Computer Science
You received this message because you are subscribed to a topic in the Google Groups "beast-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/beast-users/f1WFyeEk6X4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to beast-users...@googlegroups.com.

Kurt Wollenberg

unread,
Jul 2, 2013, 10:04:07 AM7/2/13
to beast-users
That's why I'm putting this issue out there. I upgraded my system to the latest version so I could utilize the current CUDA drivers, which I installed. I also reinstalled the latest BEAGLE libraries and the latest version of BEAST, and yet I'm still not getting BEAST+BEAGLE using my GPUs when I tell it to through the BEAST GUI interface. It seems to me that this is a flaw with the BEAGLE libraries and/or the BEAST GUI and that I should not have to rebuild the BEAGLE from source to get it to work the way the documentation tells me it should. If there is a legitimate reason why BEAGLE needs to be rebuilt for this to work then this needs to be explicitly stated in the instructions for installing BEAGLE. If I have missed the instructions in the documentation I would appreciate it if someone could point it out to me.
Reply all
Reply to author
Forward
0 new messages