kaori
A C++ library for barcode extraction and matching
|
#include <BarcodeSearch.hpp>
Public Attributes | |
BarcodeIndex | index = 0 |
int | mismatches = 0 |
std::array< int, num_segments_ > | per_segment |
State of the search.
This contains both the results of search()
for any given input sequence, as well as cached mismatches to optimize searches for future inputs.
BarcodeIndex kaori::SegmentedBarcodeSearch< num_segments_ >::State::index = 0 |
Index of the known sequence that matches best to the input sequence in search()
(i.e., fewest total mismatches). If all barcodes have more mismatches than allowed_mismatches
, STATUS_UNMATCHED
is returned. If multiple barcodes share the same lowest number of mismatches (not greater than allowed_mismatches
), STATUS_AMBIGUOUS
is returned.
int kaori::SegmentedBarcodeSearch< num_segments_ >::State::mismatches = 0 |
Total number of mismatches with the matching known sequence, summed across all segments. This should be ignored if index == STATUS_UNMATCHED
, as the search will terminate early without computing the exact number of mismatches if allowed_mismatches
is exceeded.
std::array<int, num_segments_> kaori::SegmentedBarcodeSearch< num_segments_ >::State::per_segment |
Number of mismatches in each segment. This should be ignored if index == STATUS_UNMATCHED
, as the search will terminate early without computing the exact number of mismatches if allowed_mismatches
is exceeded.