SeqAn3 3.4.0-rc.1
The Modern C++ library for sequence analysis.
|
The underlying data structure of seqan3::detail::edit_distance_unbanded that represents the score matrix. More...
#include <seqan3/alignment/matrix/detail/edit_distance_score_matrix_full.hpp>
Classes | |
struct | column_type |
The state of one computation step. More... | |
struct | max_errors_state |
If use_max_errors is true store these additional state information in state_type. More... | |
struct | score_matrix_state |
This information is needed to infer the score matrix. More... | |
Public Types | |
using | reference = value_type |
The type of a reference to an entry in the matrix. | |
using | score_type = score_t |
The type of the score. | |
using | size_type = size_t |
The size type of the matrix. | |
using | value_type = std::conditional_t< use_max_errors, std::optional< score_type >, score_type > |
The type of an entry in the matrix. | |
using | word_type = word_t |
The type of one machine word. | |
Public Member Functions | |
reference | at (matrix_coordinate const &coordinate) const noexcept |
A reference to the entry of the matrix at the given coordinate. | |
size_t | cols () const noexcept |
The number of columns in the matrix. | |
void | reserve (size_t const new_capacity) |
Increase the capacity of the columns to a value that is greater or equal to new_capacity . | |
size_t | rows () const noexcept |
The number of rows in the matrix. | |
Static Public Member Functions | |
template<typename score_type > | |
static size_t | max_rows (word_type const score_mask, unsigned const last_block, score_type const score, score_type const max_errors) noexcept |
Computes the number of max rows in the current column. | |
static score_type | score_delta_of_word (word_type const &vp, word_type const &vn) noexcept |
Computes delta score between vp and vn . | |
Static Public Attributes | |
static constexpr std::optional< score_type > | inf = std::nullopt |
A special score which represents infinity. | |
static constexpr auto | word_size = bits_of<word_type> |
The size of one machine word. | |
Protected Member Functions | |
void | add_column (std::vector< word_type > vp, std::vector< word_type > vn) |
Adds a column to the score matrix. | |
void | add_column (std::vector< word_type > vp, std::vector< word_type > vn, size_t const max_rows) |
Adds a column to the score matrix. | |
Private Attributes | |
std::vector< column_type > | columns {} |
The columns of the score matrix. | |
size_t | rows_size {} |
The number of rows in the matrix. | |
Constructors, destructor and assignment | |
template<typename derived_t , typename edit_traits > | |
class | edit_distance_unbanded_score_matrix_policy |
Allow seqan3::detail::edit_distance_unbanded_score_matrix_policy to access the private constructor. | |
edit_distance_score_matrix_full ()=default | |
Defaulted. | |
edit_distance_score_matrix_full (edit_distance_score_matrix_full const &)=default | |
Defaulted. | |
edit_distance_score_matrix_full (edit_distance_score_matrix_full &&)=default | |
Defaulted. | |
edit_distance_score_matrix_full & | operator= (edit_distance_score_matrix_full const &)=default |
Defaulted. | |
edit_distance_score_matrix_full & | operator= (edit_distance_score_matrix_full &&)=default |
Defaulted. | |
~edit_distance_score_matrix_full ()=default | |
Defaulted. | |
edit_distance_score_matrix_full (size_t const rows_size) | |
Construct the score_matrix by giving the number of rows within the matrix. | |
The underlying data structure of seqan3::detail::edit_distance_unbanded that represents the score matrix.
word_t | The type of one machine word. |
score_t | The type of the score. |
is_semi_global | Whether the alignment is a semi-global alignment or not. |
use_max_errors | When true the computation will use the ukkonen trick with the last active cell and bounds the error to config.max_errors. |
using seqan3::detail::edit_distance_score_matrix_full< word_t, score_t, is_semi_global, use_max_errors >::reference = value_type |
The type of a reference to an entry in the matrix.
using seqan3::detail::edit_distance_score_matrix_full< word_t, score_t, is_semi_global, use_max_errors >::score_type = score_t |
The type of the score.
using seqan3::detail::edit_distance_score_matrix_full< word_t, score_t, is_semi_global, use_max_errors >::size_type = size_t |
The size type of the matrix.
using seqan3::detail::edit_distance_score_matrix_full< word_t, score_t, is_semi_global, use_max_errors >::value_type = std::conditional_t<use_max_errors, std::optional<score_type>, score_type> |
The type of an entry in the matrix.
using seqan3::detail::edit_distance_score_matrix_full< word_t, score_t, is_semi_global, use_max_errors >::word_type = word_t |
The type of one machine word.
|
inlineprotected |
Construct the score_matrix by giving the number of rows within the matrix.
rows_size | The number of rows in the matrix. |
|
inlineprotected |
Adds a column to the score matrix.
vp | The machine word which stores the positive vertical differences. |
vn | The machine word which stores the negative vertical differences. |
|
inlineprotected |
Adds a column to the score matrix.
vp | The machine word which stores the positive vertical differences. |
vn | The machine word which stores the negative vertical differences. |
max_rows | The number of max_rows within the current column. Computed by seqan3::detail::edit_distance_score_matrix_full::max_rows. |
|
inlinenoexcept |
A reference to the entry of the matrix at the given coordinate.
|
inlinenoexcept |
The number of columns in the matrix.
|
inlinestaticnoexcept |
Computes the number of max rows in the current column.
score_type | The type of the score. |
score_mask | The mask with a bit set at the position where the score change. |
last_block | The block containing the last active cell. |
score | The score of the current column. |
max_errors | Which score value is considered as a hit? |
|
inline |
Increase the capacity of the columns to a value that is greater or equal to new_capacity
.
new_capacity | The new capacity. |
Strong exception guarantee.
|
inlinenoexcept |
The number of rows in the matrix.
|
inlinestaticnoexcept |
Computes delta score between vp
and vn
.
vp | The machine word which stores the positive vertical differences. |
vn | The machine word which stores the negative vertical differences. |
|
private |
The number of rows in the matrix.
|
staticconstexpr |
The size of one machine word.