nf-core/configs: Fred Hutch Cancer Center Configuration

Configuration file to run nf-core pipelines on the cluster of the Fred Hutchinson Cancer Center.

Before running the pipeline

You need to have Nextflow and Apptainer available in your path. The easiest way to do this is through modules.

module load Nextflow
module load Apptainer

Quick start

nextflow run -profile fred_hutch ...

Additional resources

https://sciwiki.fredhutch.org/datascience/using_workflows/ https://sciwiki.fredhutch.org/compdemos/nextflow/

Config file

See config file on GitHub

conf/fred_hutch
params {
    config_profile_name        = 'Fred Hutch'
    config_profile_description = 'Fred Hutch Cancer Center HPC profile'
    config_profile_contact     = 'dgratz@fredhutch.org'
    config_profile_url         = 'https://sciwiki.fredhutch.org/'
    // Same as resourceLimits, but for older pipelines
    max_memory = 700.GB
    max_cpus = 36
    max_time = 720.h
    scratchDir = "${System.getenv('HOME')}/nextflow"
}
 
// If the user does not provide a scratch directory, use their home dir
workDir = params.scratchDir
 
process {
    executor = 'slurm'
    // clusterOptions = {} // If we want default slurm configs
    queue = { task.time > 12.h ? 'campus-new' : 'short' }
 
    maxRetries = 2
    errorStrategy = { task.exitStatus in [12,104,137,134,139,140,141,143,151,247] ? 'retry' : 'finish' }
 
    resourceLimits = [
        memory: 700.GB,
        cpus: 36,
        time: 720.h
    ]
    // Per the scicomp wiki, memory requests don't mean much on our system. Use CPUs as a proxy for mem requests
    // Request 1 CPU for each 4 GB of memory
    // https://sciwiki.fredhutch.org/scicomputing/compute_jobs/#memory
    cpus    = { 5 * task.attempt }
    memory  = { 20.GB * task.attempt }
    time    = { 24.h * task.attempt }
    withLabel:process_single {
        cpus   = { 2 * task.attempt }
        memory = { 8.GB * task.attempt }
        time   = { 12.h * task.attempt }
    }
    withLabel:process_low {
        cpus   = { 4 * task.attempt }
        memory = { 16.GB * task.attempt }
        time   = { 24.h  * task.attempt }
    }
    withLabel:process_medium {
        cpus   = { 16 * task.attempt }
        memory = { 56.GB * task.attempt }
        time   = { 72.h  * task.attempt }
    }
    withLabel:process_high {
        cpus   = 32
        memory = { 128.GB * task.attempt }
        time   = { 120.h  * task.attempt }
    }
    withLabel:process_long {
        cpus   = { 12 * task.attempt }
        memory = { 96.GB * task.attempt }
        time   = { 336.h  * task.attempt }
    }
}
 
executor {
    // How many jobs can be submitted at once
    queueSize = 16
    // Maximum jobs per second
    submitRateLimit = "10/1sec"
}
 
apptainer {
    enabled = true
    // Checks if TMPDIR is defined in the environment before mounting to avoid breaks
    runOptions = "--containall " + (System.getenv('TMPDIR') ? "-B \$TMPDIR" : "")
}
 
// clean the generated files in the working directory
// having this as true sometimes breaks things
cleanup = false