You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
799B

  1. task qualimap {
  2. File bam
  3. File bai
  4. String bamname = basename(bam,".bam")
  5. String docker
  6. String cluster_config
  7. String disk_size
  8. File? bed
  9. command <<<
  10. set -o pipefail
  11. set -e
  12. nt=$(nproc)
  13. if [ ${bed} ]; then
  14. awk 'BEGIN{OFS="\t"}{sub("\r","",$3);print $1,$2,$3,"",0,"."}' ${bed} > new.bed
  15. /opt/qualimap/qualimap bamqc -bam ${bam} -gff new.bed -outformat PDF:HTML -nt $nt -outdir ${bamname} --java-mem-size=60G
  16. else
  17. /opt/qualimap/qualimap bamqc -bam ${bam} -outformat PDF:HTML -nt $nt -outdir ${bamname} --java-mem-size=60G
  18. fi
  19. tar -zcvf ${bamname}_qualimap.zip ${bamname}
  20. >>>
  21. runtime {
  22. docker:docker
  23. cluster:cluster_config
  24. systemDisk:"cloud_ssd 40"
  25. dataDisk:"cloud_ssd " + disk_size + " /cromwell_root/"
  26. }
  27. output {
  28. File zip = "${bamname}_qualimap.zip"
  29. }
  30. }