Conversation
tomiles
left a comment
There was a problem hiding this comment.
In general, [modules/local/umi_consensus/main.nf is a mess. Almost everything there has a matching nf-core module, so we should switch to those. Local models should be limited to preprocessing workflow specific implementation that we can’t be found/pushed upstream in nf-core modules.
|
Don't forget to remove the unnecessary tests for the now deleted local modules. |
| include { SAMTOOLS_CONVERT as SAMTOOLS_CONVERT_UMI } from "../../../modules/nf-core/samtools/convert/main" | ||
| include { SAMTOOLS_SORMADUP } from "../../../modules/nf-core/samtools/sormadup/main.nf" | ||
| include { SAMTOOLS_SORT } from "../../../modules/nf-core/samtools/sort/main" | ||
| include { UMI_CONSENSUS_KAPA } from '../../local/umi_consensus/main' |
There was a problem hiding this comment.
Could it be that you forgotten git add the now separated UMI_CONSENSUS_KAPA subworkflow file?
docs/README.md
Outdated
|
|
||
| - [Usage](usage.md) | ||
| - An overview of how the pipeline works, how to run it and a description of all of the different command-line flags. | ||
| - [Technical map](technical_map.md) |
There was a problem hiding this comment.
Where does this change originate from? Since there’s no technical_map.md introduced in this PR, is this a merge/rebase conflict resolution artifact?
samplesheet.minimal.yml
Outdated
There was a problem hiding this comment.
Test samplesheet should go in the tests/inputs/test.yml Amend test samplesheet and retain per sample configurability
tests/config/nf-test.config
Outdated
| } | ||
|
|
||
| params { | ||
| disable_pipeline_plugins = true |
modules/local/umi_consensus/main.nf
Outdated
|
|
||
| // Local lightweight filtering step used before module-based UMI processing. | ||
| // Keeps primary mapped reads and removes unmapped/secondary/supplementary records. | ||
| process UMI_LOCAL_SAMTOOLS_VIEW { |
There was a problem hiding this comment.
No need for this to be an extra process. You can just alias the nf-core samtools_view module and configure in modules.config
docs/umi_consensus.md
Outdated
There was a problem hiding this comment.
Integrate relevant (global) info in existing markdown files, amend the metro map and then remove this file
docs/usage.md
Outdated
| When `umi_consensus` is enabled, the `UMI_CONSENSUS_KAPA` workflow runs multiple `samtools`/`fgbio` processes plus remapping through `FASTQ_ALIGN_DNA`. | ||
| With container-based execution (`docker`, `singularity`, etc.), default per-process containers are already configured. | ||
|
|
||
| Example custom config snippet: |
modules/local/umi_consensus/main.nf
Outdated
| } | ||
| .set { ch_umi_bam_bai_fasta_fai } | ||
|
|
||
| SAMTOOLS_CONVERT_UMI(ch_umi_bam_bai_fasta_fai) |
There was a problem hiding this comment.
No need for extra import, just mix the output bams in the bam channel and pipe to the regular samtools view
| .set { ch_cram_crai } | ||
| ch_cram_crai.dump(tag: "FASTQ_TO_CRAM: cram and crai", pretty: true) | ||
|
|
||
| ch_sormadup_metrics = ch_sormadup_metrics.mix(UMI_CONSENSUS_KAPA.out.family_sizes) |
|
|
||
| main: | ||
| // 1) Initial mapping of raw reads with the configured aligner/index. | ||
| FASTQ_ALIGN_DNA(ch_meta_reads_aligner_index_fasta, false) |
There was a problem hiding this comment.
Should be handled by the parent workflow, use pre-aligned bam as input
| } | ||
|
|
||
| // 3) Prepare read-pair metadata and UMI tags before consensus calling. | ||
| UMI_SAMTOOLS_VIEW( |
| // 3) Prepare read-pair metadata and UMI tags before consensus calling. | ||
| UMI_SAMTOOLS_VIEW( | ||
| FASTQ_ALIGN_DNA.out.bam | ||
| .map { meta, bam -> [meta, bam, file('/etc/hosts')] }, |
tests/inputs/zipper_ref2.txt
Outdated
There was a problem hiding this comment.
remove this and add to test-datasets if needed
…s named UMI_SAMTOOLS_PREP_TEMPLATE
a7bdabe to
b4ebadf
Compare
| -o ${prefix}.bam \\ | ||
| -t ${task.cpus} \\ | ||
| snap-aligner ${subcmd} \ | ||
| \$INDEX \ |
| SAMTOOLS_STATS(ch_bam_bai_fasta_fai) | ||
| SAMTOOLS_FLAGSTAT(ch_bam_bai_fasta_fai) | ||
| SAMTOOLS_IDXSTATS(ch_bam_bai_fasta_fai) | ||
| SAMTOOLS_FLAGSTAT(ch_bam_bai) |
| // FUNCTIONS | ||
| include { getGenomeAttribute } from '../../local/utils_nfcore_preprocessing_pipeline' | ||
|
|
||
| workflow FASTQ_ALIGN_DNA { |
PR checklist
nf-core pipelines lint).nextflow run . -profile test,docker --outdir <OUTDIR>).nextflow run . -profile debug,test,docker --outdir <OUTDIR>).docs/usage.mdis updated.docs/output.mdis updated.CHANGELOG.mdis updated.README.mdis updated (including new tool citations and authors/contributors).