-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Added nf-core module presto/pairseq #12222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Vivian0105
wants to merge
3
commits into
nf-core:master
Choose a base branch
from
Vivian0105:new_presto_pairseq
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+217
−0
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| --- | ||
| # yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json | ||
| channels: | ||
| - conda-forge | ||
| - bioconda | ||
| dependencies: | ||
| - "bioconda::presto=0.7.9" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| process PRESTO_PAIRSEQ { | ||
| tag "$meta.id" | ||
| label 'process_low' | ||
|
|
||
| conda "${moduleDir}/environment.yml" | ||
| container "${ workflow.containerEngine in ['singularity', 'apptainer'] && !task.ext.singularity_pull_docker_container ? | ||
| 'https://depot.galaxyproject.org/singularity/presto:0.7.9--pyhdfd78af_0': | ||
| 'quay.io/biocontainers/presto:0.7.9--pyhdfd78af_0' }" | ||
|
|
||
| input: | ||
| tuple val(meta), path(R1_reads), path(R2_reads) | ||
| val(barcode_position) | ||
|
|
||
| output: | ||
| tuple val(meta), path("*_pair-pass.fastq.gz"), path("*_pair-pass.fastq.gz") , emit: reads | ||
| path "*_command_log.txt", emit: logs | ||
| tuple val("${task.process}"), val('presto'), eval('PairSeq.py --version | grep -o "[0-9][0-9.]*" | head -n 1'), emit: versions_presto, topic: versions | ||
|
|
||
| when: | ||
| task.ext.when == null || task.ext.when | ||
|
|
||
| script: | ||
| def copyfield = (barcode_position == 'R1')? '--1f BARCODE' : (barcode_position == 'R2')? '--2f BARCODE' : (barcode_position == 'R1R2')? '--1f BARCODE --2f BARCODE' : (barcode_position == 'clustersets')? '--1f CLUSTER --2f CLUSTER' : '' | ||
| def args = task.ext.args?: '' | ||
| def prefix = task.ext.prefix ?: "${meta.id}" | ||
| """ | ||
| PairSeq.py -1 ${R1_reads} \\ | ||
| -2 ${R2_reads} \\ | ||
| --outname ${prefix} \\ | ||
| $copyfield \\ | ||
| $args > ${prefix}_command_log.txt | ||
|
|
||
| """ | ||
|
|
||
| stub: | ||
| def copyfield = (barcode_position == 'R1')? '--1f BARCODE' : (barcode_position == 'R2')? '--2f BARCODE' : (barcode_position == 'R1R2')? '--1f BARCODE --2f BARCODE' : (barcode_position == 'clustersets')? '--1f CLUSTER --2f CLUSTER' : '' | ||
| def args = task.ext.args?: '' | ||
| def prefix = task.ext.prefix ?: "${meta.id}" | ||
| """ | ||
| touch ${prefix}-1_pair-pass.fastq.gz \\ | ||
| ${prefix}-2_pair-pass.fastq.gz \\ | ||
| ${prefix}_command_log.txt | ||
| """ | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,89 @@ | ||
| name: "presto_pairseq" | ||
| description: Sorts and matches sequence records with matching coordinates across | ||
| files | ||
| keywords: | ||
| - immcantation | ||
| - airrseq | ||
| - genomics | ||
| - immunoinformatics | ||
| tools: | ||
| - "presto": | ||
| description: "A bioinformatics toolkit for processing high-throughput lymphocyte | ||
| receptor sequencing data." | ||
| homepage: "https://immcantation.readthedocs.io" | ||
| documentation: "https://presto.readthedocs.io" | ||
| tool_dev_url: "https://bitbucket.org/kleinstein/presto" | ||
| doi: "10.1093/bioinformatics/btu138" | ||
| licence: | ||
| - "AGPL v3" | ||
| identifier: biotools:presto-measure | ||
| input: | ||
| - - meta: | ||
| type: map | ||
| description: | | ||
| Groovy Map containing sample information | ||
| e.g. `[ id:'test']` | ||
| - R1_reads: | ||
| type: file | ||
| description: compressed fastq file | ||
| pattern: "*.{fastq.gz}" | ||
| ontologies: | ||
| - edam: http://edamontology.org/format_1930 | ||
| - R2_reads: | ||
| type: file | ||
| description: compressed fastq file | ||
| pattern: "*.{fastq.gz}" | ||
| ontologies: | ||
| - edam: http://edamontology.org/format_1930 | ||
| - barcode_position: | ||
| type: string | ||
| description: Barcode position. One of "R1, R2, R1R2 or clustersets". Default | ||
| is "" | ||
| output: | ||
| reads: | ||
| - - meta: | ||
| type: map | ||
| description: | | ||
| Groovy Map containing sample information | ||
| e.g. `[ id:'test']` | ||
| - "*_pair-pass.fastq.gz": | ||
| type: file | ||
| description: paired fastq.gz file of R1 reads | ||
| pattern: "*.{fastq.gz}" | ||
| ontologies: | ||
| - edam: http://edamontology.org/format_1930 | ||
| - "*_pair-pass.fastq.gz": | ||
| type: file | ||
| description: paired fastq.gz file of R2 reads | ||
| pattern: "*.{fastq.gz}" | ||
| ontologies: | ||
| - edam: http://edamontology.org/format_1930 | ||
| logs: | ||
| - "*_command_log.txt": | ||
| type: file | ||
| description: command_logs | ||
| pattern: "*.txt" | ||
| ontologies: [] | ||
| versions_presto: | ||
| - - ${task.process}: | ||
| type: string | ||
| description: The name of the process | ||
| - presto: | ||
| type: string | ||
| description: the name of the tool | ||
| - PairSeq.py --version | grep -o "[0-9][0-9.]*" | head -n 1: | ||
| type: eval | ||
| description: The expression to obtain the version of the tool | ||
| topics: | ||
| versions: | ||
| - - ${task.process}: | ||
| type: string | ||
| description: The name of the process | ||
| - presto: | ||
| type: string | ||
| description: the name of the tool | ||
| - PairSeq.py --version | grep -o "[0-9][0-9.]*" | head -n 1: | ||
| type: eval | ||
| description: The expression to obtain the version of the tool | ||
| authors: | ||
| - "@Vivian0105" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,42 @@ | ||||||||||||||||||||||||||||||||||||||||
| nextflow_process { | ||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
| name "Test Process PRESTO_PAIRSEQ" | ||||||||||||||||||||||||||||||||||||||||
| script "../main.nf" | ||||||||||||||||||||||||||||||||||||||||
| process "PRESTO_PAIRSEQ" | ||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
| tag "modules" | ||||||||||||||||||||||||||||||||||||||||
| tag "modules_nfcore" | ||||||||||||||||||||||||||||||||||||||||
| tag "presto" | ||||||||||||||||||||||||||||||||||||||||
| tag "presto/pairseq" | ||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
| test("homo_sapiens - fastq") { | ||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
| when { | ||||||||||||||||||||||||||||||||||||||||
| process { | ||||||||||||||||||||||||||||||||||||||||
| """ | ||||||||||||||||||||||||||||||||||||||||
| input[0] = [ | ||||||||||||||||||||||||||||||||||||||||
| [ id:'test' ], | ||||||||||||||||||||||||||||||||||||||||
| file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/fastq/test_airrseq_umi_R1.fastq.gz', checkIfExists: true), | ||||||||||||||||||||||||||||||||||||||||
| file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/fastq/test_airrseq_R2.fastq.gz', checkIfExists: true), | ||||||||||||||||||||||||||||||||||||||||
| ] | ||||||||||||||||||||||||||||||||||||||||
| input[1] = "" | ||||||||||||||||||||||||||||||||||||||||
| """ | ||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
| then { | ||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
| assertAll( | ||||||||||||||||||||||||||||||||||||||||
| { assert process.success}, | ||||||||||||||||||||||||||||||||||||||||
| { assert snapshot( | ||||||||||||||||||||||||||||||||||||||||
| process.out.reads.get(0).get(1), | ||||||||||||||||||||||||||||||||||||||||
| process.out.reads.get(0).get(2) | ||||||||||||||||||||||||||||||||||||||||
| ).match("test_snap_out")}, | ||||||||||||||||||||||||||||||||||||||||
| { assert snapshot( | ||||||||||||||||||||||||||||||||||||||||
| process.out.versions_presto).match("test_snap_versions") | ||||||||||||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||||||||||||
| { assert path(process.out.logs.get(0)).getText().contains("PASS") } | ||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+29
to
+39
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
a bit more compact way to write this |
||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| { | ||
| "test_snap_out": { | ||
| "content": [ | ||
| [ | ||
| "test-1_pair-pass.fastq.gz:md5,7f98eefe4c7111d4632685680b6b9a4b", | ||
| "test-2_pair-pass.fastq.gz:md5,51220f557d95ab70c0819e9a3e8e593a" | ||
| ], | ||
| [ | ||
| "test-1_pair-pass.fastq.gz:md5,7f98eefe4c7111d4632685680b6b9a4b", | ||
| "test-2_pair-pass.fastq.gz:md5,51220f557d95ab70c0819e9a3e8e593a" | ||
| ] | ||
| ], | ||
| "timestamp": "2026-07-01T11:37:32.233234794", | ||
| "meta": { | ||
| "nf-test": "0.9.5", | ||
| "nextflow": "26.04.4" | ||
| } | ||
| }, | ||
| "test_snap_versions": { | ||
| "content": [ | ||
| [ | ||
| [ | ||
| "PRESTO_PAIRSEQ", | ||
| "presto", | ||
| "0.7.9" | ||
| ] | ||
| ] | ||
| ], | ||
| "timestamp": "2026-07-01T11:37:32.31243821", | ||
| "meta": { | ||
| "nf-test": "0.9.5", | ||
| "nextflow": "26.04.4" | ||
| } | ||
| } | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will using the same glob not resulting in both channels having both reads? Can't you somehow distinguish between read 1 and read 2 in the output to preserve the order?