Python bindings to scrappie basecaller
Project description
Scrappy provides a minimal python binding to some of the core functionality of the scrappie raw basecaller. The performance of scrappy should be comparable (if not essentially identical) to scrappie.
Installation
Scrappy is available on pypi. For linux it is available as a pre-compiled wheel, for MacOS the distribution will be built from source. Scrappy can be installed simply as:
pip install scrappie
Note the spelling! The above may fail on MacOS, due to various compiler and library versions which might be present. In this case please report an issue on github.
Building from the source is also supported, providing one has met the requirements for building the scrappie itself. It is recommended to first ensure scrappie builds cleanly before attempting to build it’s python counterpart. To build from the source, run:
pip install -r requirements python setup.py install
The second command may be modified as appropriate (perhaps by adding –user for non-root installations).
API
Scrappy directly exposes the key parts of scrappie’s “from raw” basecalling pipeline. The steps are:
scrappy.trim_raw: attempt to remove data points corresponding to adapters,
scrappy.scale_raw: perform a robust normalization of the data,
scrappy.calc_post: calculate time-resolved label probabilties (“posterior probabilities”),
scrappy.decode_post: a Viterbi decoding to obtain optimal base sequence.
The above is illustrated in scrappy.basecall_raw.
Additionally the squiggle simulation and alignment functionality is exposed via:
scrappy.sequence_to_squiggle: simulate a squiggle from a base sequence,
scrappy.map_signal_to_squiggle: align raw data to a simulated sequence.
Demo
After installation the scrappy program can be run to demonstrate the API’s function. The program takes one or more filepaths to .fast5 files and outputs FASTA formatted basecalls to stdout, e.g.:
scrappy file1.fast5 <file2.fast5> <file3.fast5> …
As with scrappie to achieve best performance it is recommended to disable threading in your BLAS library (this is true also if building an application using the API).
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
Built Distributions
File details
Details for the file scrappie-1.4.2.tar.gz
.
File metadata
- Download URL: scrappie-1.4.2.tar.gz
- Upload date:
- Size: 24.2 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ca968f1d9427c1f2b353c8c9a689798f58e06451eba63e331db85da64b4856fa |
|
MD5 | c8578035c5c6f3e4f1b0246086dd6a70 |
|
BLAKE2b-256 | 90f50b27d0e7d1ddf569d498c6612a4a42767eb46254b9e2848ff212ca08b887 |
File details
Details for the file scrappie-1.4.2-cp36-cp36m-manylinux1_x86_64.whl
.
File metadata
- Download URL: scrappie-1.4.2-cp36-cp36m-manylinux1_x86_64.whl
- Upload date:
- Size: 19.2 MB
- Tags: CPython 3.6m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 099fcd56227c4ba00ecf8551a1befea765e6d9a061c269a9e545404791de8ffd |
|
MD5 | bd09757caeac89455ec4563c6a412c18 |
|
BLAKE2b-256 | e489dce2954d98f221e5ba7f17e3fb42af04c6322ada3ba608d8a372d6083077 |
File details
Details for the file scrappie-1.4.2-cp35-cp35m-manylinux1_x86_64.whl
.
File metadata
- Download URL: scrappie-1.4.2-cp35-cp35m-manylinux1_x86_64.whl
- Upload date:
- Size: 19.2 MB
- Tags: CPython 3.5m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3d92c04191159c0c32c3813f68ad2f6e07a302fd0c2342e9471562aa5ba09874 |
|
MD5 | 49370b376ff34c880830c281485b2754 |
|
BLAKE2b-256 | c26b2eba7132695fd6126e0845f63d010a4e6a1559db1b3bbdde2fd5dc1912c5 |
File details
Details for the file scrappie-1.4.2-cp34-cp34m-manylinux1_x86_64.whl
.
File metadata
- Download URL: scrappie-1.4.2-cp34-cp34m-manylinux1_x86_64.whl
- Upload date:
- Size: 19.2 MB
- Tags: CPython 3.4m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 157e94a60173ef185db1f796fe83448b5bb01cf0215def7a432ec02df07ff81e |
|
MD5 | 40fa92c9af07a01e4d89d3935175a1d1 |
|
BLAKE2b-256 | b4254bb9a6b6939f41fb7f12efc5dc795fd41a7628f36cb278283a33bb3213cd |