Debian Codegraph @

invertkey.sh

raw symbols SCIP
1 #!/bin/bashscip-shell filesystem . . `/bin/bash`.
2
3 usagescip-shell shell bbmap 39.20+dfsg-3 usage().(){
4 echoscip-shell system . . echo. "
5 Written by Brian Bushnell
6 Last modified October 2, 2017
7
8 Description: Inverts a sketch key, given a matching reference.
9
10 Usage: invertsketch.sh in=<reference> key=<key> k=<31>
11
12 I/O parameters:
13 out=<file> Output file.
14 overwrite=f (ow) Set to false to force the program to abort rather than
15 overwrite an existing file.
16
17 Processing parameters:
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
23 specify 200 megs. The max is typically 85% of physical memory.
24 -eoom This flag will cause the process to exit if an out-of-memory
25 exception occurs. Requires Java 8u92+.
26 -da Disable assertions.
27
28 Please contact Brian Bushnell at [email protected] if you encounter any problems.
29 "
30 }
31
32 #This block allows symlinked shellscripts to correctly set classpath.
33 pushd . > /dev/nullscip-shell filesystem . . `/dev/null`.
34 DIR="${BASH_SOURCE[0]}"
35 while [scip-shell system . . `[`. -h "$DIR" ]; do
36 cd "$(dirnamescip-shell system . . dirname. "$DIR")"
37 DIR="$(readlinkscip-shell system . . readlink. "$(basenamescip-shell system . . basename. "$DIR")")"
38 done
39 cd "$(dirnamescip-shell system . . dirname. "$DIR")"
40 DIR="$(pwdscip-shell system . . pwd.)/"
41 popd > /dev/nullscip-shell filesystem . . `/dev/null`.
42
43 #DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/"
44 CP="$DIR""current/"
45
46 z="-Xmx4g"
47 z2="-Xms4g"
48 set=0
49
50 if [scip-shell system . . `[`. -z "$1" ] || [[ $1 == -h ]] || [[ $1 == --help ]]; then
51 usagescip-shell shell bbmap 39.20+dfsg-3 usage().
52 exit
53 fi
54
55 calcXmxscip-shell shell bbmap 39.20+dfsg-3 calcXmx(). () {
56 source "$DIR""/calcmem.sh"
57 setEnvironment
58 parseXmx "$@"
59 if [[ $set == 1 ]]; then
60 return
61 fi
62 freeRam 4000m 84
63 z="-Xmx${RAM}m"
64 z2="-Xms${RAM}m"
65 }
66 calcXmxscip-shell shell bbmap 39.20+dfsg-3 calcXmx(). "$@"
67
68 makepolymersscip-shell shell bbmap 39.20+dfsg-3 makepolymers().() {
69 local CMD="java $EA $EOOM $z $z2 -cp $CP sketch.InvertKey $@"
70 echoscip-shell system . . echo. $CMD >&2
71 eval $CMD
72 }
73
74 makepolymersscip-shell shell bbmap 39.20+dfsg-3 makepolymers(). "$@"