<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pise PUBLIC "pise2.dtd" "pise2.dtd" >
<pise>
	<head>
		<title>ASTRAL on XSEDE</title>
		<version>5.15.4</version>
		<description>Coalescent-based species tree estimation</description>
		<authors>Siavash Mirab and Tandy Warnow</authors>
		<reference>Mirarab, S., and Warnow, T. (2015) ASTRAL-II: coalescent-based species tree estimation with many hundreds of taxa and thousands of genes. Bioinformatics 31, i44-i52. 10.1093/bioinformatics/btv234</reference>
		<category>Phylogeny / Alignment</category>
	</head>

	<command>astral_xsede</command>
	
<!--
*****************************************************************************************************************************************
Created by Mark Miller for CSG, 9/8/2021 or thereabouts
***************************************************************************************************************************************** -->

<!-- 

  Usage:
  ASTRAL (version5.15.4) [-*help] (-i|-*input) <input file> [(-o|-*output) <output
  file>] [-C|-*cpu-only] [(-T|-*cpu-threads) <cpu threads>] [(-G|-*GPU) <GPU>]
  [-A|-*internode] [(-q|-*score-tree) <score species trees>]
  [(-t|-*branch-annotate) <branch annotation level>] [(-b|-*bootstraps)
  <bootstraps>] [(-r|-*reps) <replicates>] [(-s|-*seed) <seed>]
  [-g|-*gene-resampling] [-*gene-only] [(-k|-*keep) <keep>] [(-c|-*lambda)
  <lambda>] [(-a|-*namemapfile) <mapping file>] [(-m|-*minleaves) <minleaves>]
  [-*samplingrounds <samplingrounds>] [(-w|-*generepeat) <gene repetition>]
  [-*polylimit <polylimit>] [-x|-*exact] [(-p|-*extraLevel) <extraLevel>]
  [(-e|-*extra) <extra trees>] [(-f|-*extra-species) <extra species trees>]
  [-*remove-bipartitions <remove extra tree bipartitions>] [-*matrixcount
  <matrixcount>] [(-d|-*trimming) <trimming threshold>]

species tree inference from unrooted gene trees. The ASTRAL algorithm maximizes
the number of shared quartet trees with the collection of all gene trees. The
result of this optimization problem is statistically consistent under the
multi-species coalescent model. This software can also solve MGD and MGDL
problems (see options) instead of ASTRAL.


  [-*help]
        Prints this help message.
        
  Wont offer these as visible params:
    [-C|-*cpu-only]
        Do not use GPUs.

  [(-T|-*cpu-threads) <cpu threads>]
        Number of threads to use.  (default: -1)

  [(-G|-*GPU) <GPU>]
        the index of GPUs to be used, provided as a comma-separated list. If
        missing, all GPUs are used. (default)

  [-*polylimit <polylimit>]
        Sets a limit for size of polytomies in greedy consensus trees where O(n)
        number of new  resolutions are added. ASTRAL-III sets automatic limits
        to guarantee polynomial time running time.
     
  [-*matrixcount <matrixcount>]
        Sets the number of concurrent threads used for similarity matrix
        calculation.  Reducing this can help reducing memory footprint.

Will offer these:
  (-i|-*input) <input file>
        a file containing input gene trees in newick format. (required)

  [(-o|-*output) <output file>]
        a filename for storing the output species tree. Defaults to outputting
        to stdout.

  [-A|-*internode]
        USe NJst-like internode distances instead of quartet distance for
        building the search space (X). Unpublished work. 

  [(-q|-*score-tree) <score species trees>]
        score the provided species tree and exit

  [(-t|-*branch-annotate) <branch annotation level>]
        How much annotations should be added to each branch: 0, 1, or 2. 
        0: no annotations. 
        1: only the quartet support for the main resolution. 
        2: full annotation (quartet support, quartet frequency, and posterior
        probability for all three alternatives, plus total number of quartets
        around the branch and effective number of genes).
        3 (default): only the posterior probability for the main resolution.
        4: three alternative posterior probabilities.
        8: three alternative quartet scores.
        16/32: hidden commands useful to create a file called freqQuad.csv.
        10: p-values of a polytomy null hypothesis test. (default: 3)

  [(-b|-*bootstraps) <bootstraps>]
        perform multi-locus bootstrapping using input bootstrap replicate files
        (use -*rep to change the number of replications). The file given with
        this option should have a list of the gene tree bootstrap files, one per
        line, and each line corresponding to one gene. By default performs
        site-only resampling, but gene/site resampling can also be used. 

  [(-r|-*reps) <replicates>]
        Set the number of bootstrap replicates done in multi-locus
        bootstrapping.  (default: 100)

  [(-s|-*seed) <seed>]
        Set the seed number used in multi-locus bootstrapping.  (default: 692)

  [-g|-*gene-resampling]
        perform gene tree resampling in addition to site resampling. Useful only
        with the -b option.

  [-*gene-only]
        perform bootstrapping but only with gene tree resampling. Should not be
        used with the -b option.

  [(-k|-*keep) <keep>]
        -k completed: outputs completed gene trees (i.e. after adding missing
        taxa) to a file called [output file name].completed_gene_trees.
        -k bootstraps: outputs individual bootstrap replicates to a file called
        [output file name].[i].bs
        -k bootstraps_norun: just like -k bootstraps, but exits after outputting
        bootstraps.
        -k searchspace_norun: outputs the search space and exits; use -k
        searchspace to continue the run after outputting the search space.When
        -k option is used, -o option needs to be given. The file name specified
        using -o is used as the prefix for the name of the extra output files.

  [(-c|-*lambda) <lambda>]
        Set the lambda parameter for the Yule prior used in the calculations of
        branch lengths and posterior probabilities. Set to zero to get ML branch
        lengths instead of MAP. Higher values tend to shorten estimated branch
        lengths and very high values can give inaccurate results (or even result
        in underflow). (default: 0.5)

  [(-a|-*namemapfile) <mapping file>]
        a file containing the mapping between names in gene tree and names in
        the species tree. The mapping file has one line per species, with one of
        two formats:
        species: gene1,gene2,gene3,gene4
        species 4 gene1 gene2 gene3 gene4

  [(-m|-*minleaves) <minleaves>]
        Remove genes with less than specified number of leaves 

  [-*samplingrounds <samplingrounds>]
        For multi-individual datasets, perform these many rounds of individual
        sampling for building the set X. The program automatically picks this
        parameter if not provided or if below one.

  [(-w|-*generepeat) <gene repetition>]
        the number of trees sampled for each locus.  (default: 1)

  [-x|-*exact]
        find the exact solution by looking at all clusters - recommended only
        for small (<18) number of taxa.

  [(-p|-*extraLevel) <extraLevel>]
        How much extra bipartitions should be added: 0, 1, or 2. 0: adds nothing
        extra. 1 (default): adds to X but not excessively (greedy resolutions).
        2: adds a potentially large number and therefore can be slow (quadratic
        distance-based). (default: 1)

  [(-e|-*extra) <extra trees>]
        provide extra trees (with gene labels) used to enrich the set of
        clusters searched

  [(-f|-*extra-species) <extra species trees>]
        provide extra trees (with species labels) used to enrich the set of
        clusters searched

  [-*remove-bipartitions <remove extra tree bipartitions>]
        removes bipartitions of the provided extra trees (with species labels)
 

  [(-d|-*trimming) <trimming threshold>]
        trimming threshold is user's estimate on normalized score; the closer
        user's estimate is, the faster astral runs. (default: 0)
 -->

<!-- rules
Rules for running ASTRAL on Expanse via the CIPRES gateway

The runs use varying numbers of cores and GPUs within a single node of Expanse
depending upon the data set.

- Ask the user for the following:

  the number of gene trees in the data set.

- Specify the Slurm partition, cores, GPUs, and memory according to the
  following table.

      Gene          Slurm                   Slurm
      trees       partition   cores  GPUs  memory  

        <1,000     shared       8            15G
   1,000-3,999     shared      16            30G

   4,000-7,999   gpu-shared    10      1     92G
  8,000-15,999   gpu-shared    20      2    184G
      >=16,000       gpu       40      4    368G

- For runs in the Slurm shared partition, include the following in the run
  script.

  #SBATCH -p shared
  #SBATCH -*qos=shared-cipres
  #SBATCH -N 1
  #SBATCH -*ntasks-per-node=1
  #SBATCH -*cpus-per-task=<cores>
  #SBATCH -*mem=<memory>
  ...
  /expanse/projects/ngbt/home/cipres/ngbw/contrib/scripts/astral_5.15.4_expanse -T <cores> ...

- For runs on one GPU in the Slurm gpu-shared partition, include the following
  in the run script.
   
  #SBATCH -p gpu-shared
  #SBATCH -*qos=gpu-shared-cipres
  #SBATCH -N 1
  #SBATCH -*gpus=1
  #SBATCH -*ntasks-per-node=10
  #SBATCH -*mem=92G
  ...
  /expanse/projects/ngbt/home/cipres/ngbw/contrib/scripts/astral_5.15.4_expanse.gpu -T 10 -G 1 ...

- For runs on two GPUs in the Slurm gpu-shared partition, include the following
  in the run script.

  #SBATCH -p gpu-shared
  #SBATCH -*qos=gpu-shared-cipres
  #SBATCH -N 1
  #SBATCH -*gpus=2
  #SBATCH -*ntasks-per-node=20
  #SBATCH -*mem=184G
  ...
  /expanse/projects/ngbt/home/cipres/ngbw/contrib/scripts/astral_5.15.4_expanse.gpu -T 20 -G 1,2 ...
   
- For runs on four GPUs in the Slurm gpu partition, include the following in
  the run script.

  #SBATCH -p gpu
  #SBATCH -*qos=gpu-cipres
  #SBATCH -N 1
  #SBATCH -*gpus=4
  #SBATCH -*ntasks-per-node=40
  #SBATCH -*mem=368G
  ...
  /expanse/projects/ngbt/home/cipres/ngbw/contrib/scripts/astral_5.15.4_expanse.gpu -T 40 -G 1,2,3,4 ...
  -->



<parameters>
	
<!--  submission on comet  -->
					<parameter ismandatory="1" ishidden="1" type="String">
						<name>astral_invoke</name>
						<attributes>
  							<precond>
								<language>perl</language>
								<code>$num_gtress &lt; "4000"</code>
							</precond> 
							<format>
								<language>perl</language>		
								<code>"astral_5.15.4_expanse"</code>					
							</format>
							<group>0</group>
						</attributes>
					</parameter> 
					
					<parameter ismandatory="1" ishidden="1" type="String">
						<name>astral_invoke_gpu</name>
						<attributes>
  						<precond>
								<language>perl</language>
								<code>$num_gtress &gt; "3999"</code>
							</precond> 
							<format>
								<language>perl</language>		
								<code>"astral_5.15.4_expanse.gpu"</code>					
							</format>
							<group>0</group>
						</attributes>
					</parameter> 
<!-- 
      Gene          Slurm                   Slurm
      trees       partition   cores  GPUs  memory  

        <1,000     shared       8            15G
   1,000-3,999     shared      16            30G

   4,000-7,999   gpu-shared    10      1     92G
  8,000-15,999   gpu-shared    20      2    184G
      >=16,000       gpu       40      4    368G  --> 
					
<!-- when run type = 1 -->
				<parameter type="String" ishidden="1" >
					<name>number_cores1</name>
					<attributes>
						<group>2</group>
						<paramfile>scheduler.conf</paramfile>
  						<precond>
							<language>perl</language>
							<code>$num_gtrees &lt; 1000</code>
						</precond>  
						<format>
							<language>perl</language>
							<code>
									"ChargeFactor=1.0\\n" .
									"nodes=1\\n" .
									"mem=15G\\n" .
									"node_exclusive=0\\n" .
									"cpus-per-task=8\\n" .
									"threads_per_process=8\\n"
							</code>
						</format>
					</attributes>
				</parameter> 	
				
<!-- when run type = 1 -->
				<parameter type="String" ishidden="1" >
					<name>number_cores2</name>
					<attributes>
						<group>2</group>
						<paramfile>scheduler.conf</paramfile>
 					<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 999 &amp;&amp; $num_gtrees &lt; 4000  </code>
					</precond>  
						<format>
							<language>perl</language>
							<code>
									"ChargeFactor=1.0\\n" .
									"nodes=1\\n" .
									"mem=30G\\n" .
									"node_exclusive=0\\n" .
									"cpus-per-task=16\\n" .
									"threads_per_process=16\\n"
							</code>
						</format>
					</attributes>
				</parameter> 
				
				<!-- when run type = 1 -->
				<parameter type="String" ishidden="1" >
					<name>number_cores3</name>
					<attributes>
						<group>2</group>
						<paramfile>scheduler.conf</paramfile>
 					<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 3999 &amp;&amp; $num_gtrees &lt; 8000  </code>
					</precond>  
						<format>
							<language>perl</language>
							<code>
									"ChargeFactor=1.0\\n" .
									"gpu=1\\n" .
									"nodes=1\\n" .
									"mem=92G\\n" .	 					
									"node_exclusive=0\\n" .
									"threads_per_process=10\\n"
							</code>
						</format>
					</attributes>
				</parameter> 
				
				<!-- when run type = 1 -->
				<parameter type="String" ishidden="1" >
					<name>number_cores4</name>
					<attributes>
						<group>2</group>
						<paramfile>scheduler.conf</paramfile>
 					<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 7999 &amp;&amp; $num_gtrees &lt; 16000  </code>
					</precond>  
						<format>
							<language>perl</language>
							<code>
									"ChargeFactor=1.0\\n" .
									"gpu=2\\n" .
									"nodes=1\\n" .
									"mem=184G\\n" .	 					
									"node_exclusive=0\\n" .
									"threads_per_process=20\\n"
							</code>
						</format>
					</attributes>
				</parameter> 
				
				<!-- when run type = 1 -->
				<parameter type="String" ishidden="1" >
					<name>number_cores5</name>
					<attributes>
						<group>2</group>
						<paramfile>scheduler.conf</paramfile>
 					<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 15999 </code>
					</precond>  
						<format>
							<language>perl</language>
							<code>
									"ChargeFactor=1.0\\n" .
									"gpu=4\\n" .
									"nodes=1\\n" .
									"mem=368G\\n" .	 					
									"node_exclusive=1\\n" .
									"threads_per_process=40\\n"
							</code>
						</format>
					</attributes>
				</parameter> 

<!-- end number of nodes  -->

<!-- 
  (-i|-*input) <input file>
        a file containing input gene trees in newick format. (required) -->
	<parameter ismandatory="1" issimple="1" isinput="1" type="InFile"> 
	<name>infile</name>
		<attributes>
			<prompt>Input</prompt>
			<filenames>infile.tre</filenames>
			<group>1</group>
		</attributes>
	</parameter>
	
<parameter ishidden="1" type="String"> 
	<name>infile_invoke</name>
		<attributes>
			<prompt>Input</prompt>
<!--  			<precond>
				<language>perl</language>
				<code>!defined $score_only</code>
			</precond> -->
   			<format>
				<language>perl</language>
				<code>"-i infile.tre"</code>
			</format>
			<group>1</group>
		</attributes>
	</parameter>
			
<!--   [(-T|-*cpu-threads) <cpu threads>]
        Number of threads to use.  (default: -1) -->
 				<parameter type="String" ishidden="1" >
					<name>number_threads1</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &lt; 1000 </code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-T 8"</code>
						</format>
					</attributes>
				</parameter> 
				
				 <parameter type="String" ishidden="1" >
					<name>number_threads2</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 999 &amp;&amp; $num_gtrees &lt; 4000 </code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-T 16"</code>
						</format>
					</attributes>
				</parameter> 
				
				<parameter type="String" ishidden="1" >
					<name>number_threads3</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 3999 &amp;&amp; $num_gtrees &lt; 8000 </code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-T 10"</code>
						</format>
					</attributes>
				</parameter> 
				
				<parameter type="String" ishidden="1" >
					<name>number_gpus1</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 3999 &amp;&amp; $num_gtrees &lt; 8000 </code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-G 1"</code>
						</format>
					</attributes>
				</parameter> 
				
				<parameter type="String" ishidden="1" >
					<name>number_threads4</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 7999 &amp;&amp; $num_gtrees &lt; 16000 </code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-T 20"</code>
						</format>
					</attributes>
				</parameter> 
				
				<parameter type="String" ishidden="1" >
					<name>number_gpus2</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 7999 &amp;&amp; $num_gtrees &lt; 16000 </code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-G 1,2"</code>
						</format>
					</attributes>
				</parameter> 
				
				<parameter type="String" ishidden="1" >
					<name>number_threads5</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 15999</code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-T 40"</code>
						</format>
					</attributes>
				</parameter> 
				
				<parameter type="String" ishidden="1" >
					<name>number_gpus4</name>
					<attributes>
						<group>4</group>
 						<precond>
							<language>perl</language>
							<code>$num_gtrees &gt; 15999</code>
						</precond>  
						<format>
							<language>perl</language>
							<code>"-G 1,2,3,4"</code>
						</format>
					</attributes>
				</parameter>  

<!--   [specify the logfile ] -->
 				<parameter type="String" ishidden="1" >
					<name>write_log</name>
					<attributes>
						<group>99</group>  
						<format>
							<language>perl</language>
							<code>"2&gt; output.log"</code>
						</format>
					</attributes>
				</parameter>  
<!-- begin visible parameters -->		

<!-- this sets the run time -->
				<parameter type="Float" issimple="1" ismandatory="1">
					<name>runtime</name> 
					<attributes>
						<group>1</group>
						<paramfile>scheduler.conf</paramfile>
						<prompt>Maximum Hours to Run (up to 168 hours)</prompt>
						<vdef>
							<value>0.5</value>
						</vdef>
						<ctrls>
							<ctrl>
								<message>The maximum hours to run must be less than 168</message>
								<language>perl</language>
								<code>$runtime &gt; 168.0 &amp;&amp; $num_gtrees &lt; 4000</code>
							</ctrl>
							<ctrl>
								<message>The maximum hours to run must be greater than 0.05</message>
								<language>perl</language>
								<code>$runtime &lt; 0.05</code>
							</ctrl>
							<ctrl>
								<message>The maximum hours to run must be less than or equal to 120</message>
								<language>perl</language>
								<code>$runtime &gt; 120.0 &amp;&amp; $num_gtrees &gt; 3999</code>
							</ctrl>
						</ctrls>
						<format>
							<language>perl</language>
							<code>"runhours=$value\\n"</code>
						</format>

<!-- provide feedback on number of cpu hrs to be consumed; all runs are the same, but this must be keyed to a visible param, so here we make it conditional on a non-zero run time. -->
<!--  
      Gene          Slurm                   Slurm
      trees       partition   cores  GPUs  memory  

        <1,000     shared       8            15G
   1,000-3,999     shared      16            30G

   4,000-7,999   gpu-shared    10      1     92G
  8,000-15,999   gpu-shared    20      2    184G
      >=16,000       gpu       40      4    368G  --> 
					 
						<warns>
							<warn>
								<message>The job will run on 8 processors as configured. If it runs for the entire configured time, it will consume 8 x $runtime cpu hours</message>
								<language>perl</language>
								<code>$num_gtrees &lt; 1000 </code>
							</warn>
							<warn>
								<message>The job will run on 16 processors as configured. If it runs for the entire configured time, it will consume 16 x $runtime cpu hours</message>
								<language>perl</language>
								<code>$num_gtrees &gt; 999 &amp;&amp; $num_gtrees &lt; 4000 </code>
							</warn>
							<warn>
								<message>The job will run on 10 processors and 1 GPU as configured. If it runs for the entire configured time, it will consume 21 x $runtime cpu hours</message>
								<language>perl</language>
								<code>$num_gtrees &gt; 3999 &amp;&amp; $num_gtrees &lt; 8000 </code>
							</warn>
							<warn>
								<message>The job will run on 20 processors and 2 GPU as configured. If it runs for the entire configured time, it will consume 42 x $runtime cpu hours</message>
								<language>perl</language>
								<code>$num_gtrees &gt; 7999 &amp;&amp; $num_gtrees &lt; 16000 </code>
							</warn>
							<warn>
								<message>The job will run on 40 processors and 4 GPU as configured. If it runs for the entire configured time, it will consume 84 x $runtime cpu hours</message>
								<language>perl</language>
								<code>$num_gtrees &gt; 15999</code>
							</warn>
						</warns>
						<comment>
<value>Estimate the maximum time your job will need to run. We recommend testing initially with a &lt; 0.5hr test run because Jobs set for 0.5 h or less depedendably run immediately in the "debug" queue. 
Once you are sure the configuration is correct, you then increase the time. The reason is that jobs &gt; 0.5 h are submitted to the "normal" queue, where jobs configured for 1 or a few hours times may
	run sooner than jobs configured for the full 168 hours. 
</value>
						</comment>
					</attributes>
				</parameter>

<parameter  issimple="1" type="Integer"> 
	<name>num_gtrees</name>
		<attributes>
			<prompt>Number of Gene trees in your input file</prompt>
		</attributes>
	</parameter> 
	
<!-- [(-o|-*output) <output file>]
        a filename for storing the output species tree. Defaults to outputting
        to stdout.-->
	<parameter  issimple="1" type="String"> 
	<name>outfile_name</name>
		<attributes>
			<prompt>Output file name </prompt>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-o $value":"" </code>
			</format>
			<comment>
			<value>Specify a filename for storing the output species tree.</value>
			</comment>
		</attributes>
	</parameter>

 <!-- [(-q|-*score-tree) <score species trees>]
        score the provided species tree and exit  -->
  	<parameter  issimple="1" type="InFile"> 
	<name>score_only</name>
		<attributes>
			<prompt>Score the provided species tree and exit (-q)</prompt>
			<filenames>species_tree.tre</filenames>
			<format>
				<language>perl</language>
				<code>($value) ? "-q species_tree.tre":"" </code>
			</format>
			<group>8</group>
		</attributes>
	</parameter> 

	
 <!--   [-A|-*internode]
        USe NJst-like internode distances instead of quartet distance for
        building the search space (X). Unpublished work.-->
 	<parameter  issimple="0" type="Switch"> 
	<name>use_internodedist</name>
		<attributes>
			<prompt>USe NJst-like internode distances</prompt>
			<format>
				<language>perl</language>
				<code>($value) ? "-A":"" </code>
			</format>
			<group>6</group>
			<comment>
			<value>USe NJst-like internode distances instead of quartet distance for
        building the search space (X). Unpublished work.</value>
			</comment>
		</attributes>
	</parameter> 

<!--   [(-t|-*branch-annotate) <branch annotation level>]
        How much annotations should be added to each branch: 0, 1, or 2. 
        0: no annotations. 
        1: only the quartet support for the main resolution. 
        2: full annotation (quartet support, quartet frequency, and posterior
        probability for all three alternatives, plus total number of quartets
        around the branch and effective number of genes).
        3 (default): only the posterior probability for the main resolution.
        4: three alternative posterior probabilities.
        8: three alternative quartet scores.
        16/32: hidden commands useful to create a file called freqQuad.csv.
        10: p-values of a polytomy null hypothesis test. (default: 3)
         -->
   	<parameter  issimple="1" type="Excl"> 
	<name>branch_annotate</name>
		<attributes>
			<prompt>How much annotations should be added to each branch (-t)</prompt>
			<format>
				<language>perl</language>
				<code>($value) ? "-t $value":"" </code>
			</format>
			<vlist>
				<value>0</value>
				<label>none</label>
				<value>1</value>
				<label>only quartet support</label>
				<value>2</value>
				<label>full annotation</label>
				<value>3</value>
				<label>only posterior probability</label>
				<value>4</value>
				<label>three alt. post. probabilities</label>
				<value>8</value>
				<label>three alt. quartet scores</label>
				<value>10</value>
				<label>p-values of a polytomy null hypothesis test</label>
			</vlist>
			<vdef>
				<value>3</value>
			</vdef>
			<group>8</group>
			<comment>
			<value></value>
			</comment>
		</attributes>
	</parameter>
	


  <!--  [(-c|-*lambda) <lambda>]
        Set the lambda parameter for the Yule prior used in the calculations of
        branch lengths and posterior probabilities. Set to zero to get ML branch
        lengths instead of MAP. Higher values tend to shorten estimated branch
        lengths and very high values can give inaccurate results (or even result
        in underflow). (default: 0.5)-->
 <parameter issimple="0" type="Float"> 
	<name>specify_lambda</name>
		<attributes>
			<prompt>Set the lambda parameter for the Yule prior. (-c)</prompt>
<!-- 			<precond>
				<language>perl</language>
				<code>!defined $score_only</code>
			</precond>  -->
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-c $value":"" </code>
			</format>
			<vdef>
				<value>0.5</value>
			</vdef>
			<group>12</group>
			<comment>
			<value>Set the lambda parameter for the Yule prior used in the calculations of
        branch lengths and posterior probabilities. Set to zero to get ML branch
        lengths instead of MAP. Higher values tend to shorten estimated branch
        lengths and very high values can give inaccurate results (or even result
        in underflow). (default: 0.5)</value>
			</comment>
		</attributes>
	</parameter>

<!--   [(-a|-*namemapfile) <mapping file>]
        a file containing the mapping between names in gene tree and names in
        the species tree. The mapping file has one line per species, with one of
        two formats:
        species: gene1,gene2,gene3,gene4
        species 4 gene1 gene2 gene3 gene4 -->
        
 		<parameter issimple="0" type="InFile" >
			<name>upload_namemapfile</name>
				<attributes>
					<prompt>Select a name mapping file</prompt>
						<group>30</group>
						<filenames>namemapfile.txt</filenames>
						<format>
							<language>perl</language>
							<code>(defined $value) ? "-a namemapfile.txt":"" </code>
						</format>
						<comment>
			<value>Select a file containing the mapping between names in gene tree and names in
        the species tree. The mapping file has one line per species, with one of
        two formats:
        species: gene1,gene2,gene3,gene4
        species 4 gene1 gene2 gene3 gene4</value>
			</comment>
				</attributes>
		</parameter>

 <!-- [(-m|-*minleaves) <minleaves>]
        Remove genes with less than specified number of leaves  --> 
  <parameter issimple="0" type="Integer"> 
	<name>specify_minleaves</name>
		<attributes>
			<prompt>Remove genes with less than specified number of leaves (-m)</prompt>
<!--  			<precond>
				<language>perl</language>
				<code>!defined $score_only</code>
			</precond>-->
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-m $value":"" </code>
			</format>
			<group>26</group>
			<comment>
			<value></value>
			</comment>
		</attributes>
	</parameter>

 <!--   [-*samplingrounds <samplingrounds>]
        For multi-individual datasets, perform these many rounds of individual
        sampling for building the set X. The program automatically picks this
        parameter if not provided or if below one.-->
   <parameter issimple="0" type="Integer"> 
	<name>specify_samplingrounds</name>
		<attributes>
			<prompt>Perform this many rounds of individual sampling for building the set X (--samplingrounds)</prompt>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "--samplingrounds $value":"" </code>
			</format>
			<group>26</group>
			<comment>
			<value>For multi-individual datasets, perform these many rounds of individual
        sampling for building the set X. The program automatically picks this
        parameter if not provided or if below one</value>
			</comment>
		</attributes>
	</parameter>

 <!--   [(-w|-*generepeat) <gene repetition>]
        the number of trees sampled for each locus.  (default: 1) -->
    <parameter issimple="0" type="Integer"> 
	<name>specify_samplenumtrees</name>
		<attributes>
			<prompt>Sample this number of trees for each locus (-w)</prompt>
<!-- 			<precond>
				<language>perl</language>
				<code>!defined $score_only</code>
			</precond>  -->
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-w $value":"" </code>
			</format>
			<vdef>
				<value>1</value>
			</vdef>
			<group>26</group>
			<comment>
			<value></value>
			</comment>
		</attributes>
	</parameter>

 <!--  [-*polylimit <polylimit>]
        Sets a limit for size of polytomies in greedy consensus trees where O(n)
        number of new  resolutions are added. ASTRAL-III sets automatic limits
        to guarantee polynomial time running time.
    <parameter issimple="0" type="Integer"> 
	<name>specify_samplingrounds</name>
		<attributes>
			<prompt>Sample this number of trees for each locus (-w)</prompt>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-w $value":"" </code>
			</format>
			<vdef>
				<value>1</value>
			</vdef>
			<group>26</group>
			<comment>
			<value></value>
			</comment>
		</attributes>x
	</parameter>  --> 
<!-- [-x|-*exact]
        find the exact solution by looking at all clusters - recommended only
        for small (<18) number of taxa.  --> 
    <parameter issimple="0" type="Switch"> 
	<name>specify_exactsoln</name>
		<attributes>
			<prompt>Find the exact solution by looking at all clusters (-x)</prompt>
			<format>
				<language>perl</language>
				<code>($value) ? "-x ":"" </code>
			</format>
			<vdef>
				<value>0</value>
			</vdef>
			<group>32</group>
			<warns>
				<warn>
					<message>Please do not use the exact (-x) option when there are more than 18 taxa</message>
					<language>perl</language>
					<code>$specify_exactsoln</code>
				</warn>
			</warns>
			<comment>
			<value></value>
			</comment>
		</attributes>
	</parameter>

<!--  [(-p|-*extraLevel) <extraLevel>]
        How much extra bipartitions should be added: 0, 1, or 2. 0: adds nothing
        extra. 1 (default): adds to X but not excessively (greedy resolutions).
        2: adds a potentially large number and therefore can be slow (quadratic
        distance-based). (default: 1)  --> 
  <parameter  issimple="0" ismandatory="0" type="Excl"> 
	<name>extra_biparts</name>
		<attributes>
			<prompt>How much extra bipartitions should be added? (-p)</prompt>
<!--  			<precond>
				<language>perl</language>
				<code>!defined $score_only</code>
			</precond> -->
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-p $value":"" </code>
			</format>
			<vlist>
				<value>0</value>
				<label>Nothing</label>
				<value>1</value>
				<label>Greedy resolutions</label>
				<value>2</value>
				<label>Quadratic distance-based</label>
			</vlist>
			<vdef>
				<value>1</value>
			</vdef>
			<warns>
				<warn>
					<message>Quadratic distance-based method can be quite slow</message>
					<language>perl</language>
					<code>$extra_biparts = 3</code>
				</warn>
			</warns>
			<group>38</group>
			<comment>
<value>0: adds nothing extra. </value>
<value>1: (default): adds to X but not excessively (greedy resolutions).
        </value>
<value>2: adds a potentially large number and therefore can be slow (quadratic
        distance-based).</value> 
			</comment>
		</attributes>
	</parameter>

<!--  [(-e|-*extra) <extra trees>]
        provide extra trees (with gene labels) used to enrich the set of
        clusters searched  --> 
    <parameter issimple="0" type="InFile"> 
	<name>provide_extratrees</name>
		<attributes>
			<prompt>Provide extra trees (with gene labels) (-e)</prompt>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-e extratrees.tre ":"" </code>
			</format>
			<filenames>extratrees.tre</filenames>
			<group>32</group>
			<comment>
			<value>Provide extra trees (with gene labels) used to enrich the set of
        clusters searched </value>
			</comment>
		</attributes>
	</parameter>

<!--   [(-f|-*extra-species) <extra species trees>]
        provide extra trees (with species labels) used to enrich the set of
        clusters searched --> 
    <parameter issimple="0" type="InFile"> 
	<name>extra_speciestrees</name>
		<attributes>
			<prompt>Provide extra trees (with species labels) (-f)</prompt>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-f extraspeciestrees.tre":"" </code>
			</format>
			<filenames>extraspeciestrees.tre</filenames>
			<group>32</group>
			<comment>
			<value>Provide extra trees (with species labels) used to enrich the set of
        clusters searched</value>
			</comment>
		</attributes>
	</parameter>

<!--  [-*remove-bipartitions <remove extra tree bipartitions>]
        removes bipartitions of the provided extra trees (with species labels) --> 
    <parameter issimple="0" type="InFile"> 
	<name>remove_biparts</name>
		<attributes>
			<prompt>Remove bipartitions of the provided extra trees (--remove-bipartition)</prompt>
			<format>
				<language>perl</language>
				<code>($value) ? "--remove-bipartition ":"" </code>
			</format>
			<filenames>extraspeciestrees.tre</filenames>
			<group>32</group>
			<comment>
			<value>Removes bipartitions of the provided extra trees (with species labels)</value>
			</comment>
		</attributes>
	</parameter>

  <!-- [-*matrixcount <matrixcount>]
        Sets the number of concurrent threads used for similarity matrix
        calculation.  Reducing this can help reducing memory footprint.  
    <parameter issimple="0" type="Integer"> 
	<name>specify_samplenumtrees</name>
		<attributes>
			<prompt>Sample this number of trees for each locus (-w)</prompt>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-w $value":"" </code>
			</format>
			<vdef>
				<value>1</value>
			</vdef>
			<group>26</group>
			<comment>
			<value></value>
			</comment>
		</attributes>
	</parameter> -->
	
<!--   [(-d|-*trimming) <trimming threshold>]
        trimming threshold is user's estimate on normalized score; the closer
        user's estimate is, the faster astral runs. (default: 0) -->
 <!-- not woith -q -->					
    <parameter issimple="0" type="Float"> 
	<name>specify_trimthreshold</name>
		<attributes>
			<prompt>Trimming threshold (-d)</prompt>
<!--  			<precond>
				<language>perl</language>
				<code>!defined $score_only</code>
			</precond>-->
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-d $value":"" </code>
			</format>
			<vdef>
				<value>0</value>
			</vdef>
			<group>26</group>
			<comment>
			<value>The trimming threshold is the user's estimate on normalized score; the closer
        user's estimate is, the faster Astral runs. (default: 0)</value>
			</comment>
		</attributes>
	</parameter>
	
	  <!--  [-*gene-only]
        perform bootstrapping but only with gene tree resampling. Should not be
        used with the -b option. -->
    <parameter issimple="0" type="Switch"> 
	<name>boot_onlygtr</name>
		<attributes>
			<prompt>Perform bootstrapping but only with gene tree resampling. (--gene-only)</prompt>
			<precond>
				<language>perl</language>
				<code>!$use_bootstrapping <!-- &amp;&amp; !defined $score_only  --></code>
			</precond>
			<format>
				<language>perl</language>
				<code>($value) ? "--gene-only":"" </code>
			</format>
			<group>14</group>
		</attributes>
	</parameter>
<!-- 
<parameter type="Paragraph">
<paragraph>
<name>bootstrapping_section</name>
<prompt>Bootstrapping Options</prompt>
<parameters> -->
 
 <!--  [(-b|-*bootstraps) <bootstraps>]
        perform multi-locus bootstrapping using input bootstrap replicate files
        (use -*rep to change the number of replications). The file given with
        this option should have a list of the gene tree bootstrap files, one per
        line, and each line corresponding to one gene. By default performs
        site-only resampling, but gene/site resampling can also be used.  -->
 
<!--  <parameter  issimple="0" type="Switch"> 
	<name>use_bootstrapping</name>
		<attributes>
			<prompt>Perform multi-locus bootstrapping using input bootstrap replicate files (-b)</prompt>
			<format>
				<language>perl</language>
				<code>($value) ? "-b":"" </code>
			</format>
			<group>8</group>
			<comment>
			<value>Use this option to perform multi-locus bootstrapping using input bootstrap replicate files.
			 The file given with this option should have a list of the gene tree bootstrap files, one per
			 line, and each line corresponding to one gene. By default performs site-only resampling, 
			 but gene/site resampling can also be used.</value>
			</comment>
		</attributes>
	</parameter> -->
	
 <!--   [(-r|-*reps) <replicates>]
        Set the number of bootstrap replicates done in multi-locus
        bootstrapping.  (default: 100)
 <parameter issimple="0" type="Integer"> 
	<name>specify_reps</name>
		<attributes>
			<prompt>Set the number of bootstrap replicates done in multi-locus bootstrapping (-r)</prompt>
			<precond>
				<language>perl</language>
				<code>$use_bootstrapping</code>
			</precond>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-r $value":"" </code>
			</format>
			<vdef>
				<value>100</value>
			</vdef>
			<group>10</group>
			<comment>
			<value>Use this option to perform multi-locus bootstrapping using input bootstrap replicate files.
			 The file given with this option should have a list of the gene tree bootstrap files, one per
			 line, and each line corresponding to one gene. By default performs site-only resampling, 
			 but gene/site resampling can also be used.</value>
			</comment>
		</attributes>
	</parameter>-->

<!--   [(-s|-*seed) <seed>]
        Set the seed number used in multi-locus bootstrapping.  (default: 692)  
        
 <parameter issimple="0" type="Integer"> 
	<name>specify_seed</name>
		<attributes>
			<prompt>Set the seed number used in multi-locus bootstrapping. (-s)</prompt>
			<precond>
				<language>perl</language>
				<code>$use_bootstrapping</code>
			</precond>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-s $value":"" </code>
			</format>
			<vdef>
				<value>692</value>
			</vdef>
			<group>12</group>
		</attributes>
	</parameter>-->
	
<!--    [-g|-*gene-resampling]
        perform gene tree resampling in addition to site resampling. Useful only
        with the -b option. 
  <parameter issimple="0" type="Switch"> 
	<name>use_gtresampling</name>
		<attributes>
			<prompt>Perform gene tree resampling in addition to site resampling. (-g)</prompt>
			<precond>
				<language>perl</language>
				<code>$use_bootstrapping</code>
			</precond>
			<format>
				<language>perl</language>
				<code>($value) ? "-g":"" </code>
			</format>
			<group>14</group>
		</attributes>
	</parameter>-->

  <!--  [(-k|-*keep) <keep>]
        -k completed: outputs completed gene trees (i.e. after adding missing
        taxa) to a file called [output file name].completed_gene_trees.
        -k bootstraps: outputs individual bootstrap replicates to a file called
        [output file name].[i].bs
        -k bootstraps_norun: just like -k bootstraps, but exits after outputting
        bootstraps.
        -k searchspace_norun: outputs the search space and exits; use -k
        searchspace to continue the run after outputting the search space.When
        -k option is used, -o option needs to be given. The file name specified
        using -o is used as the prefix for the name of the extra output files.
        
  <parameter  issimple="0" ismandatory="0" type="Excl"> 
	<name>keep_option</name>
		<attributes>
			<prompt>What outputs do you want to keep? (-k)</prompt>
			<precond>
				<language>perl</language>
				<code>$use_bootstrapping</code>
			</precond>
			<format>
				<language>perl</language>
				<code>(defined $value) ? "-k $value":"" </code>
			</format>
			<vlist>
				<value>completed</value>
				<label>completed</label>
				<value>bootstraps</value>
				<label>bootstraps</label>
				<value>bootstraps_norun</value>
				<label>bootstraps_norun</label>
				<value>searchspace</value>
				<label>searchspace</label>
				<value>searchspace_norun</value>
				<label>searchspace_norun</label>
			</vlist>
			<vdef>
				<value>3</value>
			</vdef>
			<ctrls>
				<ctrl>
					<message>Please enter a name for the output file</message>
					<language>perl</language>
					<code>defined $keep_option &amp;&amp; !defined $outfile_name </code>
				</ctrl>
			</ctrls>
			<group>24</group>
			<comment>
<value>The file name specified using -o is used as the prefix for the name of the extra output files</value>
<value> -k options: completed: outputs completed gene trees (i.e. after adding missing
        taxa) to a file called [output file name].completed_gene_trees.</value>
<value>bootstraps: outputs individual bootstrap replicates to a file called
        [output file name].[i].bs</value> 
<value>bootstraps_norun: just like -k bootstraps, but exits after outputting
        bootstraps.</value>
<value>searchspace: to continue the run after outputting the search space.</value>
<value>searchspace_norun: outputs the search space and exits</value>
			</comment>
		</attributes>
	</parameter> --> 

<!--  </parameters>
</paragraph>
</parameter>-->



<parameter type="Results">
	<name>results</name>
	<attributes>
		<filenames>*</filenames>
	</attributes>
</parameter>

</parameters>
</pise>
