Skip to content
Snippets Groups Projects
Commit 12922fc2 authored by aliarifki's avatar aliarifki Committed by Xavier Grand
Browse files

Ajout du process barcoding

parent a83c4592
No related branches found
No related tags found
No related merge requests found
...@@ -91,7 +91,7 @@ params.gpu_runners_per_device = 32 ...@@ -91,7 +91,7 @@ params.gpu_runners_per_device = 32
params.num_callers = 16 params.num_callers = 16
params.chunks_per_runner = 512 params.chunks_per_runner = 512
params.chunk_size = 1900 params.chunk_size = 1900
params.config_file = ""
/* Params out */ /* Params out */
...@@ -156,6 +156,11 @@ Channel ...@@ -156,6 +156,11 @@ Channel
.map(it -> [it.baseName, it]) .map(it -> [it.baseName, it])
.set{barcodes} .set{barcodes}
// Test pour barcoding process
Channel
.fromPath(params.pass)
.set{pass}
/* /*
**************************************************************** ****************************************************************
Imports Imports
...@@ -164,6 +169,7 @@ Channel ...@@ -164,6 +169,7 @@ Channel
if(!params.skipBC) { if(!params.skipBC) {
/* Hardware configuration, if Nvidia CUDA compatible graphic card is installed, use guppy-gpu, else guppy-cpu (much slower)*/ /* Hardware configuration, if Nvidia CUDA compatible graphic card is installed, use guppy-gpu, else guppy-cpu (much slower)*/
include { barcoding } from "./nf_modules/ont-guppy/main.nf"
if(params.gpu_mode) { if(params.gpu_mode) {
include { basecall_fast5_gpu } from "./nf_modules/ont-guppy/main.nf" include { basecall_fast5_gpu } from "./nf_modules/ont-guppy/main.nf"
} }
...@@ -201,9 +207,11 @@ include { rna_count } from "./nf_modules/rna_count/main.nf" ...@@ -201,9 +207,11 @@ include { rna_count } from "./nf_modules/rna_count/main.nf"
*/ */
workflow { workflow {
pass.view()
barcoding(pass)
//######################## BASECALLING ######################## //######################## BASECALLING ########################
/*
if(params.skipBC) { // we take fastq files as input and skip basecalling if(params.skipBC) { // we take fastq files as input and skip basecalling
concatenate(barcodes) concatenate(barcodes)
} }
......
...@@ -9,6 +9,7 @@ params.min_qscore = 7.0 ...@@ -9,6 +9,7 @@ params.min_qscore = 7.0
params.gpu_runners_per_device = 1 params.gpu_runners_per_device = 1
params.num_callers = 1 params.num_callers = 1
params.chunks_per_runner = 1 params.chunks_per_runner = 1
options = ""
process basecall_fast5_gpu { process basecall_fast5_gpu {
container = "${container_url}" container = "${container_url}"
label "gpus" label "gpus"
...@@ -27,6 +28,14 @@ process basecall_fast5_gpu { ...@@ -27,6 +28,14 @@ process basecall_fast5_gpu {
errorKit.view() errorKit.view()
} }
if (params.config_file != "") {
options = "-c /opt/ont/guppy/data/${params.config_file}"
}
else {
options = "--flowcell ${params.flowcell} \
--kit ${params.kit} "
}
input: input:
path(fast5_folder) path(fast5_folder)
...@@ -46,14 +55,12 @@ guppy_basecaller --compress_fastq \ ...@@ -46,14 +55,12 @@ guppy_basecaller --compress_fastq \
-i / \ -i / \
--input_file_list fichier.txt \ --input_file_list fichier.txt \
-s . \ -s . \
--flowcell ${params.flowcell} \
--kit ${params.kit} \
-x "cuda:all" \ -x "cuda:all" \
--min_qscore ${params.min_qscore} \ --min_qscore ${params.min_qscore} \
--gpu_runners_per_device ${params.gpu_runners_per_device} \ --gpu_runners_per_device ${params.gpu_runners_per_device} \
--num_callers ${params.num_callers} \ --num_callers ${params.num_callers} \
--chunks_per_runner ${params.chunks_per_runner} \ --chunks_per_runner ${params.chunks_per_runner} \
-c ${params.config_file} ${options}
""" """
} }
...@@ -98,3 +105,35 @@ guppy_basecaller --compress_fastq \ ...@@ -98,3 +105,35 @@ guppy_basecaller --compress_fastq \
--kit ${params.kit} --kit ${params.kit}
""" """
} }
<<<<<<< HEAD
=======
process barcoding {
container = "${container_url}"
label "big_mem_multi_cpus"
tag "$fast5_folder"
if (params.barcoding_out != "") {
publishDir "results/${params.barcoding_out}", mode: 'copy'
}
input:
path(pass_path)
output:
path("barcode")
script:
"""
guppy_barcoder \
--input_path ${pass_path} \
--save_path barcode/ \
-c /opt/ont/guppy/data/${params.config_file} \
--barcode_kits ${params.kit} \
--progress_stats_frequency 60 \
-x "cuda:all" \
--enable_trim_barcodes \
--trim_adapters \
--compress_fastq
"""
}
>>>>>>> 622494c (Ajout du process barcoding)
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