diff --git a/README.md b/README.md index 8e460b488a18b5582418ac8d49f95268422eee17..47834be970c7b3e85fedd6048e2b7ff4253f5c18 100755 --- a/README.md +++ b/README.md @@ -70,6 +70,7 @@ NextFlow pipeline used by the Developmental Cognitive Neuroscience Lab (DCNL) to images/debian-nanopore.sif \ containers/debian-nanopore.def ``` + If the container build fails due to size, it may be related to limitations in the **tmp/** folder, change it with ``export APPTAINER_TMPDIR="path/"``. See [documentation](https://apptainer.org/docs/user/1.0/build_env.html#temporary-folders) for details. 1. You should now be able to run the `nextflow` pipeline (`src/main.nf`). See [Pipeline parameters](#pipeline-parameters) and [Examples](#examples) for details. @@ -222,9 +223,9 @@ Many of the parameters for this step are based on dorado basecaller, see their [ ``` -### Config Profiles +### Parameter Files -The pipeline also supports running [pre-configured profiles](https://www.nextflow.io/docs/latest/config.html#config-profiles). The currently supported profiles are under the `src/configs/` dir and can be used via the parameter `-profile ` option in `nextflow run`. All such profiles make assumptions about the type of data to be used and where they are being stored/output. +The pipeline also supports running [pre-configured parameter files](https://www.nextflow.io/docs/latest/cli.html#pipeline-parameters). The currently supported analyses are under the `parameters/` subdir and can be used via the option `-params-file "./parameters//.yaml"` in `nextflow run`. All such files make assumptions about the type of data to be used and where they are being stored. [top](#table-of-contents) @@ -315,15 +316,15 @@ The following examples assume your current directory is the root directory of th -resume ``` -Alternatively, you can make use of an existing [configuration profile](#config-profiles) to run one or more of the mentioned steps without the need to specify all parameters (the profiles are optimized for specific types of analysis). For example, the `src/configs/human_blood.config` file implements the `human_blood_basecall` profile, which can be executed from the project root directory as follows: +Alternatively, you can make use of an existing [parameter file](#parameter-files) to run one or more of the mentioned steps without the need to specify all parameters (each file is optimized for specific types of analysis). For example, the `parameters/human_blood/basecall.yaml` file runs the basecall analysis for a human blood sample, which can be executed from the project root directory as follows: ```sh -nextflow ./src/main.nf -profile human_blood_basecall +nextflow ./src/main.nf -params-file ./parameters/human_blood/basecall.yaml ``` ### Slurm script -The pipeline can be executed in an HPC environment using [Slurm](https://slurm.schedmd.com/). A job submission template for basecalling with the `human_blood_basecall` profile is provided below. +The pipeline can be executed in an HPC environment using [Slurm](https://slurm.schedmd.com/). A job submission template for basecalling with the `human_blood_basecall` parameters is provided below. 1. Create a shell script: @@ -342,7 +343,7 @@ The pipeline can be executed in an HPC environment using [Slurm](https://slurm.s #SBATCH --cpus-per-task 12 #SBATCH --gpus 3 srun nextflow run ./src/main.nf \ - -profile human_blood_basecall \ + -params-file ./parameters/human_blood/basecall.yaml \ --basecall_mods "5mC_5hmC,6mA" ``` diff --git a/parameters/human_blood/basecall.yaml b/parameters/human_blood/basecall.yaml new file mode 100644 index 0000000000000000000000000000000000000000..4e476093e00f11bfe1706200156d3eba6d787120 --- /dev/null +++ b/parameters/human_blood/basecall.yaml @@ -0,0 +1,5 @@ +project_name: "human_blood" +step: 1 +basecall_path: "./data/pod5" +reference_file: "./references/Homo_sapiens.GRCh38.dna.primary_assembly.fa" +out_dir: "results_human_blood/" \ No newline at end of file diff --git a/parameters/human_blood/modkit.yaml b/parameters/human_blood/modkit.yaml new file mode 100644 index 0000000000000000000000000000000000000000..5149ad894bc1204d3e42e2a5579b0d4274dcaa6e --- /dev/null +++ b/parameters/human_blood/modkit.yaml @@ -0,0 +1,4 @@ +project_name: "results_human_blood" +step: 3 +steps_2_and_3_input_directory: "./results/results_human_blood/" +out_dir: "results_human_blood/" \ No newline at end of file diff --git a/parameters/human_blood/qc.yaml b/parameters/human_blood/qc.yaml new file mode 100644 index 0000000000000000000000000000000000000000..c72858ebee69626058b00e0ad124b28c9b055b6c --- /dev/null +++ b/parameters/human_blood/qc.yaml @@ -0,0 +1,4 @@ +project_name: "results_human_blood" +step: "2_from_step_1" +steps_2_and_3_input_directory: "./results/results_human_blood/" +out_dir: "results_human_blood/" \ No newline at end of file diff --git a/src/configs/human_blood.config b/src/configs/human_blood.config deleted file mode 100644 index 9560781f2cb418e78d301b1b3a81a953a9ba5d24..0000000000000000000000000000000000000000 --- a/src/configs/human_blood.config +++ /dev/null @@ -1,28 +0,0 @@ -// Human Blood profile -profiles { - human_blood_basecall { - params { - project_name = "human_blood" - step = 1 - basecall_path = "./data/pod5" - reference_file = "./references/Homo_sapiens.GRCh38.dna.primary_assembly.fa" - out_dir = "results_human_blood/" - } - } - human_blood_qc { - params { - project_name = "results_human_blood" - step = "2_from_step_1" - steps_2_and_3_input_directory = "./results/results_human_blood/" - out_dir = "results_human_blood/" - } - } - human_blood_modkit { - params { - project_name = "results_human_blood" - step = 3 - steps_2_and_3_input_directory = "./results/results_human_blood/" - out_dir = "results_human_blood/" - } - } -} \ No newline at end of file diff --git a/src/nextflow.config b/src/nextflow.config index 1c4f7aaf72208bd550c22c79ade6c0ff98d60402..41d22397149db2cd972c6cbea2069d6c26aa7051 100755 --- a/src/nextflow.config +++ b/src/nextflow.config @@ -75,6 +75,3 @@ apptainer { enabled = true pullTimeout = '60m' } - -// include one or more profiles from the configs subdir -includeConfig "./configs/human_blood.config"