-
Notifications
You must be signed in to change notification settings - Fork 0
/
SRA2Fastq.wdl
49 lines (41 loc) · 1.02 KB
/
SRA2Fastq.wdl
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
#########################################
# This is a WDL File #
# This file was formed for SRA to Fastq #
# Author: Sun Hao #
# Date: YYYY/MM/DD 2024/03/06 #
#########################################
version 1.0
task SRAtoFastq {
input {
Array[String] sra_files
Int ncpu = 4
Int memory_gb = 8
}
command <<<
set -e
mkdir -p fastq_output
for sra_file in ~{sep=' ' sra_files}; do
fasterq-dump ${sra_file} --threads ~{ncpu} --outdir ./fastq_output/
done
>>>
runtime {
cpu: ncpu
memory: "~{memory_gb} GB"
docker: "ghcr.io/stjude/abralab/sratoolkit:v3.0.0"
}
output {
Array[File] fastq_files = glob("fastq_output/*.fastq")
}
}
workflow ConvertSRAtoFastq {
input {
Array[File] sra_files
}
call SRAtoFastq {
input:
sra_files = sra_files,
}
output {
Array[File] fastq_files = SRAtoFastq.fastq_files
}
}