Infer and visualize copy number from high-throughput DNA sequencing data.
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

63 行
2.0KB

  1. task batch {
  2. String sample_id
  3. Array[File] tumor_bam
  4. Array[File] normal_bam
  5. File faidx
  6. File fasta
  7. File? ref_flat
  8. File access_bed
  9. File? reference
  10. String method
  11. String segment_method
  12. String docker
  13. String cluster_config
  14. String disk_size
  15. String annotate_opt = if (ref_flat != "") then "--annotate ref_flat.txt" else ""
  16. String reference_opt = if (reference != "") then "--reference my_reference.cnn" else ""
  17. String access_opt = if (method == "amplicon") then "--access target.bed" else "--access access-mappable.bed"
  18. command <<<
  19. set -o pipefail
  20. set -e
  21. nt=$(nproc)
  22. mkdir -p /cromwell_root/tmp/cnvkit
  23. # must exist parameters
  24. cp ${fasta} /cromwell_root/tmp/cnvkit/hg_ref.fa
  25. cp ${faidx} /cromwell_root/tmp/cnvkit/hg_ref.fai
  26. cp ${access_bed} /cromwell_root/tmp/cnvkit/access-mappable.bed
  27. # optional parameters
  28. if [ ${ref_flat} != "" ]; then cp ${ref_flat} /cromwell_root/tmp/cnvkit/ref_flat.txt; fi
  29. if [ ${reference} != "" ]; then cp ${reference} /cromwell_root/tmp/cnvkit/my_reference.cnn; fi
  30. cd /cromwell_root/tmp/cnvkit
  31. mkdir results
  32. cnvkit.py batch -p $nt ${sep=' ' tumor_bam} --normal ${sep=' ' normal_bam} \
  33. --method ${method} --segment-method ${segment_method} \
  34. ${access_opt} ${annotate_opt} \
  35. --fasta hg_ref.fa ${reference_opt} \
  36. --output-reference ${sample_id}.reference.cnn \
  37. --output-dir ./results/ \
  38. --drop-low-coverage \
  39. --diagram --scatter
  40. cp ${sample_id}.reference.cnn ~/${sample_id}.reference.cnn
  41. >>>
  42. runtime {
  43. docker: docker
  44. cluster: cluster_config
  45. systemDisk: "cloud_ssd 40"
  46. dataDisk: "cloud_ssd " + disk_size + " /cromwell_root/"
  47. }
  48. output {
  49. File reference_cnn = "${sample_id}.reference.cnn"
  50. Array[File] results = glob("/cromwell_root/tmp/cnvkit/results/*")
  51. }
  52. }