Add cwl and docker files
[lightning.git] / cwl / gvcf2fasta / gvcf2fasta_splitvcftar-wf.cwl
1 # Copyright (C) The Lightning Authors. All rights reserved.
2 #
3 # SPDX-License-Identifier: AGPL-3.0
4
5 cwlVersion: v1.1
6 class: Workflow
7 label: Convert gVCF to FASTA for gVCF tar split by chromosome
8 requirements:
9   ScatterFeatureRequirement: {}
10 hints:
11   DockerRequirement:
12     dockerPull: vcfutil
13   ResourceRequirement:
14     ramMin: 5000
15
16 inputs:
17   sampleid:
18     type: string
19     label: Sample ID
20   vcftar:
21     type: File
22     label: Input gVCF tar
23   gqcutoff:
24     type: int
25     label: GQ (Genotype Quality) cutoff for filtering
26   genomebed:
27     type: File
28     label: Whole genome BED
29   ref:
30     type: File
31     label: Reference FASTA
32   haplotypes:
33     type: int[]
34     label: Haplotypes of sample
35     default: [1, 2]
36
37 outputs:
38   fas:
39     type: File[]
40     label: Output pair of FASTAs
41     outputSource: bcftools-consensus/fa
42
43 steps:
44   untar-concat-get_bed_varonlyvcf:
45     run: untar-concat-get_bed_varonlyvcf.cwl
46     in:
47       sampleid: sampleid
48       vcftar: vcftar
49       gqcutoff: gqcutoff
50       genomebed: genomebed
51     out: [nocallbed, varonlyvcf]
52
53   bcftools-consensus:
54     run: bcftools-consensus.cwl
55     scatter: haplotype
56     in:
57       sampleid: sampleid
58       vcf: untar-concat-get_bed_varonlyvcf/varonlyvcf
59       ref: ref
60       haplotype: haplotypes
61       mask: untar-concat-get_bed_varonlyvcf/nocallbed
62     out: [fa]