tesseract
5.0.0-alpha-619-ge9db
|
#include <intmatcher.h>
Public Member Functions | |
IntegerMatcher (tesseract::IntParam *classify_debug_level) | |
void | Match (INT_CLASS ClassTemplate, BIT_VECTOR ProtoMask, BIT_VECTOR ConfigMask, int16_t NumFeatures, const INT_FEATURE_STRUCT *Features, tesseract::UnicharRating *Result, int AdaptFeatureThreshold, int Debug, bool SeparateDebugWindows) |
float | ApplyCNCorrection (float rating, int blob_length, int normalization_factor, int matcher_multiplier) |
int | FindGoodProtos (INT_CLASS ClassTemplate, BIT_VECTOR ProtoMask, BIT_VECTOR ConfigMask, int16_t NumFeatures, INT_FEATURE_ARRAY Features, PROTO_ID *ProtoArray, int AdaptProtoThreshold, int Debug) |
int | FindBadFeatures (INT_CLASS ClassTemplate, BIT_VECTOR ProtoMask, BIT_VECTOR ConfigMask, int16_t NumFeatures, INT_FEATURE_ARRAY Features, FEATURE_ID *FeatureArray, int AdaptFeatureThreshold, int Debug) |
Static Public Attributes | |
static const int | kIntThetaFudge = 128 |
static const int | kEvidenceTableBits = 9 |
static const int | kIntEvidenceTruncBits = 14 |
static const float | kSEExponentialMultiplier = 0.0f |
static const float | kSimilarityCenter = 0.0075f |
Definition at line 70 of file intmatcher.h.
IntegerMatcher::IntegerMatcher | ( | tesseract::IntParam * | classify_debug_level | ) |
Definition at line 708 of file intmatcher.cpp.
float IntegerMatcher::ApplyCNCorrection | ( | float | rating, |
int | blob_length, | ||
int | normalization_factor, | ||
int | matcher_multiplier | ||
) |
Applies the CN normalization factor to the given rating and returns the modified rating.
Definition at line 1223 of file intmatcher.cpp.
int IntegerMatcher::FindBadFeatures | ( | INT_CLASS | ClassTemplate, |
BIT_VECTOR | ProtoMask, | ||
BIT_VECTOR | ConfigMask, | ||
int16_t | NumFeatures, | ||
INT_FEATURE_ARRAY | Features, | ||
FEATURE_ID * | FeatureArray, | ||
int | AdaptFeatureThreshold, | ||
int | Debug | ||
) |
FindBadFeatures finds all features with maximum feature-evidence < AdaptFeatureThresh. The list is ordered by increasing feature number.
ClassTemplate | Prototypes & tables for a class |
ProtoMask | AND Mask for proto word |
ConfigMask | AND Mask for config word |
NumFeatures | Number of features in blob |
Features | Array of features |
FeatureArray | Array of bad features |
AdaptFeatureThreshold | Threshold for bad features |
Debug | Debugger flag: 1=debugger on |
Definition at line 656 of file intmatcher.cpp.
int IntegerMatcher::FindGoodProtos | ( | INT_CLASS | ClassTemplate, |
BIT_VECTOR | ProtoMask, | ||
BIT_VECTOR | ConfigMask, | ||
int16_t | NumFeatures, | ||
INT_FEATURE_ARRAY | Features, | ||
PROTO_ID * | ProtoArray, | ||
int | AdaptProtoThreshold, | ||
int | Debug | ||
) |
FindGoodProtos finds all protos whose normalized proto-evidence exceed AdaptProtoThreshold. The list is ordered by increasing proto id number.
Globals:
Definition at line 588 of file intmatcher.cpp.
void IntegerMatcher::Match | ( | INT_CLASS | ClassTemplate, |
BIT_VECTOR | ProtoMask, | ||
BIT_VECTOR | ConfigMask, | ||
int16_t | NumFeatures, | ||
const INT_FEATURE_STRUCT * | Features, | ||
tesseract::UnicharRating * | Result, | ||
int | AdaptFeatureThreshold, | ||
int | Debug, | ||
bool | SeparateDebugWindows | ||
) |
IntegerMatcher returns the best configuration and rating for a single class. The class matched against is determined by the uniqueness of the ClassTemplate parameter. The best rating and its associated configuration are returned.
Globals:
Definition at line 510 of file intmatcher.cpp.
|
static |
Definition at line 75 of file intmatcher.h.
|
static |
Definition at line 77 of file intmatcher.h.
|
static |
Definition at line 73 of file intmatcher.h.
|
static |
Definition at line 79 of file intmatcher.h.
|
static |
Definition at line 81 of file intmatcher.h.