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.

58 lines
2.0KB

  1. task teprof_s1 {
  2. String sample_id
  3. File fastq1
  4. File fastq2
  5. File STAR_INDEX_DIR
  6. String disk_size
  7. String docker
  8. String cluster
  9. command <<<
  10. set -o pipefail
  11. set -e
  12. pigz -p 16 -dc ${fastq1} > ${sample_id}_R1.fastq
  13. pigz -p 16 -dc ${fastq2} > ${sample_id}_R2.fastq
  14. STAR \
  15. --runThreadN 8 \
  16. --genomeDir ${STAR_INDEX_DIR} \
  17. --readFilesIn ${sample_id}_R1.fastq ${sample_id}_R2.fastq \
  18. --outSAMstrandField intronMotif \
  19. --outSAMtype BAM SortedByCoordinate \
  20. --outFileNamePrefix ./${sample_id}.
  21. samtools view -@ 16 -q 255 -h ${sample_id}.Aligned.sortedByCoord.out.bam > ${sample_id}.filtered.Aligned.sortedByCoord.out.bam
  22. stringtie -p 16 ${sample_id}.filtered.Aligned.sortedByCoord.out.bam -o ${sample_id}.Aligned.sortedByCoord.out.gtf -m 100 -c 1 --rf
  23. python /database/rnapipelinerefhg38/rnapipeline/rmskhg38_annotate_gtf_update_test_tpm.py ${sample_id}.Aligned.sortedByCoord.out.gtf /database/rnapipelinerefhg38/rnapipeline/arguments.txt
  24. python /database/rnapipelinerefhg38/rnapipeline/annotationtpmprocess.py ${sample_id}.Aligned.sortedByCoord.out.gtf_annotated_filtered_test
  25. mkdir ${sample_id}_annotated
  26. cp ${sample_id}.Aligned.sortedByCoord.out.gtf_annotated_* ${sample_id}_annotated
  27. tar -zcvf ${sample_id}_annotated.tgz ${sample_id}_annotated
  28. rm ${sample_id}.filtered.Aligned.sortedByCoord.out.bam
  29. rm ${sample_id}_R1.fastq
  30. rm ${sample_id}_R2.fastq
  31. >>>
  32. runtime {
  33. docker: docker
  34. cluster: cluster
  35. systemDisk: "cloud_ssd 40"
  36. dataDisk: "cloud_ssd " + disk_size + " /cromwell_root/"
  37. }
  38. output {
  39. File annotated = "${sample_id}_annotated.tgz"
  40. File annotated_use = "${sample_id}.Aligned.sortedByCoord.out.gtf_annotated_filtered_test_c"
  41. File output_bam = "${sample_id}.Aligned.sortedByCoord.out.bam"
  42. File output_gtf = "${sample_id}.Aligned.sortedByCoord.out.gtf"
  43. }
  44. }