Skip to content
Snippets Groups Projects
Commit 4dc89d1a authored by Xavier Grand's avatar Xavier Grand
Browse files

Add pychopper instead porechop not functionnal

parent 33c2088a
No related branches found
No related tags found
No related merge requests found
# SPDX-FileCopyrightText: 2023 Xavier Grand <xavier.grand@inserm.fr>
#
# SPDX-License-Identifier: AGPL-3.0-or-later
FROM continuumio/miniconda3
MAINTAINER Xavier Grand
RUN apt-get update && apt-get install -y procps
ENV PYCHOPPER_VERSION="2.5.0"
RUN conda init \
&& conda config --add channels r \
&& conda config --add channels defaults \
&& conda config --add channels conda-forge \
&& conda config --add channels bioconda \
&& conda create -y -n pychopper
SHELL ["conda", "run", "-n", "pychopper", "/bin/bash", "-c"]
RUN conda install -c nanoporetech -c conda-forge -c bioconda "nanoporetech::pychopper" \
&& echo "conda activate pychopper" >> /root/.bashrc
ENV PATH /usr/local/envs/pychopper/bin:/usr/local/condabin:$PATH
\ No newline at end of file
#!/bin/sh
# docker pull lbmc/pychopper:2.5.0
# docker build src/.docker_modules/pychopper/2.5.0 -t 'lbmc/pychopper:2.5.0'
# docker push lbmc/pychopper:2.5.0
# docker buildx build --platform linux/amd64,linux/arm64 -t "lbmc/pychopper:2.5.0" --push src/.docker_modules/pychopper/2.5.0
# docker pull xgrand/pychopper:2.5.0
docker build src/.docker_modules/pychopper/2.5.0 -t 'xgrand/pychopper:2.5.0'
docker push xgrand/pychopper:2.5.0
# docker buildx build --platform linux/amd64,linux/arm64 -t "xgrand/pychopper:2.5.0" --push src/.docker_modules/pychopper/2.5.0
\ No newline at end of file
......@@ -84,9 +84,9 @@ params.skipBC = true
params.gpu_mode = false
params.adapt = "CGACTGGAGCACGAGGACACTGA" // "CGACTGGAGCACGAGGACACTGACATGGACTGAAGGAGTAGAAA" //
params.gsp = "TTAGGCAGAGGTGAAAAAGTTG"
params.transcriptome = "./data/202201_Full-length_HBV_GTFv3/20220112_preCore_FL_HBV_XGR_transcripts.fasta"
params.genome = "./data/202201_Full-length_HBV_GTFv3/preCore_XGR.fasta"
params.gtf = "./data/202201_Full-length_HBV_GTFv3/20220112_GTF_preCore_FL_HBV_XGR.gtf"
// params.transcriptome = "./data/202201_Full-length_HBV_GTFv3/20220112_preCore_FL_HBV_XGR_transcripts.fasta"
params.genome = "/home/xavier/Data/Genome/202201_Full-length_HBV_GTFv3/20230516_HBV_FL_preCore_reference.fasta"
params.gtf = "/home/xavier/Data/Genome/202201_Full-length_HBV_GTFv3/20230516_GTF_preCore_FL_HBV_XGR.gtf"
params.flowcell = "FLO-MIN106"
params.kit = "SQK-PBK004"
......@@ -188,7 +188,9 @@ include { start_position_individuals } from "./nf_modules/start_positions/main.n
include { jwr_checker } from "./nf_modules/nanosplicer/main.nf"
include { junctions_nanosplicer } from "./nf_modules/junction_nanosplicer/main.nf"
include { rna_count } from "./nf_modules/rna_count/main.nf"
include { porechop } from "./nf_modules/porechop/main.nf"
include { trimmming_pychopper } from "./nf_modules/pychopper/main.nf"
/*
****************************************************************
......@@ -250,9 +252,13 @@ workflow {
//Trimming with porechop
porechop(seqkit_grep.out.filtered_fastq)
//Trimming with pychopper
//trimmming_pychopper(seqkit_grep.out.filtered_fastq)
//Cut of the 5'RACE sequence
cut_5pRACE(porechop.out.porechoped_fastq, params.adapt)
//cut_5pRACE(trimmming_pychopper.out.pychoped_fastq, params.adapt)
//cut_5pRACE(seqkit_grep.out.filtered_fastq, params.adapt)
//########################## MAPPING ##########################
......@@ -304,3 +310,22 @@ workflow {
rna_count(files_for_rna_count)
}
// End message:
workflow.onComplete {
println ( workflow.success ? """
DUPFinder tools execution summary
---------------------------
Completed at : ${workflow.complete}
Duration : ${workflow.duration}
Success : ${workflow.success}
workDir : ${workflow.workDir}
exit status : ${workflow.exitStatus}
""" : """
Failed: ${workflow.errorReport}
exit status : ${workflow.exitStatus}
"""
)
}
version = "2.5.0"
container_url = "xgrand/pychopper:${version}"
params.pychopper_out =""
process trimmming_pychopper {
container = "${container_url}"
label "big_mem_multi_cpus"
tag "${barcode}"
if (params.pychopper_out != "") {
publishDir "results/${params.pychopper_out}", mode: 'copy'
}
input:
tuple val(barcode), path(fastq)
output:
tuple val(barcode), path("${barcode}/${barcode}_merged_pychoped.fastq.gz"), emit: pychoped_fastq
script:
"""
mkdir ${barcode}
cd ${barcode}/
pychopper -k ${params.kit} -r ${barcode}_pychopper_report.pdf -S ${barcode}_statistics.tsv -t ${task.cpus} ../${fastq} ${barcode}_merged_pychoped.fastq.gz
"""
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment