Skip to content

Commit

Permalink
Merge pull request #297 from MaxUlysse/dsl2_somatic
Browse files Browse the repository at this point in the history
Add somatic to DSL2
  • Loading branch information
maxulysse authored Jan 27, 2021
2 parents 8a7cb68 + daae20f commit 2a15600
Show file tree
Hide file tree
Showing 17 changed files with 613 additions and 305 deletions.
63 changes: 40 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ jobs:
- name: Run pipeline with test data
run: |
nextflow run ${GITHUB_WORKSPACE} -profile test,docker
- name: Show results
run: ls -lR results

aligner:
name: Run aligner tests
Expand All @@ -54,6 +56,8 @@ jobs:
NXF_VER: '20.11.0-edge'
- name: Run ${{ matrix.profile }} test
run: nextflow run ${GITHUB_WORKSPACE} -profile test,docker --aligner ${{ matrix.aligner }}
- name: Show results
run: ls -lR results

germline:
name: Run input from a folder test and restart from step tests
Expand All @@ -76,12 +80,20 @@ jobs:
run: git clone --single-branch --branch sarek https://github.com/nf-core/test-datasets.git data
- name: Run germline test with ${{ matrix.markduplicates }} --step mapping
run: nextflow run ${GITHUB_WORKSPACE} -profile test,docker ${{ matrix.markduplicates }} --input data/testdata/tiny/normal --save_bam_mapped
- name: Show results
run: ls -lR results
- name: Run germline test with ${{ matrix.markduplicates }} --step prepare_recalibration
run: nextflow run ${GITHUB_WORKSPACE} -profile test,docker ${{ matrix.markduplicates }} --input=false --step prepare_recalibration -resume
- name: Show results
run: ls -lR results
- name: Run germline test with ${{ matrix.markduplicates }} --step recalibrate
run: nextflow run ${GITHUB_WORKSPACE} -profile test,docker ${{ matrix.markduplicates }} --input=false --step recalibrate -resume
- name: Show results
run: ls -lR results
- name: Run germline test with ${{ matrix.markduplicates }} --step variantCalling
run: nextflow run ${GITHUB_WORKSPACE} -profile test,docker ${{ matrix.markduplicates }} --input=false --step variantCalling
- name: Show results
run: ls -lR results

# annotation:
# env:
Expand Down Expand Up @@ -126,24 +138,27 @@ jobs:
# - name: Run test for minimal genomes
# run: nextflow run ${GITHUB_WORKSPACE} -profile test,docker --skipQC all --genome ${{ matrix.genome }} ${{ matrix.intervals }} --tools Manta,mpileup,Strelka,FreeBayes

# profile:
# env:
# NXF_ANSI_LOG: false
# runs-on: ubuntu-latest
# strategy:
# matrix:
# profile: [test_split_fastq, test_targeted, test_trimming, test_no_gatk_spark, test_umi_tso, test_umi_qiaseq]
# steps:
# - uses: actions/checkout@v2
# - name: Install Nextflow
# run: |
# wget -qO- get.nextflow.io | bash
# sudo mv nextflow /usr/local/bin/
# env:
# # Only check Nextflow pipeline minimum version
# NXF_VER: '20.11.0-edge'
# - name: Run ${{ matrix.profile }} test
# run: nextflow run ${GITHUB_WORKSPACE} -profile ${{ matrix.profile }},docker
profile:
env:
NXF_ANSI_LOG: false
runs-on: ubuntu-latest
strategy:
matrix:
# profile: [test_split_fastq, test_targeted, test_trimming, test_use_gatk_spark, test_umi_tso, test_umi_qiaseq]
profile: [test_use_gatk_spark, test_targeted]
steps:
- uses: actions/checkout@v2
- name: Install Nextflow
run: |
wget -qO- get.nextflow.io | bash
sudo mv nextflow /usr/local/bin/
env:
# Only check Nextflow pipeline minimum version
NXF_VER: '20.11.0-edge'
- name: Run ${{ matrix.profile }} test
run: nextflow run ${GITHUB_WORKSPACE} -profile ${{ matrix.profile }},docker
- name: Show results
run: ls -lR results

tools:
name: Run tool tests
Expand All @@ -153,13 +168,13 @@ jobs:
strategy:
matrix:
# tool: [Haplotypecaller, Freebayes, Manta, mpileup, MSIsensor, Strelka, TIDDIT]
tool: [Haplotypecaller, Strelka]
tool: [Haplotypecaller, Manta, MSIsensor, Strelka]
intervals: [--no_intervals, '']
exclude:
# - tool: Manta
# intervals: --no_intervals
# - tool: MSIsensor
# intervals: --no_intervals
- tool: Manta
intervals: --no_intervals
- tool: MSIsensor
intervals: --no_intervals
- tool: Strelka
intervals: --no_intervals
# - tool: TIDDIT
Expand All @@ -175,3 +190,5 @@ jobs:
NXF_VER: '20.11.0-edge'
- name: Run ${{ matrix.tool }} test
run: nextflow run ${GITHUB_WORKSPACE} -profile test_tool,docker --tools ${{ matrix.tool }} ${{ matrix.intervals }}
- name: Show results
run: ls -lR results
31 changes: 31 additions & 0 deletions conf/modules.config
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ params {
publish_dir = "reference"
publish_files = "false"
}
'index_target_bed' {
publish_dir = "reference"
publish_files = "false"
}
'msisensor_scan' {
publish_dir = "reference"
publish_files = "false"
}
'samtools_faidx' {
publish_dir = "reference"
publish_files = "false"
Expand Down Expand Up @@ -144,6 +152,29 @@ params {
publish_dir = "variant_calling"
publish_files = ['vcf.gz':'strelka', 'vcf.gz.tbi':'strelka']
}
// TUMOR_VARIANT_CALLING

// PAIR_VARIANT_CALLING
'manta_somatic' {
publish_by_id = "true"
publish_dir = "variant_calling"
publish_files = ['vcf.gz':'manta', 'vcf.gz.tbi':'manta']
}
'msisensor_msi' {
publish_by_id = "true"
publish_dir = "variant_calling"
publish_files = ['list':'msisensor']
}
'strelka_somatic' {
publish_by_id = "true"
publish_dir = "variant_calling"
publish_files = ['vcf.gz':'strelka', 'vcf.gz.tbi':'strelka']
}
'strelka_somatic_bp' {
publish_by_id = "true"
publish_dir = "variant_calling"
publish_files = ['vcf.gz':'strelka', 'vcf.gz.tbi':'strelka']
}
// QC_TRIM
'fastqc' {
args = "--quiet"
Expand Down
10 changes: 5 additions & 5 deletions lib/Completion.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*/

class Completion {
static void email(workflow, params, summary, run_name, baseDir, multiqc_report, log) {
static void email(workflow, params, summary, run_name, projectDir, multiqc_report, log) {

// Set up the e-mail variables
def subject = "[$workflow.manifest.name] Successful: $workflow.runName"
Expand Down Expand Up @@ -56,18 +56,18 @@ class Completion {

// Render the TXT template
def engine = new groovy.text.GStringTemplateEngine()
def tf = new File("$baseDir/assets/email_template.txt")
def tf = new File("$projectDir/assets/email_template.txt")
def txt_template = engine.createTemplate(tf).make(email_fields)
def email_txt = txt_template.toString()

// Render the HTML template
def hf = new File("$baseDir/assets/email_template.html")
def hf = new File("$projectDir/assets/email_template.html")
def html_template = engine.createTemplate(hf).make(email_fields)
def email_html = html_template.toString()

// Render the sendmail template
def smail_fields = [ email: email_address, subject: subject, email_txt: email_txt, email_html: email_html, baseDir: "$baseDir", mqcFile: mqc_report, mqcMaxSize: params.max_multiqc_email_size.toBytes() ]
def sf = new File("$baseDir/assets/sendmail_template.txt")
def smail_fields = [ email: email_address, subject: subject, email_txt: email_txt, email_html: email_html, projectDir: "$projectDir", mqcFile: mqc_report, mqcMaxSize: params.max_multiqc_email_size.toBytes() ]
def sf = new File("$projectDir/assets/sendmail_template.txt")
def sendmail_template = engine.createTemplate(sf).make(smail_fields)
def sendmail_html = sendmail_template.toString()

Expand Down
4 changes: 2 additions & 2 deletions lib/Schema.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class JSON {

summary['MarkDuplicates'] = "Options"
summary['Java options'] = params.markdup_java_options
summary['GATK Spark'] = params.no_gatk_spark ? 'No' : 'Yes'
summary['GATK Spark'] = params.use_gatk_spark ? 'Yes' : 'No'

summary['Save BAMs mapped'] = params.save_bam_mapped ? 'Yes' : 'No'
summary['Skip MarkDuplicates'] = params.skip_markduplicates ? 'Yes' : 'No'
Expand All @@ -126,7 +126,7 @@ class JSON {
if (params.cf_ploidy) summary['ploidy'] = params.cf_ploidy
}

if ('haplotypecaller' in tools) summary['GVCF'] = params.no_gvcf ? 'No' : 'Yes'
if ('haplotypecaller' in tools) summary['GVCF'] = params.generate_gvcf ? 'Yes' : 'No'
if ('strelka' in tools && 'manta' in tools) summary['Strelka BP'] = params.no_strelka_bp ? 'No' : 'Yes'
if (params.pon && ('mutect2' in tools || (params.sentieon && 'tnscope' in tools))) summary['Panel of normals'] = params.pon

Expand Down
Loading

0 comments on commit 2a15600

Please sign in to comment.