Verkko is a hybrid genome assembly pipeline developed for telomere-to-telomere assembly of accurate long reads (PacBio HiFi, Oxford Nanopore Duplex, HERRO corrected Oxford Nanopore Simplex) and Oxford Nanopore ultra-long reads. Verkko is Finnish for net, mesh and graph.
Verkko uses Canu to correct remaining errors in the reads, builds a multiplex de Bruijn graph using MBG, aligns the Oxford Nanopore reads to the graph using GraphAligner, progressively resolves loops and tangles first with the HiFi reads then with the aligned Oxford Nanopore reads, and finally creates contig consensus sequences using Canu's consensus module.
Installing with a 'package manager' is recommended:
conda install -c conda-forge -c bioconda -c defaults verkko
or
conda create -n verkko -c conda-forge -c bioconda -c defaults verkko
if you prefer to install verkko in a separate environment. Alternatively, you can download and compile the source for a recent release.
Verkko is implemented as a Snakemake workflow, launched by a wrapper script to parse options
and create a verkko.yml
file.
verkko -d <work-directory> --hifi <hifi-read-files> [--nano <ont-read-files>]
Run verkko
with no options will list all available options with brief descriptions. At the minimum verkko requires high-accuracy long reads, provided with the --hifi
option. You can provide any combination of PacBio HiFi/Oxford Nanopore duplex/both to the --hifi
parameter. However, we strongly recommend including some ultra-long sequence data using the --nano
parameter and phasing information (see below). For HERRO corrected reads, provide the corrected reads with the --hifi
option and the uncorrected reads as --nano
. The output of verkko will be phased scaffolds. Note that no attempt is made to generate a primary or pseudo-haplotype assembly.
Verkko supports extended phasing using using rukki using either trio or Hi-C information.
To run in trio mode, you must first generate merqury hapmer databases and pass them to verkko.
verkko -d asm \
--hifi hifi/*.fastq.gz \
--nano ont/*.fastq.gz \
--hap-kmers maternal_compress.k30.hapmer.meryl \
paternal_compress.k30.hapmer.meryl \
trio
To run in Hi-C mode, reads should be provided using the --hic1 and --hic2 options. For example:
verkko -d asm \
--hifi hifi/*.fastq.gz \
--nano ont/*.fastq.gz \
--hic1 hic/*R1*fastq.gz \
--hic2 hic/*R2*fastq.gz
To run in PoreC mode, reads should be provided using the --porec option. For example:
verkko -d asm \
--hifi hifi/*.fastq.gz \
--nano ont/*.fastq.gz \
--porec porec/*fastq.gz
Hi-C/PoreC integration was tested mostly on human and primate genomes. Please see the --rdna-scaff-ref, --rdna-tangle, --uneven-depth and --haplo-divergence options if you want to assemble something distant from human and/or have uneven coverage. If you encounter issues or have questions about appropriate parameters, please open an issue.
By default, verkko will run the snakemake workflow and all compute on the local machine. Support for SGE, Slurm and LSF (untested) can be enabled with options --sge
, --slurm
and --lsf
, respectively. This will run the snakemake workflow on the local machine but submit all compute to the grid. To launch the both the snakemake workflow and compute on the grid, wrap the verkko command in a shell script and submit using your scheduler. If you're using conda, you may need to make the conda-installed python your default. You can do this with the --python
option when calling verkko
For cluster runs verkko uses different cpu/memory/time options for different parts of the pipeline. Usually a user does not need to change them, however advanced tuning is possible with --
You can pass through snakemake options to restrict CPU/memory/cluster resources by adding the --snakeopts
option to verkko. You can also pass arbitrary Snakemake options this way. For example, --snakeopts "--dry-run"
will print a plan of what jobs will run while --snakeopts "--cores 1000"
would restrict grid runs to at most 1000 cores across all submited jobs. Running with --snakeopts "--touch"
will reset all timestamps to be consistent and avoid re-generating any files which already exist. We recommend using --snakeopts "--dry-run"
, especially when restarting or modifying intermediates in an assembly to check that only the expected steps will run.
Verkko has the ability to filter common contaminants from an assembly using the --screen
option. For human samples, you can specify --screen human
which will automatically filter the mitochonrdia, rDNA, and EBV sequences. For other samples you can specify an arbitrary number of targets using --screen exampleN exampleN.fasta
. For each contaminant, verkko will remove all sequences matching the target from the main assembly output. It will also identify a 'cannonical' reprentative by coverage and circularize it to remove self-similarity at the start/end.
The final assembly result is under asm/assembly.fasta
. The final graph (in homopolymer-compressed space) is under asm/assembly.homopolymer-compressed.gfa
along with coverage files in asm/assembly*csv
. There is also an asm/assembly.scfmap
file which translates the final sequence name in assembly.fasta
to graph nodes. You can find intermediate graphs and coverage files under asm/*/unitig-*gfa
and asm/*/unitig-*csv
.
If you provided phasing information, you will also have asm/assembly.haplotype[12].fasta
, asm/assembly.colors.csv
, and asm/assembly.paths.tsv
. The latter two files provide information on the colors obtained from phasing information for each node in the graph and the paths selected to phase the assembly.
If you provided screening information, you will also have an asm/assembly.exampleN.fasta
and asm/assembly.exampleN.exemplar.fasta
files which specify all sequences removed from the assembly maching contaminant 'exampleN' as well as the circularized (when possible) selected cannonical sequence.
To test your installation we have an E. coli K12 dataset available.
curl -L https://obj.umiacs.umd.edu/sergek/shared/ecoli_hifi_subset24x.fastq.gz -o hifi.fastq.gz
curl -L https://obj.umiacs.umd.edu/sergek/shared/ecoli_ont_subset50x.fastq.gz -o ont.fastq.gz
verkko -d asm --hifi ./hifi.fastq.gz --nano ./ont.fastq.gz
doi:10.1038/s41587-023-01662-6