-
Notifications
You must be signed in to change notification settings - Fork 272
/
roslin.config
78 lines (69 loc) · 3.08 KB
/
roslin.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
//Profile config names for nf-core/configs
params {
config_profile_description = 'University of Edinburgh (Eddie) cluster profile for Roslin Institute provided by nf-core/configs.'
config_profile_contact = 'Sebastien Guizard (@sguizard) and Donald Dunbar (@ddunbar)'
config_profile_url = 'https://www.ed.ac.uk/information-services/research-support/research-computing/ecdf/high-performance-computing'
}
executor {
name = "sge"
}
process {
stageInMode = 'symlink'
scratch = 'false'
penv = { task.cpus > 1 ? "sharedmem" : null }
// To date (16/08/2024), the FastQC module is still broken.
// More details here: https://github.com/nf-core/modules/pull/6156
// Until the Pull Request is accepted, and the new version of the module is integrated to pipelines,
// We force the amount of memory here.
withName: 'FASTQC.*' {
cpus = 5
memory = '5.GB'
// Check if an environment variable NFX_SGE_PROJECT exists, if yes, use the stored value for -P option
// Otherwise set the project to uoe_baseline
if (System.getenv('NFX_SGE_PROJECT')) {
clusterOptions = {"-l rl9=false -l h=!node1d01 -l h_vmem=10G -pe sharedmem 5 -P $NFX_SGE_PROJECT"}
} else {
clusterOptions = {"-l rl9=false -l h=!node1d01 -l h_vmem=10G -pe sharedmem 5 -P uoe_baseline"}
}
}
// This withName will override all jobs (except for FASTQC jobs, cf above) clusterOptions
// This is necessary to allow jobs to run on Eddie for many users
// For each job, we add an extra 4 Gb of memory.
// For example, the process asked 16 Gb of RAM (task.memory). The job will reserve 20 Gb of RAM.
// The process will still use 16 Gb (task.memory) leaving 4 Gb for other system processes.
// This is very useful any JAVA programs which allocate task.memory RAM for its Virtual Machine
// Also it leaves enough memory for singularity to unpack images.
withName: '!.*FASTQC.*' {
// Check if an environment variable NFX_SGE_PROJECT exists, if yes, use the stored value for -P option
// Otherwise set the project to uoe_baseline
if (System.getenv('NFX_SGE_PROJECT')) {
clusterOptions = {"-l rl9=false -l h=!node1d01 -l h_vmem=${(task.memory + 8.GB).bytes/task.cpus} -P $NFX_SGE_PROJECT"}
} else {
clusterOptions = {"-l rl9=false -l h=!node1d01 -l h_vmem=${(task.memory + 8.GB).bytes/task.cpus} -P uoe_baseline"}
}
}
// common SGE error statuses
errorStrategy = {task.exitStatus in [143,137,104,134,139,140] ? 'retry' : 'finish'}
maxErrors = '-1'
maxRetries = 3
beforeScript =
"""
. /etc/profile.d/modules.sh
module load singularity
export SINGULARITY_TMPDIR="\$TMPDIR"
"""
}
params {
// iGenomes reference base
igenomes_base = '/exports/igmm/eddie/BioinformaticsResources/igenomes'
}
env {
MALLOC_ARENA_MAX=1
}
singularity {
envWhitelist = "SINGULARITY_TMPDIR,TMPDIR"
runOptions = '-p -B "$TMPDIR"'
enabled = true
autoMounts = true
cacheDir = '/exports/cmvm/eddie/eb/groups/alaw3_eb_singularity_cache'
}