Просмотр исходного кода

fix bug: the timestamp of BED files

master
YaqingLiu 4 лет назад
Родитель
Сommit
727f0e671b
2 измененных файлов: 13 добавлений и 7 удалений
  1. +12
    -6
      tasks/batch.wdl
  2. +1
    -1
      workflow.wdl

+ 12
- 6
tasks/batch.wdl Просмотреть файл

Array[File] tumor_bai Array[File] tumor_bai
Array[File] normal_bam Array[File] normal_bam
Array[File] normal_bai Array[File] normal_bai
File bed
File? bed
File faidx File faidx
File fasta File fasta
File? ref_flat File? ref_flat
String cluster_config String cluster_config
String disk_size String disk_size


String annotate_opt = if (ref_flat != "") then "--annotate ${ref_flat}" else ""
String reference_opt = if (reference != "") then "--reference ${reference}" else ""
String access_opt = if (method == "amplicon") then "--access ${bed}" else "--access ${access_bed}"
String annotate_opt = if (ref_flat != "") then "--annotate ref_flat.txt" else ""
String reference_opt = if (reference != "") then "--reference my_reference.cnn" else ""
String access_opt = if (method == "amplicon") then "--access amplicon.bed" else "--access access-mappable.bed"


command <<< command <<<
set -o pipefail set -o pipefail
mkdir -p /cromwell_root/tmp/cnvkit mkdir -p /cromwell_root/tmp/cnvkit
cp ${sep=' ' normal_bai} /cromwell_root/tmp/cnvkit cp ${sep=' ' normal_bai} /cromwell_root/tmp/cnvkit
cp ${sep=' ' tumor_bai} /cromwell_root/tmp/cnvkit cp ${sep=' ' tumor_bai} /cromwell_root/tmp/cnvkit
# must exist parameters
cp ${fasta} /cromwell_root/tmp/cnvkit/hg38.fa cp ${fasta} /cromwell_root/tmp/cnvkit/hg38.fa
cp ${faidx} /cromwell_root/tmp/cnvkit/hg38.fai cp ${faidx} /cromwell_root/tmp/cnvkit/hg38.fai
cp ${access_bed} /cromwell_root/tmp/cnvkit/access-mappable.bed
# optional parameters
if [ ${bed} != "" ]; then cp ${bed} /cromwell_root/tmp/cnvkit/amplicon.bed; fi
if [ ${ref_flat} != "" ]; then cp ${ref_flat} /cromwell_root/tmp/cnvkit/ref_flat.txt; fi
if [ ${reference} != "" ]; then cp ${reference} /cromwell_root/tmp/cnvkit/my_reference.cnn; fi
cd /cromwell_root/tmp/cnvkit cd /cromwell_root/tmp/cnvkit
mkdir results mkdir results
cnvkit.py batch ${sep=' ' tumor_bam} --normal ${sep=' ' normal_bam} \ cnvkit.py batch ${sep=' ' tumor_bam} --normal ${sep=' ' normal_bam} \
--method ${method} \ --method ${method} \
--targets ${bed} ${annotate_opt} \
--fasta hg38.fa ${access_opt} ${reference_opt} \
--targets amplicon.bed ${access_opt} ${annotate_opt} \
--fasta hg38.fa ${reference_opt} \
--output-reference ~/${sample_id}.reference.cnn \ --output-reference ~/${sample_id}.reference.cnn \
--output-dir ./results/ \ --output-dir ./results/ \
--drop-low-coverage --diagram --scatter --drop-low-coverage --diagram --scatter

+ 1
- 1
workflow.wdl Просмотреть файл

Array[File] tumor_bai Array[File] tumor_bai
Array[File] normal_bam Array[File] normal_bam
Array[File] normal_bai Array[File] normal_bai
File bed
File? bed
File faidx File faidx
File fasta File fasta
File? ref_flat File? ref_flat

Загрузка…
Отмена
Сохранить