Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

69 lines
2.1KB

  1. task lohhla {
  2. String sample_id
  3. File normBAM
  4. File normBAM_bai
  5. File tumorBAM
  6. File tumorBAM_bai
  7. File hlas
  8. File ascat
  9. String docker
  10. String cluster
  11. String disk_size
  12. command <<<
  13. set -o pipefail
  14. set -e
  15. now_path=`pwd`
  16. echo $now_path > $now_path/test.txt
  17. mkdir -p ./ana/${sample_id}/
  18. cp ${normBAM} ./ana/${sample_id}/
  19. cp ${normBAM_bai} ./ana/${sample_id}/
  20. cp ${tumorBAM} ./ana/${sample_id}/
  21. cp ${tumorBAM_bai} ./ana/${sample_id}/
  22. cp ${hlas} ./ana/
  23. cp ${ascat} ./ana/
  24. for line in `ls ./ana/${sample_id}|sed 's/.bam.*//'|sort|uniq`
  25. do
  26. new_name=`echo $line|sed 's/\./_/g'`
  27. mv ./ana/${sample_id}/$line.bam ./ana/${sample_id}/$new_name.bam
  28. mv ./ana/${sample_id}/$line.bam.bai ./ana/${sample_id}/$new_name.bam.bai
  29. done
  30. normBAM_file=`ls ./ana/${sample_id}/|grep bam|grep -v "TT"|grep -v "bai"|grep -v "_T_sorted"`
  31. Rscript /software/lohhla_hg38/LOHHLAscript_hg38.R --patientId ${sample_id} \
  32. --outputDir $now_path/ana/${sample_id}_output \
  33. --normalBAMfile $now_path/ana/${sample_id}/$normBAM_file \
  34. --BAMDir $now_path/ana/${sample_id} \
  35. --hlaPath $now_path/ana/${sample_id}_winners.hlas \
  36. --HLAfastaLoc /software/lohhla_hg38/data/abc_complete.fasta \
  37. --CopyNumLoc $now_path/ana/${sample_id}_ascat.txt \
  38. --mappingStep TRUE --minCoverageFilter 10 --fishingStep TRUE --cleanUp FALSE \
  39. --gatkDir /software/picard-tools-1.122 \
  40. --novoDir /opt/conda/bin \
  41. --HLAexonLoc /software/lohhla_hg38/data/hla.dat
  42. tar -zcvf ./ana/${sample_id}_output.tgz ./ana/${sample_id}_output
  43. >>>
  44. runtime {
  45. docker : docker
  46. cluster: cluster
  47. systemDisk: "cloud_ssd 40"
  48. dataDisk: "cloud_ssd " + disk_size + " /cromwell_root/"
  49. }
  50. output {
  51. Array[File] lohhla_xls = glob("./ana/${sample_id}_output/*.xls")
  52. Array[File] lohhla_pdf = glob("./ana/${sample_id}_output/Figures/*.pdf")
  53. Array[File] lohhla_tgz = glob("./ana/*.tgz")
  54. }
  55. }