{"id":622,"date":"2018-10-19T15:29:59","date_gmt":"2018-10-19T14:29:59","guid":{"rendered":"http:\/\/ri.itservices.manchester.ac.uk\/csf3\/?page_id=622"},"modified":"2025-05-29T13:14:22","modified_gmt":"2025-05-29T12:14:22","slug":"mrbayes","status":"publish","type":"page","link":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/software\/applications\/mrbayes\/","title":{"rendered":"MrBayes"},"content":{"rendered":"<h2>Overview<\/h2>\n<p><a href=\"http:\/\/mrbayes.sourceforge.net\/\">MrBayes<\/a> is a program for Bayesian inference and model choice across a wide range of phylogenetic and evolutionary models. It uses Markov chain Monte Carlo (MCMC) methods to estimate the posterior distribution of model parameters.<\/p>\n<p>Version 3.2.6 is installed on the CSF.<\/p>\n<h2>Restrictions on use<\/h2>\n<p>There are no restrictions on access on the CSF &#8211; the software is made available under the <a href=\"http:\/\/www.gnu.org\/copyleft\/gpl.html\">GNU GPL v3 license<\/a>. If you use this software in your research please cite it. Run the command <code>citations<\/code> in the software for further details.<\/p>\n<h2>Set up procedure<\/h2>\n<p>To access the software you must first load the most appropriate modulefile:<\/p>\n<pre>\r\n# Serial and Parallel (MPI) versions\r\napps\/gcc\/mrbayes\/3.2.6\r\n\r\n# Serial and Parallel (MPI) versions with Beagle for GPU support\r\napps\/gcc\/mrbayes\/3.2.6-beagle\r\n<\/pre>\n<p>The <code>beagle<\/code> versions of the modulefiles load a version of MrBayes that has been compiled against the <a href=\"https:\/\/github.com\/beagle-dev\/beagle-lib\">Beagle<\/a> library. You run this version in the same way as all other versions but may see some speed-up depending on the features you used in MrBayes. Please consult the <a href=\"http:\/\/mrbayes.sourceforge.net\/mb3.2_manual.pdf\">MrBayes<\/a> manual for more information. <\/p>\n<h2>Running the application<\/h2>\n<p>Please do not run MrBayes on the login node. Jobs should be submitted to the compute nodes via batch.<\/p>\n<p>We now recommend loading modulefiles within your jobscript so that you have a full record of how the job was run. See the example jobscript below for how to do this. Alternatively, you may load modulefiles on the login node and let the job <abbr title=\"add '#$ -V' to your jobscript\">inherit these settings<\/abbr>.<\/p>\n<h3>Serial batch job submission<\/h3>\n<p>Create a batch submission script, for example:<\/p>\n<pre>\r\n#!\/bin\/bash --login\r\n#SBATCH -p serial      # (or --partition=) Use the nodes dedicated to serial jobs\r\n#SBATCH -t 1-0         # Wallclock timelimt (1-0 is 1 day, max permitted is 7-0)\r\n\r\nmodule purge\r\nmodule load apps\/gcc\/mrbayes\/3.2.6\r\n\r\nmb myinput.nex\r\n<\/pre>\n<p>Submit the jobscript using: <\/p>\n<pre>qsub <em>scriptname<\/em><\/pre>\n<p>where <em>scriptname<\/em> is the name of your jobscript.<\/p>\n<h3>Small Single-node Parallel batch job submission<\/h3>\n<p>The number of cores should be between 2 and 32. Note that the parallel version of the MrBayes executable is named<\/p>\n<pre>\r\npmb\r\n<\/pre>\n<p>An example jobscript is:<\/p>\n<pre>\r\n#!\/bin\/bash --login\r\n#SBATCH -p multicore   # (or --partition=) Use the AMD Genoa nodes\r\n#SBATCH -n 16          # (or --ntasks=) Number of cores\r\n#SBATCH -t 1-0         # Wallclock timelimt (1-0 is 1 day, max permitted is 7-0)\r\n\r\nmodule purge\r\nmodule load apps\/gcc\/mrbayes\/3.2.6\r\n\r\n# mpirun will run $SLURM_NTASKS (-n above) processes\r\nmpirun pmb myinput.nex\r\n       #\r\n       # Note that the executable is now 'pmb' not 'mb'\r\n<\/pre>\n<p>Submit the jobscript using: <\/p>\n<pre>sbatch <em>scriptname<\/em><\/pre>\n<p>where <em>scriptname<\/em> is the name of your jobscript.<\/p>\n<h3>Interactive use for Development<\/h3>\n<p>MrBayes provides an interactive command-line which can be used for testing and developing your scripts. Please <strong>do not<\/strong> run MrBayes on the login node. Instead you should request an interactive session on a compute node as follows:<\/p>\n<pre>\r\nsrun -p interactive -t 0-1 --pty bash\r\n  #\r\n  # Wait for an interactive session to start. If no resources\r\n  # are free you will be asked to try again later.\r\n\r\n# Now on the backend compute-node load the modulefile\r\nmodule purge\r\nmodule load apps\/gcc\/mrbayes\/<em>version<\/em>\r\n\r\n# Start the interactive shell\r\nmb\r\n\r\n# When you have finished with your interactive session, return to login node;\r\nexit\r\n<\/pre>\n<h3>Using the Beagle-enabled Version<\/h3>\n<p>A version of MrBayes that uses the Beagle library is also available. This will support GPU acceleration of some functions. To use this version, load the modulefile:<\/p>\n<pre>\r\nmodule load apps\/gcc\/mrbayes\/3.2.6-beagle\r\n<\/pre>\n<p>The executables have the same names as before:<\/p>\n<pre>\r\nmb       # The serial version\r\npmb      # The parallel version\r\n<\/pre>\n<p>To run on a GPU node, if you have been granted access to these nodes, add the following to your jobscript:<\/p>\n<pre>\r\n#SBATCH -p gpuV    # (or --partition=) Run on the v100 GPUs\r\n#SBATCH -G 1       # (or --gpus=) Number of GPUs. Can be 1 to 4 GPUs depending on your level of access.\r\n<\/pre>\n<p>The MrBayes executables will automatically detect the GPU if running on a GPU node. To check this submit the following job:<\/p>\n<pre>\r\n#!\/bin\/bash --login\r\n#SBATCH -p gpuV    # (or --partition=) Run on the v100 GPUs\r\n#SBATCH -G 1       # (or --gpus=) Number of GPUs. Can be 1 to 4 GPUs depending on your level of access.\r\nmodule purge\r\nmodule load apps\/gcc\/mrbayes\/3.2.6-beagle\r\necho Showbeagle | mb\r\n       #\r\n       # This is a MrBayes command to report info about the Beagle\r\n       # library and features (such as GPU support).\r\n<\/pre>\n<p>Submit the jobscript using: <\/p>\n<pre>sbatch <em>scriptname<\/em><\/pre>\n<p>where <em>scriptname<\/em> is the name of your jobscript.<\/p>\n<p>The output file will contain info about the GPU hardware.<\/p>\n<h3>Example Scripts<\/h3>\n<p>After loading one of the modulefiles, example scripts are available in the directory:<\/p>\n<pre>\r\n$MRBAYES_HOME\/examples\/\r\n<\/pre>\n<h2>Further info<\/h2>\n<ul>\n<li><a href=\"http:\/\/mrbayes.sourceforge.net\/\">MrBayes website<\/a><\/li>\n<\/ul>\n<h2>Updates<\/h2>\n<p>None.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview MrBayes is a program for Bayesian inference and model choice across a wide range of phylogenetic and evolutionary models. It uses Markov chain Monte Carlo (MCMC) methods to estimate the posterior distribution of model parameters. Version 3.2.6 is installed on the CSF. Restrictions on use There are no restrictions on access on the CSF &#8211; the software is made available under the GNU GPL v3 license. If you use this software in your research.. <a href=\"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/software\/applications\/mrbayes\/\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":86,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-622","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/pages\/622","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/comments?post=622"}],"version-history":[{"count":6,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/pages\/622\/revisions"}],"predecessor-version":[{"id":10204,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/pages\/622\/revisions\/10204"}],"up":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/pages\/86"}],"wp:attachment":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf3\/wp-json\/wp\/v2\/media?parent=622"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}