Commit 04e3d2c7 authored by van den Berg's avatar van den Berg
Browse files

Merge branch 'devel' of github.com:LUMC/HAMLET into devel

parents 1d2d6a67 7d1116d9
### Checklist
- [ ] Pull request details were added to CHANGELOG.md.
- [ ] Documentation was updated (if required).
- [ ] New test have been properly tagged with the test (`sanity`, `dry-run` or
`intergration`) **and** the apropriate module (`qc`, `itd`, `fusion`,
`expression`, `snv-indels` or `hamlet`).
name: Continuous Integration
on: [push, pull_request]
defaults:
run:
# This is needed for miniconda, see:
# https://github.com/marketplace/actions/setup-miniconda#important.
shell: bash -l {0}
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
test:
- sanity
- dry-run
module:
- qc
- itd
- fusion
- expression
- snv-indels
- hamlet
steps:
- uses: actions/checkout@v2.3.4 # https://github.com/actions/checkout.
with:
submodules: recursive
- name: Set up Conda environment
uses: conda-incubator/setup-miniconda@v2.0.1 # https://github.com/conda-incubator/setup-miniconda.
with:
activate-environment: HAMLET
environment-file: environment.yml
auto-activate-base: false
- name: Install singularity
uses: eWaterCycle/setup-singularity@v6
with:
singularity-version: 3.6.4
- name: Run test in conda environment
# Use --symlink to limit disk usage.
run: >-
pytest --keep-workflow-wd-on-fail
--tag ${{ matrix.test }}
--tag ${{ matrix.module }}
--symlink test/
- name: Check cromwell log in case of failure.
if: ${{ failure() }}
# Get the last 1000 lines of the cromwell log to catch the error.
run: bash -c 'tail -n 1000 /tmp/pytest_workflow_*/*/log.out'
- name: Check pytest stdout messages in case of failure
if: ${{ failure() }}
run: >-
bash -c '
for file in $(find /tmp -name log.out);
do echo $file; cat $file; done'
- name: Check pytest stderr messages in case of failure
if: ${{ failure() }}
run: >-
bash -c '
for file in $(find /tmp -name log.err);
do echo $file; cat $file; done'
Changelog
==========
<!--
Newest changes should be on top.
This document is user facing. Please word the changes in such a way
that users understand how the changes affect the new version.
-->
v1.0.2-dev
---------------------------
+ Add support for Snakemake 6.3.0
[![Continuous Integration](https://github.com/LUMC/HAMLET/actions/workflows/ci.yml/badge.svg)](https://github.com/LUMC/HAMLET/actions/workflows/ci.yml)
# Hamlet
Hamlet is a pipeline for analysis of human acute myeloid leukemia RNA-seq samples. Please use the
......@@ -52,7 +54,7 @@ Additionally, `singularity` version 3 or greater should be installed on the syst
## Data files
HAMLET requires around 100GB of reference files to run. You can download the data files [here](https://barmsijs.lumc.nl/HAMLET/deps.tar.gz),
the md5sum for the archive is `5541718e8bc17bcd00ec90ff23ebcfae`.
the md5sum for the archive is `5ca99cde00955cae44cb63ef3f7d3fd4`.
Please contact the author or open an issue if the link is not working.
## Testing
......
# This file may be used to create an environment using:
# $ conda create --name <env> --file <this file>
# $ conda env create -f environment.yml
# platform: linux-64
name: HAMLET
channels:
- bioconda
- conda-forge
- defaults
dependencies:
- pytest-workflow>=1.4.0
- python>3.6
- snakemake=5.9
- snakemake-minimal=6.3.0
- smart_open>=3
......@@ -56,12 +56,12 @@ rule count_fragments:
bam="{sample}/snv-indels/{sample}.snv-indel.idsorted.bam",
gtf=settings["expression_gtf"],
output:
count="{sample}/expression/{sample}.fragments_per_gene",
fragments_per_gene="{sample}/expression/{sample}.fragments_per_gene",
threads: 1
singularity: containers["htseq"]
shell:
"htseq-count --format bam --order name --stranded no"
" {input.bam} {input.gtf} > {output.count}"
" {input.bam} {input.gtf} > {output.fragments_per_gene}"
rule count_raw_bases:
input:
......@@ -81,28 +81,28 @@ rule count_bases_exon:
raw="{sample}/expression/{sample}.raw_base",
aggr_script=settings["aggr_base_count_script"],
output:
count="{sample}/expression/{sample}.bases_per_exon",
bases_per_exon="{sample}/expression/{sample}.bases_per_exon",
params:
sample="{sample}"
threads: 1
singularity: containers["hamlet-scripts"]
shell:
"Rscript {input.aggr_script} -I {input.raw} -N {params.sample}"
" -E {output.count}"
" -E {output.bases_per_exon}"
rule count_bases_gene:
input:
raw="{sample}/expression/{sample}.raw_base",
aggr_script=settings["aggr_base_count_script"],
output:
count="{sample}/expression/{sample}.bases_per_gene",
bases_per_gene="{sample}/expression/{sample}.bases_per_gene",
params:
sample="{sample}"
threads: 1
singularity: containers["hamlet-scripts"]
shell:
"Rscript {input.aggr_script} -I {input.raw} -N {params.sample}"
" -G {output.count}"
" -G {output.bases_per_gene}"
rule calc_exon_ratios:
input:
......
- name: test-expression-dry-run-single
tags:
- dry-run
- expression
command: >
snakemake -n
--snakefile includes/expression/Snakefile
......@@ -17,6 +18,7 @@
- name: test-expression-dry-run-trio
tags:
- dry-run
- expression
command: >
snakemake -n
--snakefile includes/expression/Snakefile
......@@ -40,27 +42,20 @@
- "TestSample3/expression/TestSample3.fragments_per_gene"
- "TestSample3/expression/TestSample3.raw_base"
- name: test-expression-sanity-snakemake
tags:
- sanity
command: >
snakemake --version
stdout:
contains:
- "5.9"
- name: test-expression-sanity-singularity
tags:
- sanity
- expression
command: >
singularity --version
stdout:
contains:
- "singularity version 3"
contains_regex:
- "singularity(-ce)? version 3"
- name: test-expression-integration-HEL
tags:
- integration
- expression
command: >
snakemake -rp
--snakefile includes/expression/Snakefile
......@@ -101,6 +96,7 @@
- name: test-expression-MECOM-vs-MECOM
tags:
- integration
- expression
command: >
snakemake -rp
--snakefile includes/expression/Snakefile
......
- name: test-fusion-dry-run-single
tags:
- dry-run
- fusion
command: >
snakemake -n
--snakefile includes/fusion/Snakefile
......@@ -23,6 +24,7 @@
- name: test-fusion-dry-run-trio
tags:
- dry-run
- fusion
command: >
snakemake -n
--snakefile includes/fusion/Snakefile
......@@ -66,27 +68,20 @@
- "TestSample3/fusion/TestSample3.sf-isect-circos/fsnviz.svg"
- "TestSample3/fusion/TestSample3.fusions-combined.svg"
- name: test-fusion-sanity-snakemake
tags:
- sanity
command: >
snakemake --version
stdout:
contains:
- "5.9"
- name: test-fusion-sanity-singularity
tags:
- sanity
- fusion
command: >
singularity --version
stdout:
contains:
- "singularity version 3"
contains_regex:
- "singularity(-ce)? version 3"
- name: test-fusion-integration-NB-4-dry-run
tags:
- dry-run
- fusion
command: >
snakemake -rpn
--snakefile includes/fusion/Snakefile
......@@ -97,6 +92,7 @@
- name: test-fusion-integration-NB-4
tags:
- integration
- fusion
command: >
snakemake -rp
--snakefile includes/fusion/Snakefile
......
- name: test-hamlet-dry-run-single
tags:
- dry-run
- hamlet
command: >
snakemake -n
--snakefile Snakefile
......@@ -16,6 +17,7 @@
- name: test-hamlet-dry-run-trio
tags:
- dry-run
- hamlet
command: >
snakemake -n
--snakefile Snakefile
......@@ -38,27 +40,20 @@
- "TestSample3/hamlet_report.TestSample3.pdf"
- "TestSample3/TestSample3.summary.json"
- name: test-hamlet-sanity-snakemake
tags:
- sanity
command: >
snakemake --version
stdout:
contains:
- "5.9"
- name: test-hamlet-sanity-singularity
tags:
- sanity
- hamlet
command: >
singularity --version
stdout:
contains:
- "singularity version 3"
contains_regex:
- "singularity(-ce)? version 3"
- name: test-hamlet-frankenstein-integration
tags:
- integration
- hamlet
command: >
snakemake -rp
--snakefile Snakefile
......
- name: test-itd-dry-run-single
tags:
- dry-run
- itd
command: >
snakemake -n
--snakefile includes/itd/Snakefile
......@@ -18,6 +19,7 @@
- name: test-itd-dry-run-trio
tags:
- dry-run
- itd
command: >
snakemake -n
--snakefile includes/itd/Snakefile
......@@ -44,27 +46,20 @@
- "TestSample3/itd/TestSample3.flt3.bg.csv"
- "TestSample3/itd/TestSample3.flt3.png"
- name: test-itd-sanity-snakemake
tags:
- sanity
command: >
snakemake --version
stdout:
contains:
- "5.9"
- name: test-itd-sanity-singularity
tags:
- sanity
- itd
command: >
singularity --version
stdout:
contains:
- "singularity version 3"
contains_regex:
- "singularity(-ce)? version 3"
- name: test-itd-MV4-11-flt3
tags:
- integration
- itd
- flt3
command: >
snakemake -rp
......@@ -92,6 +87,7 @@
- name: test-ptd-EoL-1-KMT2A
tags:
- integration
- itd
- kmt2a
command: >
snakemake -rp
......@@ -117,6 +113,7 @@
- name: test-flt3-kmt2a-no-reads
tags:
- integration
- itd
command: >
snakemake -rp
--snakefile includes/itd/Snakefile
......
- name: test-qc-dry-run-single
tags:
- dry-run
- qc
command: >
snakemake -n
--snakefile includes/qc-seq/Snakefile
......@@ -12,6 +13,7 @@
- name: test-qc-dry-run-trio
tags:
- dry-run
- qc
command: >
snakemake -n
--snakefile includes/qc-seq/Snakefile
......@@ -20,27 +22,20 @@
contains:
- "Job counts:"
- name: test-qc-sanity-snakemake
tags:
- sanity
command: >
snakemake --version
stdout:
contains:
- "5.9"
- name: test-qc-sanity-singularity
tags:
- sanity
- qc
command: >
singularity --version
stdout:
contains:
- "singularity version 3"
contains_regex:
- "singularity(-ce)? version 3"
- name: test-qc-single
tags:
- integration
- qc
command: >
snakemake -rp
--snakefile includes/qc-seq/Snakefile
......@@ -60,6 +55,7 @@
- name: test-qc-duo
tags:
- functional
- qc
command: >
snakemake -rp
--snakefile includes/qc-seq/Snakefile
......@@ -79,6 +75,7 @@
- name: test-qc-trio
tags:
- functional
- qc
command: >
snakemake -rp
--snakefile includes/qc-seq/Snakefile
......@@ -93,6 +90,7 @@
- name: test-qc-single-low-qual-adapters
tags:
- functional
- qc
command: >
snakemake -rp
--snakefile includes/qc-seq/Snakefile
......
- name: test-snv-indels-dry-run-single
tags:
- dry-run
- snv-indels
command: >
snakemake -n
--snakefile includes/snv-indels/Snakefile
......@@ -15,6 +16,7 @@
- name: test-snv-indels-dry-run-trio
tags:
- dry-run
- snv-indels
command: >
snakemake -n
--snakefile includes/snv-indels/Snakefile
......@@ -34,28 +36,21 @@
- "TestSample3/snv-indels/TestSample3.variants_all.csv"
- "TestSample3/snv-indels/TestSample3.variants_hi.csv"
- name: test-snv-indels-sanity-snakemake
tags:
- sanity
command: >
snakemake --version
stdout:
contains:
- "5.9"
- name: test-snv-indels-sanity-singularity
tags:
- sanity
- snv-indels
command: >
singularity --version
stdout:
contains:
- "singularity version 3"
contains_regex:
- "singularity(-ce)? version 3"
- name: test-p53-integration-NB-4
tags:
- integration
- p53
- snv-indels
command: >
snakemake -rp
--snakefile includes/snv-indels/Snakefile
......@@ -108,8 +103,9 @@
- name: test-flt3-integration-MV4-11
tags:
- flt3
- integration
- flt3
- snv-indels
command: >
snakemake -rp
--snakefile includes/snv-indels/Snakefile
......@@ -128,6 +124,7 @@
- name: test-TET2-insertion-config
tags:
- integration
- snv-indels
command: >
snakemake -rp
--snakefile includes/snv-indels/Snakefile
......@@ -150,6 +147,7 @@
- name: test-RUNX1-insertion
tags:
- integration
- snv-indels
command: >
snakemake -rp
--snakefile includes/snv-indels/Snakefile
......@@ -165,6 +163,7 @@
- name: test-TET2-false-positive-mutation
tags:
- integration
- snv-indels
command: >
snakemake -rp
--snakefile includes/snv-indels/Snakefile
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment