Build branch main with version main (1d87dc7)
Build pipeline: viash-hub.rnaseq.main-g2rlq
Source commit: 1d87dc7c24
Source message: Multiple fixes (#23)
* multiple fixes
* update arguments and add test
* fix biobox module calls
* fix dependency
* add rsem merge counts
* exclude general stats in multiqc report
* output markduplicates metrics
* rename output reference files
This commit is contained in:
@@ -323,26 +323,16 @@ argument_groups:
|
||||
multiple_sep: ";"
|
||||
- name: "Read filtering options"
|
||||
arguments:
|
||||
- type: "boolean"
|
||||
- type: "boolean_true"
|
||||
name: "--skip_bbsplit"
|
||||
description: "Skip BBSplit for removal of non-reference genome reads."
|
||||
info: null
|
||||
default:
|
||||
- true
|
||||
required: false
|
||||
direction: "input"
|
||||
multiple: false
|
||||
multiple_sep: ";"
|
||||
- type: "boolean"
|
||||
- type: "boolean_true"
|
||||
name: "--remove_ribo_rna"
|
||||
description: "Enable the removal of reads derived from ribosomal RNA using SortMeRNA."
|
||||
info: null
|
||||
default:
|
||||
- false
|
||||
required: false
|
||||
direction: "input"
|
||||
multiple: false
|
||||
multiple_sep: ";"
|
||||
- name: "Other options"
|
||||
arguments:
|
||||
- type: "string"
|
||||
@@ -363,7 +353,7 @@ argument_groups:
|
||||
description: "Path to output directory"
|
||||
info: null
|
||||
default:
|
||||
- "$id.$key.read_1.fastq"
|
||||
- "$id.read_1.fastq"
|
||||
must_exist: false
|
||||
create_parent: true
|
||||
required: false
|
||||
@@ -375,7 +365,7 @@ argument_groups:
|
||||
description: "Path to output directory"
|
||||
info: null
|
||||
default:
|
||||
- "$id.$key.read_2.fastq"
|
||||
- "$id.read_2.fastq"
|
||||
must_exist: false
|
||||
create_parent: true
|
||||
required: false
|
||||
@@ -520,6 +510,40 @@ argument_groups:
|
||||
direction: "output"
|
||||
multiple: false
|
||||
multiple_sep: ";"
|
||||
- type: "file"
|
||||
name: "--trim_json"
|
||||
description: "The fastp json format report file name"
|
||||
info: null
|
||||
default:
|
||||
- "$id.fastp_out.json"
|
||||
must_exist: true
|
||||
create_parent: true
|
||||
required: false
|
||||
direction: "output"
|
||||
multiple: false
|
||||
multiple_sep: ";"
|
||||
- type: "file"
|
||||
name: "--trim_html"
|
||||
description: "The fastp html format report file name"
|
||||
info: null
|
||||
default:
|
||||
- "$id.fastp_out.html"
|
||||
must_exist: true
|
||||
create_parent: true
|
||||
required: false
|
||||
direction: "output"
|
||||
multiple: false
|
||||
multiple_sep: ";"
|
||||
- type: "file"
|
||||
name: "--merged_out"
|
||||
description: "File name to store merged fastp output."
|
||||
info: null
|
||||
must_exist: true
|
||||
create_parent: true
|
||||
required: false
|
||||
direction: "output"
|
||||
multiple: false
|
||||
multiple_sep: ";"
|
||||
resources:
|
||||
- type: "nextflow_script"
|
||||
path: "main.nf"
|
||||
@@ -538,6 +562,11 @@ dependencies:
|
||||
- name: "umitools/umitools_extract"
|
||||
repository:
|
||||
type: "local"
|
||||
- name: "umi_tools/umi_tools_extract"
|
||||
repository:
|
||||
type: "vsh"
|
||||
repo: "vsh/biobox"
|
||||
tag: "v0.2.0"
|
||||
- name: "trimgalore"
|
||||
repository:
|
||||
type: "local"
|
||||
@@ -644,11 +673,12 @@ build_info:
|
||||
output: "target/executable/workflows/pre_processing"
|
||||
executable: "target/executable/workflows/pre_processing/pre_processing"
|
||||
viash_version: "0.9.0"
|
||||
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
|
||||
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
|
||||
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
|
||||
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
|
||||
dependencies:
|
||||
- "target/nextflow/fastqc"
|
||||
- "target/nextflow/umitools/umitools_extract"
|
||||
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/umi_tools/umi_tools_extract"
|
||||
- "target/nextflow/trimgalore"
|
||||
- "target/nextflow/bbmap_bbsplit"
|
||||
- "target/nextflow/sortmerna"
|
||||
|
||||
@@ -333,13 +333,11 @@ function ViashHelp {
|
||||
echo ""
|
||||
echo "Read filtering options:"
|
||||
echo " --skip_bbsplit"
|
||||
echo " type: boolean"
|
||||
echo " default: true"
|
||||
echo " type: boolean_true"
|
||||
echo " Skip BBSplit for removal of non-reference genome reads."
|
||||
echo ""
|
||||
echo " --remove_ribo_rna"
|
||||
echo " type: boolean"
|
||||
echo " default: false"
|
||||
echo " type: boolean_true"
|
||||
echo " Enable the removal of reads derived from ribosomal RNA using SortMeRNA."
|
||||
echo ""
|
||||
echo "Other options:"
|
||||
@@ -352,12 +350,12 @@ function ViashHelp {
|
||||
echo "Output:"
|
||||
echo " --qc_output1"
|
||||
echo " type: file, output"
|
||||
echo " default: \$id.\$key.read_1.fastq"
|
||||
echo " default: \$id.read_1.fastq"
|
||||
echo " Path to output directory"
|
||||
echo ""
|
||||
echo " --qc_output2"
|
||||
echo " type: file, output"
|
||||
echo " default: \$id.\$key.read_2.fastq"
|
||||
echo " default: \$id.read_2.fastq"
|
||||
echo " Path to output directory"
|
||||
echo ""
|
||||
echo " --fastqc_html_1"
|
||||
@@ -413,6 +411,20 @@ function ViashHelp {
|
||||
echo " type: file, output, file must exist"
|
||||
echo " default: \$id.salmon_quant_output"
|
||||
echo " Results from Salmon quant"
|
||||
echo ""
|
||||
echo " --trim_json"
|
||||
echo " type: file, output, file must exist"
|
||||
echo " default: \$id.fastp_out.json"
|
||||
echo " The fastp json format report file name"
|
||||
echo ""
|
||||
echo " --trim_html"
|
||||
echo " type: file, output, file must exist"
|
||||
echo " default: \$id.fastp_out.html"
|
||||
echo " The fastp html format report file name"
|
||||
echo ""
|
||||
echo " --merged_out"
|
||||
echo " type: file, output, file must exist"
|
||||
echo " File name to store merged fastp output."
|
||||
}
|
||||
|
||||
# initialise variables
|
||||
@@ -754,24 +766,12 @@ while [[ $# -gt 0 ]]; do
|
||||
;;
|
||||
--skip_bbsplit)
|
||||
[ -n "$VIASH_PAR_SKIP_BBSPLIT" ] && ViashError Bad arguments for option \'--skip_bbsplit\': \'$VIASH_PAR_SKIP_BBSPLIT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_SKIP_BBSPLIT="$2"
|
||||
[ $# -lt 2 ] && ViashError Not enough arguments passed to --skip_bbsplit. Use "--help" to get more information on the parameters. && exit 1
|
||||
shift 2
|
||||
;;
|
||||
--skip_bbsplit=*)
|
||||
[ -n "$VIASH_PAR_SKIP_BBSPLIT" ] && ViashError Bad arguments for option \'--skip_bbsplit=*\': \'$VIASH_PAR_SKIP_BBSPLIT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_SKIP_BBSPLIT=$(ViashRemoveFlags "$1")
|
||||
VIASH_PAR_SKIP_BBSPLIT=true
|
||||
shift 1
|
||||
;;
|
||||
--remove_ribo_rna)
|
||||
[ -n "$VIASH_PAR_REMOVE_RIBO_RNA" ] && ViashError Bad arguments for option \'--remove_ribo_rna\': \'$VIASH_PAR_REMOVE_RIBO_RNA\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_REMOVE_RIBO_RNA="$2"
|
||||
[ $# -lt 2 ] && ViashError Not enough arguments passed to --remove_ribo_rna. Use "--help" to get more information on the parameters. && exit 1
|
||||
shift 2
|
||||
;;
|
||||
--remove_ribo_rna=*)
|
||||
[ -n "$VIASH_PAR_REMOVE_RIBO_RNA" ] && ViashError Bad arguments for option \'--remove_ribo_rna=*\': \'$VIASH_PAR_REMOVE_RIBO_RNA\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_REMOVE_RIBO_RNA=$(ViashRemoveFlags "$1")
|
||||
VIASH_PAR_REMOVE_RIBO_RNA=true
|
||||
shift 1
|
||||
;;
|
||||
--extra_fq_subsample_args)
|
||||
@@ -939,6 +939,39 @@ while [[ $# -gt 0 ]]; do
|
||||
VIASH_PAR_SALMON_QUANT_OUTPUT=$(ViashRemoveFlags "$1")
|
||||
shift 1
|
||||
;;
|
||||
--trim_json)
|
||||
[ -n "$VIASH_PAR_TRIM_JSON" ] && ViashError Bad arguments for option \'--trim_json\': \'$VIASH_PAR_TRIM_JSON\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_TRIM_JSON="$2"
|
||||
[ $# -lt 2 ] && ViashError Not enough arguments passed to --trim_json. Use "--help" to get more information on the parameters. && exit 1
|
||||
shift 2
|
||||
;;
|
||||
--trim_json=*)
|
||||
[ -n "$VIASH_PAR_TRIM_JSON" ] && ViashError Bad arguments for option \'--trim_json=*\': \'$VIASH_PAR_TRIM_JSON\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_TRIM_JSON=$(ViashRemoveFlags "$1")
|
||||
shift 1
|
||||
;;
|
||||
--trim_html)
|
||||
[ -n "$VIASH_PAR_TRIM_HTML" ] && ViashError Bad arguments for option \'--trim_html\': \'$VIASH_PAR_TRIM_HTML\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_TRIM_HTML="$2"
|
||||
[ $# -lt 2 ] && ViashError Not enough arguments passed to --trim_html. Use "--help" to get more information on the parameters. && exit 1
|
||||
shift 2
|
||||
;;
|
||||
--trim_html=*)
|
||||
[ -n "$VIASH_PAR_TRIM_HTML" ] && ViashError Bad arguments for option \'--trim_html=*\': \'$VIASH_PAR_TRIM_HTML\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_TRIM_HTML=$(ViashRemoveFlags "$1")
|
||||
shift 1
|
||||
;;
|
||||
--merged_out)
|
||||
[ -n "$VIASH_PAR_MERGED_OUT" ] && ViashError Bad arguments for option \'--merged_out\': \'$VIASH_PAR_MERGED_OUT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_MERGED_OUT="$2"
|
||||
[ $# -lt 2 ] && ViashError Not enough arguments passed to --merged_out. Use "--help" to get more information on the parameters. && exit 1
|
||||
shift 2
|
||||
;;
|
||||
--merged_out=*)
|
||||
[ -n "$VIASH_PAR_MERGED_OUT" ] && ViashError Bad arguments for option \'--merged_out=*\': \'$VIASH_PAR_MERGED_OUT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
|
||||
VIASH_PAR_MERGED_OUT=$(ViashRemoveFlags "$1")
|
||||
shift 1
|
||||
;;
|
||||
---engine)
|
||||
VIASH_ENGINE_ID="$2"
|
||||
shift 2
|
||||
@@ -1125,7 +1158,7 @@ if [ -z ${VIASH_PAR_EXTRA_SALMON_QUANT_ARGS+x} ]; then
|
||||
VIASH_PAR_EXTRA_SALMON_QUANT_ARGS=""
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_SKIP_BBSPLIT+x} ]; then
|
||||
VIASH_PAR_SKIP_BBSPLIT="true"
|
||||
VIASH_PAR_SKIP_BBSPLIT="false"
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_REMOVE_RIBO_RNA+x} ]; then
|
||||
VIASH_PAR_REMOVE_RIBO_RNA="false"
|
||||
@@ -1134,10 +1167,10 @@ if [ -z ${VIASH_PAR_EXTRA_FQ_SUBSAMPLE_ARGS+x} ]; then
|
||||
VIASH_PAR_EXTRA_FQ_SUBSAMPLE_ARGS="--record-count 1000000 --seed 1"
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_QC_OUTPUT1+x} ]; then
|
||||
VIASH_PAR_QC_OUTPUT1="\$id.\$key.read_1.fastq"
|
||||
VIASH_PAR_QC_OUTPUT1="\$id.read_1.fastq"
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_QC_OUTPUT2+x} ]; then
|
||||
VIASH_PAR_QC_OUTPUT2="\$id.\$key.read_2.fastq"
|
||||
VIASH_PAR_QC_OUTPUT2="\$id.read_2.fastq"
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_FASTQC_HTML_1+x} ]; then
|
||||
VIASH_PAR_FASTQC_HTML_1="\$id.read_1.fastqc.html"
|
||||
@@ -1175,6 +1208,12 @@ fi
|
||||
if [ -z ${VIASH_PAR_SALMON_QUANT_OUTPUT+x} ]; then
|
||||
VIASH_PAR_SALMON_QUANT_OUTPUT="\$id.salmon_quant_output"
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_TRIM_JSON+x} ]; then
|
||||
VIASH_PAR_TRIM_JSON="\$id.fastp_out.json"
|
||||
fi
|
||||
if [ -z ${VIASH_PAR_TRIM_HTML+x} ]; then
|
||||
VIASH_PAR_TRIM_HTML="\$id.fastp_out.html"
|
||||
fi
|
||||
|
||||
# check whether required files exist
|
||||
if [ ! -z "$VIASH_PAR_FASTQ_1" ] && [ ! -e "$VIASH_PAR_FASTQ_1" ]; then
|
||||
@@ -1269,13 +1308,13 @@ if [[ -n "$VIASH_PAR_SAVE_TRIMMED" ]]; then
|
||||
fi
|
||||
if [[ -n "$VIASH_PAR_SKIP_BBSPLIT" ]]; then
|
||||
if ! [[ "$VIASH_PAR_SKIP_BBSPLIT" =~ ^(true|True|TRUE|false|False|FALSE|yes|Yes|YES|no|No|NO)$ ]]; then
|
||||
ViashError '--skip_bbsplit' has to be a boolean. Use "--help" to get more information on the parameters.
|
||||
ViashError '--skip_bbsplit' has to be a boolean_true. Use "--help" to get more information on the parameters.
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
if [[ -n "$VIASH_PAR_REMOVE_RIBO_RNA" ]]; then
|
||||
if ! [[ "$VIASH_PAR_REMOVE_RIBO_RNA" =~ ^(true|True|TRUE|false|False|FALSE|yes|Yes|YES|no|No|NO)$ ]]; then
|
||||
ViashError '--remove_ribo_rna' has to be a boolean. Use "--help" to get more information on the parameters.
|
||||
ViashError '--remove_ribo_rna' has to be a boolean_true. Use "--help" to get more information on the parameters.
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
@@ -1444,6 +1483,15 @@ fi
|
||||
if [ ! -z "$VIASH_PAR_SALMON_QUANT_OUTPUT" ] && [ ! -d "$(dirname "$VIASH_PAR_SALMON_QUANT_OUTPUT")" ]; then
|
||||
mkdir -p "$(dirname "$VIASH_PAR_SALMON_QUANT_OUTPUT")"
|
||||
fi
|
||||
if [ ! -z "$VIASH_PAR_TRIM_JSON" ] && [ ! -d "$(dirname "$VIASH_PAR_TRIM_JSON")" ]; then
|
||||
mkdir -p "$(dirname "$VIASH_PAR_TRIM_JSON")"
|
||||
fi
|
||||
if [ ! -z "$VIASH_PAR_TRIM_HTML" ] && [ ! -d "$(dirname "$VIASH_PAR_TRIM_HTML")" ]; then
|
||||
mkdir -p "$(dirname "$VIASH_PAR_TRIM_HTML")"
|
||||
fi
|
||||
if [ ! -z "$VIASH_PAR_MERGED_OUT" ] && [ ! -d "$(dirname "$VIASH_PAR_MERGED_OUT")" ]; then
|
||||
mkdir -p "$(dirname "$VIASH_PAR_MERGED_OUT")"
|
||||
fi
|
||||
|
||||
if [ "$VIASH_ENGINE_ID" == "native" ] ; then
|
||||
if [ "$VIASH_MODE" == "run" ]; then
|
||||
@@ -1462,6 +1510,7 @@ VIASH_DEP_TRIMGALORE="$VIASH_META_RESOURCES_DIR/../../../nextflow/trimgalore/mai
|
||||
VIASH_DEP_BBMAP_BBSPLIT="$VIASH_META_RESOURCES_DIR/../../../nextflow/bbmap_bbsplit/main.nf"
|
||||
VIASH_DEP_SORTMERNA="$VIASH_META_RESOURCES_DIR/../../../nextflow/sortmerna/main.nf"
|
||||
VIASH_DEP_FQ_SUBSAMPLE="$VIASH_META_RESOURCES_DIR/../../../nextflow/fq_subsample/main.nf"
|
||||
VIASH_DEP_UMI_TOOLS_UMI_TOOLS_EXTRACT="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/umi_tools/umi_tools_extract/main.nf"
|
||||
VIASH_DEP_FASTP="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/fastp/main.nf"
|
||||
VIASH_DEP_SALMON_SALMON_QUANT="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/salmon/salmon_quant/main.nf"
|
||||
|
||||
@@ -1559,7 +1608,8 @@ workflow run_wf {
|
||||
"trim_zip_2": "trimmed_fastqc_zip_2",
|
||||
"trim_html_1": "trimmed_fastqc_html_1",
|
||||
"trim_html_2": "trimmed_fastqc_html_2"
|
||||
]
|
||||
],
|
||||
args: [gzip: true, fastqc: true]
|
||||
)
|
||||
|
||||
// Trim reads using fastp
|
||||
@@ -1575,7 +1625,7 @@ workflow run_wf {
|
||||
],
|
||||
toState: [
|
||||
"fastq_1": "out1",
|
||||
// "fastq_2": "out2",
|
||||
"fastq_2": "out2",
|
||||
"failed_trim": "failed_out",
|
||||
"failed_trim_unpaired1": "unpaired1",
|
||||
"failed_trim_unpaired2": "unpaired2",
|
||||
@@ -1639,8 +1689,10 @@ workflow run_wf {
|
||||
runIf: { id, state -> state.strandedness == 'auto' },
|
||||
fromState: { id, state ->
|
||||
def input = state.paired ? [ state.fastq_1, state.fastq_2 ] : [ state.fastq_1 ]
|
||||
[ input: input,
|
||||
extra_args: state.extra_fq_subsample_args ]
|
||||
[
|
||||
input: input,
|
||||
extra_args: state.extra_fq_subsample_args
|
||||
]
|
||||
},
|
||||
toState: [
|
||||
"subsampled_fastq_1": "output_1",
|
||||
@@ -1674,9 +1726,8 @@ workflow run_wf {
|
||||
def mates1 = state.paired ? state.subsampled_fastq_1 : null
|
||||
def mates2 = state.paired ? state.subsampled_fastq_2 : null
|
||||
[ unmated_reads: unmated_reads,
|
||||
mates1: state.fastq1,
|
||||
mates2: state.fastq2,
|
||||
targets: state.transcript_fasta,
|
||||
mates1: mates1,
|
||||
mates2: mates2,
|
||||
gene_map: state.gtf,
|
||||
index: state.salmon_index,
|
||||
lib_type: state.lib_type ]
|
||||
@@ -1735,6 +1786,18 @@ if [ ! -z "$VIASH_PAR_SALMON_QUANT_OUTPUT" ] && [ ! -e "$VIASH_PAR_SALMON_QUANT_
|
||||
ViashError "Output file '$VIASH_PAR_SALMON_QUANT_OUTPUT' does not exist."
|
||||
exit 1
|
||||
fi
|
||||
if [ ! -z "$VIASH_PAR_TRIM_JSON" ] && [ ! -e "$VIASH_PAR_TRIM_JSON" ]; then
|
||||
ViashError "Output file '$VIASH_PAR_TRIM_JSON' does not exist."
|
||||
exit 1
|
||||
fi
|
||||
if [ ! -z "$VIASH_PAR_TRIM_HTML" ] && [ ! -e "$VIASH_PAR_TRIM_HTML" ]; then
|
||||
ViashError "Output file '$VIASH_PAR_TRIM_HTML' does not exist."
|
||||
exit 1
|
||||
fi
|
||||
if [ ! -z "$VIASH_PAR_MERGED_OUT" ] && [ ! -e "$VIASH_PAR_MERGED_OUT" ]; then
|
||||
ViashError "Output file '$VIASH_PAR_MERGED_OUT' does not exist."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
exit 0
|
||||
|
||||
Reference in New Issue
Block a user