/// Create new aligner instance with scoring and size hint. The size hints help to
/// avoid unnecessary memory allocations.
///
/// # Arguments
///
/// * `m` - the expected size of x
/// * `n` - the expected size of y
/// * `scoring` - the scoring struct
Create new aligner instance with scoring and size hint. The size hints help to
avoid unnecessary memory allocations.
Create new aligner instance with scoring and size hint . The size hints help to avoid unnecessary memory allocations .
pub fn with_capacity_and_scoring(m: usize, n: usize, scoring: Scoring<F>) -> Self {
        assert!(scoring.gap_open <= 0, "gap_open can't be positive");
        assert!(scoring.gap_extend <= 0, "gap_extend can't be positive");
        assert!(
            scoring.xclip_prefix <= 0,
            "Clipping penalty (x prefix) can't be positive"
        );
        assert!(
            scoring.xclip_suffix <= 0,
            "Clipping penalty (x suffix) can't be positive"
        );
        assert!(
            scoring.yclip_prefix <= 0,
            "Clipping penalty (y prefix) can't be positive"
        );
        assert!(
            scoring.yclip_suffix <= 0,
            "Clipping penalty (y suffix) can't be positive"
        );
        Aligner {
            I: [Vec::with_capacity(m + 1), Vec::with_capacity(m + 1)],
            D: [Vec::with_capacity(m + 1), Vec::with_capacity(m + 1)],
            S: [Vec::with_capacity(m + 1), Vec::with_capacity(m + 1)],
            Lx: Vec::with_capacity(n + 1),
            Ly: Vec::with_capacity(m + 1),
            Sn: Vec::with_capacity(m + 1),
            traceback: Traceback::with_capacity(m, n),
            scoring,
        }
    }
pub fn with_capacity_and_scoring ( m : usize , n : usize , scoring : Scoring < F > ) -> Self { assert ! ( scoring gap_open 0 " " ) ; assert ! ( scoring gap_extend 0 " " ) ; assert ! ( scoring xclip_prefix 0 " " ) ; assert ! ( scoring xclip_suffix 0 " " ) ; assert ! ( scoring yclip_prefix 0 " " ) ; assert ! ( scoring yclip_suffix 0 " " ) ; Aligner { I : [ Vec :: with_capacity ( m + 1 ) , Vec :: with_capacity ( m + 1 ) ] , D : [ Vec :: with_capacity ( m + 1 ) , Vec :: with_capacity ( m + 1 ) ] , S : [ Vec :: with_capacity ( m + 1 ) , Vec :: with_capacity ( m + 1 ) ] , Lx : Vec :: with_capacity ( n + 1 ) , Ly : Vec :: with_capacity ( m + 1 ) , Sn : Vec :: with_capacity ( m + 1 ) , traceback : Traceback :: with_capacity ( m , n ) , scoring , } }
Create new aligner instance with scoring and size hint.
Create new aligner instance with scoring and size hint .
m
usize
n
usize
scoring
Scoring<F>