Repository 'raxml'
hg clone https://toolshed.g2.bx.psu.edu/repos/iuc/raxml

Changeset 1:ba29b5e2a4be (2017-06-27)
Previous changeset 0:6805e85573b8 (2016-11-14) Next changeset 2:a4b71be30c3c (2019-12-02)
Commit message:
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/raxml commit b23553a3d29d50e05d8b37a5c5780e3ffc937069
modified:
raxml.py
raxml.xml
removed:
tool_dependencies.xml
b
diff -r 6805e85573b8 -r ba29b5e2a4be raxml.py
--- a/raxml.py Mon Nov 14 14:03:39 2016 -0500
+++ b/raxml.py Tue Jun 27 16:27:39 2017 -0400
[
b'@@ -6,14 +6,6 @@\n import fnmatch\n import glob\n import optparse\n-import os\n-import subprocess\n-import sys\n-\n-\n-def stop_err(msg):\n-    sys.stderr.write("%s\\n" % msg)\n-    sys.exit()\n \n \n def getint(name):\n@@ -24,347 +16,91 @@\n \n \n def __main__():\n-    usage = "usage: %prog -T <threads> -s <input> -n <output> -m <model> [optional arguments]"\n-\n     # Parse the primary wrapper\'s command line options\n-    parser = optparse.OptionParser(usage=usage)\n-    # raxml binary name, hardcoded in the xml file\n-    parser.add_option("--binary", action="store", type="string", dest="binary", help="Command to run")\n-    # (-a)\n-    parser.add_option("--weightfile", action="store", type="string", dest="weightfile", help="Column weight file")\n-    # (-A)\n-    parser.add_option("--secondary_structure_model", action="store", type="string", dest="secondary_structure_model", help="Secondary structure model")\n+    parser = optparse.OptionParser()\n     # (-b)\n-    parser.add_option("--bootseed", action="store", type="int", dest="bootseed", help="Bootstrap random number seed")\n-    # (-c)\n-    parser.add_option("--numofcats", action="store", type="int", dest="numofcats", help="Number of distinct rate categories")\n-    # (-d)\n-    parser.add_option("--search_complete_random_tree", action="store_true", dest="search_complete_random_tree", help="Search with a complete random starting tree")\n-    # (-D)\n-    parser.add_option("--ml_search_convergence", action="store_true", dest="ml_search_convergence", help="ML search onvergence criterion")\n-    # (-e)\n-    parser.add_option("--model_opt_precision", action="store", type="float", dest="model_opt_precision", help="Model Optimization Precision (-e)")\n-    # (-E)\n-    parser.add_option("--excludefile", action="store", type="string", dest="excludefile", help="Exclude File Name")\n-    # (-f)\n-    parser.add_option("--search_algorithm", action="store", type="string", dest="search_algorithm", help="Search Algorithm")\n-    # (-F)\n-    parser.add_option("--save_memory_cat_model", action="store_true", dest="save_memory_cat_model", help="Save memory under CAT and GTRGAMMA models")\n-    # (-g)\n-    parser.add_option("--groupingfile", action="store", type="string", dest="groupingfile", help="Grouping File Name")\n-    # (-G)\n-    parser.add_option("--enable_evol_heuristics", action="store_true", dest="enable_evol_heuristics", help="Enable evol algo heuristics")\n-    # (-i)\n-    parser.add_option("--initial_rearrangement_setting", action="store", type="int", dest="initial_rearrangement_setting", help="Initial Rearrangement Setting")\n-    # (-I)\n-    parser.add_option("--posterior_bootstopping_analysis", action="store", type="string", dest="posterior_bootstopping_analysis", help="Posterior bootstopping analysis")\n-    # (-J)\n-    parser.add_option("--majority_rule_consensus", action="store", type="string", dest="majority_rule_consensus", help="Majority rule consensus")\n-    # (-k)\n-    parser.add_option("--print_branch_lengths", action="store_true", dest="print_branch_lengths", help="Print branch lengths")\n-    # (-K)\n-    parser.add_option("--multistate_sub_model", action="store", type="string", dest="multistate_sub_model", help="Multistate substitution model")\n-    # (-m)\n-    parser.add_option("--model_type", action="store", type="string", dest="model_type", help="Model Type")\n-    parser.add_option("--base_model", action="store", type="string", dest="base_model", help="Base Model")\n-    parser.add_option("--aa_empirical_freq", action="store_true", dest="aa_empirical_freq", help="Use AA Empirical base frequences")\n-    parser.add_option("--aa_search_matrix", action="store", type="string", dest="aa_search_matrix", help="AA Search Matrix")\n-    # (-n)\n-    parser.add_option("--name", action="store", type="string", dest="name", help="Run Name")\n+    parser.add_option("--bootseed", action="store", type="int", dest="bootseed", help="Random number for non-parametric bootstrapping")\n     # (-N/#)\n-    parser.add_option("--numbe'..b'                 outfile.write(line)\n+            # Results\n+            with open(\'RAxML_result.galaxy\', \'w\') as outfile:\n+                for filename in runfiles:\n+                    if fnmatch.fnmatch(filename, \'RAxML_result.galaxy.RUN.*\'):\n+                        with open(filename, \'r\') as infile:\n+                            filename_line = "%s\\n" % filename\n+                            outfile.write(filename_line)\n+                            for line in infile:\n+                                outfile.write(line)\n     # Multiple Model Partition Files\n-    if multiple_model:\n+    if options.multiple_model:\n         files = glob.glob(\'RAxML_bestTree.galaxy.PARTITION.*\')\n         if len(files) > 0:\n             files.sort(key=getint)\n-            outfile = open(\'RAxML_bestTreePartitions.galaxy\', \'w\')\n             # Best Tree Partitions\n-            for filename in files:\n-                if fnmatch.fnmatch(filename, \'RAxML_bestTree.galaxy.PARTITION.*\'):\n-                    infile = open(filename, \'r\')\n-                    filename_line = "%s\\n" % filename\n-                    outfile.write(filename_line)\n-                    for line in infile:\n-                        outfile.write(line)\n-                    infile.close()\n-            outfile.close()\n+            with open(\'RAxML_bestTreePartitions.galaxy\', \'w\') as outfile:\n+                for filename in files:\n+                    if fnmatch.fnmatch(filename, \'RAxML_bestTree.galaxy.PARTITION.*\'):\n+                        with open(filename, \'r\') as infile:\n+                            filename_line = "%s\\n" % filename\n+                            outfile.write(filename_line)\n+                            for line in infile:\n+                                outfile.write(line)\n         else:\n-            outfile = open(\'RAxML_bestTreePartitions.galaxy\', \'w\')\n-            outfile.write("No partition files were produced.\\n")\n-            outfile.close()\n+            with open(\'RAxML_bestTreePartitions.galaxy\', \'w\') as outfile:\n+                outfile.write("No partition files were produced.\\n")\n \n         # Result Partitions\n         files = glob.glob(\'RAxML_result.galaxy.PARTITION.*\')\n         if len(files) > 0:\n             files.sort(key=getint)\n-            outfile = open(\'RAxML_resultPartitions.galaxy\', \'w\')\n-            for filename in files:\n-                if fnmatch.fnmatch(filename, \'RAxML_result.galaxy.PARTITION.*\'):\n-                    infile = open(filename, \'r\')\n-                    filename_line = "%s\\n" % filename\n-                    outfile.write(filename_line)\n-                    for line in infile:\n-                        outfile.write(line)\n-                    infile.close()\n-            outfile.close()\n+            with open(\'RAxML_resultPartitions.galaxy\', \'w\') as outfile:\n+                for filename in files:\n+                    if fnmatch.fnmatch(filename, \'RAxML_result.galaxy.PARTITION.*\'):\n+                        with open(filename, \'r\') as infile:\n+                            filename_line = "%s\\n" % filename\n+                            outfile.write(filename_line)\n+                            for line in infile:\n+                                outfile.write(line)\n         else:\n-            outfile = open(\'RAxML_resultPartitions.galaxy\', \'w\')\n-            outfile.write("No partition files were produced.\\n")\n-            outfile.close()\n+            with open(\'RAxML_resultPartitions.galaxy\', \'w\') as outfile:\n+                outfile.write("No partition files were produced.\\n")\n \n     # DEBUG options\n-    infof = open(\'RAxML_info.galaxy\', \'a\')\n-    infof.write(\'\\nOM: CLI options DEBUG START:\\n\')\n-    infof.write(options.__repr__())\n-    infof.write(\'\\nOM: CLI options DEBUG END\\n\')\n+    with open(\'RAxML_info.galaxy\', \'a\') as infof:\n+        infof.write(\'\\nOM: CLI options DEBUG START:\\n\')\n+        infof.write(options.__repr__())\n+        infof.write(\'\\nOM: CLI options DEBUG END\\n\')\n+\n \n if __name__ == "__main__":\n     __main__()\n'
b
diff -r 6805e85573b8 -r ba29b5e2a4be raxml.xml
--- a/raxml.xml Mon Nov 14 14:03:39 2016 -0500
+++ b/raxml.xml Tue Jun 27 16:27:39 2017 -0400
[
b'@@ -1,197 +1,146 @@\n-<tool id="raxml" name="Phyogenetic reconstruction with RaXML" version="1.0.2">\n+<tool id="raxml" name="Phyogenetic reconstruction with RaXML" version="8.2.4">\n     <description>- Maximum Likelihood based inference of large phylogenetic trees</description>\n     <requirements>\n-        <requirement type=\'package\' version="8.2.4">raxml</requirement>\n+        <requirement type="package" version="8.2.4">raxml</requirement>\n     </requirements>\n-    <command interpreter="python">raxml.py\n-    ## Required parameters \n-    ## binary is hard-coded to the pthreads enabled raxml executable if threads > 1\n-    ## (-T)\n-    ## Cannot have --threads 1\n-    #set $slots = $getVar(\'GALAXY_SLOTS\', 1)\n-    #if $slots == 1:\n-        --binary "raxmlHPC"\n-        --threads 1\n-    #else:\n-        --binary "raxmlHPC-PTHREADS"\n-        --threads $slots\n-    #end if\n-    ## (-s)\n-    --source "$infile"\n-    ## (-m)\n-    --model_type $search_model_selector.model_type\n-    --base_model $search_model_selector.base_model\n-    #if str( $search_model_selector.model_type ) == \'aminoacid\':\n-        $search_model_selector.aa_model_empirical_base_frequencies\n-        #if $search_model_selector.aa_search_matrix:\n-            --aa_search_matrix $search_model_selector.aa_search_matrix\n-        #end if\n-    #end if\n-\n-    ## Optional parameters\n+    <command detect_errors="exit_code"><![CDATA[\n+## binary is hard-coded to the pthreads enabled raxml executable if threads > 1\n+#set $slots = $getVar(\'GALAXY_SLOTS\', 1)\n+#if $slots == 1:\n+    raxmlHPC\n+    ## Cannot have -T 1\n+#else:\n+    raxmlHPC-PTHREADS\n+    -T $slots\n+#end if\n+-s \'$infile\'\n+-n galaxy\n+#if $search_model_selector.model_type == \'aminoacid\':\n+    -m ${search_model_selector.base_model}${search_model_selector.aa_search_matrix}${search_model_selector.aa_model_empirical_base_frequencies}\n+#else:\n+    -m $search_model_selector.base_model\n+#end if\n+-p $random_seed\n \n-    #if str( $selExtraOpts.extraOptions ) == \'full\':\n-        ## (-N/#)\n-        #if $selExtraOpts.number_of_runs:\n-            --number_of_runs $selExtraOpts.number_of_runs\n-        #end if\n-        #if $selExtraOpts.number_of_runs_bootstop:\n-            --number_of_runs_bootstop $selExtraOpts.number_of_runs_bootstop\n-        #end if\n-        ## (-a)\n-        #if $selExtraOpts.weightfile:\n-            --weightfile "$selExtraOpts.weightfile"\n-        #end if\n-        ## (-b)\n-        #if str ($selExtraOpts.secondary_structure_model) != "":\n-            --secondary_structure_model $selExtraOpts.secondary_structure_model\n-        #end if\n-        ## (-b)\n-        #if str($selExtraOpts.bootseed):\n-            --bootseed $selExtraOpts.bootseed\n-        #end if\n-        ## (-c)\n-        #if $selExtraOpts.numofcats:\n-            --numofcats $selExtraOpts.numofcats\n-        #end if\n-        ## (-d)\n-        $selExtraOpts.search_complete_random_tree\n-        ## (-D)\n-        $selExtraOpts.ml_search_convergence\n-        ## (-e)\n-        #if $selExtraOpts.model_opt_precision:\n-            --model_opt_precision $selExtraOpts.model_opt_precision\n-        #end if\n-        ## (-E)\n-        #if $selExtraOpts.excludefile:\n-            --excludefile "$selExtraOpts.excludefile"\n-        #end if\n-        ## (-f)\n-        #if $selExtraOpts.search_algorithm:\n-            --search_algorithm $selExtraOpts.search_algorithm\n-        #end if\n-        ## (-F)\n-        $selExtraOpts.save_memory_cat_model\n-        ## (-g)\n-        #if $selExtraOpts.groupingfile:\n-            --groupingfile "$selExtraOpts.groupingfile"\n-        #end if\n-        ## (-G)\n-        #if $selExtraOpts.enable_evol_heuristics:\n-            --enable_evol_heuristics $selExtraOpts.enable_evol_heuristics\n-        #end if\n-        ## (-i)\n-        #if $selExtraOpts.initial_rearrangement_setting:\n-            --initial_rearrangement_setting $selExtraOpts.initial_rearrangement_setting\n-        #end if\n-        ## (-I)\n-        #if $selExtraOpts.posterior_bootstopping_analysis:\n-         '..b'ts[\'search_algorithm\'] != \'a\'</filter>\n+            <filter>selExtraOpts[\'constraint_file\'] is None</filter>\n+            <filter>selExtraOpts[\'groupingfile\'] is None</filter>\n+            <filter>selExtraOpts[\'search_complete_random_tree\'] is False</filter>\n+            <filter>selExtraOpts[\'start_tree_file\'] is None</filter>\n+            <filter>not selExtraOpts[\'majority_rule_consensus\'] == \'\'</filter>\n         -->\n         </data>\n         <data format="nhx" name="bootstrap" from_work_dir="RAxML_bootstrap.galaxy" label="Final Bootstrap Trees">\n@@ -458,24 +409,24 @@\n             <filter>selExtraOpts[\'rapid_bootstrap_random_seed\'] != \'\' or selExtraOpts[\'bootseed\'] != \'\'</filter>\n         </data>\n         <data format="txt" name="bipartitions" from_work_dir="RAxML_bipartitions.galaxy" label="Bipartitions">\n-            <filter>(selExtraOpts[\'search_algorithm\'] == \'b\') or ((selExtraOpts[\'search_algorithm\'] == \'a\') and (selExtraOpts[\'rapid_bootstrap_random_seed\'] != \'\')) </filter>\n+            <filter>selExtraOpts[\'search_algorithm\'] == \'b\' or (selExtraOpts[\'search_algorithm\'] == \'a\' and selExtraOpts[\'rapid_bootstrap_random_seed\'] != \'\') </filter>\n             <filter>selExtraOpts[\'extraOptions\'] == "full"</filter>\n         </data>\n         <data format="txt" name="bipartitionsBranchLabels" from_work_dir="RAxML_bipartitionsBranchLabels.galaxy" label="Bipartitions Branch Labels">\n             <filter>selExtraOpts[\'extraOptions\'] == "full"</filter>\n-            <filter>(selExtraOpts[\'search_algorithm\'] == \'b\') or ((selExtraOpts[\'search_algorithm\'] == \'a\') and (selExtraOpts[\'rapid_bootstrap_random_seed\'] != \'\')) </filter>\n+            <filter>selExtraOpts[\'search_algorithm\'] == \'b\' or (selExtraOpts[\'search_algorithm\'] == \'a\' and selExtraOpts[\'rapid_bootstrap_random_seed\'] != \'\') </filter>\n         </data>\n         <data format="nhx" name="strictConsensusTree" from_work_dir="RAxML_StrictConsensusTree.galaxy" label="Strict Consensus Tree">\n             <filter>selExtraOpts[\'extraOptions\'] == "full"</filter>\n-            <filter>(selExtraOpts[\'majority_rule_consensus\'] == \'STRICT\') </filter>\n+            <filter>selExtraOpts[\'majority_rule_consensus\'] == \'STRICT\'</filter>\n         </data>\n         <data format="nhx" name="majorityRuleConsensusTree" from_work_dir="RAxML_MajorityRuleConsensusTree.galaxy" label="Majority Rule Consensus Tree">\n             <filter>selExtraOpts[\'extraOptions\'] == "full"</filter>\n-            <filter>(selExtraOpts[\'majority_rule_consensus\'] == \'MR\')</filter>\n+            <filter>selExtraOpts[\'majority_rule_consensus\'] == \'MR\'</filter>\n         </data>\n         <data format="nhx" name="majorityRuleExtendedConsensusTree" from_work_dir="RAxML_MajorityRuleExtendedConsensusTree.galaxy" label="Majority Rule Extended Consensus Tree">\n             <filter>selExtraOpts[\'extraOptions\'] == "full"</filter>\n-            <filter>(selExtraOpts[\'majority_rule_consensus\'] == \'MRE\')</filter>\n+            <filter>selExtraOpts[\'majority_rule_consensus\'] == \'MRE\'</filter>\n         </data>\n         <data format="txt" name="bipartitionFreq" from_work_dir="RAxML_bipartitionFrequences.galaxy" label="Pair-wise bipartition frequences.">\n             <filter>selExtraOpts[\'search_algorithm\'] == \'m\' </filter>\n@@ -523,22 +474,18 @@\n             </output>\n         </test>\n     </tests>\n-    <help>\n-\n+    <help><![CDATA[\n RAxML_ (Randomized Axelerated Maximum Likelihood) is a program for Maximum Likelihood-based inference of large phylogenetic\n trees. The program is explicitly being developed to efficiently infer trees for\n extremely large datasets, either in terms of the number of taxa and/or the\n sequence length.\n \n-\n-.. _RAxML: http://www.exelixis-lab.org/\n-\n+.. _RAxML: http://www.exelixis-lab.org/web/software/raxml/\n \n **Tool development**:\n \n Oleksandr Moskalenko with adaptations from Tiago Antao.\n-\n-    </help>\n+    ]]></help>\n     <citations>\n         <citation type="doi">10.1093/bioinformatics/btu033</citation>\n     </citations>\n'
b
diff -r 6805e85573b8 -r ba29b5e2a4be tool_dependencies.xml
--- a/tool_dependencies.xml Mon Nov 14 14:03:39 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,6 +0,0 @@
-<?xml version="1.0"?>
-<tool_dependency>
-    <package name="raxml" version="8.2.4">
-        <repository changeset_revision="34be595fd2a9" name="package_raxml_8_2_4" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" />
-    </package>
-</tool_dependency>