Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mirrors
biopet.biopet
Commits
c8f56975
Commit
c8f56975
authored
Mar 14, 2016
by
Sander van der Zeeuw
Browse files
General refactor Biopet
parent
ede07209
Changes
56
Expand all
Hide whitespace changes
Inline
Side-by-side
public/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/extensions/PythonCommandLineFunction.scala
View file @
c8f56975
...
...
@@ -22,22 +22,22 @@ import org.broadinstitute.gatk.utils.commandline.Input
trait
PythonCommandLineFunction
extends
BiopetCommandLineFunction
{
@Input
(
doc
=
"Python script"
,
required
=
false
)
var
python
_s
cript
:
File
=
_
var
python
S
cript
:
File
=
_
executable
=
config
(
"exe"
,
default
=
"python"
,
submodule
=
"python"
,
freeVar
=
false
)
protected
var
python
_s
cript
_n
ame
:
String
=
_
protected
var
python
S
cript
N
ame
:
String
=
_
/**
* checks if script already exist in jar otherwise try to fetch from the jar
* @param script name / location of script
*/
def
setPythonScript
(
script
:
String
)
{
python
_s
cript
=
new
File
(
script
)
if
(!
python
_s
cript
.
exists
())
{
python
S
cript
=
new
File
(
script
)
if
(!
python
S
cript
.
exists
())
{
setPythonScript
(
script
,
""
)
}
else
{
python
_s
cript
_n
ame
=
script
python
S
cript
N
ame
=
script
}
}
...
...
@@ -47,17 +47,17 @@ trait PythonCommandLineFunction extends BiopetCommandLineFunction {
* @param subpackage location of script in jar
*/
def
setPythonScript
(
script
:
String
,
subpackage
:
String
)
{
python
_s
cript
_n
ame
=
script
python
_s
cript
=
new
File
(
".queue/tmp/"
+
subpackage
+
python
_s
cript
_n
ame
)
if
(!
python
_s
cript
.
getParentFile
.
exists
)
python
_s
cript
.
getParentFile
.
mkdirs
val
is
=
getClass
.
getResourceAsStream
(
subpackage
+
python
_s
cript
_n
ame
)
val
os
=
new
FileOutputStream
(
python
_s
cript
)
python
S
cript
N
ame
=
script
python
S
cript
=
new
File
(
".queue/tmp/"
+
subpackage
+
python
S
cript
N
ame
)
if
(!
python
S
cript
.
getParentFile
.
exists
)
python
S
cript
.
getParentFile
.
mkdirs
val
is
=
getClass
.
getResourceAsStream
(
subpackage
+
python
S
cript
N
ame
)
val
os
=
new
FileOutputStream
(
python
S
cript
)
org
.
apache
.
commons
.
io
.
IOUtils
.
copy
(
is
,
os
)
os
.
close
()
}
/** return basic command to prefix the complete command with */
def
getPythonCommand
:
String
=
{
required
(
executable
)
+
required
(
python
_s
cript
)
required
(
executable
)
+
required
(
python
S
cript
)
}
}
public/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/Cufflinks.scala
View file @
c8f56975
...
...
@@ -44,29 +44,29 @@ class Cufflinks(val root: Configurable) extends BiopetCommandLineFunction with V
@Output
(
doc
=
"Output GTF file"
)
lazy
val
outputGtf
:
File
=
{
require
(
input
!=
null
&&
output
_d
ir
!=
null
,
require
(
input
!=
null
&&
output
D
ir
!=
null
,
"Can not set Cufflinks GTF output while input file and/or output directory is not defined"
)
// cufflinks always outputs a transcripts.gtf file in the output directory
new
File
(
output
_d
ir
,
"transcripts.gtf"
)
new
File
(
output
D
ir
,
"transcripts.gtf"
)
}
@Output
(
doc
=
"Output isoform FPKM file"
)
lazy
val
outputIsoformsFpkm
:
File
=
{
require
(
input
!=
null
&&
output
_d
ir
!=
null
,
require
(
input
!=
null
&&
output
D
ir
!=
null
,
"Can not set Cufflinks isoforms.fpkm_tracking output while input file and/or output directory is not defined"
)
new
File
(
output
_d
ir
,
"isoforms.fpkm_tracking"
)
new
File
(
output
D
ir
,
"isoforms.fpkm_tracking"
)
}
@Output
(
doc
=
"Output GTF file"
)
lazy
val
outputGenesFpkm
:
File
=
{
require
(
input
!=
null
&&
output
_d
ir
!=
null
,
require
(
input
!=
null
&&
output
D
ir
!=
null
,
"Can not set Cufflinks genes.fpkm_tracking output while input file and/or output directory is not defined"
)
// cufflinks always outputs a genes.fpkm_tracking file in the output directory
new
File
(
output
_d
ir
,
"genes.fpkm_tracking"
)
new
File
(
output
D
ir
,
"genes.fpkm_tracking"
)
}
/** write all output files to this directory [./] */
var
output
_d
ir
:
File
=
config
(
"output_dir"
,
default
=
new
File
(
"."
))
var
output
D
ir
:
File
=
config
(
"output_dir"
,
default
=
new
File
(
"."
))
/** value of random number generator seed [0] */
var
seed
:
Option
[
Int
]
=
config
(
"seed"
)
...
...
@@ -75,106 +75,106 @@ class Cufflinks(val root: Configurable) extends BiopetCommandLineFunction with V
var
GTF
:
Option
[
File
]
=
config
(
"GTF"
)
/** use reference transcript annotation to guide assembly */
var
GTF_g
uide
:
Option
[
File
]
=
config
(
"GTF_guide"
)
var
gtfG
uide
:
Option
[
File
]
=
config
(
"GTF_guide"
)
/** ignore all alignment within transcripts in this file */
var
mask
_f
ile
:
Option
[
File
]
=
config
(
"mask_file"
)
var
mask
F
ile
:
Option
[
File
]
=
config
(
"mask_file"
)
/** use bias correction - reference fasta required [NULL] */
var
frag
_b
ias
_c
orrect
:
Option
[
String
]
=
config
(
"frag_bias_correct"
)
var
frag
B
ias
C
orrect
:
Option
[
String
]
=
config
(
"frag_bias_correct"
)
/** use 'rescue method' for multi-reads (more accurate) [FALSE] */
var
multi
_r
ead
_c
orrect
:
Boolean
=
config
(
"multi_read_correct"
,
default
=
false
)
var
multi
R
ead
C
orrect
:
Boolean
=
config
(
"multi_read_correct"
,
default
=
false
)
/** library prep used for input reads [below] */
var
library
_t
ype
:
Option
[
String
]
=
config
(
"library_type"
)
var
library
T
ype
:
Option
[
String
]
=
config
(
"library_type"
)
/** Method used to normalize library sizes [below] */
var
library
_n
orm
_m
ethod
:
Option
[
String
]
=
config
(
"library_norm_method"
)
var
library
N
orm
M
ethod
:
Option
[
String
]
=
config
(
"library_norm_method"
)
/** average fragment length (unpaired reads only) [200] */
var
frag
_len_m
ean
:
Option
[
Int
]
=
config
(
"frag_len_mean"
)
var
frag
LenM
ean
:
Option
[
Int
]
=
config
(
"frag_len_mean"
)
/** fragment length std deviation (unpaired reads only) [80] */
var
frag
_len_std_d
ev
:
Option
[
Int
]
=
config
(
"frag_len_std_dev"
)
var
frag
LenStdD
ev
:
Option
[
Int
]
=
config
(
"frag_len_std_dev"
)
/** maximum iterations allowed for MLE calculation [5000] */
var
max
_mle_i
terations
:
Option
[
Int
]
=
config
(
"max_mle_iterations"
)
var
max
MleI
terations
:
Option
[
Int
]
=
config
(
"max_mle_iterations"
)
/** count hits compatible with reference RNAs only [FALSE] */
var
compatible
_h
its
_n
orm
:
Boolean
=
config
(
"compatible_hits_norm"
,
default
=
false
)
var
compatible
H
its
N
orm
:
Boolean
=
config
(
"compatible_hits_norm"
,
default
=
false
)
/** count all hits for normalization [TRUE] */
var
total
_h
its
_n
orm
:
Boolean
=
config
(
"total_hits_norm"
,
default
=
true
)
var
total
H
its
N
orm
:
Boolean
=
config
(
"total_hits_norm"
,
default
=
true
)
/** Number of fragment generation samples [100] */
var
num
_f
rag
_c
ount
_d
raws
:
Option
[
Int
]
=
config
(
"num_frag_count_draws"
)
var
num
F
rag
C
ount
D
raws
:
Option
[
Int
]
=
config
(
"num_frag_count_draws"
)
/** Number of fragment assignment samples per generation [50] */
var
num
_f
rag
_a
ssign
_d
raws
:
Option
[
Int
]
=
config
(
"num_frag_assign_draws"
)
var
num
F
rag
A
ssign
D
raws
:
Option
[
Int
]
=
config
(
"num_frag_assign_draws"
)
/** Maximum number of alignments allowed per fragment [unlim] */
var
max
_f
rag
_m
ultihits
:
Option
[
Int
]
=
config
(
"max_frag_multihits"
)
var
max
F
rag
M
ultihits
:
Option
[
Int
]
=
config
(
"max_frag_multihits"
)
/** No effective length correction [FALSE] */
var
no
_e
ffective
_l
ength
_c
orrection
:
Boolean
=
config
(
"no_effective_length_correction"
,
default
=
false
)
var
no
E
ffective
L
ength
C
orrection
:
Boolean
=
config
(
"no_effective_length_correction"
,
default
=
false
)
/** No length correction [FALSE] */
var
no
_l
ength
_c
orrection
:
Boolean
=
config
(
"no_length_correction"
,
default
=
false
)
var
no
L
ength
C
orrection
:
Boolean
=
config
(
"no_length_correction"
,
default
=
false
)
/** assembled transcripts have this ID prefix [CUFF] */
var
label
:
Option
[
String
]
=
config
(
"label"
)
/** suppress transcripts below this abundance level [0.10] */
var
min
_i
soform
_f
raction
:
Option
[
Float
]
=
config
(
"min_isoform_fraction"
)
var
min
I
soform
F
raction
:
Option
[
Float
]
=
config
(
"min_isoform_fraction"
)
/** suppress intra-intronic transcripts below this level [0.15] */
var
pre
_m
rna
_f
raction
:
Option
[
Float
]
=
config
(
"pre_mrna_fraction"
)
var
pre
M
rna
F
raction
:
Option
[
Float
]
=
config
(
"pre_mrna_fraction"
)
/** ignore alignments with gaps longer than this [300000] */
var
max
_i
ntron
_l
ength
:
Option
[
Int
]
=
config
(
"max_intron_length"
)
var
max
I
ntron
L
ength
:
Option
[
Int
]
=
config
(
"max_intron_length"
)
/** alpha for junction binomial test filter [0.001] */
var
junc
_a
lpha
:
Option
[
Float
]
=
config
(
"junc_alpha"
)
var
junc
A
lpha
:
Option
[
Float
]
=
config
(
"junc_alpha"
)
/** percent read overhang taken as 'suspiciously small' [0.09] */
var
small
_a
nchor
_f
raction
:
Option
[
Float
]
=
config
(
"small_anchor_fraction"
)
var
small
A
nchor
F
raction
:
Option
[
Float
]
=
config
(
"small_anchor_fraction"
)
/** minimum number of fragments needed for new transfrags [10] */
var
min
_f
rags
_per_t
ransfrag
:
Option
[
Int
]
=
config
(
"min_frags_per_transfrag"
)
var
min
F
rags
PerT
ransfrag
:
Option
[
Int
]
=
config
(
"min_frags_per_transfrag"
)
/** number of terminal exon bp to tolerate in introns [8] */
var
overhang
_t
olerance
:
Option
[
Int
]
=
config
(
"overhang_tolerance"
)
var
overhang
T
olerance
:
Option
[
Int
]
=
config
(
"overhang_tolerance"
)
/** maximum genomic length allowed for a given bundle [3500000] */
var
max
_b
undle
_l
ength
:
Option
[
Int
]
=
config
(
"max_bundle_length"
)
var
max
B
undle
L
ength
:
Option
[
Int
]
=
config
(
"max_bundle_length"
)
/** maximum fragments allowed in a bundle before skipping [500000] */
var
max
_b
undle
_f
rags
:
Option
[
Int
]
=
config
(
"max_bundle_frags"
)
var
max
B
undle
F
rags
:
Option
[
Int
]
=
config
(
"max_bundle_frags"
)
/** minimum intron size allowed in genome [50] */
var
min
_i
ntron
_l
ength
:
Option
[
Int
]
=
config
(
"min_intron_length"
)
var
min
I
ntron
L
ength
:
Option
[
Int
]
=
config
(
"min_intron_length"
)
/** minimum avg coverage required to attempt 3' trimming [10] */
var
trim
_3_a
vg
c
ov
_t
hresh
:
Option
[
Int
]
=
config
(
"trim_3_avgcov_thresh"
)
var
trim
3A
vg
C
ov
T
hresh
:
Option
[
Int
]
=
config
(
"trim_3_avgcov_thresh"
)
/** fraction of avg coverage below which to trim 3' end [0.1] */
var
trim
_3_d
rop
o
ff
_f
rac
:
Option
[
Float
]
=
config
(
"trim_3_dropoff_frac"
)
var
trim
3D
rop
O
ff
F
rac
:
Option
[
Float
]
=
config
(
"trim_3_dropoff_frac"
)
/** maximum fraction of allowed multireads per transcript [0.75] */
var
max
_m
ultiread
_f
raction
:
Option
[
Float
]
=
config
(
"max_multiread_fraction"
)
var
max
M
ultiread
F
raction
:
Option
[
Float
]
=
config
(
"max_multiread_fraction"
)
/** maximum gap size to fill between transfrags (in bp) [50] */
var
overlap
_r
adius
:
Option
[
Int
]
=
config
(
"overlap_radius"
)
var
overlap
R
adius
:
Option
[
Int
]
=
config
(
"overlap_radius"
)
/** disable tiling by faux reads [FALSE] */
var
no
_f
aux
_r
eads
:
Boolean
=
config
(
"no_faux_reads"
,
default
=
false
)
var
no
F
aux
R
eads
:
Boolean
=
config
(
"no_faux_reads"
,
default
=
false
)
/** overhang allowed on 3' end when merging with reference [600] */
var
flag
_3_o
verhang
_t
olerance
:
Option
[
Int
]
=
config
(
"flag_3_overhang_tolerance"
)
var
flag
3O
verhang
T
olerance
:
Option
[
Int
]
=
config
(
"flag_3_overhang_tolerance"
)
/** overhang allowed inside reference intron when merging [30] */
var
intron
_o
verhang
_t
olerance
:
Option
[
Int
]
=
config
(
"intron_overhang_tolerance"
)
var
intron
O
verhang
T
olerance
:
Option
[
Int
]
=
config
(
"intron_overhang_tolerance"
)
/** log-friendly verbose processing (no progress bar) [FALSE] */
var
verbose
:
Boolean
=
config
(
"verbose"
,
default
=
false
)
...
...
@@ -183,7 +183,7 @@ class Cufflinks(val root: Configurable) extends BiopetCommandLineFunction with V
var
quiet
:
Boolean
=
config
(
"quiet"
,
default
=
false
)
/** do not contact server to check for update availability [FALSE] */
var
no
_u
pdate
_c
heck
:
Boolean
=
config
(
"no_update_check"
,
default
=
false
)
var
no
U
pdate
C
heck
:
Boolean
=
config
(
"no_update_check"
,
default
=
false
)
def
versionRegex
=
"""cufflinks v(.*)"""
.
r
def
versionCommand
=
executable
...
...
@@ -191,46 +191,46 @@ class Cufflinks(val root: Configurable) extends BiopetCommandLineFunction with V
def
cmdLine
=
required
(
executable
)
+
required
(
"--output-dir"
,
output
_d
ir
)
+
required
(
"--output-dir"
,
output
D
ir
)
+
optional
(
"--num-threads"
,
threads
)
+
optional
(
"--seed"
,
seed
)
+
optional
(
"--GTF"
,
GTF
)
+
optional
(
"--GTF-guide"
,
GTF_g
uide
)
+
optional
(
"--mask-file"
,
mask
_f
ile
)
+
optional
(
"--frag-bias-correct"
,
frag
_b
ias
_c
orrect
)
+
conditional
(
multi
_r
ead
_c
orrect
,
"--multi-read-correct"
)
+
optional
(
"--library-type"
,
library
_t
ype
)
+
optional
(
"--library-norm-method"
,
library
_n
orm
_m
ethod
)
+
optional
(
"--frag-len-mean"
,
frag
_len_m
ean
)
+
optional
(
"--frag-len-std-dev"
,
frag
_len_std_d
ev
)
+
optional
(
"--max-mle-iterations"
,
max
_mle_i
terations
)
+
conditional
(
compatible
_h
its
_n
orm
,
"--compatible-hits-norm"
)
+
conditional
(
total
_h
its
_n
orm
,
"--total-hits-norm"
)
+
optional
(
"--num-frag-count-draws"
,
num
_f
rag
_c
ount
_d
raws
)
+
optional
(
"--num-frag-assign-draws"
,
num
_f
rag
_a
ssign
_d
raws
)
+
optional
(
"--max-frag-multihits"
,
max
_f
rag
_m
ultihits
)
+
conditional
(
no
_e
ffective
_l
ength
_c
orrection
,
"--no-effective-length-correction"
)
+
conditional
(
no
_l
ength
_c
orrection
,
"--no-length-correction"
)
+
optional
(
"--GTF-guide"
,
gtfG
uide
)
+
optional
(
"--mask-file"
,
mask
F
ile
)
+
optional
(
"--frag-bias-correct"
,
frag
B
ias
C
orrect
)
+
conditional
(
multi
R
ead
C
orrect
,
"--multi-read-correct"
)
+
optional
(
"--library-type"
,
library
T
ype
)
+
optional
(
"--library-norm-method"
,
library
N
orm
M
ethod
)
+
optional
(
"--frag-len-mean"
,
frag
LenM
ean
)
+
optional
(
"--frag-len-std-dev"
,
frag
LenStdD
ev
)
+
optional
(
"--max-mle-iterations"
,
max
MleI
terations
)
+
conditional
(
compatible
H
its
N
orm
,
"--compatible-hits-norm"
)
+
conditional
(
total
H
its
N
orm
,
"--total-hits-norm"
)
+
optional
(
"--num-frag-count-draws"
,
num
F
rag
C
ount
D
raws
)
+
optional
(
"--num-frag-assign-draws"
,
num
F
rag
A
ssign
D
raws
)
+
optional
(
"--max-frag-multihits"
,
max
F
rag
M
ultihits
)
+
conditional
(
no
E
ffective
L
ength
C
orrection
,
"--no-effective-length-correction"
)
+
conditional
(
no
L
ength
C
orrection
,
"--no-length-correction"
)
+
optional
(
"--label"
,
label
)
+
optional
(
"--min-isoform-fraction"
,
min
_i
soform
_f
raction
)
+
optional
(
"--pre-mrna-fraction"
,
pre
_m
rna
_f
raction
)
+
optional
(
"--max-intron-length"
,
max
_i
ntron
_l
ength
)
+
optional
(
"--junc-alpha"
,
junc
_a
lpha
)
+
optional
(
"--small-anchor-fraction"
,
small
_a
nchor
_f
raction
)
+
optional
(
"--min-frags-per-transfrag"
,
min
_f
rags
_per_t
ransfrag
)
+
optional
(
"--overhang-tolerance"
,
overhang
_t
olerance
)
+
optional
(
"--max-bundle-length"
,
max
_b
undle
_l
ength
)
+
optional
(
"--max-bundle-frags"
,
max
_b
undle
_f
rags
)
+
optional
(
"--min-intron-length"
,
min
_i
ntron
_l
ength
)
+
optional
(
"--trim-3-avgcov-thresh"
,
trim
_3_a
vg
c
ov
_t
hresh
)
+
optional
(
"--trim-3-dropoff-frac"
,
trim
_3_d
rop
o
ff
_f
rac
)
+
optional
(
"--max-multiread-fraction"
,
max
_m
ultiread
_f
raction
)
+
optional
(
"--overlap-radius"
,
overlap
_r
adius
)
+
conditional
(
no
_f
aux
_r
eads
,
"--no-faux-reads"
)
+
optional
(
"--flag-3-overhang-tolerance"
,
flag
_3_o
verhang
_t
olerance
)
+
optional
(
"--intron-overhang-tolerance"
,
intron
_o
verhang
_t
olerance
)
+
optional
(
"--min-isoform-fraction"
,
min
I
soform
F
raction
)
+
optional
(
"--pre-mrna-fraction"
,
pre
M
rna
F
raction
)
+
optional
(
"--max-intron-length"
,
max
I
ntron
L
ength
)
+
optional
(
"--junc-alpha"
,
junc
A
lpha
)
+
optional
(
"--small-anchor-fraction"
,
small
A
nchor
F
raction
)
+
optional
(
"--min-frags-per-transfrag"
,
min
F
rags
PerT
ransfrag
)
+
optional
(
"--overhang-tolerance"
,
overhang
T
olerance
)
+
optional
(
"--max-bundle-length"
,
max
B
undle
L
ength
)
+
optional
(
"--max-bundle-frags"
,
max
B
undle
F
rags
)
+
optional
(
"--min-intron-length"
,
min
I
ntron
L
ength
)
+
optional
(
"--trim-3-avgcov-thresh"
,
trim
3A
vg
C
ov
T
hresh
)
+
optional
(
"--trim-3-dropoff-frac"
,
trim
3D
rop
O
ff
F
rac
)
+
optional
(
"--max-multiread-fraction"
,
max
M
ultiread
F
raction
)
+
optional
(
"--overlap-radius"
,
overlap
R
adius
)
+
conditional
(
no
F
aux
R
eads
,
"--no-faux-reads"
)
+
optional
(
"--flag-3-overhang-tolerance"
,
flag
3O
verhang
T
olerance
)
+
optional
(
"--intron-overhang-tolerance"
,
intron
O
verhang
T
olerance
)
+
conditional
(
verbose
,
"--verbose"
)
+
conditional
(
quiet
,
"--quiet"
)
+
conditional
(
no
_u
pdate
_c
heck
,
"--no-update-check"
)
+
conditional
(
no
U
pdate
C
heck
,
"--no-update-check"
)
+
required
(
input
)
}
public/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/Cuffquant.scala
View file @
c8f56975
...
...
@@ -40,46 +40,46 @@ class Cuffquant(val root: Configurable) extends BiopetCommandLineFunction with V
/** input GTF file */
@Input
(
doc
=
"Input GTF file"
,
required
=
true
)
var
transcripts
_g
tf
:
File
=
null
var
transcripts
G
tf
:
File
=
null
/** output file, computed automatically from output directory */
@Output
(
doc
=
"Output CXB file"
)
lazy
val
outputCxb
:
File
=
{
require
(
output
_d
ir
!=
null
,
require
(
output
D
ir
!=
null
,
"Can not set Cuffquant CXB output while input file and/or output directory is not defined"
)
// cufflinks always outputs a transcripts.gtf file in the output directory
new
File
(
output
_d
ir
,
"abundances.cxb"
)
new
File
(
output
D
ir
,
"abundances.cxb"
)
}
/** write all output files to this directory [./] */
var
output
_d
ir
:
File
=
config
(
"output_dir"
,
default
=
new
File
(
"."
))
var
output
D
ir
:
File
=
config
(
"output_dir"
,
default
=
new
File
(
"."
))
/** ignore all alignment within transcripts in this file */
var
mask
_f
ile
:
Option
[
File
]
=
config
(
"mask_file"
)
var
mask
F
ile
:
Option
[
File
]
=
config
(
"mask_file"
)
/** use bias correction - reference fasta required [NULL] */
var
frag
_b
ias
_c
orrect
:
Option
[
String
]
=
config
(
"frag_bias_correct"
)
var
frag
B
ias
C
orrect
:
Option
[
String
]
=
config
(
"frag_bias_correct"
)
/** use 'rescue method' for multi-reads (more accurate) [FALSE] */
var
multi
_r
ead
_c
orrect
:
Boolean
=
config
(
"multi_read_correct"
,
default
=
false
)
var
multi
R
ead
C
orrect
:
Boolean
=
config
(
"multi_read_correct"
,
default
=
false
)
/** number of threads used during analysis [1] */
var
num
_t
hreads
:
Option
[
Int
]
=
config
(
"num_threads"
)
var
num
T
hreads
:
Option
[
Int
]
=
config
(
"num_threads"
)
/** library prep used for input reads [below] */
var
library
_t
ype
:
Option
[
String
]
=
config
(
"library_type"
)
var
library
T
ype
:
Option
[
String
]
=
config
(
"library_type"
)
/** average fragment length (unpaired reads only) [200] */
var
frag
_len_m
ean
:
Option
[
Int
]
=
config
(
"frag_len_mean"
)
var
frag
LenM
ean
:
Option
[
Int
]
=
config
(
"frag_len_mean"
)
/** fragment length std deviation (unpaired reads only) [80] */
var
frag
_len_std_d
ev
:
Option
[
Int
]
=
config
(
"frag_len_std_dev"
)
var
frag
LenStdD
ev
:
Option
[
Int
]
=
config
(
"frag_len_std_dev"
)
/** minimum number of alignments in a locus for testing [10] */
var
min
_a
lignment
_c
ount
:
Option
[
Int
]
=
config
(
"min_alignment_count"
)
var
min
A
lignment
C
ount
:
Option
[
Int
]
=
config
(
"min_alignment_count"
)
/** maximum iterations allowed for MLE calculation [5000] */
var
max
_mle_i
terations
:
Option
[
Int
]
=
config
(
"max_mle_iterations"
)
var
max
MleI
terations
:
Option
[
Int
]
=
config
(
"max_mle_iterations"
)
/** log-friendly verbose processing (no progress bar) [FALSE] */
var
verbose
:
Boolean
=
config
(
"verbose"
,
default
=
false
)
...
...
@@ -91,31 +91,31 @@ class Cuffquant(val root: Configurable) extends BiopetCommandLineFunction with V
var
seed
:
Option
[
Int
]
=
config
(
"seed"
)
/** do not contact server to check for update availability [FALSE] */
var
no
_u
pdate
_c
heck
:
Boolean
=
config
(
"no_update_check"
,
default
=
false
)
var
no
U
pdate
C
heck
:
Boolean
=
config
(
"no_update_check"
,
default
=
false
)
/** maximum fragments allowed in a bundle before skipping [500000] */
var
max
_b
undle
_f
rags
:
Option
[
Int
]
=
config
(
"max_bundle_frags"
)
var
max
B
undle
F
rags
:
Option
[
Int
]
=
config
(
"max_bundle_frags"
)
/** Maximum number of alignments allowed per fragment [unlim] */
var
max
_f
rag
_m
ultihits
:
Option
[
Int
]
=
config
(
"max_frag_multihits"
)
var
max
F
rag
M
ultihits
:
Option
[
Int
]
=
config
(
"max_frag_multihits"
)
/** No effective length correction [FALSE] */
var
no
_e
ffective
_l
ength
_c
orrection
:
Boolean
=
config
(
"no_effective_length_correction"
,
default
=
false
)
var
no
E
ffective
L
ength
C
orrection
:
Boolean
=
config
(
"no_effective_length_correction"
,
default
=
false
)
/** No length correction [FALSE] */
var
no
_l
ength
_c
orrection
:
Boolean
=
config
(
"no_length_correction"
,
default
=
false
)
var
no
L
ength
C
orrection
:
Boolean
=
config
(
"no_length_correction"
,
default
=
false
)
/** Skip a random subset of reads this size [0.0] */
var
read
_s
kip
_f
raction
:
Option
[
Double
]
=
config
(
"read_skip_fraction"
)
var
read
S
kip
F
raction
:
Option
[
Double
]
=
config
(
"read_skip_fraction"
)
/** Break all read pairs [FALSE] */
var
no
_r
ead
_p
airs
:
Boolean
=
config
(
"no_read_pairs"
,
default
=
false
)
var
no
R
ead
P
airs
:
Boolean
=
config
(
"no_read_pairs"
,
default
=
false
)
/** Trim reads to be this long (keep 5' end) [none] */
var
trim
_r
ead
_l
ength
:
Option
[
Int
]
=
config
(
"trim_read_length"
)
var
trim
R
ead
L
ength
:
Option
[
Int
]
=
config
(
"trim_read_length"
)
/** Disable SCV correction */
var
no
_scv_c
orrection
:
Boolean
=
config
(
"no_scv_correction"
,
default
=
false
)
var
no
ScvC
orrection
:
Boolean
=
config
(
"no_scv_correction"
,
default
=
false
)
def
versionRegex
=
"""cuffquant v(.*)"""
.
r
def
versionCommand
=
executable
...
...
@@ -123,28 +123,28 @@ class Cuffquant(val root: Configurable) extends BiopetCommandLineFunction with V
def
cmdLine
=
required
(
executable
)
+
required
(
"--output-dir"
,
output
_d
ir
)
+
optional
(
"--mask-file"
,
mask
_f
ile
)
+
optional
(
"--frag-bias-correct"
,
frag
_b
ias
_c
orrect
)
+
conditional
(
multi
_r
ead
_c
orrect
,
"--multi-read-correct"
)
+
optional
(
"--num-threads"
,
num
_t
hreads
)
+
optional
(
"--library-type"
,
library
_t
ype
)
+
optional
(
"--frag-len-mean"
,
frag
_len_m
ean
)
+
optional
(
"--frag-len-std-dev"
,
frag
_len_std_d
ev
)
+
optional
(
"--min-alignment-count"
,
min
_a
lignment
_c
ount
)
+
optional
(
"--max-mle-iterations"
,
max
_mle_i
terations
)
+
required
(
"--output-dir"
,
output
D
ir
)
+
optional
(
"--mask-file"
,
mask
F
ile
)
+
optional
(
"--frag-bias-correct"
,
frag
B
ias
C
orrect
)
+
conditional
(
multi
R
ead
C
orrect
,
"--multi-read-correct"
)
+
optional
(
"--num-threads"
,
num
T
hreads
)
+
optional
(
"--library-type"
,
library
T
ype
)
+
optional
(
"--frag-len-mean"
,
frag
LenM
ean
)
+
optional
(
"--frag-len-std-dev"
,
frag
LenStdD
ev
)
+
optional
(
"--min-alignment-count"
,
min
A
lignment
C
ount
)
+
optional
(
"--max-mle-iterations"
,
max
MleI
terations
)
+
conditional
(
verbose
,
"--verbose"
)
+
conditional
(
quiet
,
"--quiet"
)
+
optional
(
"--seed"
,
seed
)
+
conditional
(
no
_u
pdate
_c
heck
,
"--no-update-check"
)
+
optional
(
"--max-bundle-frags"
,
max
_b
undle
_f
rags
)
+
optional
(
"--max-frag-multihits"
,
max
_f
rag
_m
ultihits
)
+
conditional
(
no
_e
ffective
_l
ength
_c
orrection
,
"--no-effective-length-correction"
)
+
conditional
(
no
_l
ength
_c
orrection
,
"--no-length-correction"
)
+
optional
(
"--read-skip-fraction"
,
read
_s
kip
_f
raction
)
+
conditional
(
no
_r
ead
_p
airs
,
"--no-read-pairs"
)
+
optional
(
"--trim-read-length"
,
trim
_r
ead
_l
ength
)
+
conditional
(
no
_scv_c
orrection
,
"--no-scv-correction"
)
+
required
(
transcripts
_g
tf
)
+
conditional
(
no
U
pdate
C
heck
,
"--no-update-check"
)
+
optional
(
"--max-bundle-frags"
,
max
B
undle
F
rags
)
+
optional
(
"--max-frag-multihits"
,
max
F
rag
M
ultihits
)
+
conditional
(
no
E
ffective
L
ength
C
orrection
,
"--no-effective-length-correction"
)
+
conditional
(
no
L
ength
C
orrection
,
"--no-length-correction"
)
+
optional
(
"--read-skip-fraction"
,
read
S
kip
F
raction
)
+
conditional
(
no
R
ead
P
airs
,
"--no-read-pairs"
)
+
optional
(
"--trim-read-length"
,
trim
R
ead
L
ength
)
+
conditional
(
no
ScvC
orrection
,
"--no-scv-correction"
)
+
required
(
transcripts
G
tf
)
+
required
(
input
.
map
(
_
.
mkString
(
";"
).
mkString
(
" "
)))
}
public/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/Cutadapt.scala
View file @
c8f56975
...
...
@@ -192,7 +192,7 @@ class Cutadapt(val root: Configurable) extends BiopetCommandLineFunction with Su
"bpoutput"
->
0
,
"toomanyn"
->
0
)
val
adapter
_s
tats
:
mutable.Map
[
String
,
Long
]
=
mutable
.
Map
()
val
adapter
S
tats
:
mutable.Map
[
String
,
Long
]
=
mutable
.
Map
()
if
(
statsOutput
.
exists
)
{
val
statsFile
=
Source
.
fromFile
(
statsOutput
)
...
...
@@ -206,7 +206,7 @@ class Cutadapt(val root: Configurable) extends BiopetCommandLineFunction with Su
case
tooManyN
(
m
)
=>
stats
(
"toomanyn"
)
=
m
.
replaceAll
(
","
,
""
).
toLong
case
basePairsProcessed
(
m
)
=>
stats
(
"bpinput"
)
=
m
.
replaceAll
(
","
,
""
).
toLong
case
basePairsWritten
(
m
)
=>
stats
(
"bpoutput"
)
=
m
.
replaceAll
(
","
,
""
).
toLong
case
adapterR
(
adapter
,
count
)
=>
adapter
_s
tats
+=
(
adapter
->
count
.
toLong
)
case
adapterR
(
adapter
,
count
)
=>
adapter
S
tats
+=
(
adapter
->
count
.
toLong
)
case
_
=>
}
}
...
...
@@ -224,7 +224,7 @@ class Cutadapt(val root: Configurable) extends BiopetCommandLineFunction with Su
"num_reads_discarded_many_n"
->
stats
(
"toomanyn"
),
"num_bases_input"
->
stats
(
"bpinput"
),
"num_based_output"
->
stats
(
"bpoutput"
),
adaptersStatsName
->
adapter
_s
tats
.
toMap
adaptersStatsName
->
adapter
S
tats
.
toMap
)
}
...
...
public/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/Fastqc.scala
View file @
c8f56975
...
...
@@ -40,7 +40,7 @@ class Fastqc(val root: Configurable) extends BiopetCommandLineFunction with Vers
var
output
:
File
=
null
executable
=
config
(
"exe"
,
default
=
"fastqc"
)
var
java
_e
xe
:
String
=
config
(
"exe"
,
default
=
"java"
,
submodule
=
"java"
,
freeVar
=
false
)
var
java
E
xe
:
String
=
config
(
"exe"
,
default
=
"java"
,
submodule
=
"java"
,
freeVar
=
false
)
var
kmers
:
Option
[
Int
]
=
config
(
"kmers"
)
var
quiet
:
Boolean
=
config
(
"quiet"
,
default
=
false
)
var
noextract
:
Boolean
=
config
(
"noextract"
,
default
=
false
)
...
...
@@ -85,7 +85,7 @@ class Fastqc(val root: Configurable) extends BiopetCommandLineFunction with Vers
/** return commandline to execute */
def
cmdLine
=
required
(
executable
)
+
optional
(
"--java"
,
java
_e
xe
)
+
optional
(
"--java"
,
java
E
xe
)
+
optional
(
"--threads"
,
threads
)
+
optional
(
"--contaminants"
,
contaminants
)
+
optional
(
"--adapters"
,
adapters
)
+
...
...
public/biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/Sickle.scala
View file @
c8f56975
...
...
@@ -31,22 +31,22 @@ import scala.io.Source
*/
class
Sickle
(
val
root
:
Configurable
)
extends
BiopetCommandLineFunction
with
Summarizable
with
Version
{
@Input
(
doc
=
"R1 input"
)
var
input
_
R1
:
File
=
_
var
inputR1
:
File
=
_
@Input
(
doc
=
"R2 input"
,
required
=
false
)
var
input
_
R2
:
File
=
_
var
inputR2
:
File
=
_
@Output
(
doc
=
"R1 output"
,
required
=
false
)
var
output
_
R1
:
File
=
_
var
outputR1
:
File
=
_
@Output
(
doc
=
"R2 output"
,
required
=
false
)
var
output
_
R2
:
File
=
_
var
outputR2
:
File
=
_
@Output
(
doc
=
"singles output"
,
required
=
false
)
var
output
_s
ingles
:
File
=
_
var
output
S
ingles
:
File
=
_
@Output
(
doc
=
"stats output"
)
var
output
_s
tats
:
File
=
_
var
output
S
tats
:
File
=
_