Skip to content
Snippets Groups Projects
Commit 0c88d32c authored by Gervaise Henry's avatar Gervaise Henry :cowboy:
Browse files

Merge branch '8-makeBigWig' of git.biohpc.swmed.edu:GUDMAP_RBK/RNA-seq into 35-RSeQC

parents 4d598c06 ff7f8483
Branches
Tags
3 merge requests!37v0.0.1,!24Develop,!23Resolve "process_RSeQC"
...@@ -64,8 +64,16 @@ alignData: ...@@ -64,8 +64,16 @@ alignData:
dedupData: dedupData:
stage: unit stage: unit
script: script:
- singularity exec 'docker://bicf/picard2.21.7:2.0.0' java -jar /picard/build/libs/picard.jar MarkDuplicates I=./test_data/bam/small/Q-Y5JA_1M.se.sorted.bam O=Q-Y5JA_1M.se.deduped.bam M=Q-Y5JA_1M.se.deduped.Metrics.txt REMOVE_DUPLICATES=true - singularity run 'docker://bicf/gudmaprbkdedup:2.0.0' java -jar /picard/build/libs/picard.jar MarkDuplicates I=./test_data/bam/small/Q-Y5JA_1M.se.sorted.bam O=Q-Y5JA_1M.se.deduped.bam M=Q-Y5JA_1M.se.deduped.Metrics.txt REMOVE_DUPLICATES=true
- singularity run 'docker://bicf/gudmaprbkdedup:2.0.0' samtools sort -@ `nproc` -O BAM -o Q-Y5JA_1M.se.sorted.deduped.bam ./test_data/bam/small/Q-Y5JA_1M.se.deduped.bam
- singularity run 'docker://bicf/gudmaprbkdedup:2.0.0' samtools index -@ `nproc` -b ./test_data/bam/small/Q-Y5JA_1M.se.sorted.deduped.bam Q-Y5JA_1M.se.sorted.deduped.bai
- pytest -m dedupData - pytest -m dedupData
makeBigWig:
stage: unit
script:
- singularity run 'docker://bicf/deeptools3.3:2.0.0' bamCoverage -p `nproc` -b ./test_data/bam/small/Q-Y5JA_1M.se.sorted.deduped.bam -o Q-Y5JA_1M.se.bw
- pytest -m makeBigWig
fastqc: fastqc:
stage: unit stage: unit
......
...@@ -16,13 +16,13 @@ process { ...@@ -16,13 +16,13 @@ process {
executor = 'local' executor = 'local'
} }
withName:trimData { withName:trimData {
queue = 'super' queue = '128GB,256GB,256GBv1'
} }
withName:alignData { withName:alignData {
queue = '256GB,256GBv1' queue = '256GB,256GBv1'
} }
withName: dedupData { withName: dedupData {
queue = 'super' queue = '128GB,256GB,256GBv1'
} }
withName: fastqc { withName: fastqc {
queue = 'super' queue = 'super'
......
...@@ -30,11 +30,14 @@ process { ...@@ -30,11 +30,14 @@ process {
container = 'bicf/gudmaprbkaligner:2.0.0' container = 'bicf/gudmaprbkaligner:2.0.0'
} }
withName: dedupData { withName: dedupData {
container = 'bicf/picard2.21.7:2.0.0' container = 'bicf/gudmaprbkdedup:2.0.0'
} }
withName: fastqc { withName: fastqc {
container = 'bicf/fastqc:2.0.0' container = 'bicf/fastqc:2.0.0'
} }
withName: makeBigWig {
container = 'bicf/deeptools3.3:2.0.0'
}
} }
trace { trace {
...@@ -64,4 +67,4 @@ manifest { ...@@ -64,4 +67,4 @@ manifest {
mainScript = 'rna-seq.nf' mainScript = 'rna-seq.nf'
version = 'v0.0.1_indev' version = 'v0.0.1_indev'
nextflowVersion = '>=19.09.0' nextflowVersion = '>=19.09.0'
} }
\ No newline at end of file
...@@ -340,7 +340,7 @@ process dedupData { ...@@ -340,7 +340,7 @@ process dedupData {
path rawBam path rawBam
output: output:
path ("${repRID}.deduped.bam") into dedupBam tuple val ("${repRID}"), path ("${repRID}.sorted.deduped.bam"), path ("${repRID}.sorted.deduped.bai") into dedupBam
path ("${repRID}.dedup.out") path ("${repRID}.dedup.out")
path ("${repRID}.dedup.err") path ("${repRID}.dedup.err")
...@@ -351,6 +351,8 @@ process dedupData { ...@@ -351,6 +351,8 @@ process dedupData {
# remove duplicated reads # remove duplicated reads
java -jar /picard/build/libs/picard.jar MarkDuplicates I=${rawBam} O=${repRID}.deduped.bam M=${repRID}.deduped.Metrics.txt REMOVE_DUPLICATES=true 1>>${repRID}.dedup.out 2>> ${repRID}.dedup.err java -jar /picard/build/libs/picard.jar MarkDuplicates I=${rawBam} O=${repRID}.deduped.bam M=${repRID}.deduped.Metrics.txt REMOVE_DUPLICATES=true 1>>${repRID}.dedup.out 2>> ${repRID}.dedup.err
samtools sort -@ `nproc` -O BAM -o ${repRID}.sorted.deduped.bam ${repRID}.deduped.bam 1>>${repRID}.dedup.out 2>> ${repRID}.dedup.err
samtools index -@ `nproc` -b ${repRID}.sorted.deduped.bam ${repRID}.sorted.deduped.bai 1>>${repRID}.dedup.out 2>> ${repRID}.dedup.err
""" """
} }
...@@ -376,4 +378,23 @@ process fastqc { ...@@ -376,4 +378,23 @@ process fastqc {
# run fastqc # run fastqc
fastqc *.fastq.gz -o . >>${repRID}.fastqc.err fastqc *.fastq.gz -o . >>${repRID}.fastqc.err
""" """
} }
\ No newline at end of file
/*
*Make BigWig files for later processes
*/
process makeBigWig {
tag "${repRID}"
publishDir "${logsDir}", mode: 'copy', pattern: "*.makeBigWig.err"
input:
set val (repRID), path (inBam), path (inBai) from dedupBam
output:
path ("${repRID}.bw")
script:
"""
bamCoverage -p `nproc` -b ${inBam} -o ${repRID}.bw
"""
}
#!/usr/bin/env python3
import pytest
import pandas as pd
import os
import utils
data_output_path = os.path.dirname(os.path.abspath(__file__)) + \
'/../../'
@pytest.mark.makeBigWig
def test_makeBigWig():
assert os.path.exists(os.path.join(data_output_path, 'Q-Y5JA_1M.se.bw'))
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment