Debian Codegraph @

filtersilva.sh

raw symbols SCIP
1 #!/bin/bash
2
3 usage(){
4 echo "
5 Written by Brian Bushnell
6 Last modified Jan 27, 2020
7
8 Description: Removes .
9
10 Usage: filtersilva.sh in=x.fa out=y.fa
11
12 Standard parameters:
13 in=<file> Input file.
14 out=<file> Output file.
15
16 Additional files:
17 tree=auto Path to TaxTree.
18
19
20 Java Parameters:
21 -Xmx This will set Java's memory usage, overriding autodetection.
22 -Xmx20g will specify 20 gigs of RAM, and -Xmx200m will specify 200 megs.
23 The max is typically 85% of physical memory.
24 -da Disable assertions.
25
26 For more detailed information, please read /bbmap/docs/guides/BBSketchGuide.txt.
27 Please contact Brian Bushnell at [email protected] if you encounter any problems.
28 "
29 }
30
31 #This block allows symlinked shellscripts to correctly set classpath.
32 pushd . > /dev/null
33 DIR="${BASH_SOURCE[0]}"
34 while [ -h "$DIR" ]; do
35 cd "$(dirname "$DIR")"
36 DIR="$(readlink "$(basename "$DIR")")"
37 done
38 cd "$(dirname "$DIR")"
39 DIR="$(pwd)/"
40 popd > /dev/null
41
42 #DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/"
43 CP="$DIR""current/"
44
45 z="-Xmx4g"
46 z2="-Xms4g"
47 set=0
48
49 if [ -z "$1" ] || [[ $1 == -h ]] || [[ $1 == --help ]]; then
50 usage
51 exit
52 fi
53
54 calcXmx () {
55 source "$DIR""/calcmem.sh"
56 setEnvironment
57 parseXmx "$@"
58 if [[ $set == 1 ]]; then
59 return
60 fi
61 #freeRam 3200m 84
62 #z="-Xmx${RAM}m"
63 #z2="-Xms${RAM}m"
64 }
65 calcXmx "$@"
66
67 filtersilva() {
68 local CMD="java $EA $EOOM $z -cp $CP prok.FilterSilva $@"
69 echo $CMD >&2
70 eval $CMD
71 }
72
73 filtersilva "$@"