epi2me-labs / wf-metagenomics

Metagenomic classification of long-read sequencing data
Other
54 stars 23 forks source link

ERROR ~ Validation of pipeline parameters failed! (fastq/bam) #113

Open LucyNanopore opened 2 months ago

LucyNanopore commented 2 months ago

Operating System

Windows 10

Other Linux

No response

Workflow Version

v24.04.2

Workflow Execution

Command line (Cluster)

Other workflow execution

No response

EPI2ME Version

No response

CLI command run

qrsh cd my/directory/ conda activate nextflow qsub -M myemail.ac.uk -m a -m b -m e -N 9Jul_3 run1.sh --input /cluster/my/space/on/cluster/sample_file.csv

Within the run1.sh file is the following:

!/bin/bash

$ -j y

$ -cwd

$ -V

$ -mods l_hard mfree 200G

eval "$(conda shell.bash hook)"

cd ~/

source activate nextflow

cd /cluster/my/folder/on/cluster

###################################################################

fastq_path=/cluster/my/space/barcodes output=/cluster/my/space/output

###################################################################

cd /cluster/my/space

mkdir analysis/metagenomics

cd $fastq_path

nextflow run epi2me-labs/wf-metagenomics \

--fastq $fastq_path \

-profile singularity \

--kraken2_memory_mapping \

--database_set PlusPF-8 \

--amr \

--amr_db resfinder \

--out_dir $output

Workflow Execution - CLI Execution Profile

None

What happened?

I have a "run complete" message shoot back in a minute of me beginning the run, with the error specifying that I have to pick between --fastq and --bam, although the original config file does not detail any bam

Relevant log output

mkdir: cannot create directory ‘analysis/metagenomics’: No such file or directory

 N E X T F L O W   ~  version 24.04.2

Launching `https://github.com/epi2me-labs/wf-metagenomics` [golden_euler] DSL2 - revision: 4c2c583cfd [master]

WARN: NEXTFLOW RECURSION IS A PREVIEW FEATURE - SYNTAX AND FUNCTIONALITY CAN CHANGE IN FUTURE RELEASES

ERROR ~ Validation of pipeline parameters failed!

 -- Check '.nextflow.log' file for details
ERROR ~ * Bad parameter configuration. You must select only one option of:
    --fastq
    --bam

 -- Check '.nextflow.log' file for details
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 44: --fastq: command not found
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 46: -profile: command not found
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 49: --kraken2_memory_mapping: command not found
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 50: --database_set: command not found
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 53: --amr: command not found
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 54: --amr_db: command not found
/opt/sge/default/spool/gpu-49/job_scripts/1783636: line 56: --out_dir: command not found

Application activity log entry

No response

Were you able to successfully run the latest version of the workflow with the demo data?

no

Other demo data information

No response

nggvs commented 2 months ago

Hi @LucyNanopore , There are different things that can be weird.

The first error is mkdir: cannot create directory ‘analysis/metagenomics’: No such file or directory, which comes from this command: mkdir analysis/metagenomics

It also recognizes each param as an individual command. Maybe there is something weird with the format of the script run1.sh, have you written it in windows10? is that the case and you want to run it in an Unix system, you may want to reformat it (you can try dos2unix)

Also I don't think you will need to use --kraken2_memory_mapping with the PlusPF-8 database if you are running it in a cluster. Besides, I don't know if $fastq_path is an absolute path and what it contains, but if it is relative and directly contains the barcodes folder, as you are cd in it before, could throw an error with input data does not exist (make sure you the input data follows one of the next structures.

Depending on your samples and your device, but if you want to use the 8GB database (and you have 16GB of RAM memory), maybe you want to try to run the workflow within the EPI2ME Desktop Application, which can be installed directly in windows and is easy to use, you wouldn't need to write any script, just load the files using the interface and select your options :)