#include "params.h"
#include "pageres.h"
Go to the source code of this file.
◆ compute_reject_threshold()
Definition at line 226 of file reject.cpp.
228 float bestgap = 0.0f;
231 BLOB_CHOICE_IT choice_it;
233 int blob_count = word->
length();
236 for (
int i = 0; i < blob_count; ++i) {
240 gapstart = ratings[0] - 1;
241 if (blob_count >= 3) {
242 for (
int index = 0; index < blob_count - 1; index++) {
243 if (ratings[index + 1] - ratings[index] > bestgap) {
244 bestgap = ratings[index + 1] - ratings[index];
246 gapstart = ratings[index];
250 threshold = gapstart + bestgap / 2;
void resize_no_init(int size)
◆ dont_allow_1Il()
◆ flip_0O()
◆ flip_hyphens()
◆ non_0_digit()
BOOL8 non_0_digit |
( |
const char * |
str, |
|
|
int |
length |
|
) |
| |
◆ reject_blanks()
Definition at line 178 of file reject.cpp.
const STRING & unichar_string() const
WERD_CHOICE * best_choice
const STRING & unichar_lengths() const
◆ reject_poor_matches()
void reject_poor_matches |
( |
WERD_RES * |
word | ) |
|
Definition at line 207 of file reject.cpp.
UNICHAR_ID unichar_id(int index) const
float compute_reject_threshold(WERD_CHOICE *word)
WERD_CHOICE * best_choice
◆ word_contains_non_1_digit()
BOOL8 word_contains_non_1_digit |
( |
const char * |
word, |
|
|
const char * |
word_lengths |
|
) |
| |