-
Notifications
You must be signed in to change notification settings - Fork 1
/
nextflow.config
155 lines (135 loc) · 3.74 KB
/
nextflow.config
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
manifest {
name = 'pclust'
description = 'Cluster proteins and annotate them'
homePage = 'https://github.com/darcyabjones/pclust'
author = 'Darcy Jones'
mainScript = 'main.nf'
nextflowVersion = '>=0.31.1'
version = "0.0.3"
}
params {
seqs = false
db = false
enrich_db = false
enrich_seqs = false
// Options to skip steps, using provided datasets instead
// Skip the clustering.
enrich_cluster = false
clusters = false
// Skip the multiple sequence alignment.
msas = false
// Skip the hhsuite database construction.
hhself = false
// Options to stop analyses at points.
nomsa = false
tree = false
noremote_build = false
noremote = false
// Remote homology analyses options.
hhdata = false
// Filter the self hmms database to just these members before doing hmm-hmm
// comparisons.
hhself_subset_seqs = false
// Provided hhsuite formatted databases to search against.
// These should be in a directory, and the db name prefix should be 'pfam',
// 'scop', 'pdb', or 'uniref'.
// e.g. db/pfam_cs219.ff{data,index} db/pfam_a3m.ff{data,index} etc...
//
// I recognise that having to rename things is painful, but there are too many
// files for each database to provide options for them individually.
hhpfam = false
hhscop = false
hhpdb = false
hhuniref = false
// Use these hhblits results instead of running the analyses.
hhmatches_self = false
hhmatches_pfam = false
hhmatches_scop = false
hhmatches_pdb = false
hhmatches_uniref = false
split_size = 20000
max_memory = 48.GB
max_cpus = 16
max_time = 24.h
help = false
outdir = "results"
tracedir = "${params.outdir}/trace"
}
includeConfig "conf/base.config"
process.container = "darcyabjones/${manifest.name}:${manifest.name}-v${manifest.version}"
profiles {
docker {
docker.enabled = true
}
docker_sudo {
docker.enabled = true
docker.sudo = true
}
docker_indiv {
includeConfig "conf/docker_indiv.config"
}
singularity {
singularity.enabled = true
}
singularity_indiv {
includeConfig "conf/singularity_indiv.config"
}
pawsey_zeus {
process.module = "singularity/3.5.2"
includeConfig "conf/pawsey_zeus.config"
}
nimbus {
includeConfig "conf/nimbus.config"
}
}
// Capture exit codes from upstream processes when piping
process.shell = ['/bin/bash', '-euo', 'pipefail']
timeline {
enabled = true
file = "${params.tracedir}/pipeline_info/pclust_timeline.html"
}
report {
enabled = true
file = "${params.tracedir}/pipeline_info/pclust_report.html"
}
trace {
enabled = true
file = "${params.tracedir}/pipeline_info/pclust_trace.txt"
}
dag {
enabled = true
file = "${params.tracedir}/pipeline_info/pclust_DAG.svg"
}
// Function to ensure that resource requirements don't go beyond
// a maximum limit
// From NFCORE
def check_max(obj, type) {
if(type == 'memory'){
try {
if(obj.compareTo(params.max_memory as nextflow.util.MemoryUnit) == 1)
return params.max_memory as nextflow.util.MemoryUnit
else
return obj
} catch (all) {
println " ### ERROR ### Max memory '${params.max_memory}' is not valid! Using default value: $obj"
return obj
}
} else if(type == 'time'){
try {
if(obj.compareTo(params.max_time as nextflow.util.Duration) == 1)
return params.max_time as nextflow.util.Duration
else
return obj
} catch (all) {
println " ### ERROR ### Max time '${params.max_time}' is not valid! Using default value: $obj"
return obj
}
} else if(type == 'cpus'){
try {
return Math.min( obj, params.max_cpus as int )
} catch (all) {
println " ### ERROR ### Max cpus '${params.max_cpus}' is not valid! Using default value: $obj"
return obj
}
}
}