AMR-Viz is a package for genomics analysis of antimicrobial resistant (AMR) bacteria. The core of AMRViz is a pipeline that bundles the current best practices for end-to-end AMR genomics analyses. The pipeline analysis results are presented and visualized via a web application. AMRViz also provides a dashboard for efficient management of AMR genomic projects and data.
AMRViz is written in python and its web back-end is implemented with nodejs. It includes the followings dependencies:
- blast (known to work with 2.10.1+)
- samtools (1.11)
- trimmomatic (0.39)
- spades (3.14.1)
- shovill (1.1.0)
- prokka (1.14.6)
- mlst (2.19.6)
- abricate (1.0.1 | Database: vfdb ecoli_vf ecoh card megares resfinder argannot ncbi plasmidfinder)
- roary (3.13.0)
- iqtree (2.1.2)
AMRViz is cross-platform and can be installed via conda or docker.
AMRViz can be installed on a Unix-like machine running conda. It can also run on Windows machines via WSL. Follow the instructions here to set up WSL on Windows. Make sure that a conda container such as anaconda or miniconda is installed.
Instructions:
- Check out the github AMRViz repository and change directory to the root of the repository
git clone --recursive https://github.com/amromics/amrviz
cd amrviz
The instructions below assume working from the root directory for the repository.
- Create a conda environment named
amromics
with all the necessary dependencies.
conda create -y -c conda-forge -c defaults --name amromics python=3.10 mamba
source activate amromics
#Install dependencies
mamba install -y -c conda-forge -c bioconda -c anaconda -c etetoolkit -c defaults --file submodules/amromics/requirements.txt
pip install panta
#Install amromics
(cd submodules/amromics && pip install .)
For all subsequent steps, assume that environment amromics
is activated.
- Extract databases
tar zxvf submodules/amromics/db.tar.gz
- Install nodejs
mamba install -y -c conda-forge nodejs==14.8.0
npm install -g live-server
Once all the packages are installed, the web-based platform can be started (once only) by
./amrviz.py start -p 3000 --webapp-dir web-app/
Here, port 3000 is assumed. If the port is not available, please choose another number. Once the server has been started, the platform can be accessed via a web-browser at the address http://localhost:3000/.
To illustrate AMRViz usage, we prepare several datasets and instructions how to analyze the.
The Kp100 dataset consists of 89 Klebsiella pneumoniae samples sequenced with Illumina technology, 11 samples with Oxfort Nanopore and 1 sample with Pacbio. The ENA accessions for these samples are listed in examples/Kp100/raw/acc_list.csv
. We also include two reference genomes in the dataset.
To prepare the input data for the case study, run
(cd examples/Kp100/raw && ./download_ascp.sh)
This might take a few hours depending on the network connection. Alternatively, you can use your favourite download tools to download the listed accessions.
We also provide a miniature dataset which is a subset of 7 samples of the Kp100 dataset. To download the raw data for the miniature dataset
(cd examples/Kp100/raw && ./download_mini.sh)
To run the pipeline, users need to provide a tsv file listing the samples and input
data in either fastq (sequencing reads) or fasta (assemply). The input file for the
Kp100 dataset is under examples/Kp100/raw/config_K100.tsv
To perform analysis on the Kp100 dataset, and to import to the web platform, run the followint command line. Adjust the number of cpus and the amount of memory allocated for running analysis according to the hardware configuration of your computer.
./amrviz.py pa -t 20 -m 28 -c Kp100 -i examples/Kp100/config_Kp100.tsv --work-dir data/work --webapp-dir web-app/ -n "Collection of 103 MDR clinical Kp isolates"
For analyzing the miniature dataset
./amrviz.py pa -t 20 -m 28 -c KpMini -i examples/Kp100/config_mini.tsv --work-dir data/work --webapp-dir web-app/ -n "Mini collection 7 Kp isolates"
This dataset contains 76 Steptococcus pyogenes samples. To download the raw data for the dataset
(cd examples/iGAS70/raw && ./download_ascp.sh)
To analyze the dataset
./amrviz.py pa -t 20 -m 25 -c iGAS70 -i examples/iGAS70/config_iGAS70.tsv --work-dir data/work --webapp-dir web-app -n "Collection of >70 Steptococcus pyogenes from MDU-Australia."
This dataset contains 24 Klebsiella pneumoniae samples. To download the raw data for the dataset
(cd examples/Kp24/raw && ./download_kp24.sh)
To analyze the dataset
./amrviz.py pa -t 20 -m 25 -c KpMDR -i examples/Kp24/config_Kp24.tsv --work-dir data/work --webapp-dir web-app -n "Collection of MDR Klebsiella pneumoniae"