-
Notifications
You must be signed in to change notification settings - Fork 714
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch '325-mixed-model-in-limma' of github.com:nf-core/modules…
… into 325-mixed-model-in-limma
- Loading branch information
Showing
5 changed files
with
254 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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::pbmm2=1.14.99" |
This file contains 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,51 @@ | ||
process PBMM2_ALIGN { | ||
tag "$meta.id" | ||
label 'process_large' | ||
|
||
|
||
conda "${moduleDir}/environment.yml" | ||
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? | ||
'https://depot.galaxyproject.org/singularity/pbmm2:1.14.99--h9ee0642_0': | ||
'biocontainers/pbmm2:1.14.99--h9ee0642_0' }" | ||
|
||
input: | ||
tuple val(meta), path(bam) | ||
tuple val(meta2), path(fasta) | ||
|
||
output: | ||
tuple val(meta), path("*.bam"), emit: bam | ||
path "versions.yml" , emit: versions | ||
|
||
when: | ||
task.ext.when == null || task.ext.when | ||
|
||
script: | ||
def args = task.ext.args ?: '' | ||
def prefix = task.ext.prefix ?: "${meta.id}" | ||
""" | ||
pbmm2 \\ | ||
align \\ | ||
$args \\ | ||
$fasta \\ | ||
$bam \\ | ||
${prefix}.bam \\ | ||
--num-threads ${task.cpus} | ||
cat <<-END_VERSIONS > versions.yml | ||
"${task.process}": | ||
pbmm2: \$(pbmm2 --version |& sed '1!d ; s/pbmm2 //') | ||
END_VERSIONS | ||
""" | ||
|
||
stub: | ||
def args = task.ext.args ?: '' | ||
def prefix = task.ext.prefix ?: "${meta.id}" | ||
""" | ||
touch ${prefix}.bam | ||
cat <<-END_VERSIONS > versions.yml | ||
"${task.process}": | ||
pbmm2: \$(pbmm2 --version |& sed '1!d ; s/pbmm2 //') | ||
END_VERSIONS | ||
""" | ||
} |
This file contains 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,61 @@ | ||
# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json | ||
name: "pbmm2_align" | ||
description: Alignment with PacBio's minimap2 frontend | ||
keywords: | ||
- align | ||
- pacbio | ||
- genomics | ||
tools: | ||
- "pbmm2": | ||
description: "A minimap2 frontend for PacBio native data formats" | ||
homepage: "https://github.com/PacificBiosciences/pbmm2" | ||
documentation: "https://github.com/PacificBiosciences/pbmm2" | ||
tool_dev_url: "https://github.com/PacificBiosciences/pbmm2" | ||
licence: ["BSD-3-clause-Clear"] | ||
identifier: biotools:pbmm2 | ||
|
||
input: | ||
- - meta: | ||
type: map | ||
description: | | ||
Groovy Map containing sample information | ||
e.g. `[ id:'sample1', single_end:false ]` | ||
- bam: | ||
type: file | ||
description: Sorted BAM/CRAM/SAM file | ||
pattern: "*.{bam,cram,sam}" | ||
- - meta2: | ||
type: map | ||
description: | | ||
Groovy Map containing sample information | ||
e.g. `[ id:'sample1', single_end:false ]` | ||
- fasta: | ||
type: file | ||
description: fasta file to align bam to | ||
pattern: "*.{fasta}" | ||
output: | ||
- bam: | ||
- meta: | ||
type: map | ||
description: | | ||
Groovy Map containing sample information | ||
e.g. `[ id:'sample1', single_end:false ]` | ||
- "*.bam": | ||
type: file | ||
description: Sorted BAM/CRAM/SAM file | ||
pattern: "*.{bam,cram,sam}" | ||
ontologies: | ||
- edam: "http://edamontology.org/format_2572" | ||
- edam: "http://edamontology.org/format_2573" | ||
- edam: "http://edamontology.org/format_3462" | ||
|
||
- versions: | ||
- "versions.yml": | ||
type: file | ||
description: File containing software versions | ||
pattern: "versions.yml" | ||
|
||
authors: | ||
- "@tanyasarkjain" | ||
maintainers: | ||
- "@tanyasarkjain" |
This file contains 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,67 @@ | ||
nextflow_process { | ||
|
||
name "Test Process PBMM2_ALIGN" | ||
script "../main.nf" | ||
process "PBMM2_ALIGN" | ||
|
||
tag "modules" | ||
tag "modules_nfcore" | ||
tag "pbmm2" | ||
tag "pbmm2/align" | ||
|
||
test("pbmm2 - bam") { | ||
when { | ||
process { | ||
""" | ||
input[0] = [ | ||
[ id:'test' ], // meta map | ||
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam', checkIfExists: true), | ||
] | ||
input[1] = [ | ||
[ id:'test' ], // meta map | ||
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome3.fasta', checkIfExists: true), | ||
] | ||
""" | ||
} | ||
} | ||
|
||
then { | ||
assertAll( | ||
{ assert process.success }, | ||
{ assert snapshot(process.out).match() } | ||
) | ||
} | ||
|
||
} | ||
|
||
test("pbmm2 - bam - stub") { | ||
|
||
options "-stub" | ||
|
||
when { | ||
process { | ||
""" | ||
input[0] = [ | ||
[ id:'test' ], // meta map | ||
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam', checkIfExists: true), | ||
] | ||
input[1] = [ | ||
[ id:'test' ], // meta map | ||
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome3.fasta', checkIfExists: true), | ||
] | ||
""" | ||
} | ||
} | ||
|
||
then { | ||
assertAll( | ||
{ assert process.success }, | ||
{ assert snapshot(process.out).match() } | ||
) | ||
} | ||
|
||
} | ||
|
||
} |
This file contains 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,68 @@ | ||
{ | ||
"pbmm2 - bam": { | ||
"content": [ | ||
{ | ||
"0": [ | ||
[ | ||
{ | ||
"id": "test" | ||
}, | ||
"test.bam:md5,b1d6b50f20ba0389435c6a51de26d836" | ||
] | ||
], | ||
"1": [ | ||
"versions.yml:md5,e8aa0696ac2bf135b5f88e6cb7e7b18a" | ||
], | ||
"bam": [ | ||
[ | ||
{ | ||
"id": "test" | ||
}, | ||
"test.bam:md5,b1d6b50f20ba0389435c6a51de26d836" | ||
] | ||
], | ||
"versions": [ | ||
"versions.yml:md5,e8aa0696ac2bf135b5f88e6cb7e7b18a" | ||
] | ||
} | ||
], | ||
"meta": { | ||
"nf-test": "0.9.0", | ||
"nextflow": "24.04.4" | ||
}, | ||
"timestamp": "2024-10-30T10:53:18.838135" | ||
}, | ||
"pbmm2 - bam - stub": { | ||
"content": [ | ||
{ | ||
"0": [ | ||
[ | ||
{ | ||
"id": "test" | ||
}, | ||
"test.bam:md5,d41d8cd98f00b204e9800998ecf8427e" | ||
] | ||
], | ||
"1": [ | ||
"versions.yml:md5,e8aa0696ac2bf135b5f88e6cb7e7b18a" | ||
], | ||
"bam": [ | ||
[ | ||
{ | ||
"id": "test" | ||
}, | ||
"test.bam:md5,d41d8cd98f00b204e9800998ecf8427e" | ||
] | ||
], | ||
"versions": [ | ||
"versions.yml:md5,e8aa0696ac2bf135b5f88e6cb7e7b18a" | ||
] | ||
} | ||
], | ||
"meta": { | ||
"nf-test": "0.9.0", | ||
"nextflow": "24.04.4" | ||
}, | ||
"timestamp": "2024-10-30T10:53:31.992125" | ||
} | ||
} |