kProcessor Python interface
Project description
@DIB-LAB/kProcessor
📖 Table of Contents
➤ Table of Contents
➤ Introduction
kProcessor is a C++ API with a handy Python interface that enables easy handling of sequence kmer content. kProcessor stores kmers with their associated metadata in a virtual data structure called kDataframe. By default, kDataFrame stores the kmers with their counts in the input dataset. However, kDataFrame supports adding multiple other columns to store more information about these kmers in different data types. Users can easily merge multiple kDataFrames or apply different set functions (e.g. union, intersect and difference) on a group of kDataFrames. Colored kDataFrame is another core virtual data structure in kProcessor that allows the indexing of the kmers in a multi-sequence reference input. It is composed of a kDataFrame that replaces the kmer count with a key (aka color). This key connects the kmer to all sequences associated with this kmer.
➤ Quick Installation (pip)
python -m pip install kProcessor
➤ Build from source
Clone
git clone https://github.com/dib-lab/kProcessor.git
cd kProcessor/
git submodule update --init --recursive
Install dependencies
sudo apt-get install g++ swig cmake python3-dev zlib1g-dev libghc-bzlib-dev python3-distutils libboost-all-dev
Build
CMake options
| Description | Option | Default |
|---|---|---|
| Build tests | BUILD_TESTS | OFF |
| Build documentation | BUILD_DOCS | OFF |
| Build everything! | BUILD_ALL | OFF |
Build The kProcessor Library
# Run CMake configure
cmake -Bbuild
# Run make with parallel execution.
cmake --build build -j4 # -j4 = execute 4 recipes simultaneously.
Build Everything
cmake -Bbuild -DBUILD_ALL=1
cmake --build build -j4 # -j4 = execute 4 recipes simultaneously.
Build Docs Only
Output directory: build/doxygen/html
cmake -Bbuild -DBUILD_DOCS=1
cmake --build build --target GenerateDocs
Build Tests Only
cmake -Bbuild -DBUILD_TESTS=1
cmake --build build -j4
# Run tests
cd build/tests/kProcessorLibTests
./testKprocessorLib
➤ Manually build the Python bindings
Python bindings are generated using SWIG. It's recommended to install swig=4.0.2 using Conda.
You can build the python bindings by executing build_wrapper.sh, or you can follow the next steps.
Generate bindings
- First, you need to follow the instructions in the Build from source.
- While
pwd=kProcessorrun:python setup.py bdist_wheel. - Install the generated wheel package using:
cd dist && python -m pip install kProcessor*.whl.
➤ Contributors
| Mostafa Shokrof | Mohamed Abuelanin | Tamer Manosur |
➤ License
Licensed under BSD-3-Clause.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kProcessor-1.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: kProcessor-1.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 4.8 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c4a7d2652035d02784e59143bb1da5d94dbaa79c241227318d98de3926ea3bf
|
|
| MD5 |
1320a13a8e0fdd7fd41a98547c7eb664
|
|
| BLAKE2b-256 |
fc788679482f9b7cfe87e23a004ea2d7f8cd3ed095cedcc1f9d1f158292e516b
|
File details
Details for the file kProcessor-1.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: kProcessor-1.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 4.8 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c9743a1c42d52cd2b139a8ff49d083b30412604f51b52e002a3d94eb74cb95a
|
|
| MD5 |
03a845270740164ebb5640b3fe13bd72
|
|
| BLAKE2b-256 |
e50cfa98dac45e6131c8e94fa32eda25c13003e2e5139f625ae90da10d898449
|
File details
Details for the file kProcessor-1.2.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: kProcessor-1.2.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 4.8 MB
- Tags: CPython 3.7m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
308be82324110fccfa951aa6ab370e62be7c7c7814d0b6d9ba2070eea6b0ff37
|
|
| MD5 |
fa850e3f0ec1d7f7a4b213ad1e44208a
|
|
| BLAKE2b-256 |
2501bd99e526d70e5af2e96be469a815d66bca2f85bf9a8226677761c2113d15
|
File details
Details for the file kProcessor-1.2.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: kProcessor-1.2.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 4.8 MB
- Tags: CPython 3.6m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f824e77948e91d6169ee4cf697fe54150b058edb5c6fc65674f52874c41f057f
|
|
| MD5 |
37d485ab6a2c3af636c347d98397b422
|
|
| BLAKE2b-256 |
d7f38852c59915309b62bcd4efbc0e40f6dd84977bb96e58e787816a5701eb9f
|