-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmetagenome-assembly-pipeline.cwl
More file actions
524 lines (524 loc) · 12.5 KB
/
Copy pathmetagenome-assembly-pipeline.cwl
File metadata and controls
524 lines (524 loc) · 12.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
class: Workflow
cwlVersion: v1.2
id: metagenome_assembly_pipeline
label: Metagenome Assembly and Quantification
$namespaces:
sbg: 'https://www.sevenbridges.com/'
inputs:
- id: assemblyName
type: string
doc: Name of the assembly
'sbg:x': 2291.843994140625
'sbg:y': 135.27081298828125
- id: runIds
type: 'string[]'
doc: MGX seqrun IDs
'sbg:x': -1998.548095703125
'sbg:y': -476.452392578125
- id: apiKey
type: string
'sbg:x': -1995.6141357421875
'sbg:y': -61.706756591796875
- id: projectName
type: string
'sbg:x': -2003.3499755859375
'sbg:y': -340.8485107421875
- id: hostURI
type: string
'sbg:x': -2001.72265625
'sbg:y': -196.57472229003906
- id: taxonomyDirectory
type: Directory
'sbg:x': 1731.2672119140625
'sbg:y': -357.7862548828125
- id: checkmDataDir
type: Directory
'sbg:x': 1310.708251953125
'sbg:y': -735.12158203125
- id: dastoolDatabaseDir
type: Directory
'sbg:x': 909.6793823242188
'sbg:y': -747.2562866210938
- id: metabuliDatabaseDir
type: Directory
'sbg:x': 1301.1171875
'sbg:y': -289.041748046875
outputs:
- id: success
outputSource:
- annotationclient/success
type: boolean
'sbg:x': 2657.0322265625
'sbg:y': -49.6494140625
steps:
- id: fastp
in:
- id: detect-paired-end-adapter
default: true
- id: read1
source: seqrunfetch/fwdReads
- id: read2
source: seqrunfetch/revReads
- id: trim-poly-g
default: true
out:
- id: reads1
- id: reads2
run: tools/fastp.cwl
label: 'fastp: trim PE reads'
scatter:
- read1
- read2
scatterMethod: dotproduct
'sbg:x': -1094.861572265625
'sbg:y': 419.8493957519531
- id: megahit
in:
- id: presets
default: meta-sensitive
- id: read1
source:
- fastp/reads1
- id: read2
source:
- fastp/reads2
- id: singleended
source:
- fastp_1/reads1
pickValue: all_non_null
out:
- id: contigs
run: tools/megahit.cwl
label: 'MEGAHIT: metagenome assembly'
'sbg:x': -477.37213134765625
'sbg:y': 392.39459228515625
- id: samtools_sam2bam
in:
- id: input
source: strobealign_pe/sam
- id: thread-number
default: 10
out:
- id: output
run: tools/samtools-sam2bam.cwl
scatter:
- input
scatterMethod: dotproduct
'sbg:x': 215.52435302734375
'sbg:y': 552.3421020507812
- id: samtools_sort
in:
- id: input
source: samtools_sam2bam/output
- id: thread-number
default: 10
out:
- id: output
run: tools/samtools-sort.cwl
scatter:
- input
scatterMethod: dotproduct
'sbg:x': 383.2618103027344
'sbg:y': 558.3683471679688
- id: checkm
in:
- id: bin_suffix
default: fas
- id: binnedFastas
source:
- tsv2bins/binFastas
- id: dataDir
source: checkmDataDir
out:
- id: output
run: tools/checkm.cwl
'sbg:x': 1425.5784912109375
'sbg:y': -645.318115234375
- id: feature_counts_pe_samples
in:
- id: annotation
source: prodigal_assembly/annotations
- id: attribute_type
default: ID
- id: bamFile
source: samtools_sort/output
- id: feature_type
default: CDS
out:
- id: output_counts
run: tools/featureCounts.cwl
label: featureCounts per paired sample
scatter:
- bamFile
scatterMethod: dotproduct
'sbg:x': 1676.5452880859375
'sbg:y': 433.1310729980469
- id: assign_bin
in:
- id: kraken2Output
source: metabuli/output
- id: taxonomyDirectory
source: taxonomyDirectory
out:
- id: lineage
run: tools/assignBin.cwl
label: Taxonomic assignment of a metagenomic bin
scatter:
- kraken2Output
scatterMethod: dotproduct
'sbg:x': 1866.4539794921875
'sbg:y': -317.1265563964844
- id: dastool
in:
- id: binAssignments
linkMerge: merge_flattened
source:
- removefirstline/binAssignment
- filterbin/filtered
- metabat/binAssignment
- id: contigs
source: rename_contigs/renamedFile
- id: dastoolDatabaseDir
source: dastoolDatabaseDir
- id: threads
default: 10
out:
- id: binTSV
run: tools/dastool.cwl
label: DAS tool
'sbg:x': 1043.5084228515625
'sbg:y': -626.27734375
- id: bamstats
in:
- id: bamFile
source: samtools_merge_all/output
- id: outFile
default: contig_coverage.tsv
out:
- id: tsvOutput
run: tools/bamstats.cwl
label: bamstats contig coverage
'sbg:x': 1941.128662109375
'sbg:y': 624.66259765625
- id: tsv2bins
in:
- id: assembledContigs
source: rename_contigs/renamedFile
- id: scaffold2bin
source: dastool/binTSV
out:
- id: binFastas
run: tools/tsv2bins.cwl
label: TSV to binned FASTA
'sbg:x': 1162.4385986328125
'sbg:y': -487.7795104980469
- id: prodigal_assembly
in:
- id: inputFile
source: rename_contigs/renamedFile
- id: metagenomic
default: false
out:
- id: annotations
- id: genes
- id: proteins
run: tools/prodigal.cwl
label: Prodigal 2.6.3
'sbg:x': 1101.5889892578125
'sbg:y': 372.96759033203125
- id: annotationclient
in:
- id: apiKey
source: apiKey
- id: assemblyName
source: assemblyName
- id: binLineages
source:
- rename_tax_file/renamedFile
- id: binnedFastas
source:
- tsv2bins/binFastas
- id: checkmReport
source: checkm/output
- id: contigCoverage
source: bamstats/tsvOutput
- id: featureCountsPerSample
linkMerge: merge_flattened
source:
- feature_counts_se_samples/output_counts
- feature_counts_pe_samples/output_counts
- id: featureCountsTotal
source: merge_featurecounts/tsvOutput
- id: hostURI
source: hostURI
- id: predictedGenes
source: prodigal_assembly/annotations
- id: projectName
source: projectName
- id: runIds
source:
- runIds
out:
- id: success
run: tools/annotationclient.cwl
label: MGX Annotate
'sbg:x': 2443.158203125
'sbg:y': -52.65791320800781
- id: seqrunfetch
in:
- id: apiKey
source: apiKey
- id: hostURI
source: hostURI
- id: projectName
source: projectName
- id: runId
source: runIds
out:
- id: fwdReads
- id: revReads
- id: singleReads
run: tools/seqrunfetch.cwl
label: MGX Fetch sequences
scatter:
- runId
scatterMethod: dotproduct
'sbg:x': -1400.3929443359375
'sbg:y': 389.80621337890625
- id: strobealign_pe
in:
- id: read1
source: fastp/reads1
- id: read2
source: fastp/reads2
- id: reference
source: rename_contigs/renamedFile
- id: skip_unaligned
default: true
out:
- id: sam
run: tools/strobealign.cwl
label: 'StrobeAlign: map PE reads'
scatter:
- read1
- read2
scatterMethod: dotproduct
'sbg:x': 30.550609588623047
'sbg:y': 550.9737548828125
- id: vamb
in:
- id: bamfiles
source:
- samtools_sort/output
- id: contigs
source: rename_contigs/renamedFile
out:
- id: binAssignment
run: tools/vamb.cwl
label: VAMB
'sbg:x': 502.3221130371094
'sbg:y': -659.5704956054688
- id: semibin2
in:
- id: bamfiles
source:
- samtools_sort/output
- id: contigs
source: rename_contigs/renamedFile
out:
- id: binAssignment
run: tools/semibin2.cwl
label: SemiBin 2
'sbg:x': 488.7420654296875
'sbg:y': -821.9281005859375
- id: vamb2bintsv
in:
- id: vambOutput
source: vamb/binAssignment
out:
- id: binAssignment
run: tools/vamb2bintsv.cwl
label: VAMB to Bin TSV
'sbg:x': 637.894775390625
'sbg:y': -590.1747436523438
- id: fastp_1
in:
- id: read1
source: seqrunfetch/singleReads
out:
- id: reads1
- id: reads2
run: tools/fastp.cwl
label: 'fastp: trim SE reads'
scatter:
- read1
scatterMethod: dotproduct
'sbg:x': -1085.7545166015625
'sbg:y': 178.67938232421875
when: $(inputs.read1 != null)
- id: strobealign_se
in:
- id: read1
source: fastp_1/reads1
pickValue: all_non_null
- id: reference
source: rename_contigs/renamedFile
out:
- id: sam
run: tools/strobealign.cwl
label: 'StrobeAlign: map SE reads'
scatter:
- read1
scatterMethod: dotproduct
'sbg:x': 16.529380798339844
'sbg:y': 296.0989074707031
- id: samtools_sam2bam_1
in:
- id: input
source: strobealign_se/sam
out:
- id: output
run: tools/samtools-sam2bam.cwl
scatter:
- input
scatterMethod: dotproduct
'sbg:x': 199.96910095214844
'sbg:y': 296.8038330078125
- id: samtools_sort_1
in:
- id: input
source: samtools_sam2bam_1/output
out:
- id: output
run: tools/samtools-sort.cwl
scatter:
- input
scatterMethod: dotproduct
'sbg:x': 353.5250244140625
'sbg:y': 295.3158264160156
- id: samtools_merge_all
in:
- id: inputs
linkMerge: merge_flattened
source:
- samtools_sort_1/output
- samtools_sort/output
out:
- id: output
run: tools/samtools-merge.cwl
'sbg:x': 1241.137451171875
'sbg:y': 627.0687255859375
- id: feature_counts_se_samples
in:
- id: annotation
source: prodigal_assembly/annotations
- id: attribute_type
default: ID
- id: bamFile
source: samtools_sort_1/output
- id: feature_type
default: CDS
out:
- id: output_counts
run: tools/featureCounts.cwl
label: featureCounts per single-end sample
scatter:
- bamFile
scatterMethod: dotproduct
'sbg:x': 1676.52392578125
'sbg:y': 251.05320739746094
- id: removefirstline
in:
- id: infile
source: semibin2/binAssignment
out:
- id: binAssignment
run: tools/removefirstline.cwl
label: remove first line
'sbg:x': 638.3487548828125
'sbg:y': -734.4201049804688
- id: filterbin
in:
- id: assembledContigs
source: rename_contigs/renamedFile
- id: binTSV
source: vamb2bintsv/binAssignment
out:
- id: filtered
run: tools/filterbin.cwl
label: filter bin TSV by size
'sbg:x': 763.8992919921875
'sbg:y': -487.2594909667969
- id: metabat
in:
- id: bamfiles
source:
- samtools_sort/output
- id: contigs
source: rename_contigs/renamedFile
out:
- id: binAssignment
run: tools/metabat.cwl
label: >-
MetaBAT: Metagenome Binning based on Abundance and Tetranucleotide
frequency
'sbg:x': 481.2071533203125
'sbg:y': -973.3815307617188
- id: merge_featurecounts
in:
- id: featureCountsTSV
linkMerge: merge_flattened
source:
- feature_counts_se_samples/output_counts
- feature_counts_pe_samples/output_counts
- id: outFile
default: genecoverage_total.tsv
out:
- id: tsvOutput
run: tools/mergeFC.cwl
'sbg:x': 1843.674072265625
'sbg:y': 296.18115234375
- id: metabuli
in:
- id: databaseDir
source: metabuliDatabaseDir
- id: querySequences
source: tsv2bins/binFastas
out:
- id: output
run: tools/metabuli.cwl
scatter:
- querySequences
scatterMethod: dotproduct
'sbg:x': 1438.596923828125
'sbg:y': -284.7552490234375
- id: rename_tax_file
in:
- id: binFile
source: tsv2bins/binFastas
- id: taxFile
source: assign_bin/lineage
out:
- id: renamedFile
run: tools/renameTaxFile.cwl
scatter:
- binFile
- taxFile
scatterMethod: dotproduct
'sbg:x': 2175.639892578125
'sbg:y': -391.54400634765625
- id: rename_contigs
in:
- id: inFile
source: megahit/contigs
- id: outFile
default: contigs.fasta
out:
- id: renamedFile
run: tools/renameContigs.cwl
'sbg:x': -296.1886291503906
'sbg:y': 397.2237548828125
requirements:
- class: ScatterFeatureRequirement
- class: MultipleInputFeatureRequirement
- class: InlineJavascriptRequirement