-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
72 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
cimport numpy as np | ||
from libc.stdint cimport uint64_t, intptr_t | ||
|
||
ctypedef unsigned char CHAR | ||
|
||
|
||
cdef np.uint64_t c_kmer_to_index(const CHAR[:], bint*) nogil | ||
cdef np.uint64_t c_kmer_to_index_rc(const CHAR[:], bint*) nogil | ||
cdef void c_index_to_kmer(np.uint64_t, CHAR[:]) nogil | ||
cdef uint64_t c_kmer_to_index(const CHAR[:], bint*) nogil | ||
cdef uint64_t c_kmer_to_index_rc(const CHAR[:], bint*) nogil | ||
cdef void c_index_to_kmer(uint64_t, CHAR[:]) nogil | ||
cdef void c_revcomp(const CHAR[:], CHAR[:]) nogil |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
from libc.stdint cimport intptr_t | ||
from .types cimport SCORE_T, BOUNDS_T, COORDS_T, COORDS_T_2 | ||
|
||
cdef SCORE_T c_jaccarddist(COORDS_T[:] coords1, COORDS_T_2[:] coords2) nogil |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,23 @@ | ||
"""Shared typedefs.""" | ||
|
||
cimport numpy as np | ||
from libc.stdint cimport uint16_t, uint32_t, uint64_t, intptr_t | ||
|
||
|
||
# Type for similarity scores | ||
ctypedef np.float32_t SCORE_T | ||
ctypedef float SCORE_T | ||
|
||
# Type for bounds on c_jaccard_coords_col | ||
ctypedef np.intp_t BOUNDS_T | ||
# This should be equal to Numpy's intp dtype | ||
ctypedef intptr_t BOUNDS_T | ||
|
||
# Fused type for storing k-mer coordinates/indices | ||
ctypedef fused COORDS_T: | ||
np.int16_t | ||
np.uint16_t | ||
np.int32_t | ||
np.uint32_t | ||
np.int64_t | ||
np.uint64_t | ||
uint16_t | ||
uint32_t | ||
uint64_t | ||
|
||
# Copy of COORDS_T, used when two arguments have types in this set but may be different than each other. | ||
ctypedef fused COORDS_T_2: | ||
np.int16_t | ||
np.uint16_t | ||
np.int32_t | ||
np.uint32_t | ||
np.int64_t | ||
np.uint64_t | ||
uint16_t | ||
uint32_t | ||
uint64_t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
"""Calculate and store collections of k-mer signatures.""" | ||
|
||
from .base import KmerSignature, SignatureArray, SignatureList, sigarray_eq, SignaturesMeta,\ | ||
AnnotatedSignatures, dump_signatures, load_signatures | ||
AnnotatedSignatures, dump_signatures, load_signatures, BOUNDS_DTYPE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters