Skip to content

1. Installation

Tim Kahlke edited this page Aug 9, 2018 · 6 revisions

Install using Conda

Basta and its dependencies can be installed using the conda package manager:

conda install -c bioconda -c bnoon -c timkahlke basta

After this BASTA should be ready to use by just typing "basta".

BASTA native install

BASTA depends on LevelDB and the python wrapper Plyvel as well as a few non-standard python libraries which can easily be installed using pip.

Required Python Libraries (non levelDB)

  • gzip
  • hashlib

The easiest way to install the libraries is using the python package manager pip

pip install gzip hashlib

LevelDB

LevelDB installation: MacOSX

The easiest way to install BASTA on MacOSX is through homebrew (https://brew.sh/) and pip.

brew install leveldb
pip install Plyvel

NOTE Often MacOSX can't find the leveldb header files. If so try:

pip install --global-option=build_ext --global-option="-I/usr/local/include" --global-option="-L/usr/local/lib" Plyvel

LevelDB installation: Ubuntu

LevelDB can be installed using aptitude:

sudo apt-get update
sudo apt-get install python-leveldb
pip install Plyvel

Why LevelDB ?

Currently, BASTA uses levelDB (https://github.com/google/leveldb) for storage of NCBI taxonomies and mapping files. The reason is that the otherwise preferred database system SQLite can lead to locking errors when used on infrastructure that mounts hard drives using Network File System (NFS) which is often the case on compute clusters.


Installing BASTA

BASTA is written in python, i.e., it doesn't have to be compiled. However, the python scripts have to be put in the proper directories.

First download the BASTA repository to your current directory using git

git clone https://github.com/timkahlke/BASTA.git

Change into the BASTA repository and install BASTA:

cd BASTA
python setup.py install

Krona (optional)

BASTA provides a custom script to create Krona plots (https://github.com/marbl/Krona/wiki) from annotation files. To install KronaTools please follow the Krona installation guide.