Struct block_aligner::scan_block::Block [−][src]
pub struct Block<'a, M: 'static + Matrix, const TRACE: bool, const X_DROP: bool> { /* fields omitted */ }
Expand description
Data structure storing the settings for block aligner.
Implementations
pub fn align(
query: &'a PaddedBytes,
reference: &'a PaddedBytes,
matrix: &'a M,
gaps: Gaps,
size: RangeInclusive<usize>,
x_drop: i32
) -> Self
pub fn align(
query: &'a PaddedBytes,
reference: &'a PaddedBytes,
matrix: &'a M,
gaps: Gaps,
size: RangeInclusive<usize>,
x_drop: i32
) -> SelfAlign two strings with block aligner.
If TRACE is true, then information for computing the traceback will be stored.
After alignment, the traceback CIGAR string can then be computed.
This will slow down alignment and use a lot more memory.
If X_DROP is true, then the alignment process will be terminated early when
the max score in the current block drops by x_drop below the max score encountered
so far. If X_DROP is false, then global alignment is done.
Since larger scores are better, gap and mismatches penalties should be negative.
The minimum and maximum sizes of the block must be powers of 2 that are greater than the number of 16-bit lanes in a SIMD vector.
The block aligner algorithm will dynamically shift a block down or right and grow its size to efficiently calculate the alignment between two strings. This is fast, but it may be slightly less accurate than computing the entire the alignment dynamic programming matrix. Growing the size of the block allows larger gaps and other potentially difficult regions to be handled correctly. 16-bit deltas and 32-bit offsets are used to ensure that accurate scores are computed, even when the the strings are long.
Get the resulting score and ending location of the alignment.
Auto Trait Implementations
impl<'a, M, const TRACE: bool, const X_DROP: bool> RefUnwindSafe for Block<'a, M, TRACE, X_DROP> where
M: RefUnwindSafe, impl<'a, M, const TRACE: bool, const X_DROP: bool> Send for Block<'a, M, TRACE, X_DROP> where
M: Sync, impl<'a, M, const TRACE: bool, const X_DROP: bool> Sync for Block<'a, M, TRACE, X_DROP> where
M: Sync, impl<'a, M, const TRACE: bool, const X_DROP: bool> UnwindSafe for Block<'a, M, TRACE, X_DROP> where
M: RefUnwindSafe,