-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathnextflow.config
More file actions
453 lines (343 loc) · 12.3 KB
/
nextflow.config
File metadata and controls
453 lines (343 loc) · 12.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
params {
// a help parameter for print all the available parameters.
help = null
/*
a bed file of primer coordinates relative to the reference provided with the
parameters `refseq` and `ref_gbk`.
*/
primer_bed = null
// suffixes in the primer bed file denoting whether a primer is forward or reverse
fwd_suffix = "_LEFT"
rev_suffix = "_RIGHT"
// The reference sequence to be used for mapping in FASTA format.
refseq = null
// The reference sequence to be used for variant annotation in Genbank format.
ref_gbk = null
// A tsv file of primer sequences
primer_tsv = null
/*
A remote location to use with a ssh client to watch for pod5 files in
realtime as they are generated by the sequencing instrument.
*/
remote_pod5_location = ""
/*
Configuration file for remote file monitoring. An example can be found at
conf/file_watcher.template.yml
*/
file_watcher_config = ""
// where to cache pod5s as they arrive from the remote location
pod5_staging = "${launchDir}/pod5_cache"
/* If a remote pod5 location isn't given, users may provide a local,
on-device directory where pod5 files have been manually transferred.
*/
pod5_dir = ""
/*
A local directory to watch for Nanopore FASTQs or BAMs as the become
available. This is for cases where basecalling is being performed via another
workflow, resulting in BAMs or FASTQs that are gradually transferred into
`params.precalled_staging` as basecalling completes.
*/
precalled_staging = ""
/*
If pod5 files have already been basecalled and demultiplexed, users can
specify their location with prepped data.
*/
prepped_data = ""
/*
If users have Illumina data to be processed, they may specify their
paired-end FASTQ files' location with `illumina_fastq_dir`.
*/
illumina_fastq_dir = ""
/*
the Nanopore basecalling model to apply to the provided pod5 data (defaults
to the latest super-accuracy version)
*/
model = "sup@latest"
/*
where to cache the models locally (defaults to a directory called models/
that will be placed alongside the other workflow files). Models will only be
downloaded upon the user's first execution of the workflow unless the user
deletes the models directory.
*/
model_cache = "${launchDir}/work/basecalling_models"
// The Nanopore barcoding kit used to prepare sequencing libraries.
kit = null
/*
How many pod5 files to basecall at once. With a single available GPU, all
pod5 files should be basecalled together, so this parameter defaults to
telling Nextflow to take all pod5 files at once.
*/
pod5_batch_size = null
/*
If basecalling pod5 files is to be parallelized across multiple available
GPUs, this parameter tells Nextflow how many parallel instances of the
basecaller to run at once (defaults to 1).
*/
basecall_max = 1
// the maximum acceptable length for a given read
max_len = 12345678910
// the minimum acceptable length for a given read
min_len = 1
// the minimum acceptable average quality for a given read
min_qual = 20
/*
Whether to turn on secondary alignments for each amplicon. Secondary alignments can
increase depth at the cost of more reads potentially mapping to the wrong locations.
By default, secondary alignments are off.
*/
secondary = null
/*
The maximum number of mismatches to allow when finding primers (defaults
to 0)
*/
max_mismatch = 0
/*
Limit forward primer search to the first N bases of each read. This is a
performance optimization for long reads (e.g., Nanopore) where primers are
expected near read termini. Set to 0 (default) to search the entire read.
*/
forward_window = 0
/*
Limit reverse primer search to the last N bases of each read. This is a
performance optimization for long reads (e.g., Nanopore) where primers are
expected near read termini. Set to 0 (default) to search the entire read.
*/
reverse_window = 0
/*
Disable primer trimming. When set to true, amplicons are identified by their
primer sequences but the primers are not trimmed from the output. This is useful
when you want to identify which reads contain valid amplicons without modifying
the sequences.
*/
no_primer_trim = null
// Desired coverage to downsample to, with a sentinal value of 0 to indicate 0 downsampling
downsample_to = 0
// Early downsampling param
early_downsample_to = 0
/*
The minimum required frequency of a variant base to be included in a consensus
sequence.
*/
min_consensus_freq = 0.5
// The minimum required read support to report an amplicon-haplotype
min_haplo_reads = 2
// deduplication flag, by default false
dedup = null
/*
Where to cache a custom snpEff database (defaults to a directory called
snpEff_cache/ that will be placed alongside the other workflow files). Like
with the model data, this database will only be generated upon the user's
first execution of the workflow unless the user deletes the snpEff_cache
directory
*/
snpeff_cache = "${launchDir}/work/snpEff_cache"
// Minimum depth of coverage
min_depth_coverage = 10
// nextclade dataset
nextclade_dataset = null
// Dataset, either a local FASTA file or a pre-built dataset built by Sylph, to use
// for metagenomic profiling
meta_ref = null
// for identifying sylph tax database
sylph_tax_db = null
sylph_db_link = null
// Contamination FASTA dataset to scrub from reads
contam_fasta = null
contam_link = null
// K-mer size to use for metagenomic sketching
k = 31
// devider haplotype phasing preset
devider_preset = "nanopore-r10"
// old-long-reads, nanopore-r9, nanopore-r10, hi-fi
// nextclade dataset cache
nextclade_cache = "${launchDir}/work/nextclade_datasets"
//launch dir
launch_dir = "${launchDir}"
// Whether to plot multisample coverages with a log scale
log = null
// Where to place results
results = "${launchDir}/results"
// Whether to run in low-memory mode, which limits the number of parallel instances
// of high-memory files
low_memory = null
// whether to cleanup work directory after a successful run (defaults to false)
cleanup = null
// where test results should go, default test
// test = "test"
// parameters that generally should not be overwritten in normal use cases
// ---------------------------------------------------------------------- //
// snpEff config file
snpEff_config = "${projectDir}/conf/snpeff.config"
// email address to notify on completion. Multiple comma dilimeted emails may be provided.
email = null
}
// load platform-specific configurations
includeConfig params.remote_pod5_location != "" || params.pod5_dir != "" || params.precalled_staging || params.prepped_data
? "conf/nanopore.config"
: "conf/illumina.config"
// load reporting configuration (applies to both platforms)
includeConfig "conf/reporting.config"
// WHETHER TO GENERATE A REPORT OF RUN STATISTICS
report {
enabled = true
overwrite = true
file = "${params.results}/report.html"
}
// WHETHER TO GENERATE A VISUALIZATION OF THE WORKFLOW
dag {
enabled = true
overwrite = true
file = "${params.results}/workflow-visualization.png"
}
// WHETHER TO REMOVE TEMPORARY FILES AFTER A SUCCESSFUL RUN
cleanup = params.cleanup
// PROFILE OPTIONS
profiles {
standard {
docker.enabled = true
singularity.enabled = false
conda.enabled = false
process.container = "nrminor/oneroof:2.2.1"
}
docker {
docker.enabled = true
singularity.enabled = false
conda.enabled = false
process.container = "nrminor/oneroof:2.2.1"
}
singularity {
singularity.enabled = true
docker.enabled = false
conda.enabled = false
process.container = "docker://nrminor/oneroof:2.2.1"
}
apptainer {
apptainer.enabled = true
docker.enabled = false
conda.enabled = false
process.container = "docker://nrminor/dorado-and-friends:v0.2.3"
}
containerless {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
}
// =========================================================================
// PRESET PROFILES
// These configure databases for specific analysis types. Combine with
// execution profiles above, e.g.: -profile virus,docker
// =========================================================================
virus {
// General viral metagenomics: IMG/VR 4.1 + panhuman decontamination
includeConfig "conf/presets/virus.config"
}
sarscov2 {
// SARS-CoV-2 analysis: virus preset + Nextclade dataset
includeConfig "conf/presets/sarscov2.config"
}
// =========================================================================
// TEST PROFILES
// =========================================================================
// illumina tests
illumina_test_with_primers {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_with_primers_test.config"
}
illumina_test_without_primers {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_without_primers_test.config"
}
illumina_test_with_metagenomics {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_with_metagenomics.config"
}
illumina_test_with_phylo {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_with_phylo_test.config"
}
illumina_test_missing_fastq {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_missing_fastq.config"
}
illumina_test_bad_primers {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_bad_primer_input.config"
}
illumina_test_decon {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/illumina_tests/illumina_decontaminate_test.config"
}
// nanopore tests
nanopore_test_with_primers {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_with_primers_test.config"
}
nanopore_test_without_primers {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_without_primers_test.config"
}
nanopore_test_with_haplo {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_with_haplotyping.config"
}
nanopore_test_with_metagenomics {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_with_metagenomics.config"
}
nanopore_test_with_phylo {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_with_phylo_test.config"
}
nanopore_test_missing_input {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_no_input_data.config"
}
nanopore_test_bad_primers {
apptainer.enabled = false
docker.enabled = false
conda.enabled = false
includeConfig "conf/nanopore.config"
includeConfig "conf/nanopore_tests/nanopore_bad_primers.config"
}
}
// MANIFEST
manifest {
name = "oneroof"
homePage = 'https://github.com/nrminor/oneroof'
mainScript = 'main.nf'
defaultBranch = 'main'
description = 'Base-, Variant-, and Consensus-calling under One Proverbial Roof.'
author = 'Nicholas R. Minor'
}