Skip to main content

A pipeline implementing TB-Profiler for batch detection and reporting of anti-microbial resistance in TB for public health and clinical use.

Project description

Python 3.7

Troika

Detection of resistance mechanisms in Mycobacterium tuberculosis is dependent upon identification of SNPs that may confer decreased susceptibility to anti-mycobacterial drugs. Troika is a pipeline, which calls SNPs for both phylogenetic analysis and determination of AST. Troika leverages high quality tools, including Snippy and TB-profiler and its related database to detect resistance conferring mutations from Illumina read data and filters these results for reporting for public health and clinical use in Australia.

Motivation

There are many tools and databases available, however, for the purposes of reporting genomic AST for M. tuberculosis in the context of public health and clinical use in Australia customisation is required. Rather than reinventing the wheel, Troika leverages a high quality database and a detection tool which is highly customisable.

Pipeline

Troika is designed for batch reporting of AST in M. tuberculosis isolates generated from Illumina reads and phylogenetic analysis and clustering to identify potentially related isolates. This pipeline is in use at MDU Victoria Australia for Tuberculosis surveillance and AST reporting.

Installation

Conda (Recomended)

TO COME

PyPi

pip3 install Troika-Tb

Running Troika

input

Input for troika is a tab-delimited file containing three columns (no header) <sample_name> <path_to_read1> <path_to_read2>

troika -h

usage: troika_tb.py [-h] [-v] [--input_file INPUT_FILE] [--detect_species]
                    [--resistance_only] [--Singularity]
                    [--profiler_singularity_path PROFILER_SINGULARITY_PATH]
                    [--snippy_singularity_path SNIPPY_SINGULARITY_PATH]
                    [--workdir WORKDIR] [--resources RESOURCES] [--jobs JOBS]
                    [--profiler_threads PROFILER_THREADS]
                    [--kraken_threads KRAKEN_THREADS] [--kraken_db KRAKEN_DB]
                    [--snippy_threads SNIPPY_THREADS] [--mode {mdu,normal}]
                    [--positive_control POSITIVE_CONTROL]
                    [--db_version DB_VERSION] [--min_cov MIN_COV]
                    [--min_aln MIN_ALN]

Troika - a pipeline for phylogenentic analysis, detection and reporting of
genomic AST in Mtb If an arg is specified in more than one place, then
commandline values override environment variables which override defaults.

optional arguments:
  -h, --help            show this help message and exit
  -v, --version         show program's version number and exit
  --input_file INPUT_FILE, -i INPUT_FILE
                        Input file tab-delimited file 3 columns isolate_id
                        path_to_r1 path_to_r2 (default: )
  --detect_species, -d  Set if you would like to detect species - note if not
                        set troika may include non-tuberculosis species in the
                        analysis. (default: False)
  --resistance_only     If detection of resistance mutations only is needed.
                        Phylogeny will not be performed. (default: False)
  --Singularity, -S     If singularity is to be used for troika. (default:
                        False)
  --profiler_singularity_path PROFILER_SINGULARITY_PATH, -ps PROFILER_SINGULARITY_PATH
                        URL for TB-profiler singularity container. (default:
                        docker://mduphl/mtbtools)
  --workdir WORKDIR, -w WORKDIR
                        Working directory, default is current directory
                        (default: /home/khhor/dev/troika_tb)
  --resources RESOURCES, -r RESOURCES
                        Directory where templates are stored (default:
                        troika_tb)
  --jobs JOBS, -j JOBS  Number of jobs to run in parallel. (default: 8)
  --profiler_threads PROFILER_THREADS, -t PROFILER_THREADS
                        Number of threads to run TB-profiler (default: 1)
  --kraken_threads KRAKEN_THREADS, -kt KRAKEN_THREADS
                        Number of threads for kraken (default: 4)
  --kraken_db KRAKEN_DB, -k KRAKEN_DB
                        Path to DB for use with kraken2, if no DB present
                        speciation will not be performed. [env var:
                        KRAKEN2_DEFAULT_DB] (default: None)
  --snippy_threads SNIPPY_THREADS, -st SNIPPY_THREADS
                        Number of threads for snippy (default: 8)
  --mode {mdu,normal}, -m {mdu,normal}
                        If running for MDU service use 'mdu', else use
                        'normal' (default: normal)
  --positive_control POSITIVE_CONTROL, -pc POSITIVE_CONTROL
                        Path to positive control - REQUIRED if running for MDU
                        service (default: )
  --db_version DB_VERSION
                        The version of database being used. (default:
                        TBProfiler-20190820)
  --min_cov MIN_COV, -mc MIN_COV
                        Minimum coverage for quality checks, isolates with
                        coverage below this threshold will not be used in the
                        analysis. (default: 40)
  --min_aln MIN_ALN, -ma     MIN_ALN
                        Minimum alignment for phylogenetic analysis,
                        alignments lower than this threshold will not be
                        included in the calculation of core-genome. (default:
                        80)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Troika_TB-0.0.4.tar.gz (1.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Troika_TB-0.0.4-py3-none-any.whl (1.3 MB view details)

Uploaded Python 3

File details

Details for the file Troika_TB-0.0.4.tar.gz.

File metadata

  • Download URL: Troika_TB-0.0.4.tar.gz
  • Upload date:
  • Size: 1.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.29.1 CPython/3.7.7

File hashes

Hashes for Troika_TB-0.0.4.tar.gz
Algorithm Hash digest
SHA256 f3d2b192a12f7a4e427a5148058ae2f63da52d7215287a4b2087c387be19a76b
MD5 0f1d0eed4bed934be91218740031ce16
BLAKE2b-256 9f9440cdaba66bf5a3b1eb786acce9f961eaa2e9c63c9418bde60aebc785d340

See more details on using hashes here.

File details

Details for the file Troika_TB-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: Troika_TB-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.29.1 CPython/3.7.7

File hashes

Hashes for Troika_TB-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 81192ee72483d9784108d21969b1dd8ba46e0725ac8626ed4618200bee833a28
MD5 ffab858dc4f66924f4a5438fa65aff5e
BLAKE2b-256 101a81fdc7b6de5d1fb2fbb6287a4b0b06f0efe449ea5ecde774fcee83a4c9ef

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page