Skip to content

Conversation

@yuukiiwa
Copy link
Member

No description provided.

christopher-hakkaart and others added 30 commits February 24, 2023 22:12
With the updated biocontainer for m6anet being built, can update
the singularity and docker container with the latest version.

This version changed how m6anet is called.  It has `m6anet` and
the analysis as a parameter (`inference`, `dataprep`) instead of
`m6anet-run_inference` and `m6anet-dataprep` commands.

There are now two files for output from `m6anet inference`, but
the existing output of '*' captures those.  In the future, might
be nice to specify these individually and emit them as separate
outputs for downstream analysis.
I updated the samplesheet to output the filename that was attempted
to be used when looking for the fastq file.  When running the
pipeline with multiple samples, I was unable to determine which
sample was causing the samplesheet error until I added this code.
…mplesheet

Samplesheet error message updated with more useful information if fastq can't be found.
@github-actions
Copy link

nf-core pipelines lint overall result: Failed ❌

Posted for pipeline commit b175040

+| ✅ 178 tests passed       |+
#| ❔  10 tests were ignored |#
!| ❗ 106 tests had warnings |!
-| ❌   1 tests failed       |-

❌ Test failures:

  • included_configs - Pipeline config does not include custom configs. Please uncomment the includeConfig line.

❗ Test warnings:

  • pipeline_todos - TODO string in nextflow.config: Specify your pipeline's command line flags
  • pipeline_todos - TODO string in nextflow.config: Optionally, you can add a pipeline-specific nf-core config at https://github.com/nf-core/configs
  • pipeline_todos - TODO string in nextflow.config: Update the field with the details of the contributors to your pipeline. New with Nextflow version 24.10.0
  • pipeline_todos - TODO string in main.nf: Remove this line if you don't need a FASTA file
  • pipeline_todos - TODO string in ro-crate-metadata.json: "description": "

    \n \n <source media="(prefers-color-scheme: dark)" srcset="docs/images/nf-core-nanoseq_logo_dark.png">\n <img alt="nf-core/nanoseq" src="docs/images/nf-core-nanoseq_logo_light.png">\n \n

    \n\nGitHub Actions CI Status\nGitHub Actions Linting StatusAWS CICite with Zenodo\nnf-test\n\nNextflow\nrun with conda\nrun with docker\nrun with singularity\nLaunch on Seqera Platform\n\nGet help on SlackFollow on TwitterFollow on MastodonWatch on YouTube\n\n## Introduction\n\nnf-core/nanoseq is a bioinformatics pipeline that ...\n\n TODO nf-core:\n Complete this sentence with a 2-3 sentence summary of what types of data the pipeline ingests, a brief overview of the\n major pipeline sections and the types of output it produces. You're giving an overview to someone new\n to nf-core here, in 15-20 seconds. For an example, see https://github.com/nf-core/rnaseq/blob/master/README.md#introduction\n\n\n Include a figure that guides the user through the major workflow steps. Many nf-core\n workflows use the "tube map" design for that. See https://nf-co.re/docs/contributing/design_guidelines#examples for examples. \n Fill in short bullet-pointed list of the default steps in the pipeline 1. Read QC (FastQC)2. Present QC for raw reads (MultiQC)\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to this page on how to set-up Nextflow. Make sure to test your setup with -profile test before running the workflow on actual data.\n\n Describe the minimum required steps to execute the pipeline, e.g. how to prepare samplesheets.\n Explain what rows and columns represent. For instance (please edit as appropriate):\n\nFirst, prepare a samplesheet with your input data that looks as follows:\n\nsamplesheet.csv:\n\ncsv\nsample,fastq_1,fastq_2\nCONTROL_REP1,AEG588A1_S1_L002_R1_001.fastq.gz,AEG588A1_S1_L002_R2_001.fastq.gz\n\n\nEach row represents a fastq file (single-end) or a pair of fastq files (paired end).\n\n\n\nNow, you can run the pipeline using:\n\n update the following command to include all required parameters for a minimal example \n\nbash\nnextflow run nf-core/nanoseq \\\n -profile <docker/singularity/.../institute> \\\n --input samplesheet.csv \\\n --outdir <OUTDIR>\n\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow -params-file option. Custom config files including those provided by the -c Nextflow option can be used to provide any configuration except for parameters; see docs.\n\nFor more details and further functionality, please refer to the usage documentation and the parameter documentation.\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the results tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\noutput documentation.\n\n## Credits\n\nnf-core/nanoseq was originally written by Chelsea Sawyer, Yuk Kei Wan.\n\nWe thank the following people for their extensive assistance in the development of this pipeline:\n\n If applicable, make list of people who have also contributed \n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the contributing guidelines.\n\nFor further information or help, don't hesitate to get in touch on the Slack #nanoseq channel (you can join with this invite).\n\n## Citations\n\n Add citation for pipeline after first release. Uncomment lines below and update Zenodo doi and badge at the top of this file. \n If you use nf-core/nanoseq for your analysis, please cite it using the following doi: 10.5281/zenodo.XXXXXX \n\n Add bibliography of tools and data used in your pipeline \n\nAn extensive list of references for the tools used by the pipeline can be found in the CITATIONS.md file.\n\nYou can cite the nf-core publication as follows:\n\n> The nf-core framework for community-curated bioinformatics pipelines.\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> Nat Biotechnol. 2020 Feb 13. doi: 10.1038/s41587-020-0439-x.\n",
  • pipeline_todos - TODO string in main.nf: Optionally add in-text citation tools to this list.
  • pipeline_todos - TODO string in main.nf: Optionally add bibliographic entries to this list.
  • pipeline_todos - TODO string in main.nf: Only uncomment below if logic in toolCitationText/toolBibliographyText has been filled!
  • pipeline_todos - TODO string in methods_description_template.yml: #Update the HTML below to your preferred methods description, e.g. add publication citation for this pipeline
  • pipeline_todos - TODO string in base.config: Check the defaults for all processes
  • pipeline_todos - TODO string in base.config: Customise requirements for specific processes.
  • pipeline_todos - TODO string in awsfulltest.yml: You can customise AWS full pipeline tests as required
  • schema_lint - Schema $id should be https://raw.githubusercontent.com/nf-core/nanoseq/main/nextflow_schema.json or https://raw.githubusercontent.com/nf-core/nanoseq/master/nextflow_schema.json.
    Found https://raw.githubusercontent.com/nf-core/nanoseq//nextflow_schema.json
  • schema_description - Ungrouped param in schema: protocol
  • schema_description - Ungrouped param in schema: genome
  • schema_description - Ungrouped param in schema: fasta
  • schema_description - Ungrouped param in schema: gtf
  • schema_description - Ungrouped param in schema: input_path
  • schema_description - Ungrouped param in schema: input_path_file_type
  • schema_description - Ungrouped param in schema: bedmethyl_out
  • schema_description - Ungrouped param in schema: flowcell
  • schema_description - Ungrouped param in schema: kit
  • schema_description - Ungrouped param in schema: barcode_kit
  • schema_description - Ungrouped param in schema: barcode_both_ends
  • schema_description - Ungrouped param in schema: trim_barcodes
  • schema_description - Ungrouped param in schema: dorado_model
  • schema_description - Ungrouped param in schema: doraro_modification
  • schema_description - Ungrouped param in schema: dorado_device
  • schema_description - Ungrouped param in schema: qcat_min_score
  • schema_description - Ungrouped param in schema: qcat_detect_middle
  • schema_description - Ungrouped param in schema: skip_basecalling
  • schema_description - Ungrouped param in schema: skip_demultiplexing
  • schema_description - Ungrouped param in schema: nanolyse_fasta
  • schema_description - Ungrouped param in schema: run_nanolyse
  • schema_description - Ungrouped param in schema: aligner
  • schema_description - Ungrouped param in schema: stranded
  • schema_description - Ungrouped param in schema: save_align_intermeds
  • schema_description - Ungrouped param in schema: skip_alignment
  • schema_description - Ungrouped param in schema: skip_bigbed
  • schema_description - Ungrouped param in schema: skip_bigwig
  • schema_description - Ungrouped param in schema: quantification_method
  • schema_description - Ungrouped param in schema: skip_quantification
  • schema_description - Ungrouped param in schema: skip_differential_analysis
  • schema_description - Ungrouped param in schema: skip_modification_analysis
  • schema_description - Ungrouped param in schema: skip_xpore
  • schema_description - Ungrouped param in schema: skip_m6anet
  • schema_description - Ungrouped param in schema: skip_fusion_analysis
  • schema_description - Ungrouped param in schema: jaffal_ref_dir
  • schema_description - Ungrouped param in schema: skip_qc
  • schema_description - Ungrouped param in schema: skip_nanoplot
  • schema_description - Ungrouped param in schema: skip_toulligqc
  • schema_description - Ungrouped param in schema: skip_fastqc
  • schema_description - Ungrouped param in schema: skip_multiqc
  • schema_description - Ungrouped param in schema: igenomes_base
  • schema_description - Ungrouped param in schema: igenomes_ignore
  • schema_description - Ungrouped param in schema: multiqc_config
  • schema_description - Ungrouped param in schema: multiqc_title
  • schema_description - Ungrouped param in schema: multiqc_logo
  • schema_description - Ungrouped param in schema: max_multiqc_email_size
  • schema_description - Ungrouped param in schema: multiqc_methods_description
  • schema_description - Ungrouped param in schema: publish_dir_mode
  • schema_description - Ungrouped param in schema: email
  • schema_description - Ungrouped param in schema: email_on_fail
  • schema_description - Ungrouped param in schema: plaintext_email
  • schema_description - Ungrouped param in schema: monochrome_logs
  • schema_description - Ungrouped param in schema: hook_url
  • schema_description - Ungrouped param in schema: pipelines_testdata_base_path
  • schema_description - Ungrouped param in schema: config_profile_name
  • schema_description - Ungrouped param in schema: config_profile_description
  • schema_description - Ungrouped param in schema: custom_config_version
  • schema_description - Ungrouped param in schema: custom_config_base
  • schema_description - Ungrouped param in schema: config_profile_contact
  • schema_description - Ungrouped param in schema: config_profile_url
  • local_component_structure - samplesheet_check.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - m6anet_inference.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - f5c_index_eventalign.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - get_nanolyse_fasta.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - xpore_dataprep.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - fast5_to_pod5.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - dorado_aligner.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - dexseq.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - gtf2bed.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - modkit_pileup.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - blue-crab.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - dorado_basecaller.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - bambu.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - nanopolish_index_eventalign.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - jaffal.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - xpore_diffmod.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - bam_rename.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - multiqc.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - deseq2.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - get_chrom_sizes.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - get_jaffal_ref.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - get_test_data.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - m6anet_dataprep.nf in modules/local should be moved to a TOOL/SUBTOOL/main.nf structure
  • local_component_structure - input_check.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - qcfastq_nanoplot_fastqc.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - bedtools_ucsc_bigbed.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - bedtools_ucsc_bigwig.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - rna_fusions_jaffal.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - differential_deseq2_dexseq.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - rna_modifications_xpore_m6anet.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - quantify_stringtie_featurecounts.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - align_minimap2.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure
  • local_component_structure - align_graphmap2.nf in subworkflows/local should be moved to a SUBWORKFLOW_NAME/main.nf structure

❔ Tests ignored:

✅ Tests passed:

Run details

  • nf-core/tools version 3.2.1
  • Run at 2025-05-28 01:16:56

Copy link

@awgymer awgymer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I appreciate the efforts being made here but I don't think this PR is ready for a release just yet. I think some of the debug/test profiles may not work either but I haven't confirmed this locally.

I've left a few specific comments but I think there might be benefit in some more restructuring/trimming too.

I also think there would be big benefit in the validation of the samplesheet and parameters being more removed from the pipeline logic and handled by nf-schema.

pull_request_target:
branches: [master]
branches:
- main
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

master/main - are both intended to be supported by nf-core repos now?

K562,1,,K562_directcDNA_replicate1.fastq.gz,genome.fa,genes.gtf
K562,2,,K562_directcDNA_replicate2.fastq.gz,genome.fa,genes.gtf
K562,3,,K562_directRNA_replicate3.fastq.gz,genome.fa,genes.gtf
sample,fastq_1,fastq_2
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks unchanged from the template. I would either remove or update to reflect a real samplesheet format for nanoseq

@@ -1,5 +1,5 @@
{
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unchanged from template. Can either remove or consider updating to reflect the allowed samplesheet formats for nanoseq. Even if this file is unused right now (e.g. no nf-schema) an accurate schema can really help users.

// This is an example of how to use getGenomeAttribute() to fetch parameters
// from igenomes.config using `--genome`
params.fasta = getGenomeAttribute('fasta')
params.gtf = getGenomeAttribute('gtf')
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These params need to be initialised above the include for NANOSEQ or these defaults won't be propogated into that workflow.

You have to include { getGenomeAttribute } then put these lines, and then include the workflows.

@@ -21,6 +21,24 @@ if (params.input) {
exit 1, 'Input samplesheet not specified!'
}

if (params.fasta){
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be needed if getGenomeAttribute gets put in the proper place in the main.nf


script:
"""
dorado aligner --mm2-preset map-ont $fasta $mod_bam > aligned.bam && samtools sort aligned.bam -o aligned_sorted.bam && samtools index aligned_sorted.bam
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider piping the outputs rather than chaining with &&

BAM_STATS_SAMTOOLS ( ch_bam_bai, ch_fasta )
ch_stats = BAM_STATS_SAMTOOLS.out.stats
ch_flagstat = BAM_STATS_SAMTOOLS.out.flagstat
ch_idxstats = BAM_STATS_SAMTOOLS.out.idxstats

emit:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider naming the outputs for better clarity

bam_index_extension = 'bai'
cigar_paf_format = false
cigar_bam = false
if (params.call_variants) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there actually a difference in these two calls to MINIMAP2 here? I can't see any custom config for these aliases which would indicate they produce different outputs.

Additionally access of params here is against the newest guidelines for nextflow and will be deprecated shortly.

.set { ch_sample_gtf }
STRINGTIE_STRINGTIE ( ch_sorted_bam, ch_annotation_gtf )
ch_stringtie_gtf = STRINGTIE_STRINGTIE.out.transcript_gtf
stringtie2_version = STRINGTIE_STRINGTIE.out.versions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Versions can be mixed into a single ch_versions for each subworkflow and emitted as a single versions channel and then mixed into the main ch_versions of the parent workflow, unless there is good reason to keep them separate. (This applies to all the local subworkflows)

ch_software_versions = ch_software_versions.mix(CUSTOM_GETCHROMSIZES.out.versions.first().ifEmpty(null))

// will add the following in when nf-core/modules/minimap2/align supports junction bed input
//GTF2BED ( ch_chr_sizes )
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GTF2BED not used? Consider removing the module from the include and the repo generally

Copy link

@fbdtemme fbdtemme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have left some comments, mostly related to more closely following nf-core/modules style in the local modules.

Comment on lines +30 to +32
// Input data to perform both basecalling and demultiplexing
input = 'https://raw.githubusercontent.com/yuukiiwa/test-datasets/nanoseq/3.2/samplesheet/samplesheet_bc_dx.csv'
fasta = 'https://raw.githubusercontent.com/nf-core/test-datasets/nanoseq/reference/hg19_KCMF1.fa'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using the params.pipelines_testdata_base_path here instead to make the test inputs more generic.
There are quite some other places in the different .config files where the same can be done.

Comment on lines +25 to +28
// Limit resources so that this can run on GitHub Actions
max_cpus = 2
max_memory = '6.GB'
max_time = '6.h'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are now replaced with the process.resourceLimits from above so they can be removed.

path fasta

output:
tuple val(meta), path("aligned_sorted.bam"), path("*.bai") , emit: aligned_bam

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very small thing, but I find it a little confusing to call this bam bai combined channel aligned_bam.
I would just expect [ meta, bam ] from that name.

Maybe split it up

    tuple val(meta), path("aligned_sorted.bam")         , emit: bam
    tuple val(meta), path("*.bai")                      , emit: bai

or rename to aligned_bam_bai ?

path "versions.yml" , emit: versions

script:
def emit_args = (params.dorado_modification == null) ? " --emit-fastq > basecall.fastq && gzip basecall.fastq" : " --modified-bases $params.dorado_modification > basecall.bam"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here the comment from @awgymer above:
Pipe directly to gzip instead of chaining with &&

Comment on lines +21 to +29
sample_summary = "$meta.id" +"_summary.txt"
sample_eventalign = "$meta.id" +"_eventalign.txt"
fastq="$meta.id"+".fastq"
fast5 = "$meta.fast5"
fastqi="$fastq"+"*"
"""
gunzip -c $fastqgz > $fastq
f5c index -d $fast5 $fastq
echo $fastqi

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is slightly cleaner to use interpolation here instead of the string concatenation with +

Suggested change
sample_summary = "$meta.id" +"_summary.txt"
sample_eventalign = "$meta.id" +"_eventalign.txt"
fastq="$meta.id"+".fastq"
fast5 = "$meta.fast5"
fastqi="$fastq"+"*"
"""
gunzip -c $fastqgz > $fastq
f5c index -d $fast5 $fastq
echo $fastqi
def sample_summary = "${meta.id}_summary.txt"
def sample_eventalign = "${meta.id}_eventalign.txt"
def fastq ="${meta.id}.fastq"
def fast5 = meta.fast5
"""
gunzip -c $fastqgz > $fastq
f5c index -d $fast5 $fastq
echo ${fastq}*

Comment on lines -7 to +9
path "test-datasets/fast5/$barcoded/*" , emit: ch_input_fast5s_path
path "test-datasets/fast5/$barcoded/" , emit: ch_input_fast5_dir_path
path "test-datasets/modification_fast5_fastq/", emit: ch_input_dir_path
path "test-datasets/pod5/" , emit: ch_pod5_dir_path

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would remove the ch_ here from the output channel names.

cat <<-END_VERSIONS > versions.yml
"${task.process}":
m6anet: \$( echo 'm6anet 1.0' )
m6anet: \$( echo 'm6anet 2.0.2' )

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not call m6anet --version here?
It looks like its supported in m6anaet

Comment on lines +16 to +20
script:
bedmethyl = "$meta.id" +".bed"
"""
modkit pileup $aligned_mod_bam $bedmethyl --threads $task.cpus

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be good to use the nf-core/modules standard prefix here:

Suggested change
script:
bedmethyl = "$meta.id" +".bed"
"""
modkit pileup $aligned_mod_bam $bedmethyl --threads $task.cpus
script:
def prefix = task.ext.prefix ?: meta.id
"""
modkit pileup $aligned_mod_bam "${prefix}.bed" --threads $task.cpus

Comment on lines 20 to 26
script:
sample_summary = "$meta.id" +"_summary.txt"
sample_eventalign = "$meta.id" +"_eventalign.txt"
fast5 = "$meta.fast5"
"""
nanopolish index -d $fast5 $fastq
nanopolish eventalign --reads $fastq --bam $bam --genome $genome --scale-events --signal-index --summary $sample_summary --threads $task.cpus > $sample_eventalign

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here. Cleaner to use the standard prefix variable:

Suggested change
script:
sample_summary = "$meta.id" +"_summary.txt"
sample_eventalign = "$meta.id" +"_eventalign.txt"
fast5 = "$meta.fast5"
"""
nanopolish index -d $fast5 $fastq
nanopolish eventalign --reads $fastq --bam $bam --genome $genome --scale-events --signal-index --summary $sample_summary --threads $task.cpus > $sample_eventalign
script:
def prefix = task.ext.prefix ?: meta.id
fast5 = "$meta.fast5"
"""
nanopolish index -d $fast5 $fastq
nanopolish eventalign --reads $fastq \\
--bam $bam \\
--genome $genome \\
--scale-events --signal-index \\
--summary ${prefix}_summary.txt \\
--threads $task.cpus > ${prefix}_eventalign


script: // This script is bundled with the pipeline, in nf-core/nanoseq/bin/
updated_path = workflow.profile.contains('test_nodx_rnamod') ? "$input_path" : "not_changed"
updated_path = (workflow.profile.contains('test_bc_nodx') || workflow.profile.contains('rnamod')) ? "$input_path" : "not_changed"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think its cleaner here to pass in workflow.profile as a val input to the process instead of accessing the global workflow object from inside a process

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this line should be changed
from:

ch_fastqc_multiqc.ifEmpty([]),

to:

ch_fastqc_multiqc.collect().ifEmpty([]),

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.