ionique.cparsers
This contains cython implementations of ionic current parsers which are in parsers.py. Currently the only parser is StatSplit, which is implemented as FastStatSplit.
- class ionique.cparsers.FastStatSplit
Bases:
object
A cython implementation of the segmenter written by Kevin Karplus. Sped up approximately 50-100x compared to the Python implementation depending on parameters.
- __init__(*args, **kwargs)
- best_single_split(current)
Wrapper for a single call to _best_single_split. It will find the single best split in a series of current, and return the index of that split. Returns a tuple of ( gain, index ) where gain is the gain in variance by splitting there, and index is the index at which the split should occur in the current array.
- min_gain
- parse(current)
Wrapper function for the segmentation, which is implemented in cython.
- parse_meta(current)
Wrapper function for the segmentation, which is implemented in cython. returns meta segments (no current array)
- score_samples(current, no_split=False)
Return a series of lists scoring each sample. However, this isn’t just scoring each sample once. Every time a split is detected, it will return a new list with newly scored samples. In essence, it returns one list per scan of the current using the recursive method.
- ionique.cparsers.pairwise(iterable)