@@ -28,7 +28,7 @@ process {
28
28
// Pre-processing
29
29
//
30
30
withName: FASTQC_RAW {
31
- ext.args = { params.arguments_fastqc ?: '' }
31
+ ext.args = params.arguments_fastqc
32
32
ext.prefix = { "${meta.id}_raw" }
33
33
publishDir = [
34
34
path: { "${params.outdir}/preprocessing/fastqc/raw" },
@@ -39,7 +39,7 @@ process {
39
39
}
40
40
41
41
withName: TRIMMOMATIC {
42
- ext.args = {"ILLUMINACLIP:${ params.adapter_fasta}:2:30:10"}
42
+ ext.args = params.arguments_trimmomatic
43
43
publishDir = [
44
44
[
45
45
path: { "${params.outdir}/preprocessing/trimmomatic/log" },
@@ -58,7 +58,7 @@ process {
58
58
}
59
59
60
60
withName: FASTP {
61
- ext.args = { params.arguments_fastp ?: '' }
61
+ ext.args = params.arguments_fastp
62
62
publishDir = [
63
63
[
64
64
path: { "${params.outdir}/preprocessing/fastp/report" },
@@ -90,6 +90,7 @@ process {
90
90
}
91
91
92
92
withName: UMITOOLS_EXTRACT{
93
+ ext.args = params.arguments_umitools_extract
93
94
publishDir = [
94
95
[
95
96
path: { "${params.outdir}/preprocessing/umi/umitools/log" },
@@ -109,7 +110,7 @@ process {
109
110
110
111
111
112
withName: HUMID {
112
- ext.args = { params.arguments_humid ?: '' }
113
+ ext.args = '-s' + ( params.arguments_humid?: '')
113
114
publishDir = [
114
115
[
115
116
path: { "${params.outdir}/preprocessing/umi/humid/log" },
@@ -135,7 +136,7 @@ process {
135
136
}
136
137
137
138
withName: BBMAP_BBDUK {
138
- ext.args = { params.arguments_bbduk ?: '' }
139
+ ext.args = params.arguments_bbduk
139
140
publishDir = [
140
141
[
141
142
path: { "${params.outdir}/preprocessing/bbduk/log" },
@@ -154,7 +155,7 @@ process {
154
155
}
155
156
156
157
withName: PRINSEQ_READS {
157
- ext.args = { params.arguments_prinseq_reads ?: '' }
158
+ ext.args = '-out_gz' + ( params.arguments_prinseq_reads?: '')
158
159
publishDir = [
159
160
[
160
161
path: { "${params.outdir}/preprocessing/prinseq" },
@@ -173,7 +174,7 @@ process {
173
174
}
174
175
175
176
withName: FASTQC_TRIM {
176
- ext.args = { params.arguments_fastqc ?: '' }
177
+ ext.args = params.arguments_fastqc
177
178
ext.prefix = { "${meta.id}_trim" }
178
179
publishDir = [
179
180
path: { "${params.outdir}/preprocessing/fastqc/trim" },
@@ -194,7 +195,8 @@ process {
194
195
}
195
196
196
197
withName: KRAKEN2_HOST_REMOVE {
197
- memory = { 200.GB * task.attempt }
198
+ memory = { 200.GB * task.attempt }
199
+ ext.args = params.arguments_kraken2_host
198
200
ext.prefix = { "${meta.id}_kraken2_host" }
199
201
publishDir = [
200
202
[
@@ -214,7 +216,7 @@ process {
214
216
}
215
217
216
218
withName: FASTQC_HOST {
217
- ext.args = { params.arguments_fastqc ?: '' }
219
+ ext.args = params.arguments_fastqc
218
220
ext.prefix = { "${meta.id}_host" }
219
221
publishDir = [
220
222
path: { "${params.outdir}/preprocessing/fastqc/host" },
@@ -251,16 +253,16 @@ process {
251
253
]
252
254
}
253
255
254
- withName: SEQKIT_REPLACE{
255
- ext.args = { params.arguments_seqkit_replace ?: '' }
256
- ext.suffix= 'fasta'
256
+ withName: SEQKIT_REPLACE {
257
+ ext.args = '-p "[\\|\\/\\\\\\]" -r "-"'
258
+ ext.suffix = 'fasta'
257
259
publishDir = [
258
260
enabled: false,
259
261
]
260
262
}
261
263
262
- withName: BLAST_MAKEBLASTDB{
263
- ext.args = { params.arguments_blast_makeblastdb ?: '' }
264
+ withName: BLAST_MAKEBLASTDB {
265
+ ext.args = params.arguments_blast_makeblastdb
264
266
publishDir = [
265
267
path: { "${params.outdir}/databases/" },
266
268
mode: params.publish_dir_mode,
@@ -271,84 +273,74 @@ process {
271
273
]
272
274
}
273
275
274
- //
275
- // Taxonomic classification
276
- //
277
- if (!params.skip_read_classification){
278
-
279
- withName: KRAKEN2_KRAKEN2 {
280
- ext.prefix = { "${meta.id}_kraken2" }
281
- ext.args = [
282
- params.kraken2_save_minimizers ? { "--report-minimizer-data" } : "",
283
- ].join(' ').trim()
284
- publishDir = [
285
- path: { "${params.outdir}/metagenomic_diversity/kraken2/" },
286
- mode: params.publish_dir_mode,
287
- pattern: '*.{txt,fastq.gz}',
288
- saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
289
- ]
290
- }
276
+ withName: KRAKEN2_KRAKEN2 {
277
+ ext.prefix = { "${meta.id}_kraken2" }
278
+ ext.args = params.arguments_kraken
279
+ publishDir = [
280
+ path: { "${params.outdir}/metagenomic_diversity/kraken2/" },
281
+ mode: params.publish_dir_mode,
282
+ pattern: '*.{txt,fastq.gz}',
283
+ saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
284
+ ]
285
+ }
291
286
292
- withName: BRACKEN_BRACKEN {
293
- ext.prefix = { "${meta.id}_bracken" }
294
- publishDir = [
295
- path: { "${params.outdir}/metagenomic_diversity/bracken/" },
296
- mode: params.publish_dir_mode,
297
- pattern: '*.tsv',
298
- saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
299
- ]
300
- }
287
+ withName: BRACKEN_BRACKEN {
288
+ ext.prefix = { "${meta.id}_bracken" }
289
+ publishDir = [
290
+ path: { "${params.outdir}/metagenomic_diversity/bracken/" },
291
+ mode: params.publish_dir_mode,
292
+ pattern: '*.tsv',
293
+ saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
294
+ ]
295
+ }
301
296
302
- withName: KRAKENTOOLS_KREPORT2KRONA {
303
- publishDir = [
304
- enabled: false,
305
- ]
306
- }
297
+ withName: KRAKENTOOLS_KREPORT2KRONA {
298
+ publishDir = [
299
+ enabled: false,
300
+ ]
301
+ }
307
302
308
- withName: KAIJU_KAIJU {
309
- ext.args = { params.arguments_kaiju ?: '' }
310
- publishDir = [
311
- path: { "${params.outdir}/metagenomic_diversity/kaiju/" },
312
- mode: params.publish_dir_mode,
313
- pattern: '*.tsv',
314
- saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
315
- ]
316
- }
303
+ withName: KAIJU_KAIJU {
304
+ ext.args = params.arguments_kaiju
305
+ publishDir = [
306
+ path: { "${params.outdir}/metagenomic_diversity/kaiju/" },
307
+ mode: params.publish_dir_mode,
308
+ pattern: '*.tsv',
309
+ saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
310
+ ]
311
+ }
317
312
318
- withName: KAIJU_KAIJU2TABLE {
319
- ext.args = { [
320
- params.arguments_kaiju2table ?: '',
321
- "-l ${params.kaiju_taxon_rank}"
322
- ].join(' ').trim() }
323
- publishDir = [
324
- path: { "${params.outdir}/metagenomic_diversity/kaiju/" },
325
- mode: params.publish_dir_mode,
326
- pattern: '*.{txt}',
327
- saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
328
- ]
329
- }
313
+ withName: KAIJU_KAIJU2TABLE {
314
+ ext.args = params.arguments_kaiju2table
315
+ publishDir = [
316
+ path: { "${params.outdir}/metagenomic_diversity/kaiju/" },
317
+ mode: params.publish_dir_mode,
318
+ pattern: '*.{txt}',
319
+ saveAs: { filename -> params.prefix || params.global_prefix ? "${params.global_prefix}-$filename" : filename }
320
+ ]
321
+ }
330
322
331
- withName: KAIJU_KAIJU2KRONA {
332
- ext.prefix = { "${meta.id}_kaiju" }
333
- ext.args = '-v -u'
334
- publishDir = [
335
- enabled: false
336
- ]
337
- }
323
+ withName: KAIJU_KAIJU2KRONA {
324
+ ext.prefix = { "${meta.id}_kaiju" }
325
+ ext.args = params.arguments_kaiju2krona
326
+ publishDir = [
327
+ enabled: false
328
+ ]
329
+ }
338
330
339
- withName: KRONA_CLEANUP {
340
- publishDir = [
341
- enabled: false
342
- ]
343
- }
331
+ withName: KRONA_CLEANUP {
332
+ publishDir = [
333
+ enabled: false
334
+ ]
335
+ }
344
336
345
- withName: KRONA_KTIMPORTTEXT {
346
- publishDir = [
347
- path: { "${params.outdir}/metagenomic_diversity/krona/" },
348
- mode: params.publish_dir_mode ,
349
- pattern: '*.{html}'
350
- ]
351
- }
337
+ withName: KRONA_KTIMPORTTEXT {
338
+ ext.args = params.arguments_krona
339
+ publishDir = [
340
+ path: { "${ params.outdir}/metagenomic_diversity/krona/" } ,
341
+ mode: params.publish_dir_mode,
342
+ pattern: '*.{html}'
343
+ ]
352
344
}
353
345
354
346
//
0 commit comments