diff --git a/.nf-core.yml b/.nf-core.yml index 83871f2c..cfe39173 100644 --- a/.nf-core.yml +++ b/.nf-core.yml @@ -2,4 +2,5 @@ repository_type: pipeline lint: files_unchanged: - .github/ISSUE_TEMPLATE/bug_report.yml + - pyproject.toml multiqc_config: false diff --git a/CHANGELOG.md b/CHANGELOG.md index e05930bd..da0a752c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,17 +10,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [#80](https://github.com/nf-core/proteinfold/pull/80) - Add `accelerator` directive to GPU processes when `params.use_gpu` is true. - [#81](https://github.com/nf-core/proteinfold/pull/81) - Support multiline fasta for colabfold multimer predictions. - [#89](https://github.com/nf-core/proteinfold/pull/89) - Fix issue with excessive symlinking in the pdb_mmcif database. -- [#90](https://github.com/nf-core/proteinfold/pull/90) - Update pipeline template to [nf-core/tools 2.8](https://github.com/nf-core/tools/releases/tag/2.8). -- [#91](https://github.com/nf-core/proteinfold/pull/91) - Update ColabFold version to 1.5.2 and AlphaFold version to 2.3.2 -- [#92](https://github.com/nf-core/proteinfold/pull/92) - Add ESMFold workflow to the pipeline. +- [PR #91](https://github.com/nf-core/proteinfold/pull/91) - Update ColabFold version to 1.5.2 and AlphaFold version to 2.3.2 +- [PR #92](https://github.com/nf-core/proteinfold/pull/92) - Add ESMFold workflow to the pipeline. - Update metro map to include ESMFold workflow. - Update modules to remove quay from container url. - [nf-core/tools#2286](https://github.com/nf-core/tools/issues/2286) - Set default container registry outside profile scope. -- [#97](https://github.com/nf-core/proteinfold/pull/97) - Fix issue with uniref30 missing path when using the full BFD database in AlphaFold. -- [#100](https://github.com/nf-core/proteinfold/pull/100) - Update containers for AlphaFold2 and ColabFold local modules. -- [#105](https://github.com/nf-core/proteinfold/pull/105) - Update COLABFOLD_BATCH docker container, metro map figure and nextflow schema description. -- [#106](https://github.com/nf-core/proteinfold/pull/106) - Add `singularity.registry = 'quay.io'` and bump NF version to 23.04.0 -- [#108](https://github.com/nf-core/proteinfold/pull/108) - Fix gunzip error when providing too many files when downloading PDBMMCIF database. +- [PR #97](https://github.com/nf-core/proteinfold/pull/97) - Fix issue with uniref30 missing path when using the full BFD database in AlphaFold. +- [PR #100](https://github.com/nf-core/proteinfold/pull/100) - Update containers for AlphaFold2 and ColabFold local modules. +- [PR #105](https://github.com/nf-core/proteinfold/pull/105) - Update COLABFOLD_BATCH docker container, metro map figure and nextflow schema description. +- [PR #106](https://github.com/nf-core/proteinfold/pull/106) - Add `singularity.registry = 'quay.io'` and bump NF version to 23.04.0 +- [PR #108](https://github.com/nf-core/proteinfold/pull/108) - Fix gunzip error when providing too many files when downloading PDBMMCIF database. +- [PR #111](https://github.com/nf-core/proteinfold/pull/111) - Update pipeline template to [nf-core/tools 2.9](https://github.com/nf-core/tools/releases/tag/2.9). +- [PR #112](https://github.com/nf-core/rnaseq/pull/112) - Use `nf-validation` plugin for parameter and samplesheet validation ## 1.0.0 - White Silver Reebok diff --git a/assets/schema_input.json b/assets/schema_input.json index 29bca5dd..b16e3ae5 100644 --- a/assets/schema_input.json +++ b/assets/schema_input.json @@ -7,28 +7,18 @@ "items": { "type": "object", "properties": { - "sample": { + "sequence": { "type": "string", "pattern": "^\\S+$", - "errorMessage": "Sample name must be provided and cannot contain spaces" + "errorMessage": "Sequence name must be provided and cannot contain spaces", + "meta": ["id"] }, - "fastq_1": { + "fasta": { "type": "string", - "pattern": "^\\S+\\.f(ast)?q\\.gz$", - "errorMessage": "FastQ file for reads 1 must be provided, cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'" - }, - "fastq_2": { - "errorMessage": "FastQ file for reads 2 cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'", - "anyOf": [ - { - "type": "string", - "pattern": "^\\S+\\.f(ast)?q\\.gz$" - }, - { - "type": "string", - "maxLength": 0 - } - ] + "format": "file-path", + "exists": true, + "pattern": "^\\S+\\.fa(sta)?$", + "errorMessage": "Fasta file must be provided, cannot contain spaces and must have extension '.fa' or '.fasta'" } }, "required": ["sequence", "fasta"] diff --git a/conf/modules.config b/conf/modules.config index f611a660..cd1ee8d2 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -21,14 +21,6 @@ process { saveAs: { filename -> filename.equals('versions.yml') ? null : filename } ] - withName: 'SAMPLESHEET_CHECK' { - publishDir = [ - path: { "${params.outdir}/pipeline_info" }, - mode: params.publish_dir_mode, - saveAs: { filename -> filename.equals('versions.yml') ? null : filename } - ] - } - withName: 'CUSTOM_DUMPSOFTWAREVERSIONS' { publishDir = [ path: { "${params.outdir}/pipeline_info" }, diff --git a/lib/WorkflowAlphafold2.groovy b/lib/WorkflowAlphafold2.groovy index 3373b039..188ac258 100755 --- a/lib/WorkflowAlphafold2.groovy +++ b/lib/WorkflowAlphafold2.groovy @@ -10,8 +10,7 @@ class WorkflowAlphafold2 { // // Check and validate parameters // - public static void initialise(params, log) { - } + public static void initialise(params, log) { } // // Get workflow summary for MultiQC diff --git a/lib/WorkflowColabfold.groovy b/lib/WorkflowColabfold.groovy index 2896e36c..e84f9c19 100755 --- a/lib/WorkflowColabfold.groovy +++ b/lib/WorkflowColabfold.groovy @@ -10,8 +10,7 @@ class WorkflowColabfold { // // Check and validate parameters // - public static void initialise(params, log) { - } + public static void initialise(params, log) { } // // Get workflow summary for MultiQC diff --git a/lib/WorkflowEsmfold.groovy b/lib/WorkflowEsmfold.groovy index 824a1977..6c38a2af 100644 --- a/lib/WorkflowEsmfold.groovy +++ b/lib/WorkflowEsmfold.groovy @@ -10,8 +10,7 @@ class WorkflowEsmfold { // // Check and validate parameters // - public static void initialise(params, log) { - } + public static void initialise(params, log) { } // // Get workflow summary for MultiQC diff --git a/lib/WorkflowMain.groovy b/lib/WorkflowMain.groovy index 3e34ec48..645de5fd 100755 --- a/lib/WorkflowMain.groovy +++ b/lib/WorkflowMain.groovy @@ -44,11 +44,6 @@ class WorkflowMain { // Check AWS batch settings NfcoreTemplate.awsBatch(workflow, params) - - // Check input has been provided - if (!params.input) { - Nextflow.error("Please provide an input samplesheet to the pipeline e.g. '--input samplesheet.csv'") - } } // // Get attribute from genome config file e.g. fasta diff --git a/modules/local/multifasta_to_singlefasta.nf b/modules/local/multifasta_to_singlefasta.nf index 4b0eea04..0e450b82 100644 --- a/modules/local/multifasta_to_singlefasta.nf +++ b/modules/local/multifasta_to_singlefasta.nf @@ -29,7 +29,7 @@ process MULTIFASTA_TO_SINGLEFASTA { stub: """ - touch input.csv + touch ${meta.id}.fasta cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/local/samplesheet_check.nf b/modules/local/samplesheet_check.nf deleted file mode 100644 index 58027d71..00000000 --- a/modules/local/samplesheet_check.nf +++ /dev/null @@ -1,31 +0,0 @@ -process SAMPLESHEET_CHECK { - tag "$samplesheet" - label 'process_single' - - conda "conda-forge::python=3.8.3" - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/python:3.8.3' : - 'biocontainers/python:3.8.3' }" - - input: - path samplesheet - - output: - path '*.csv' , emit: csv - path "versions.yml", emit: versions - - when: - task.ext.when == null || task.ext.when - - script: // This script is bundled with the pipeline, in nf-core/proteinfold/bin/ - """ - check_samplesheet.py \\ - $samplesheet \\ - samplesheet.valid.csv - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - python: \$(python --version | sed 's/Python //g') - END_VERSIONS - """ -} diff --git a/nextflow.config b/nextflow.config index 50be4881..530332ae 100644 --- a/nextflow.config +++ b/nextflow.config @@ -114,7 +114,7 @@ params { // Schema validation default options validationFailUnrecognisedParams = false validationLenientMode = false - validationSchemaIgnoreParams = 'genomes' + validationSchemaIgnoreParams = '' validationShowHiddenParams = false validate_params = true diff --git a/nextflow_schema.json b/nextflow_schema.json index e7e18db7..357faa43 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -18,6 +18,7 @@ "exists": true, "mimetype": "text/csv", "pattern": "^\\S+\\.csv$", + "schema": "assets/schema_input.json", "description": "Path to comma-separated file containing information about the samples in the experiment.", "help_text": "You will need to create a design file with information about the samples in your experiment before running the pipeline. Use this parameter to specify its location. It has to be a comma-separated file with 3 columns, and a header row. See [usage docs](https://nf-co.re/proteinfold/usage#samplesheet-input).", "fa_icon": "fas fa-file-csv" @@ -68,6 +69,8 @@ }, "alphafold2_db": { "type": "string", + "format": "path", + "exists": true, "description": "Specifies the DB and PARAMS path used by 'AlphaFold2' mode", "fa_icon": "fas fa-database" }, @@ -101,6 +104,8 @@ "properties": { "colabfold_db": { "type": "string", + "format": "path", + "exists": true, "description": "Specifies the PARAMS and DB path used by 'colabfold' mode", "fa_icon": "fas fa-folder-open" }, @@ -170,6 +175,8 @@ "properties": { "esmfold_db": { "type": "string", + "format": "path", + "exists": true, "description": "Specifies the PARAMS path used by 'esmfold' mode", "fa_icon": "fas fa-folder-open" }, @@ -570,18 +577,26 @@ "multiqc_config": { "type": "string", "format": "file-path", + "exists": true, + "mimetype": "text/plain", "description": "Custom config file to supply to MultiQC.", "fa_icon": "fas fa-cog", "hidden": true }, "multiqc_logo": { "type": "string", + "format": "file-path", + "exists": true, + "mimetype": "text/plain", "description": "Custom logo file to supply to MultiQC. File name must also be set in the MultiQC config file", "fa_icon": "fas fa-image", "hidden": true }, "multiqc_methods_description": { "type": "string", + "format": "file-path", + "exists": true, + "mimetype": "text/plain", "description": "Custom MultiQC yaml file containing HTML including a methods description.", "fa_icon": "fas fa-cog" }, diff --git a/pyproject.toml b/pyproject.toml index 0d62beb6..bc01239b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,4 +1,4 @@ -# Config file for Python. Mostly used to configure linting of bin/check_samplesheet.py with Black. +# Config file for Python. Mostly used to configure linting of bin/*.py with Black. # Should be kept the same as nf-core/tools to avoid fighting with template synchronisation. [tool.black] line-length = 120 diff --git a/subworkflows/local/input_check.nf b/subworkflows/local/input_check.nf deleted file mode 100644 index 6b26fd99..00000000 --- a/subworkflows/local/input_check.nf +++ /dev/null @@ -1,37 +0,0 @@ -// -// Check input samplesheet and get read channels -// - -include { SAMPLESHEET_CHECK } from '../../modules/local/samplesheet_check' - -workflow INPUT_CHECK { - take: - samplesheet // file: /path/to/samplesheet.csv - - main: - SAMPLESHEET_CHECK ( samplesheet ) - .csv - .splitCsv ( header:true, sep:',' ) - .map { create_fasta_channel(it) } - .set { fastas } - - emit: - fastas // channel: [ val(meta), [ fastas ] ] - versions = SAMPLESHEET_CHECK.out.versions // channel: [ versions.yml ] -} - -// Function to get list of [ meta, [ fasta ] ] -def create_fasta_channel(LinkedHashMap row) { - // create meta map - def meta = [:] - meta.id = row.sequence - - // add path of the fasta file to the meta map - def fasta_meta = [] - if (!file(row.fasta).exists()) { - exit 1, "ERROR: Please check input samplesheet -> Fasta file does not exist!\n${row.fasta}" - } - fasta_meta = [ meta, file(row.fasta) ] - - return fasta_meta -} diff --git a/workflows/alphafold2.nf b/workflows/alphafold2.nf index 29f297a0..e11aadb8 100644 --- a/workflows/alphafold2.nf +++ b/workflows/alphafold2.nf @@ -4,7 +4,7 @@ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -include { paramsSummaryLog; paramsSummaryMap } from 'plugin/nf-validation' +include { paramsSummaryLog; paramsSummaryMap; fromSamplesheet } from 'plugin/nf-validation' def logo = NfcoreTemplate.logo(workflow, params.monochrome_logs) def citation = '\n' + WorkflowMain.citation(workflow) + '\n' @@ -16,16 +16,6 @@ log.info logo + paramsSummaryLog(workflow) + citation // Validate input parameters WorkflowAlphafold2.initialise(params, log) -// Check input path parameters to see if they exist -def checkPathParamList = [ - params.input, - params.alphafold2_db -] -for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true) } } - -// Check mandatory parameters -if (params.input) { ch_input = file(params.input) } else { exit 1, 'Input file not specified!' } - /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ CONFIG FILES @@ -33,9 +23,9 @@ if (params.input) { ch_input = file(params.input) } else { exit 1, 'Input file n */ ch_multiqc_config = Channel.fromPath("$projectDir/assets/multiqc_config.yml", checkIfExists: true) -ch_multiqc_custom_config = params.multiqc_config ? Channel.fromPath( params.multiqc_config, checkIfExists: true ) : Channel.empty() -ch_multiqc_logo = params.multiqc_logo ? Channel.fromPath( params.multiqc_logo, checkIfExists: true ) : Channel.empty() -ch_multiqc_custom_methods_description = params.multiqc_methods_description ? file(params.multiqc_methods_description, checkIfExists: true) : file("$projectDir/assets/methods_description_template.yml", checkIfExists: true) +ch_multiqc_custom_config = params.multiqc_config ? Channel.fromPath( params.multiqc_config ) : Channel.empty() +ch_multiqc_logo = params.multiqc_logo ? Channel.fromPath( params.multiqc_logo ) : Channel.empty() +ch_multiqc_custom_methods_description = params.multiqc_methods_description ? file(params.multiqc_methods_description) : file("$projectDir/assets/methods_description_template.yml", checkIfExists: true) /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -46,7 +36,6 @@ ch_multiqc_custom_methods_description = params.multiqc_methods_description ? fil // // SUBWORKFLOW: Consisting of a mix of local and nf-core/modules // -include { INPUT_CHECK } from '../subworkflows/local/input_check' include { PREPARE_ALPHAFOLD2_DBS } from '../subworkflows/local/prepare_alphafold2_dbs' // @@ -82,28 +71,22 @@ workflow ALPHAFOLD2 { ch_versions = Channel.empty() // - // SUBWORKFLOW: Read in samplesheet, validate and stage input files + // Create input channel from input file provided through params.input // - if (params.alphafold2_model_preset != 'multimer') { - INPUT_CHECK ( - ch_input - ) - .fastas - .map { - meta, fasta -> - [ meta, fasta.splitFasta(file:true) ] - } - .transpose() + Channel + .fromSamplesheet("input") .set { ch_fasta } - } else { - INPUT_CHECK ( - ch_input - ) - .fastas - .set { ch_fasta } - } - ch_versions = ch_versions.mix(INPUT_CHECK.out.versions) + if (params.alphafold2_model_preset != 'multimer') { + ch_fasta + .map { + meta, fasta -> + [ meta, fasta.splitFasta(file:true) ] + } + .transpose() + .set { ch_fasta } + } + // // SUBWORKFLOW: Download databases and params for Alphafold2 // diff --git a/workflows/colabfold.nf b/workflows/colabfold.nf index e2048b0b..931f7d3f 100644 --- a/workflows/colabfold.nf +++ b/workflows/colabfold.nf @@ -4,7 +4,7 @@ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -include { paramsSummaryLog; paramsSummaryMap } from 'plugin/nf-validation' +include { paramsSummaryLog; paramsSummaryMap; fromSamplesheet } from 'plugin/nf-validation' def logo = NfcoreTemplate.logo(workflow, params.monochrome_logs) def citation = '\n' + WorkflowMain.citation(workflow) + '\n' @@ -16,16 +16,6 @@ log.info logo + paramsSummaryLog(workflow) + citation // Validate input parameters WorkflowColabfold.initialise(params, log) -// Check input path parameters to see if they exist -def checkPathParamList = [ - params.input, - params.colabfold_db -] -for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true) } } - -// Check mandatory parameters -if (params.input) { ch_input = file(params.input) } else { exit 1, 'Input file not specified!' } - /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ CONFIG FILES @@ -33,9 +23,9 @@ if (params.input) { ch_input = file(params.input) } else { exit 1, 'Input file n */ ch_multiqc_config = Channel.fromPath("$projectDir/assets/multiqc_config.yml", checkIfExists: true) -ch_multiqc_custom_config = params.multiqc_config ? Channel.fromPath( params.multiqc_config, checkIfExists: true ) : Channel.empty() -ch_multiqc_logo = params.multiqc_logo ? Channel.fromPath( params.multiqc_logo, checkIfExists: true ) : Channel.empty() -ch_multiqc_custom_methods_description = params.multiqc_methods_description ? file(params.multiqc_methods_description, checkIfExists: true) : file("$projectDir/assets/methods_description_template.yml", checkIfExists: true) +ch_multiqc_custom_config = params.multiqc_config ? Channel.fromPath( params.multiqc_config ) : Channel.empty() +ch_multiqc_logo = params.multiqc_logo ? Channel.fromPath( params.multiqc_logo ) : Channel.empty() +ch_multiqc_custom_methods_description = params.multiqc_methods_description ? file(params.multiqc_methods_description) : file("$projectDir/assets/methods_description_template.yml", checkIfExists: true) /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -46,7 +36,6 @@ ch_multiqc_custom_methods_description = params.multiqc_methods_description ? fil // // SUBWORKFLOW: Consisting of a mix of local and nf-core/modules // -include { INPUT_CHECK } from '../subworkflows/local/input_check' include { PREPARE_COLABFOLD_DBS } from '../subworkflows/local/prepare_colabfold_dbs' // @@ -82,12 +71,11 @@ workflow COLABFOLD { ch_versions = Channel.empty() // - // SUBWORKFLOW: Read in samplesheet, validate and stage input files + // Create input channel from input file provided through params.input // - INPUT_CHECK ( - ch_input - ) - ch_versions = ch_versions.mix(INPUT_CHECK.out.versions) + Channel + .fromSamplesheet("input") + .set { ch_fasta } PREPARE_COLABFOLD_DBS ( ) ch_versions = ch_versions.mix(PREPARE_COLABFOLD_DBS.out.versions) @@ -98,7 +86,7 @@ workflow COLABFOLD { // if (params.colabfold_model_preset != 'alphafold2_ptm' && params.colabfold_model_preset != 'alphafold2') { MULTIFASTA_TO_CSV( - INPUT_CHECK.out.fastas + ch_fasta ) ch_versions = ch_versions.mix(MULTIFASTA_TO_CSV.out.versions) COLABFOLD_BATCH( @@ -112,7 +100,7 @@ workflow COLABFOLD { ch_versions = ch_versions.mix(COLABFOLD_BATCH.out.versions) } else { COLABFOLD_BATCH( - INPUT_CHECK.out.fastas, + ch_fasta, params.colabfold_model_preset, PREPARE_COLABFOLD_DBS.out.params, [], @@ -128,7 +116,7 @@ workflow COLABFOLD { // if (params.colabfold_model_preset != 'AlphaFold2-ptm') { MULTIFASTA_TO_CSV( - INPUT_CHECK.out.fastas + ch_fasta ) ch_versions = ch_versions.mix(MULTIFASTA_TO_CSV.out.versions) MMSEQS_COLABFOLDSEARCH ( @@ -140,7 +128,7 @@ workflow COLABFOLD { ch_versions = ch_versions.mix(MMSEQS_COLABFOLDSEARCH.out.versions) } else { MMSEQS_COLABFOLDSEARCH ( - INPUT_CHECK.out.fastas, + ch_fasta, PREPARE_COLABFOLD_DBS.out.params, PREPARE_COLABFOLD_DBS.out.colabfold_db, PREPARE_COLABFOLD_DBS.out.uniref30, diff --git a/workflows/esmfold.nf b/workflows/esmfold.nf index 1512bf9a..06738add 100644 --- a/workflows/esmfold.nf +++ b/workflows/esmfold.nf @@ -4,7 +4,7 @@ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -include { paramsSummaryLog; paramsSummaryMap } from 'plugin/nf-validation' +include { paramsSummaryLog; paramsSummaryMap; fromSamplesheet } from 'plugin/nf-validation' def logo = NfcoreTemplate.logo(workflow, params.monochrome_logs) def citation = '\n' + WorkflowMain.citation(workflow) + '\n' @@ -16,16 +16,6 @@ log.info logo + paramsSummaryLog(workflow) + citation // Validate input parameters WorkflowEsmfold.initialise(params, log) -// Check input path parameters to see if they exist -def checkPathParamList = [ - params.input, - params.esmfold_db -] -for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true) } } - -// Check mandatory parameters -//if (params.input) { ch_input = file(params.input) } else { exit 1, 'Input file not specified!' } - /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ CONFIG FILES @@ -33,9 +23,9 @@ for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true */ ch_multiqc_config = Channel.fromPath("$projectDir/assets/multiqc_config.yml", checkIfExists: true) -ch_multiqc_custom_config = params.multiqc_config ? Channel.fromPath( params.multiqc_config, checkIfExists: true ) : Channel.empty() -ch_multiqc_logo = params.multiqc_logo ? Channel.fromPath( params.multiqc_logo, checkIfExists: true ) : Channel.empty() -ch_multiqc_custom_methods_description = params.multiqc_methods_description ? file(params.multiqc_methods_description, checkIfExists: true) : file("$projectDir/assets/methods_description_template.yml", checkIfExists: true) +ch_multiqc_custom_config = params.multiqc_config ? Channel.fromPath( params.multiqc_config ) : Channel.empty() +ch_multiqc_logo = params.multiqc_logo ? Channel.fromPath( params.multiqc_logo ) : Channel.empty() +ch_multiqc_custom_methods_description = params.multiqc_methods_description ? file(params.multiqc_methods_description) : file("$projectDir/assets/methods_description_template.yml", checkIfExists: true) /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -46,7 +36,6 @@ ch_multiqc_custom_methods_description = params.multiqc_methods_description ? fil // // SUBWORKFLOW: Consisting of a mix of local and nf-core/modules // -include { INPUT_CHECK } from '../subworkflows/local/input_check' include { PREPARE_ESMFOLD_DBS } from '../subworkflows/local/prepare_esmfold_dbs' // @@ -81,15 +70,11 @@ workflow ESMFOLD { ch_versions = Channel.empty() // - // SUBWORKFLOW: Read in samplesheet, validate and stage input files + // Create input channel from input file provided through params.input // - INPUT_CHECK ( - file(params.input) - ) - ch_versions = ch_versions.mix(INPUT_CHECK.out.versions) - // TODO: OPTIONAL, you can use nf-validation plugin to create an input channel from the samplesheet with Channel.fromSamplesheet("input") - // See the documentation https://nextflow-io.github.io/nf-validation/samplesheets/fromSamplesheet/ - // ! There is currently no tooling to help you write a sample sheet schema + Channel + .fromSamplesheet("input") + .set { ch_fasta } PREPARE_ESMFOLD_DBS( ) ch_versions = ch_versions.mix(PREPARE_ESMFOLD_DBS.out.versions) @@ -99,7 +84,7 @@ workflow ESMFOLD { // if (params.esmfold_model_preset != 'monomer') { MULTIFASTA_TO_SINGLEFASTA( - INPUT_CHECK.out.fastas + ch_fasta ) ch_versions = ch_versions.mix(MULTIFASTA_TO_SINGLEFASTA.out.versions) RUN_ESMFOLD( @@ -110,7 +95,7 @@ workflow ESMFOLD { ch_versions = ch_versions.mix(RUN_ESMFOLD.out.versions) } else { RUN_ESMFOLD( - INPUT_CHECK.out.fastas, + ch_fasta, PREPARE_ESMFOLD_DBS.out.params, params.num_recycles )