name: "genome_alignment_and_quant"
namespace: "workflows"
version: "multiple_fixes"
argument_groups:
- name: "Input"
  arguments:
  - type: "string"
    name: "--id"
    description: "ID of the sample."
    info: null
    example:
    - "foo"
    required: true
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--fastq_1"
    alternatives:
    - "-i"
    description: "Path to the sample (or read 1 of paired end sample)."
    info: null
    example:
    - "input.fastq.gz"
    must_exist: true
    create_parent: true
    required: true
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--fastq_2"
    description: "Path to read 2 of the sample."
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--strandedness"
    description: "Sample strand-specificity. Must be one of unstranded, forward, or\
      \ reverse"
    info: null
    required: false
    choices:
    - "forward"
    - "reverse"
    - "unstranded"
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--gtf"
    description: "GTF file"
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--transcript_fasta"
    description: "Fasta file of the reference transcriptome."
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--star_index"
    description: "STAR index directory."
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "boolean"
    name: "--star_ignore_sjdbgtf"
    description: "When using pre-built STAR indices do not re-extract and use splice\
      \ junctions from the GTF file"
    info: null
    default:
    - false
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--seq_platform"
    description: "Sequencing platform."
    info: null
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--seq_center"
    description: "Sequencing center."
    info: null
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--extra_star_align_args"
    description: "Extra arguments to pass to STAR alignment command in addition to\
      \ defaults defined by the pipeline."
    info: null
    default:
    - ""
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "boolean"
    name: "--bam_csi_index"
    description: "Create a CSI index for BAM files instead of the traditional BAI\
      \ index. This will be required for genomes with larger chromosome sizes."
    info: null
    default:
    - false
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "boolean"
    name: "--umi_dedup_stats"
    description: "Generate output stats when running \"umi_tools dedup\"."
    info: null
    default:
    - false
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "boolean"
    name: "--with_umi"
    description: "Enable UMI-based read deduplication."
    info: null
    default:
    - false
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--salmon_quant_libtype"
    description: "Override Salmon library type inferred based on strandedness defined\
      \ in meta object."
    info: null
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--extra_salmon_quant_args"
    description: "Extra arguments to pass to salmon quant command in addition to defaults\
      \ defined by the pipeline."
    info: null
    default:
    - ""
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--gtf_group_features"
    description: "Define the attribute type used to group features in the GTF file\
      \ when running Salmon."
    info: null
    default:
    - "gene_id"
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--gtf_extra_attributes"
    description: "By default, the pipeline uses the gene_name field to obtain additional\
      \ gene identifiers from the input GTF file when running Salmon."
    info: null
    default:
    - "gene_name"
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--extra_rsem_calculate_expression_args"
    description: "Extra arguments to pass to rsem-calculate-expression command in\
      \ addition to defaults defined by the pipeline."
    info: null
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "string"
    name: "--aligner"
    description: "Specifies the alignment algorithm to use - available options are\
      \ 'star_salmon', 'star_rsem' and 'hisat2'."
    info: null
    default:
    - "star_salmon"
    required: false
    choices:
    - "star_salmon"
    - "star_rsem"
    - "hisat2"
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--rsem_index"
    description: "Path to directory for pre-built RSEM index."
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--salmon_index"
    description: "Path to directory for pre-built Salmon index."
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "input"
    multiple: false
    multiple_sep: ";"
- name: "Output"
  arguments:
  - type: "file"
    name: "--star_multiqc"
    info: null
    default:
    - "$id_star.log"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--genome_bam_sorted"
    info: null
    default:
    - "$id.genome.bam"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--genome_bam_index"
    info: null
    default:
    - "$id.genome.bam.bai"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--genome_bam_stats"
    info: null
    default:
    - "$id.genome.stats"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--genome_bam_flagstat"
    info: null
    default:
    - "$id.genome.flagstat"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--genome_bam_idxstats"
    info: null
    default:
    - "$id.genome.idxstats"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--transcriptome_bam"
    info: null
    default:
    - "$id.transcriptome.bam"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--transcriptome_bam_index"
    info: null
    default:
    - "$id.transcriptome.bam.bai"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--transcriptome_bam_stats"
    info: null
    default:
    - "$id.transcriptome.stats"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--transcriptome_bam_flagstat"
    info: null
    default:
    - "$id.transcriptome.flagstat"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--transcriptome_bam_idxstats"
    info: null
    default:
    - "$id.transcriptome.idxstats"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--quant_out_dir"
    info: null
    default:
    - "$id.salmon_quant"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--quant_results_file"
    info: null
    default:
    - "$id.quant.sf"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--salmon_multiqc"
    info: null
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--rsem_counts_gene"
    description: "Expression counts on gene level"
    info: null
    default:
    - "$id.genes.results"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--counts_transcripts"
    description: "Expression counts on transcript level"
    info: null
    default:
    - "$id.isoforms.results"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--rsem_multiqc"
    description: "RSEM statistics"
    info: null
    default:
    - "$id.stat"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--bam_star_rsem"
    description: "BAM file generated by STAR (optional)"
    info: null
    default:
    - "$id.STAR.genome.bam"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--bam_genome_rsem"
    description: "Genome BAM file (optional)"
    info: null
    default:
    - "$id.genome.bam"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
  - type: "file"
    name: "--bam_transcript_rsem"
    description: "Transcript BAM file (optional)"
    info: null
    default:
    - "$id.transcript.bam"
    must_exist: true
    create_parent: true
    required: false
    direction: "output"
    multiple: false
    multiple_sep: ";"
resources:
- type: "nextflow_script"
  path: "main.nf"
  is_executable: true
  entrypoint: "run_wf"
description: "A viash sub-workflow for genome alignment and quantification stage of\
  \ nf-core/rnaseq pipeline.\n"
info: null
status: "enabled"
requirements:
  commands:
  - "ps"
dependencies:
- name: "star/star_align_reads"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "samtools/samtools_sort"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "samtools/samtools_index"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "samtools/samtools_stats"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "samtools/samtools_flagstat"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "samtools/samtools_idxstats"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "umitools/umitools_dedup"
  repository:
    type: "local"
- name: "umitools_prepareforquant"
  repository:
    type: "local"
- name: "salmon/salmon_quant"
  repository:
    type: "vsh"
    repo: "vsh/biobox"
    tag: "v0.2.0"
- name: "rsem/rsem_calculate_expression"
  repository:
    type: "local"
repositories:
- type: "vsh"
  name: "biobox"
  repo: "vsh/biobox"
  tag: "v0.2.0"
- type: "vsh"
  name: "craftbox"
  repo: "craftbox"
  tag: "v0.1.0"
runners:
- type: "executable"
  id: "executable"
  docker_setup_strategy: "ifneedbepullelsecachedbuild"
- type: "nextflow"
  id: "nextflow"
  directives:
    tag: "$id"
  auto:
    simplifyInput: true
    simplifyOutput: false
    transcript: false
    publish: false
  config:
    labels:
      mem1gb: "memory = 1000000000.B"
      mem2gb: "memory = 2000000000.B"
      mem5gb: "memory = 5000000000.B"
      mem10gb: "memory = 10000000000.B"
      mem20gb: "memory = 20000000000.B"
      mem50gb: "memory = 50000000000.B"
      mem100gb: "memory = 100000000000.B"
      mem200gb: "memory = 200000000000.B"
      mem500gb: "memory = 500000000000.B"
      mem1tb: "memory = 1000000000000.B"
      mem2tb: "memory = 2000000000000.B"
      mem5tb: "memory = 5000000000000.B"
      mem10tb: "memory = 10000000000000.B"
      mem20tb: "memory = 20000000000000.B"
      mem50tb: "memory = 50000000000000.B"
      mem100tb: "memory = 100000000000000.B"
      mem200tb: "memory = 200000000000000.B"
      mem500tb: "memory = 500000000000000.B"
      mem1gib: "memory = 1073741824.B"
      mem2gib: "memory = 2147483648.B"
      mem4gib: "memory = 4294967296.B"
      mem8gib: "memory = 8589934592.B"
      mem16gib: "memory = 17179869184.B"
      mem32gib: "memory = 34359738368.B"
      mem64gib: "memory = 68719476736.B"
      mem128gib: "memory = 137438953472.B"
      mem256gib: "memory = 274877906944.B"
      mem512gib: "memory = 549755813888.B"
      mem1tib: "memory = 1099511627776.B"
      mem2tib: "memory = 2199023255552.B"
      mem4tib: "memory = 4398046511104.B"
      mem8tib: "memory = 8796093022208.B"
      mem16tib: "memory = 17592186044416.B"
      mem32tib: "memory = 35184372088832.B"
      mem64tib: "memory = 70368744177664.B"
      mem128tib: "memory = 140737488355328.B"
      mem256tib: "memory = 281474976710656.B"
      mem512tib: "memory = 562949953421312.B"
      cpu1: "cpus = 1"
      cpu2: "cpus = 2"
      cpu5: "cpus = 5"
      cpu10: "cpus = 10"
      cpu20: "cpus = 20"
      cpu50: "cpus = 50"
      cpu100: "cpus = 100"
      cpu200: "cpus = 200"
      cpu500: "cpus = 500"
      cpu1000: "cpus = 1000"
  debug: false
  container: "docker"
engines:
- type: "native"
  id: "native"
build_info:
  config: "src/workflows/genome_alignment_and_quant/config.vsh.yaml"
  runner: "nextflow"
  engine: "native"
  output: "target/nextflow/workflows/genome_alignment_and_quant"
  executable: "target/nextflow/workflows/genome_alignment_and_quant/main.nf"
  viash_version: "0.9.0"
  git_commit: "fbc64b5f252d0e20b11d2455964e9ed5cc66d11e"
  git_remote: "https://x-access-token:ghs_Hah86hJ3ciptfjYIU38aG0V14xJ0t21hkn3l@github.com/viash-hub/rnaseq"
  dependencies:
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/star/star_align_reads"
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_sort"
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_index"
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_stats"
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_flagstat"
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_idxstats"
  - "target/nextflow/umitools/umitools_dedup"
  - "target/nextflow/umitools_prepareforquant"
  - "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/salmon/salmon_quant"
  - "target/nextflow/rsem/rsem_calculate_expression"
package_config:
  version: "multiple_fixes"
  info:
    test_resources:
    - path: "gs://viash-hub-test-data/rnaseq/v1"
      dest: "testData"
  repositories:
  - type: "vsh"
    name: "biobox"
    repo: "vsh/biobox"
    tag: "v0.2.0"
  - type: "vsh"
    name: "craftbox"
    repo: "craftbox"
    tag: "v0.1.0"
  viash_version: "0.9.0"
  source: "src"
  target: "target"
  config_mods:
  - ".requirements.commands := ['ps']\n.runners[.type == 'nextflow'].directives.tag\
    \ := '$id'\n"
  - ".engines += { type: \"native\" }"
  - ".engines[.type == 'docker'].target_registry := 'images.viash-hub.com'"
  - ".engines[.type == 'docker'].target_tag := 'multiple_fixes'"
  organization: "vsh"
