pipeline/wdl/pollution.wdl

64 lines
1.4 KiB
Plaintext
Raw Normal View History

2023-12-29 10:11:01 +08:00
# pollution
2023-12-28 09:14:58 +08:00
2023-12-19 13:37:52 +08:00
task run_pollution {
String name
String output_dir
String probe
String vcf
String? vcf2
2024-01-01 14:25:34 +08:00
command {
2023-12-19 13:37:52 +08:00
if [ ! -d ${output_dir}/pollution ];then
mkdir ${output_dir}/pollution
fi
pollution.py -n ${name} \
-v ${vcf} \
-v2 ${vcf2} \
-o ${output_dir}/pollution \
-p ${probe} \
-b $PUBLIC/pollution/${probe}_contaminate_ref.bed \
-c $PUBLIC/pollution/${probe}_contaminate_cnvkit.bed
2023-12-26 10:18:15 +08:00
2024-01-01 14:25:34 +08:00
}
2023-12-19 13:37:52 +08:00
}
workflow call_pollution {
Boolean run=true
String tumor
String? normal
String output_dir
String probe
String raw_vcf
String somatic_vcf
String germline_vcf
if (run) {
if (defined(normal)) {
2023-12-26 10:18:15 +08:00
call run_pollution as run_pollution_paired {
2023-12-19 13:37:52 +08:00
input:
name=tumor,
output_dir=output_dir,
probe=probe,
vcf=somatic_vcf,
vcf2=germline_vcf
}
}
if (!defined(normal)) {
2023-12-26 10:18:15 +08:00
call run_pollution as run_pollution_single {
2023-12-19 13:37:52 +08:00
input:
name=tumor,
output_dir=output_dir,
probe=probe,
vcf=raw_vcf
}
}
}
output {
String pollution_res = "${output_dir}/pollution/${tumor}_pollution.csv"
}
2023-11-30 15:31:35 +08:00
}