Provides configuration elements for the pairwise alignment configuration. More...
Classes | |
struct | seqan3::align_cfg::aligned_ends< end_gaps_t > |
The configuration for aligned sequence ends. More... | |
struct | seqan3::back_end_first< value_t > |
The penalty configuration for aligning the back of the first sequence with a gap. More... | |
struct | seqan3::back_end_second< value_t > |
The penalty configuration for aligning the back of the second sequence with a gap. More... | |
struct | seqan3::align_cfg::band< band_t > |
Configuration element for setting the band. More... | |
class | seqan3::end_gaps< ends_t > |
Wraps the sequence end-gap specifiers and provides ordered access to the respective values. More... | |
struct | seqan3::front_end_first< value_t > |
The penalty configuration for aligning the front of the first sequence with a gap. More... | |
struct | seqan3::front_end_second< value_t > |
The penalty configuration for aligning the front of the second sequence with a gap. More... | |
struct | seqan3::align_cfg::gap< gap_scheme_t > |
A configuration element for the gap scheme. More... | |
struct | seqan3::align_cfg::max_error |
Sets the maximal errors allowed during an edit distance computation. More... | |
struct | seqan3::align_cfg::mode< mode_type > |
Sets the alignment mode. More... | |
class | seqan3::align_cfg::result< alignment_result_tag_t, score_t > |
Sets the result of the alignment computation. More... | |
struct | seqan3::sequence_end_gap_specifier_base< value_t, _is_static, _value > |
A mixin class which can maintain a static or a dynamic bool state. More... | |
Typedefs | |
using | seqan3::align_cfg::parallel = seqan3::detail::parallel_mode< std::integral_constant< detail::align_config_id, detail::align_config_id::parallel > > |
Enables the parallel execution of the alignment algorithm if possible for the given configuration. More... | |
Variables | |
constexpr configuration | seqan3::align_cfg::edit |
Shortcut for edit distance configuration. More... | |
constexpr detail::global_alignment_type | seqan3::global_alignment |
Helper variable to select the global alignment. More... | |
constexpr detail::local_alignment_type | seqan3::local_alignment |
Helper variable to select the local alignment. More... | |
constexpr detail::vectorise_tag | seqan3::align_cfg::vectorise {} |
Enables the vectorised alignment computation if possible for the current configuration. More... | |
Provides configuration elements for the pairwise alignment configuration.
using seqan3::align_cfg::parallel = typedef seqan3::detail::parallel_mode<std::integral_constant<detail::align_config_id, detail::align_config_id::parallel> > |
Enables the parallel execution of the alignment algorithm if possible for the given configuration.
With this configuration you can enable the parallel execution of the pairwise sequence alignment. This means that for a batch of pairwise sequence alignments the specified number of threads will be spawned to compute them in parallel. Note that only independent alignment computations can be executed in parallel, i.e. you use this method when computing a batch of alignments rather than executing them separately. Depending on your processor architecture you can gain a significant speed-up.
The value represents the number of threads to be used and must be greater than 0
.
|
inlineconstexpr |
Shortcut for edit distance configuration.
The edit distance computation is a specific sub-problem of the alignment computation with the aim to count the number of edits to transform one sequence into another. An edit operation can be a substitution, an insertion, or a deletion. Accordingly, this algorithm uses a predefined scoring scheme as well as a gap scheme, where the score for a match is 0, for a mismatch -1, for a gap -1, and for a gap open 0.
Under the hood SeqAn uses a fast bit-vector algorithm to compute the edit distance whenever possible. This depends on the final alignment configuration. Currently, the fast edit distance algorithm is only triggered for global alignments and semi-global alignments with free ends in the first sequence.
The performance of the algorithm can further be improved if the number of maximal errors (edits) is known by using the align_cfg::max_error configuration.
cfg_slow
in the above example will trigger the slower algorithm which can handle the case if the ends are free in the second sequence instead of the first sequence.
|
inlineconstexpr |
Helper variable to select the global alignment.
|
inlineconstexpr |
Helper variable to select the local alignment.
|
inlineconstexpr |
Enables the vectorised alignment computation if possible for the current configuration.
In the vectorised alignment computation several pairwise sequence alignments are processed simultaneously in one invocation. To do so, we pack the alignments in so called extended SIMD registers which allow to compute a single instruction on multiple data at the same time. Depending on your processor architecture you can gain a significant speed-up, e.g. by running up to 64 alignments in parallel on the latest intel CPUs. In our mode we vectorise multiple alignments and not a single alignment. This means that you should provide many sequences to compute as one batch rather than computing them separately as there won't be performance gains.