Public | Automated Build

Last pushed: 2 years ago
Short Description
Short description is empty for this repo.
Full Description

docker-pacbiobase

Base Third Party tools for Pacbio

Installs hdf5, python, R to ease installation of Pacbio tools and libraries, such as pbcore, blasr, or quiver. Intended to be used as the base image for other Dockerfiles.

Usage

Initially pull docker image (the first time this may take a few minutes)

$> docker pull mpkocher/docker-pacbiobase

Example: Install pbcore library.

docker_tests $> docker run -i -t mpkocher/docker-pacbiobase /bin/bash
root@5e340086e053:/ cd tmp
root@5e340086e053:/tmp git clone https://github.com/PacificBiosciences/pbcore.git
Cloning into 'pbcore'...
remote: Counting objects: 2526, done.
remote: Compressing objects: 100% (8/8), done.
remote: Total 2526 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (2526/2526), 13.19 MiB | 3.52 MiB/s, done.
Resolving deltas: 100% (1662/1662), done.
Checking connectivity... done.
root@5e340086e053:/tmp cd pbcore && pip install . && cd -
Unpacking /tmp/pbcore
  Running setup.py (path:/tmp/pip-E9nsJa-build/setup.py) egg_info for package from file:///tmp/pbcore

Requirement already satisfied (use --upgrade to upgrade): h5py>=2.0.1 in /usr/local/lib/python2.7/dist-packages (from pbcore==0.9.4)
Requirement already satisfied (use --upgrade to upgrade): numpy>=1.6.0 in /usr/local/lib/python2.7/dist-packages (from pbcore==0.9.4)
Requirement already satisfied (use --upgrade to upgrade): pysam==0.8.1 in /usr/local/lib/python2.7/dist-packages (from pbcore==0.9.4)
Requirement already satisfied (use --upgrade to upgrade): Cython>=0.17 in /usr/local/lib/python2.7/dist-packages (from h5py>=2.0.1->pbcore==0.9.4)
Installing collected packages: pbcore
  Running setup.py install for pbcore

    Installing .open script to /usr/local/bin
Successfully installed pbcore
Cleaning up...
/tmp
root@5e340086e053:/tmp ipython
Python 2.7.6 (default, Mar 22 2014, 22:59:56) 
Type "copyright", "credits" or "license" for more information.

IPython 2.4.0 -- An enhanced Interactive Python.
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: from pbcore.io import FastaReader

In [2]: FastaReader?
Type:            type
String form:     <class 'pbcore.io.FastaIO.FastaReader'>
File:            /usr/local/lib/python2.7/dist-packages/pbcore/io/FastaIO.py
Init definition: FastaReader(self, f)
Docstring:
Streaming reader for FASTA files, useable as a one-shot iterator
over FastaRecord objects.  Agnostic about line wrapping.

Example:

.. doctest::

    >>> from pbcore.io import FastaReader
    >>> from pbcore import data
    >>> filename = data.getTinyFasta()
    >>> r = FastaReader(filename)
    >>> for record in r:
    ...     print record.header, len(record.sequence), record.md5
    ref000001|EGFR_Exon_2 183 e3912e9ceacd6538ede8c1b2adda7423
    ref000002|EGFR_Exon_3 203 4bf218da37175a91869033024ac8f9e9
    ref000003|EGFR_Exon_4 215 245bc7a046aad0788c22b071ed210f4d
    ref000004|EGFR_Exon_5 157 c368b8191164a9d6ab76fd328e2803ca
    >>> r.close()
Init docstring:  Prepare for iteration through the records in the file

In [3]:

Building Images

Simple Example Dockerfile

# https://gist.github.com/mpkocher/be4fd7966e22da270605
FROM mpkocher/docker-pacbiobase
MAINTAINER Michael Kocher

RUN cd /tmp && git clone https://github.com/PacificBiosciences/pbcore.git && cd pbcore && pip install .

Now build the container

be4fd7966e22da270605 $> docker build -t pbcore .
Sending build context to Docker daemon 46.08 kB
Sending build context to Docker daemon 
Step 0 : FROM mpkocher/docker-pacbiobase
 ---> 14149a5f7303
Step 1 : MAINTAINER Michael Kocher
 ---> Running in 79139d7a2826
 ---> c86afc029277
Removing intermediate container 79139d7a2826
Step 2 : RUN cd /tmp && git clone https://github.com/PacificBiosciences/pbcore.git && cd pbcore && pip install .
 ---> Running in 55f5a11f446c
Cloning into 'pbcore'...
Unpacking /tmp/pbcore
  Running setup.py (path:/tmp/pip-KdoDNP-build/setup.py) egg_info for package from file:///tmp/pbcore

Requirement already satisfied (use --upgrade to upgrade): h5py>=2.0.1 in /usr/local/lib/python2.7/dist-packages (from pbcore==0.9.4)
Requirement already satisfied (use --upgrade to upgrade): numpy>=1.6.0 in /usr/local/lib/python2.7/dist-packages (from pbcore==0.9.4)
Requirement already satisfied (use --upgrade to upgrade): pysam==0.8.1 in /usr/local/lib/python2.7/dist-packages (from pbcore==0.9.4)
Requirement already satisfied (use --upgrade to upgrade): Cython>=0.17 in /usr/local/lib/python2.7/dist-packages (from h5py>=2.0.1->pbcore==0.9.4)
Installing collected packages: pbcore
  Running setup.py install for pbcore

    Installing .open script to /usr/local/bin
Successfully installed pbcore
Cleaning up...
 ---> 17b9281a3f30
Removing intermediate container 55f5a11f446c
Successfully built 17b9281a3f30

Run command in the container

be4fd7966e22da270605 $> docker run -i -t pbcore /bin/bash
root@0aa6a650bc0d:/# ipython
Python 2.7.6 (default, Mar 22 2014, 22:59:56) 
Type "copyright", "credits" or "license" for more information.

IPython 2.4.0 -- An enhanced Interactive Python.
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: import pbcore.io

In [2]:
Docker Pull Command
Owner
mpkocher
Source Repository

Comments (0)