From 686a58f88170cc0d073450c15dd2f630cd1da448 Mon Sep 17 00:00:00 2001 From: Laurent Modolo <laurent.modolo@ens-lyon.fr> Date: Tue, 3 Jul 2018 16:35:16 +0200 Subject: [PATCH] HISAT2:2.0.0: add docker files --- src/Rnaseq.config | 121 ----------------- src/Rnaseq.nf | 122 ------------------ .../HISAT2/2.0.0/docker_init.sh | 0 src/fasta_sampler.nf | 18 --- 4 files changed, 261 deletions(-) delete mode 100644 src/Rnaseq.config delete mode 100644 src/Rnaseq.nf mode change 100644 => 100755 src/docker_modules/HISAT2/2.0.0/docker_init.sh delete mode 100644 src/fasta_sampler.nf diff --git a/src/Rnaseq.config b/src/Rnaseq.config deleted file mode 100644 index 1170cb83..00000000 --- a/src/Rnaseq.config +++ /dev/null @@ -1,121 +0,0 @@ -profiles { - docker { - docker.temp = 'auto' - docker.enabled = true - process { - $adaptor_removal { - container = "cutadapt:1.14" - } - } - } - sge { - process{ - $adaptor_removal { - beforeScript = "module purge; module load cutadapt/1.14" - executor = "sge" - cpus = 1 - memory = "5GB" - time = "6h" - queueSize = 1000 - pollInterval = '60sec' - queue = 'h6-E5-2667v4deb128' - penv = 'openmp8' - } - } - } -} - -profiles { - docker { - docker.temp = 'auto' - docker.enabled = true - process { - $trimming { - container = "urqt:d62c1f8" - } - } - } - sge { - process{ - $trimming { - beforeScript = "module purge; module load UrQt/d62c1f8" - executor = "sge" - cpus = 4 - memory = "5GB" - time = "6h" - queueSize = 1000 - pollInterval = '60sec' - queue = 'h6-E5-2667v4deb128' - penv = 'openmp8' - } - } - } -} -profiles { - docker { - docker.temp = 'auto' - docker.enabled = true - process { - $fasta_from_bed { - container = "bedtools:2.25.0" - } - } - } - sge { - process{ - $fasta_from_bed { - beforeScript = "module purge; module load BEDtools/2.25.0" - executor = "sge" - cpus = 1 - memory = "5GB" - time = "6h" - queueSize = 1000 - pollInterval = '60sec' - queue = 'h6-E5-2667v4deb128' - penv = 'openmp8' - } - } - } -} - -profiles { - docker { - docker.temp = 'auto' - docker.enabled = true - process { - $index_fasta { - container = "kallisto:0.43.1" - } - $mapping_fastq { - container = "kallisto:0.43.1" - } - } - } - sge { - process{ - $index_fasta { - beforeScript = "module purge; module load Kallisto/0.43.1" - executor = "sge" - cpus = 1 - memory = "5GB" - time = "6h" - queueSize = 1000 - pollInterval = '60sec' - queue = 'h6-E5-2667v4deb128' - penv = 'openmp8' - } - $mapping_fastq { - beforeScript = "module purge; module load Kallisto/0.43.1" - executor = "sge" - cpus = 4 - memory = "5GB" - time = "6h" - queueSize = 1000 - pollInterval = '60sec' - queue = 'h6-E5-2667v4deb128' - penv = 'openmp8' - } - } - } -} - diff --git a/src/Rnaseq.nf b/src/Rnaseq.nf deleted file mode 100644 index 1b59e883..00000000 --- a/src/Rnaseq.nf +++ /dev/null @@ -1,122 +0,0 @@ -params.fastq = "$baseDir/data/fastq/*_{1,2}.fastq" -params.fasta = "$baseDir/data/fasta/*.fasta" -params.bed = "$baseDir/data/annot/*.bed" - -log.info "fasta file : ${params.fasta}" -log.info "bed file : ${params.bed}" -log.info "fastq files : ${params.fastq}" - -Channel - .fromPath( params.fasta ) - .ifEmpty { error "Cannot find any fasta files matching: ${params.fasta}" } - .set { fasta_files } - -Channel - .fromPath( params.bed ) - .ifEmpty { error "Cannot find any bed files matching: ${params.bed}" } - .set { bed_files } - -Channel - .fromFilePairs( params.fastq ) - .ifEmpty { error "Cannot find any fastq files matching: ${params.fastq}" } - .set { fastq_files } - -process adaptor_removal { - tag "$pair_id" - publishDir "results/fastq/adaptor_removal/", mode: 'copy' - - input: - set pair_id, file(reads) from fastq_files - - output: - file "*_cut_R{1,2}.fastq.gz" into fastq_files_cut - - script: - """ - cutadapt -a AGATCGGAAGAG -g CTCTTCCGATCT -A AGATCGGAAGAG -G CTCTTCCGATCT \ - -o ${pair_id}_cut_R1.fastq.gz -p ${pair_id}_cut_R2.fastq.gz \ - ${reads[0]} ${reads[1]} > ${pair_id}_report.txt - """ -} - -process trimming { - tag "${reads}" - cpus 4 - publishDir "results/fastq/trimming/", mode: 'copy' - - input: - file reads from fastq_files_cut - - output: - file "*_trim_R{1,2}.fastq.gz" into fastq_files_trim - - script: -""" -UrQt --t 20 --m ${task.cpus} --gz \ ---in ${reads[0]} --inpair ${reads[1]} \ ---out ${reads[0].baseName}_trim_R1.fastq.gz --outpair ${reads[1].baseName}_trim_R2.fastq.gz \ -> ${reads[0].baseName}_trimming_report.txt -""" -} - -process fasta_from_bed { - tag "${bed.baseName}" - cpus 4 - publishDir "results/fasta/", mode: 'copy' - - input: - file fasta from fasta_files - file bed from bed_files - - output: - file "*_extracted.fasta" into fasta_files_extracted - - script: -""" -bedtools getfasta -name \ --fi ${fasta} -bed ${bed} -fo ${bed.baseName}_extracted.fasta -""" -} - -process index_fasta { - tag "$fasta.baseName" - publishDir "results/mapping/index/", mode: 'copy' - - input: - file fasta from fasta_files_extracted - - output: - file "*.index*" into index_files - - script: -""" -kallisto index -k 31 --make-unique -i ${fasta.baseName}.index ${fasta} \ -> ${fasta.baseName}_kallisto_report.txt -""" -} - - -process mapping_fastq { - tag "$reads" - cpus 4 - publishDir "results/mapping/quantification/", mode: 'copy' - - input: - file reads from fastq_files_trim - file index from index_files - - output: - file "*" into counts_files - - script: -""" -mkdir ${reads[0].baseName} -kallisto quant -i ${index} -t ${task.cpus} \ ---bias --bootstrap-samples 100 -o ${reads[0].baseName} \ -${reads[0]} ${reads[1]} &> ${reads[0].baseName}_kallisto_report.txt -""" -} - - - - diff --git a/src/docker_modules/HISAT2/2.0.0/docker_init.sh b/src/docker_modules/HISAT2/2.0.0/docker_init.sh old mode 100644 new mode 100755 diff --git a/src/fasta_sampler.nf b/src/fasta_sampler.nf deleted file mode 100644 index d1200ed4..00000000 --- a/src/fasta_sampler.nf +++ /dev/null @@ -1,18 +0,0 @@ -Channel - .fromPath( "data/tiny_dataset/fasta/*.fasta" ) - .set { fasta_file } - -process sample_fasta { - publishDir "results/sampling/", mode: 'copy' - - input: -file fasta from fasta_file - - output: -file "*_sample.fasta" into fasta_sample - - script: -""" -head ${fasta} > ${fasta.baseName}_sample.fasta -""" -} -- GitLab