-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathnextflow.config
More file actions
135 lines (118 loc) · 4.41 KB
/
nextflow.config
File metadata and controls
135 lines (118 loc) · 4.41 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
params {
// Container
container_url = "docker.io/elembio/cells2stats"
container_tag = "latest"
// Run
run_dir = null
id = null
// Cells2Stats
batch = ""
error_on_missing = false
log_level = "info"
max_unassigned = null
no_error_on_invalid = false
panel = null
run_manifest = null
skip_cellprofiler = false
tile = ""
well = ""
visualization = false
visualization_only = false
segmentation = null
skip_html_report = false
// Boilerplate options
outdir = './results'
tracedir = "${params.outdir}/pipeline_info"
enable_conda = false
publish_dir_mode = 'copy'
// Config options
custom_config_version = "main"
custom_config_base = "https://raw.githubusercontent.com/Elembio/configs/${params.custom_config_version}"
config_profile_description = null
config_profile_contact = null
config_profile_url = null
config_profile_name = null
// Max resources
max_cpus = 48
max_memory = '192.GB'
max_time = '8.h'
}
// Load base.config by default for all pipelines
includeConfig 'conf/base.config'
// Load nf-core custom profiles from different Institutions
try {
includeConfig "${params.custom_config_base}/nfcore_custom.config"
} catch (Exception e) {
System.err.println("WARNING: Could not load custom config profiles: ${params.custom_config_base}/nfcore_custom.config")
}
// Load elembio/cell2stats custom profiles from different institutions.
try {
includeConfig "${params.custom_config_base}/pipeline/cells2stats_nf.config"
} catch (Exception e) {
System.err.println("WARNING: Could not load pipeline config profile: ${params.custom_config_base}/pipeline/cells2stats_nf.config")
}
// Capture exit codes from upstream processes when piping
process.shell = ['/bin/bash', '-euo', 'pipefail']
manifest {
name = 'elembio/cells2stats'
author = 'Carlos A Ruiz, Bryan R Lajoie'
homePage = 'https://gitlab.com/elembio/analysis/nextflow-workflows/cells2stats-nf'
description = 'Cell stats generation from Element AVITI24 System'
mainScript = 'main.nf'
nextflowVersion = '!>=21.10.3'
version = '1.0.0'
}
// Set default registry for Apptainer, Docker, Podman and Singularity independent of -profile
// Will not be used unless Apptainer / Docker / Podman / Singularity are enabled
// Set to your registry if you have a mirror of containers
apptainer.registry = 'quay.io'
docker.registry = 'quay.io'
podman.registry = 'quay.io'
singularity.registry = 'quay.io'
profiles {
docker {
docker.enabled = true
singularity.enabled = false
podman.enabled = false
shifter.enabled = false
charliecloud.enabled = false
}
test { includeConfig 'conf/test.config' }
local { includeConfig 'conf/local.config' }
tower { includeConfig 'conf/tower.config' }
tower_spot { includeConfig 'conf/tower_spot.config' }
ElembioCloud { includeConfig 'conf/ElembioCloud.config'}
notaskdir { includeConfig 'conf/notaskdir.config'}
}
// Load modules.config for DSL2 module specific options
includeConfig 'conf/modules.config'
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
}
}
}