This minimal workshop can be summarised as a small pipeline:

filter_reads -> Megahit assembly -> geNomad -> checkV …

This page has only the ambition to show how Nextflow has become an important workflow manager.

Nextflow is a workflow language and a workflow manager, meaning that it will orchestrate the different job, parallelising them when possible. It will submit jobs to your HPC cluster or to the cloud, or simply use the CPUs of your local machine.

You can resume the pipeline if it fails.

Usually, Nextflow pipelines take care of dependencies allowing you to decide if you want to use Docker, Singularity, Conda or other containerisation tools. Nextflow would take care of the rest.

If this makes Nextflow worth of your attention, you can find more information, we also made a nice

:point_right: Nextflow tutorial

The Nextflow community is also producing a set of highly curated and thoroughly tested pipelines.

:point_right: nf-core pipelines

Installing Nextflow

You should now know the drill. It’s very easy to install Nextflow on its own, but we can use Conda to install it.

conda activate base

mamba install -c bioconda -c conda-forge nextflow

Seeing Nextflow at work

Currently there is no stable viromics pipeline in nf-core, but one, nf-core/phageannotator is under development.

To see how easy it is to run one (as you don’t need to download it!) you can type:

nextflow run  nf-core/phageannotator -r dev \
 -profile test,docker  --outdir output-nfcore 

With this command we ask Nextflow:

  1. To fetch for us the nf-core/phageannotator pipeline
  2. Run it in test mode (simple dataset provided by the pipeline)
  3. Save the output in “output-nfcore”

:warning: this pipeline is not published yet, and it’s under active development, but exemplify the amount of jobs that nextflow can orchestate.

nfcore